Test for the binary-io module.
[pspp] / ChangeLog
1 2007-01-14  Bruno Haible  <bruno@clisp.org>
2
3         * modules/binary-io-tests: New file.
4         * tests/test-binary-io.sh: New file.
5         * tests/test-binary-io.c: New file.
6
7 2007-01-14  Bruno Haible  <bruno@clisp.org>
8
9         * modules/array-oset-tests: New file.
10         * tests/test-array_oset.c: New file.
11
12 2007-01-14  Bruno Haible  <bruno@clisp.org>
13
14         * modules/array-list-tests: New file.
15         * tests/test-array_list.c: New file.
16
17 2007-01-14  Bruno Haible  <bruno@clisp.org>
18
19         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
20         and make.
21         Reported by Simon Josefsson in
22         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
23
24 2007-01-14  Bruno Haible  <bruno@clisp.org>
25
26         * modules/allocsa-tests: New file.
27         * tests/test-allocsa.c: New file.
28
29 2007-01-14  Bruno Haible  <bruno@clisp.org>
30
31         * modules/fchdir (Depends-on): Add absolute-header.
32         * modules/unistd (Depends-on): Likewise.
33
34 2006-12-30  Bruno Haible  <bruno@clisp.org>
35
36         * modules/fchdir: New file.
37         * modules/unistd (Files): Add lib/unistd_.h.
38         (Makefile.am): Generate unistd.h from unistd_.h.
39         * lib/fchdir.c: New file.
40         * lib/dirent_.h: New file.
41         * lib/unistd_.h: New file.
42         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
43         * m4/fchdir.m4: New file.
44         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
45         (gl_HEADER_UNISTD): Invoke it.
46         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
47         function.
48         * lib/backupfile.c (opendir, closedir): Undefine.
49         * lib/chown.c (open, close): Undefine.
50         * lib/clean-temp.c (open, close): Undefine.
51         * lib/copy-file.c (open, close): Undefine.
52         * lib/execute.c (open, close): Undefine.
53         * lib/fsusage.c (open, close): Undefine.
54         * lib/gc-gnulib.c (open, close): Undefine.
55         * lib/getcwd.c (opendir, closedir): Undefine.
56         * lib/glob.c (opendir, closedir): Undefine.
57         * lib/javacomp.c (open, close): Undefine.
58         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
59         * lib/openat-proc.c (open, close): Undefine.
60         * lib/pagealign_alloc.c (open, close): Undefine.
61         * lib/pipe.c (open, close): Undefine.
62         * lib/progreloc.c (open, close): Undefine.
63         * lib/savedir.c (opendir, closedir): Undefine.
64         * lib/utime.c (open, close): Undefine.
65         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
66
67 2007-01-10  Bruno Haible  <bruno@clisp.org>
68
69         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
70
71 2007-01-12  Eric Blake  <ebb9@byu.net>
72
73         Provide a robust <wchar.h>.  Further simplifications are now
74         possible in other modules, but not included here.
75         * modules/wchar: New module.
76         * m4/wchar.m4: New file.
77         * lib/wchar_.h: Likewise.
78         * modules/mbchar (Depends-on): Depend on wchar, as the first use
79         of the new module.
80         * MODULES.html.sh (Extended multibyte and wide character utilities):
81         New section.
82
83 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
84
85         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
86         to a reasonable default for memory allocation.
87         (xreadlink): Don't allocate a huge buffer, to work around a buggy
88         file system that reports garbage st_size values for symlinks.
89         Problem reported by Liyang Hu.
90
91 2007-01-11  Simon Josefsson  <simon@josefsson.org>
92
93         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
94         Emacs .#* auto-save files).
95
96 2007-01-11  Bruno Haible  <bruno@clisp.org>
97
98         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
99         directory.
100
101 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
102
103         Use @...@ consistently in lib/wctype_.h.
104         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
105         on it being set to 1 or 0.
106         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
107         go back to AC_SUBSTing it.
108         * modules/wctype (Makefile.am): Undo previous change.
109
110 2007-01-10  Eric Blake  <ebb9@byu.net>
111
112         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
113         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
114         * modules/wctype (Makefile.am): Likewise.
115         Reported by Chris McGuire.
116
117 2007-01-10  Jim Meyering  <jim@meyering.net>
118
119         fts.c: a small readability/maintainability improvement
120         * lib/fts.c (fts_read): Make this code slightly more readable and
121         maintainable by hoisting the "sp->fts_cur = p" assignments to
122         immediately follow the statements that set P.  Derived from
123         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
124
125 2007-01-10  Eric Blake  <ebb9@byu.net>
126
127         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
128         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
129         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
130         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
131         Reported by Chris McGuire.
132
133 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
134
135         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
136         in sed script.
137
138 2007-01-09  Bruno Haible  <bruno@clisp.org>
139
140         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
141         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
142         variables.
143         (func_module): Use them.
144
145 2007-01-09  Bruno Haible  <bruno@clisp.org>
146
147         * modules/unistr/base: New file.
148         * lib/unistr.h: New file.
149
150         * modules/unistr/u8-to-u16: New file.
151         * lib/unistr/u8-to-u16.c: New file.
152
153         * modules/unistr/u8-to-u32: New file.
154         * lib/unistr/u8-to-u32.c: New file.
155
156         * modules/unistr/u16-to-u8: New file.
157         * lib/unistr/u16-to-u8.c: New file.
158
159         * modules/unistr/u16-to-u32: New file.
160         * lib/unistr/u16-to-u32.c: New file.
161
162         * modules/unistr/u32-to-u8: New file.
163         * lib/unistr/u32-to-u8.c: New file.
164
165         * modules/unistr/u32-to-u16: New file.
166         * lib/unistr/u32-to-u16.c: New file.
167
168         * modules/unistr/u8-check: New file.
169         * modules/unistr/u16-check: New file.
170         * modules/unistr/u32-check: New file.
171         * lib/unistr/u8-check.c: New file.
172         * lib/unistr/u16-check.c: New file.
173         * lib/unistr/u32-check.c: New file.
174
175         * modules/unistr/u8-chr: New file.
176         * modules/unistr/u16-chr: New file.
177         * modules/unistr/u32-chr: New file.
178         * lib/unistr/u8-chr.c: New file.
179         * lib/unistr/u16-chr.c: New file.
180         * lib/unistr/u32-chr.c: New file.
181
182         * modules/unistr/u8-cmp: New file.
183         * modules/unistr/u16-cmp: New file.
184         * modules/unistr/u32-cmp: New file.
185         * lib/unistr/u8-cmp.c: New file.
186         * lib/unistr/u16-cmp.c: New file.
187         * lib/unistr/u32-cmp.c: New file.
188
189         * modules/unistr/u8-cpy: New file.
190         * modules/unistr/u16-cpy: New file.
191         * modules/unistr/u32-cpy: New file.
192         * lib/unistr/u8-cpy.c: New file.
193         * lib/unistr/u16-cpy.c: New file.
194         * lib/unistr/u32-cpy.c: New file.
195         * lib/unistr/u-cpy.h: New file.
196
197         * modules/unistr/u8-cpy-alloc: New file.
198         * modules/unistr/u16-cpy-alloc: New file.
199         * modules/unistr/u32-cpy-alloc: New file.
200         * lib/unistr/u8-cpy-alloc.c: New file.
201         * lib/unistr/u16-cpy-alloc.c: New file.
202         * lib/unistr/u32-cpy-alloc.c: New file.
203         * lib/unistr/u-cpy-alloc.h: New file.
204
205         * modules/unistr/u8-endswith: New file.
206         * modules/unistr/u16-endswith: New file.
207         * modules/unistr/u32-endswith: New file.
208         * lib/unistr/u8-endswith.c: New file.
209         * lib/unistr/u16-endswith.c: New file.
210         * lib/unistr/u32-endswith.c: New file.
211         * lib/unistr/u-endswith.h: New file.
212
213         * modules/unistr/u8-mblen: New file.
214         * modules/unistr/u16-mblen: New file.
215         * modules/unistr/u32-mblen: New file.
216         * lib/unistr/u8-mblen.c: New file.
217         * lib/unistr/u16-mblen.c: New file.
218         * lib/unistr/u32-mblen.c: New file.
219
220         * modules/unistr/u8-mbtouc: New file.
221         * modules/unistr/u16-mbtouc: New file.
222         * modules/unistr/u32-mbtouc: New file.
223         * lib/unistr/u8-mbtouc.c: New file.
224         * lib/unistr/u16-mbtouc.c: New file.
225         * lib/unistr/u32-mbtouc.c: New file.
226
227         * modules/unistr/u8-mbtouc-safe: New file.
228         * modules/unistr/u16-mbtouc-safe: New file.
229         * modules/unistr/u32-mbtouc-safe: New file.
230         * lib/unistr/u8-mbtouc-safe.c: New file.
231         * lib/unistr/u16-mbtouc-safe.c: New file.
232         * lib/unistr/u32-mbtouc-safe.c: New file.
233
234         * modules/unistr/u8-move: New file.
235         * modules/unistr/u16-move: New file.
236         * modules/unistr/u32-move: New file.
237         * lib/unistr/u8-move.c: New file.
238         * lib/unistr/u16-move.c: New file.
239         * lib/unistr/u32-move.c: New file.
240         * lib/unistr/u-move.h: New file.
241
242         * modules/unistr/u8-next: New file.
243         * modules/unistr/u16-next: New file.
244         * modules/unistr/u32-next: New file.
245         * lib/unistr/u8-next.c: New file.
246         * lib/unistr/u16-next.c: New file.
247         * lib/unistr/u32-next.c: New file.
248
249         * modules/unistr/u8-prev: New file.
250         * modules/unistr/u16-prev: New file.
251         * modules/unistr/u32-prev: New file.
252         * lib/unistr/u8-prev.c: New file.
253         * lib/unistr/u16-prev.c: New file.
254         * lib/unistr/u32-prev.c: New file.
255
256         * modules/unistr/u8-set: New file.
257         * modules/unistr/u16-set: New file.
258         * modules/unistr/u32-set: New file.
259         * lib/unistr/u8-set.c: New file.
260         * lib/unistr/u16-set.c: New file.
261         * lib/unistr/u32-set.c: New file.
262         * lib/unistr/u-set.h: New file.
263
264         * modules/unistr/u8-startswith: New file.
265         * modules/unistr/u16-startswith: New file.
266         * modules/unistr/u32-startswith: New file.
267         * lib/unistr/u8-startswith.c: New file.
268         * lib/unistr/u16-startswith.c: New file.
269         * lib/unistr/u32-startswith.c: New file.
270         * lib/unistr/u-startswith.h: New file.
271
272         * modules/unistr/u8-stpcpy: New file.
273         * modules/unistr/u16-stpcpy: New file.
274         * modules/unistr/u32-stpcpy: New file.
275         * lib/unistr/u8-stpcpy.c: New file.
276         * lib/unistr/u16-stpcpy.c: New file.
277         * lib/unistr/u32-stpcpy.c: New file.
278         * lib/unistr/u-stpcpy.h: New file.
279
280         * modules/unistr/u8-stpncpy: New file.
281         * modules/unistr/u16-stpncpy: New file.
282         * modules/unistr/u32-stpncpy: New file.
283         * lib/unistr/u8-stpncpy.c: New file.
284         * lib/unistr/u16-stpncpy.c: New file.
285         * lib/unistr/u32-stpncpy.c: New file.
286         * lib/unistr/u-stpncpy.h: New file.
287
288         * modules/unistr/u8-strcat: New file.
289         * modules/unistr/u16-strcat: New file.
290         * modules/unistr/u32-strcat: New file.
291         * lib/unistr/u8-strcat.c: New file.
292         * lib/unistr/u16-strcat.c: New file.
293         * lib/unistr/u32-strcat.c: New file.
294         * lib/unistr/u-strcat.h: New file.
295
296         * modules/unistr/u8-strchr: New file.
297         * modules/unistr/u16-strchr: New file.
298         * modules/unistr/u32-strchr: New file.
299         * lib/unistr/u8-strchr.c: New file.
300         * lib/unistr/u16-strchr.c: New file.
301         * lib/unistr/u32-strchr.c: New file.
302
303         * modules/unistr/u8-strcmp: New file.
304         * modules/unistr/u16-strcmp: New file.
305         * modules/unistr/u32-strcmp: New file.
306         * lib/unistr/u8-strcmp.c: New file.
307         * lib/unistr/u16-strcmp.c: New file.
308         * lib/unistr/u32-strcmp.c: New file.
309
310         * modules/unistr/u8-strcpy: New file.
311         * modules/unistr/u16-strcpy: New file.
312         * modules/unistr/u32-strcpy: New file.
313         * lib/unistr/u8-strcpy.c: New file.
314         * lib/unistr/u16-strcpy.c: New file.
315         * lib/unistr/u32-strcpy.c: New file.
316         * lib/unistr/u-strcpy.h: New file.
317
318         * modules/unistr/u8-strcspn: New file.
319         * modules/unistr/u16-strcspn: New file.
320         * modules/unistr/u32-strcspn: New file.
321         * lib/unistr/u8-strcspn.c: New file.
322         * lib/unistr/u16-strcspn.c: New file.
323         * lib/unistr/u32-strcspn.c: New file.
324         * lib/unistr/u-strcspn.h: New file.
325
326         * modules/unistr/u8-strdup: New file.
327         * modules/unistr/u16-strdup: New file.
328         * modules/unistr/u32-strdup: New file.
329         * lib/unistr/u8-strdup.c: New file.
330         * lib/unistr/u16-strdup.c: New file.
331         * lib/unistr/u32-strdup.c: New file.
332         * lib/unistr/u-strdup.h: New file.
333
334         * modules/unistr/u8-strlen: New file.
335         * modules/unistr/u16-strlen: New file.
336         * modules/unistr/u32-strlen: New file.
337         * lib/unistr/u8-strlen.c: New file.
338         * lib/unistr/u16-strlen.c: New file.
339         * lib/unistr/u32-strlen.c: New file.
340         * lib/unistr/u-strlen.h: New file.
341
342         * modules/unistr/u8-strmblen: New file.
343         * modules/unistr/u16-strmblen: New file.
344         * modules/unistr/u32-strmblen: New file.
345         * lib/unistr/u8-strmblen.c: New file.
346         * lib/unistr/u16-strmblen.c: New file.
347         * lib/unistr/u32-strmblen.c: New file.
348
349         * modules/unistr/u8-strmbtouc: New file.
350         * modules/unistr/u16-strmbtouc: New file.
351         * modules/unistr/u32-strmbtouc: New file.
352         * lib/unistr/u8-strmbtouc.c: New file.
353         * lib/unistr/u16-strmbtouc.c: New file.
354         * lib/unistr/u32-strmbtouc.c: New file.
355
356         * modules/unistr/u8-strncat: New file.
357         * modules/unistr/u16-strncat: New file.
358         * modules/unistr/u32-strncat: New file.
359         * lib/unistr/u8-strncat.c: New file.
360         * lib/unistr/u16-strncat.c: New file.
361         * lib/unistr/u32-strncat.c: New file.
362         * lib/unistr/u-strncat.h: New file.
363
364         * modules/unistr/u8-strncmp: New file.
365         * modules/unistr/u16-strncmp: New file.
366         * modules/unistr/u32-strncmp: New file.
367         * lib/unistr/u8-strncmp.c: New file.
368         * lib/unistr/u16-strncmp.c: New file.
369         * lib/unistr/u32-strncmp.c: New file.
370
371         * modules/unistr/u8-strncpy: New file.
372         * modules/unistr/u16-strncpy: New file.
373         * modules/unistr/u32-strncpy: New file.
374         * lib/unistr/u8-strncpy.c: New file.
375         * lib/unistr/u16-strncpy.c: New file.
376         * lib/unistr/u32-strncpy.c: New file.
377         * lib/unistr/u-strncpy.h: New file.
378
379         * modules/unistr/u8-strnlen: New file.
380         * modules/unistr/u16-strnlen: New file.
381         * modules/unistr/u32-strnlen: New file.
382         * lib/unistr/u8-strnlen.c: New file.
383         * lib/unistr/u16-strnlen.c: New file.
384         * lib/unistr/u32-strnlen.c: New file.
385         * lib/unistr/u-strnlen.h: New file.
386
387         * modules/unistr/u8-strpbrk: New file.
388         * modules/unistr/u16-strpbrk: New file.
389         * modules/unistr/u32-strpbrk: New file.
390         * lib/unistr/u8-strpbrk.c: New file.
391         * lib/unistr/u16-strpbrk.c: New file.
392         * lib/unistr/u32-strpbrk.c: New file.
393         * lib/unistr/u-strpbrk.h: New file.
394
395         * modules/unistr/u8-strrchr: New file.
396         * modules/unistr/u16-strrchr: New file.
397         * modules/unistr/u32-strrchr: New file.
398         * lib/unistr/u8-strrchr.c: New file.
399         * lib/unistr/u16-strrchr.c: New file.
400         * lib/unistr/u32-strrchr.c: New file.
401
402         * modules/unistr/u8-strspn: New file.
403         * modules/unistr/u16-strspn: New file.
404         * modules/unistr/u32-strspn: New file.
405         * lib/unistr/u8-strspn.c: New file.
406         * lib/unistr/u16-strspn.c: New file.
407         * lib/unistr/u32-strspn.c: New file.
408         * lib/unistr/u-strspn.h: New file.
409
410         * modules/unistr/u8-strstr: New file.
411         * modules/unistr/u16-strstr: New file.
412         * modules/unistr/u32-strstr: New file.
413         * lib/unistr/u8-strstr.c: New file.
414         * lib/unistr/u16-strstr.c: New file.
415         * lib/unistr/u32-strstr.c: New file.
416         * lib/unistr/u-strstr.h: New file.
417
418         * modules/unistr/u8-strtok: New file.
419         * modules/unistr/u16-strtok: New file.
420         * modules/unistr/u32-strtok: New file.
421         * lib/unistr/u8-strtok.c: New file.
422         * lib/unistr/u16-strtok.c: New file.
423         * lib/unistr/u32-strtok.c: New file.
424         * lib/unistr/u-strtok.h: New file.
425
426         * modules/unistr/u8-uctomb: New file.
427         * modules/unistr/u16-uctomb: New file.
428         * modules/unistr/u32-uctomb: New file.
429         * lib/unistr/u8-uctomb.c: New file.
430         * lib/unistr/u16-uctomb.c: New file.
431         * lib/unistr/u32-uctomb.c: New file.
432
433         * MODULES.html.sh (Unicode string functions): Add the new modules.
434
435 2007-01-08  Bruno Haible  <bruno@clisp.org>
436
437         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
438         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
439         subdirectories.
440
441 2007-01-08  Karl Berry  <karl@gnu.org>
442
443         * doc/error.texi: mention that main() fns must set program_name
444         when progname is used.
445
446 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
447
448         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
449         WCTYPE_H is empty, for the benefit of builds from non-distclean
450         directories.  Problem reported by Eric Blake in
451         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
452
453 2007-01-08  Bruno Haible  <bruno@clisp.org>
454
455         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
456         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
457         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
458         PROVIDE_CANONICALIZE_FILENAME_MODE.
459         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
460
461 2007-01-08  Bruno Haible  <bruno@clisp.org>
462
463         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
464         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
465         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
466         * lib/fts.c: Likewise.
467         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
468
469 2006-12-25  Bruno Haible  <bruno@clisp.org>
470
471         * modules/utf8-ucs4-safe: New file.
472         * lib/utf8-ucs4-safe.h: New file.
473         * lib/unistr/utf8-ucs4-safe.c: New file.
474
475         * modules/utf16-ucs4-safe: New file.
476         * lib/utf16-ucs4-safe.h: New file.
477         * lib/unistr/utf16-ucs4-safe.c: New file.
478
479         * MODULES.html.sh (Unicode string functions): Add the new modules.
480
481 2007-01-08  Bruno Haible  <bruno@clisp.org>
482
483         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
484         (Depends-on): Add unitypes.
485         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
486         (u8_mbtouc_aux): Move out to separate file.
487         (u8_mbtouc): Use ucs4_t, uint8_t types.
488         * lib/unistr/utf8-ucs4.c: New file.
489
490         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
491         (Depends-on): Add unitypes.
492         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
493         (u16_mbtouc_aux): Move out to separate file.
494         (u16_mbtouc): Use ucs4_t, uint16_t types.
495         * lib/unistr/utf16-ucs4.c: New file.
496
497         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
498         (Depends-on): Add unitypes.
499         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
500         (u8_uctomb_aux): Move out to separate file.
501         (u8_uctomb): Use ucs4_t, uint8_t types.
502         * lib/unistr/ucs4-utf8.c: New file.
503
504         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
505         (Depends-on): Add unitypes.
506         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
507         (u16_uctomb_aux): Move out to separate file.
508         (u16_uctomb): Use ucs4_t, uint16_t types.
509         * lib/unistr/ucs4-utf16.c: New file.
510
511 2006-12-25  Bruno Haible  <bruno@clisp.org>
512
513         * modules/unitypes: New file.
514         * lib/unitypes.h: New file.
515         * MODULES.html.sh (func_all_modules): New section "Unicode string
516         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
517         this section. Add unitypes.
518
519 2007-01-08  Bruno Haible  <bruno@clisp.org>
520
521         Avoid variable names that conflict with those from libtool.
522         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
523         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
524         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
525         library_names_spec to acl_library_names_spec, hardcode_* to
526         acl_hardcode_*.
527         Reported by Ralf Wildenhues.
528
529 2007-01-08  Bruno Haible  <bruno@clisp.org>
530
531         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
532         definition.
533         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
534         definition.
535         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
536         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
537         definition.
538         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
539         definition.
540         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
541         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
542         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
543         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
544         definition.
545         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
546         definition.
547         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
548         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
549         GC_USE_<algorithm>.
550         * lib/gc-libgcrypt.c: Likewise.
551         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
552         * modules/gc-arctwo (configure.ac): Likewise.
553         * modules/gc-des (configure.ac): Likewise.
554         * modules/gc-hmac-md5 (configure.ac): Likewise.
555         * modules/gc-hmac-sha1 (configure.ac): Likewise.
556         * modules/gc-md2 (configure.ac): Likewise.
557         * modules/gc-md4 (configure.ac): Likewise.
558         * modules/gc-md5 (configure.ac): Likewise.
559         * modules/gc-random (configure.ac): Likewise.
560         * modules/gc-rijndael (configure.ac): Likewise.
561         * modules/gc-sha1 (configure.ac): Likewise.
562
563 2007-01-08  Bruno Haible  <bruno@clisp.org>
564
565         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
566         macro definition.
567         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
568         definition.
569         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
570         definition.
571         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
572         * modules/fcntl-safer (configure.ac): Likewise.
573         * modules/fopen-safer (configure.ac): Likewise.
574         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
575         GNULIB_FWRITEERROR macro definition.
576
577 2007-01-08  Bruno Haible  <bruno@clisp.org>
578
579         * m4/gnulib-common.m4: New file.
580         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
581         (func_get_filelist): Add m4/gnulib-common.m4.
582
583 2007-01-08  Bruno Haible  <bruno@clisp.org>
584
585         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
586         command.
587
588 2007-01-08  Jim Meyering  <jim@meyering.net>
589
590         Use a more robust test for a "can't happen" condition.
591         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
592         narrowed the st_size value.  Presuming the "can't happen" condition
593         is true, that narrowing could conceivably convert an invalid st_size
594         value into a valid one.  Instead, use a change based on Matthew
595         Woehlke's original patch.
596
597         Slight readability improvement: use an assert-like macro
598         in place of literal "abort ()" uses.
599         * lib/fts.c (fts_assert): Define.
600         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
601         Use this macro instead of a bare 'abort'.
602
603 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
604
605         Don't worry about using IRIX 5.3's wctype.h broken definitions;
606         simply work around them.
607         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
608         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
609         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
610         Don't bother to define as macros, since the standard doesn't require it.
611         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
612         longer worry about IRIX 5.3.
613         (HAVE_WCTYPE_CTMP_BUG): Remove.
614
615 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
616
617         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
618         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
619         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
620         Problems reported by Georg Schwarz for IRIX 5.3.
621
622         * gnulib-tool (autoconf_minversion): Take the maximum version number
623         found, not the minimum.  Problem reported by James Youngman.
624
625 2007-01-03  Karl Berry  <karl@gnu.org>
626
627         * doc/error.texi: new file, explaining interaction with progname.
628         * doc/gnulib.texi: include it.  Update copyright.
629
630 2007-01-03  Simon Josefsson  <simon@josefsson.org>
631
632         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
633         AC_CANONICAL_HOST, to improve autobuild outputs.
634
635 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
636             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
637
638         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
639         sockets, server sockets, and other file descriptors.  Count errors
640         to compute the return value.  Reorder the code a bit to be easier
641         to follow.  Don't set event bits that were not requested (except
642         POLLERR and POLLHUP).
643
644 2007-01-01  Bruno Haible  <bruno@clisp.org>
645
646         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
647
648 2007-01-03  Jim Meyering  <jim@meyering.net>
649
650         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
651
652 2007-01-02  Bruno Haible  <bruno@clisp.org>
653
654         * modules/settime (Include): Require timespec.h.
655         * modules/nanosleep (Include): Likewise.
656
657 2007-01-01  Bruno Haible  <bruno@clisp.org>
658
659         * gnulib-tool (func_emit_copyright_notice): Bump year.
660         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
661
662 2007-01-01  Bruno Haible  <bruno@clisp.org>
663
664         Improve support for OpenBSD.
665         * build-aux/config.rpath (libname_spec): Export.
666         (library_names_spec): New variable. Export.
667         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
668         library_names_spec from the config.rpath output. Locate shared library
669         through the name pattern in library_names_spec.
670
671 2007-01-01  Eric Blake  <ebb9@byu.net>
672
673         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
674
675 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
676
677         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
678         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
679         assume the C locale, and avoid an "eval" that could cause trouble.
680         Problem with SORT reported by Bob Proulx.
681
682         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
683         Define.  Trivial patch from Henning Nielsen Lund, originally
684         sent to bug-grep@gnu.org today.
685
686 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
687
688         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
689         struct stat.  Problem reported by Henning Nielsen Lund.
690         * lib/acl.c: Include acl.h first, to check interface.  Don't
691         bother to include sys/types.h and sys/stat.h again.
692
693 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
694
695         Import the following change from libc; problem reported by
696         Sven Verdoolaege.
697
698         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
699
700         [BZ #1373]
701         * lib/argp.h: Remove __NTH for __argp_usage inline function.
702
703 2006-12-28  Jim Meyering  <jim@meyering.net>
704
705         * build-aux/announce-gen: Do not assume that the package
706         builds any of tar.gz, tar.bz2, and .xdelta files.
707         Suggestion from Simon Josefsson.
708
709 2006-12-28  Simon Josefsson  <simon@josefsson.org>
710
711         * modules/announce-gen: New file.
712
713 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
714
715         * lib/mbchar.h: Just include <wctype.h>; the wctype module
716         handles its gotchas now.
717         * lib/mbswidth.c: Likewise.
718         * lib/wcwidth.h: Likewise.
719         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
720         and iswcntrl; the wctype module does this stuff now.
721         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
722         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
723         * modules/mbchar (Depends-on): Add wctype.
724         * modules/mbswidth (Depends-on): Likewise.
725         * modules/wcwidth (Depends-on): Likewise.
726
727 2006-12-27  Eric Blake  <ebb9@byu.net>
728
729         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
730         module uses more than what <wctype.h> is required to provide.
731
732 2006-12-26  Eric Blake  <ebb9@byu.net>
733
734         * gnulib-tool (sed_extract_prog): Avoid space-tab.
735
736 2006-12-26  Eric Blake  <ebb9@byu.net>
737
738         * modules/absolute-header: New module.
739         * modules/fcntl (Depends-on): Depend on it.
740         * modules/inttypes (Depends-on): Likewise.
741         * modules/stdint (Depends-on): Likewise.
742         * modules/sys_stat (Depends-on): Likewise.
743         * modules/wctype (Depends-on): Likewise.
744         * MODULES.html.sh (Support for building libraries and
745         executables): Document it.
746
747 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
748
749         * gnulib-tool (SED): Remove, undoing previous change.
750         The problem was that it broke coreutils on Solaris, because
751         "sed --posix" leaked into a makefile.
752         (sed): New alias, if 'alias' and GNU sed.
753
754 2006-12-24  Jim Meyering  <jim@meyering.net>
755
756         Work around an fchownat bug in glibc-2.4:
757         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
758         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
759         in spite of the -P option.
760         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
761         New macros.
762         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
763         * modules/openat (Files): Add lib/fchownat.c.
764         * lib/openat.c (fchownat): Don't define here.  Move to...
765         * lib/fchownat.c: ...this new file.
766
767 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
768
769         Fix bug reported by Bruno Haible in
770         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
771         where quotearg.c didn't compile on Mac OS X 10.2 because it
772         lacks <wchar.h> and wint_t.
773         * lib/wctype_.h (__wctype_wint_t): New type.
774         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
775         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
776         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
777         Arg is now of type __wctype_wint_t, not wint_t.
778         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
779         substitute HAVE_WINT_T.
780         * modules/wctype (Files): Add m4/wint_t.m4.
781         (wctype.h): Substitute HAVE_WINT_T.
782
783 2006-12-23  Bruno Haible  <bruno@clisp.org>
784
785         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
786
787 2006-12-23  Bruno Haible  <bruno@clisp.org>
788
789         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
790         S_ISLNK.
791         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
792         mingw.
793
794 2006-12-22  Bruno Haible  <bruno@clisp.org>
795
796         * lib/copy-file.c: Include acl.h.
797         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
798         Close the file descriptors only after being done with copy_acl.
799         * modules/copy-file (Depends-on): Add acl.
800
801 2006-12-22  Bruno Haible  <bruno@clisp.org>
802
803         * gnulib-tool (SED): New variable.
804         Use $SED instead of sed everywhere.
805
806 2006-12-22  Bruno Haible  <bruno@clisp.org>
807
808         * modules/no-c++: New file.
809         * m4/no-c++.m4: New file.
810         * MODULES.html.sh (Support for building libraries and executables):
811         Add no-c++.
812
813 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
814
815         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
816         Include <limits.h>, and use its INT_MAX to rewrite the
817         j loop so that it does not overflow 'int'.  Problem reported by
818         Ralf Wildenhues in
819         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
820         Play it safe by shifting left by 1 rather than multiplying by 2,
821         as GCC is less likely to optimize this away when the value
822         is signed (when it assumes overflow leads to undefined behavior).
823         Also, don't assume time_t uses two's complement.
824
825 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
826
827         * MODULES.html.sh: New module wctype.
828         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
829         * lib/fnmatch.c: Don't bother to include <wchar.h> before
830         <wctype.h>, since the new wctype module should fix this.
831         * lib/quotearg.c: Include <wctype.h> unconditionally, since
832         the wctype module should arrange for it.
833         * lib/regex_internal.h: Likewise.
834         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
835         since the wctype module should handle this now.
836         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
837         * modules/fnmatch (Depends-on): Add wctype.
838         * modules/quotearg (Depends-on): Likewise.
839         * modules/regex (Depends-on): Likewise.
840
841 2006-12-19  Bruno Haible  <bruno@clisp.org>
842
843         * lib/strdup.h [C++]: Wrap definitions in extern "C".
844         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
845
846 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
847
848         * modules/savewd (Depends-on): Fix dependency on fcntl.
849
850 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
851
852         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
853         conforms to C99, rather than relying on the user's environment
854         setting of STDINT_H.
855
856 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
857         and Eric Blake  <ebb9@byu.net>
858
859         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
860         This is more consistent with the other defines here.
861         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
862         Port to z/OS.  Problem reported by Paul Gilmartin.
863         Change local vars to use gl_ prefix rather than ac_.
864         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
865         with other defines.
866         * modules/double-slash-root: New module.
867         * modules/dirname (Files): Remove m4/double-slash-root.m4.
868         (Depends-on): Add double-slash-root.
869         * MODULES.html.sh (File system functions): Mention new module.
870
871 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
872
873         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
874         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
875         This is for the benefit of gzip, which doesn't do i18n.
876
877 2006-12-12  Jim Meyering  <jim@meyering.net>
878
879         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
880         Reported by Andreas Schwab <schwab@suse.de>.
881
882 2006-12-12  Bruno Haible  <bruno@clisp.org>
883
884         Merge these changes.
885         2006-09-05  Bruno Haible  <bruno@clisp.org>
886         * lib/iconvme.c (iconv_string): No need to save and restore errno when
887         iconv_alloc succeeded.
888         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
889         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
890         test for " && dest " at the end - dest is always != NULL there. Call
891         iconv with 4xNULL arguments initially, to reset the state. Call iconv
892         with 2xNULL arguments, also to flush the state storage. Handle the
893         IRIX iconv behaviour. Realloc the final result, to throw away unused
894         memory.
895
896 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
897
898         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
899         and fchmodat unconditionally, since glibc 2.4 has them.
900         Problem reported by Arkadiusz Miskiewicz.
901
902 2006-12-10  Bruno Haible  <bruno@clisp.org>
903
904         * gnulib-tool (func_import): Show the include files only for those
905         modules that are copied and specified.
906         Reported by Karl Berry.
907
908 2006-12-08  Jim Meyering  <jim@meyering.net>
909
910         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
911         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
912
913         * build-aux/announce-gen: Add two new options, both optional:
914         --bootstrap-tools=TOOL_LIST
915               a comma-separated list of tools, e.g.,
916               autoconf,automake,bison,gnulib
917         --gnulib-snapshot-date=DATE
918               if gnulib is in the bootstrap tool list,
919               then report this as the snapshot date.
920               If not specified, use the current date/time.
921               If you specify a date here, be sure it's UTC.
922
923 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
924
925         * tests/test-argp-2.sh: Fix test to match actual output.
926         (func_compare): Fix sed script to be portable.
927
928 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
929
930         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
931         workaround for this case.  It is not autoconfigured now; offhand
932         it's hard to see how to autoconfigure it.
933
934 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
935
936         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
937         a directory that is about to be chowned.  Such a directory's
938         initial file permissions should permit the owner only and this
939         should not be changed until after the chown, since the group and
940         other bits would be incorrect if they granted permission before
941         the chown.
942
943         Fix porting problem for iswctype reported by Georg Schwarz in:
944         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
945         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
946         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
947         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
948         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
949
950 2006-12-03  Jim Meyering  <jim@meyering.net>
951
952         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
953         p->fts_statp may not yet be defined.
954         (fts_read): Instead, set it in the caller, once p->fts_statp is
955         sure to be defined, and corresponds to a top-level directory.
956         This bug made du -x fail.  Here's the coreutils test case:
957         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
958         Reported by Mike Frysinger.
959
960 2006-12-01  Jim Meyering  <jim@meyering.net>
961
962         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
963         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
964         Reported by Simon Josefsson.
965
966 2006-11-30  Jim Meyering  <jim@meyering.net>
967
968         * m4/warning.m4: Use the all-permissive copyright notice
969         recommended by RMS (rather than LGPL).
970         * m4/vararrays.m4: Likewise.
971         * m4/flexmember.m4: Likewise.
972
973 2006-11-29  Bruno Haible  <bruno@clisp.org>
974
975         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
976         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
977         using +=.
978         Reported by Simon Josefsson <simon@josefsson.org>.
979
980 2006-11-28  James Youngman <jay@gnu.org>
981
982         * README: Advise users that they might find the bug-gnulib@gnu.org
983         and autotools-announce@gnu.org mailing lists useful.
984
985 2006-11-28  Bruno Haible  <bruno@clisp.org>
986
987         * m4/ptrdiff_max.m4: Remove file.
988
989 2006-11-21  Bruno Haible  <bruno@clisp.org>
990
991         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
992         _AC_COMPUTE_INT.
993         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
994         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
995         _AC_COMPUTE_INT.
996         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
997         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
998         _AC_COMPUTE_INT.
999         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1000
1001 2006-11-28  Jim Meyering  <jim@meyering.net>
1002
1003         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
1004         warning from "gcc -Wshadow" about shadowing the builtin.
1005
1006 2006-11-27  Bruno Haible  <bruno@clisp.org>
1007
1008         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
1009         _AC_COMPUTE_INT.
1010         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1011
1012 2006-11-27  Bruno Haible  <bruno@clisp.org>
1013             Paul Eggert  <eggert@cs.ucla.edu>
1014
1015         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
1016
1017 2006-11-26  Bruno Haible  <bruno@clisp.org>
1018
1019         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1020         noinst_LTLIBRARIES.
1021
1022 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
1023             Bruno Haible  <bruno@clisp.org>
1024
1025         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
1026         if compiling with "gcc -ansi".
1027
1028 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
1029
1030         Fix some incompatibilities with gcc -ansi -pedantic.
1031         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
1032         if compiling pedantically with GCC, unless it's C99 or later.
1033         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
1034         it mishandles gcc -ansi -pedantic as well.
1035         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
1036         if gcc -pedantic.
1037         * lib/regexec.c (check_node_accept_bytes): Don't use auto
1038         initializers for struct if -pedantic, unless it's C99 or later.
1039
1040 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
1041
1042         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
1043         Don't close an fd more than once. Identical atimes indicate
1044         success, not failure.
1045
1046 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
1047
1048         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
1049
1050 2006-11-23  Jim Meyering  <jim@meyering.net>
1051
1052         * build-aux/announce-gen: New file.  From coreutils.
1053
1054 2006-11-22  Jim Meyering  <jim@meyering.net>
1055
1056         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
1057         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
1058         (fts_read): Use a temporary to narrow the overused st_size member
1059         before using it in a switch statement.  Reported by Matthew Woehlke.
1060
1061         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
1062         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
1063
1064 2006-11-20  Bruno Haible  <bruno@clisp.org>
1065
1066         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
1067         changequote instead of pairs of brackets.
1068         Reported by Andreas Schwab <schwab@suse.de>.
1069
1070 2006-11-21  Jim Meyering  <jim@meyering.net>
1071
1072         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
1073         so as to remain compatible with older compilers.
1074         Patch from Michael Deutschmann.
1075
1076 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1077
1078         * MODULES.html.sh (File system functions): Add openat.
1079
1080         * lib/openat.h (rpl_fstatat): New macro, if
1081         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
1082         (fstatat): Define to rpl_fstatat under the same conditions,
1083         unless COMPILING_FSTATAT.
1084         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
1085         seems to have the bug.
1086         * lib/fstatat.c: New file.
1087         * modules/openat (Files): Add it.
1088
1089 2006-11-20  Bruno Haible  <bruno@clisp.org>
1090
1091         * Makefile: New file.
1092
1093 2006-11-20  Jim Meyering  <jim@meyering.net>
1094
1095         The beginnings of syntax-related checks for gnulib.
1096         * lib/Makefile: New file.
1097         * lib/t-idcache: New script.  Ensure that the two halves of
1098         idcache.c stay in sync.
1099
1100         * lib/idcache.c: Adjust comments in user- and group- portions to
1101         be more accurate, and to be consistent with one another.
1102
1103 2006-11-20  Jim Meyering  <jim@meyering.net>
1104
1105         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
1106         continue using the flexible array member (thus, this module performs
1107         half as many malloc calls), with the addition that...
1108         (getgroup, getuser): Consistently record a non-match via an empty
1109         "name" string, and map an empty string match to a NULL return value.
1110         * modules/idcache (Depends-on): Re-add flexmember.
1111
1112         * lib/idcache.c (getuser): Remove all uses of the register keyword.
1113         (getuidbyname, getgroup, getgidbyname): Likewise.
1114
1115         Use cleaner syntax: NULL rather than 0.
1116         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
1117
1118 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1119
1120         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
1121         It mishandled the case where the group was missing.
1122         Problem reported by Greg Schafer.
1123         * modules/idcache: Likewise.
1124
1125 2006-11-18  Jim Meyering  <jim@meyering.net>
1126
1127         * check-module (%exempt_header): Add exception for some
1128         conditionally-included headers.
1129
1130         * modules/i-ring (Depends-on): Add verify.
1131         (License): Change to LGPL.
1132
1133 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
1134
1135         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
1136         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
1137         and inttostr.h.  Use snprintf rather than uinttostr, so that
1138         LGPLed code doesn't depend on GPLed.
1139
1140 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
1141
1142         * modules/inline (License): Change from GPL to LGPL.
1143
1144 2006-11-17  Jim Meyering  <jim@meyering.net>
1145
1146         * modules/d-type (License): Switch to LGPL.
1147
1148 2006-11-15  Bruno Haible  <bruno@clisp.org>
1149
1150         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
1151
1152 2006-11-15  Eric Blake  <ebb9@byu.net>
1153
1154         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
1155         the module dependency.
1156
1157 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1158             Bruno Haible  <bruno@clisp.org>
1159
1160         * gnulib-tool (func_create_testdir): Add license consistency check.
1161
1162 2006-11-15  Eric Blake  <ebb9@byu.net>
1163
1164         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
1165         random "(cached)" in configure output.
1166
1167 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1168
1169         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
1170         test for conforming inttypes.h is both announced and cached.
1171
1172         * MODULES.html.sh (seen_modules, seen_files): New variables.
1173         (func_module): Rewrite to use a few less gnulib-tool and sed
1174         invocations.  Avoid a couple of quadratic algorithms for ...
1175         (missed_modules, missed_files): ... these, with ...
1176         (func_append, func_tmpdir): ... these new functions, from
1177         gnulib-tool.  Analogously, install traps for cleanup.
1178
1179         * tests/test-gc.c (main): Remove unused variables.
1180         * tests/test-read-file.c: Include stdlib.h, for 'free'.
1181
1182 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
1183
1184         * modules/inttostr (License): Change to LGPL.
1185
1186 2006-11-14  Eric Blake  <ebb9@byu.net>
1187
1188         * modules/tempname (License): Change to LGPL.
1189
1190 2006-11-14  Eric Blake  <ebb9@byu.net>
1191
1192         * doc/functions.texi (Function Portability): *printf functions on
1193         Cygwin now understand all POSIX size specifiers.
1194
1195 2006-11-14  Bruno Haible  <bruno@clisp.org>
1196
1197         * modules/c-ctype (License): Change to LGPL.
1198
1199 2006-11-12  Bruno Haible  <bruno@clisp.org>
1200
1201         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
1202         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
1203         for GNOME libraries, for which the include files are installed in
1204         subdirectories of $prefix/include.
1205
1206 2006-11-12  Bruno Haible  <bruno@clisp.org>
1207
1208         * m4/lib-link.m4: Require at least autoconf-2.54.
1209         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
1210         name to underscores for the --with option.
1211
1212 2006-11-13  Bruno Haible  <bruno@clisp.org>
1213
1214         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
1215         the tests directory.
1216         Reported by Ralf Wildenhues.
1217
1218 2006-11-13  Bruno Haible  <bruno@clisp.org>
1219
1220         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
1221         (func_emit_initmacro_end): Undo the override here.
1222         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
1223         Works around the famous automake error in coreutils.
1224
1225 2006-11-13  Eric Blake  <ebb9@byu.net>
1226
1227         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
1228         element, not its node.
1229
1230 2006-11-12  Bruno Haible  <bruno@clisp.org>
1231
1232         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
1233         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
1234
1235 2006-11-12  Bruno Haible  <bruno@clisp.org>
1236
1237         * gnulib-tool: New option --local-symlink.
1238         (func_usage): Document it.
1239         (lsymbolic): New variable.
1240         (func_import, func_create_testdir): If --symlink was not specified,
1241         test whether --local-symlink was specified and the file comes from
1242         the local_gnulib_dir.
1243
1244 2006-11-12  Bruno Haible  <bruno@clisp.org>
1245
1246         * gnulib-tool (func_ln): New function.
1247         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
1248
1249 2006-11-12  Bruno Haible  <bruno@clisp.org>
1250
1251         Finish support for source files in subdirectories.
1252         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
1253         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
1254         AUTOMAKE_OPTIONS.
1255         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
1256
1257 2006-11-12  Bruno Haible  <bruno@clisp.org>
1258
1259         * gnulib-tool (func_get_automake_snippet): Synthesize also an
1260         EXTRA_lib_SOURCES augmentation.
1261         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
1262
1263 2006-11-12  Jim Meyering  <jim@meyering.net>
1264
1265         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
1266         file descriptors.  This also averts a failure on systems with
1267         native openat support when a traversed directory lacks "x" access.
1268         * lib/fts_.h: Include "i-ring.h"
1269         (struct FTS) [fts_fd_ring]: New member.
1270         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
1271         (FCHDIR): Add parentheses.
1272         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
1273         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
1274         When descending, rather than simply closing the previous
1275         fts_cwd_fd value, push that file descriptor onto the ring.
1276         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
1277         (fts_open): Initialize the new fd_ring member.
1278         (fts_close): Clear the ring.
1279         (fts_safe_changedir): When possible, use our new fd_ring to skip
1280         the diropen and fstat and dev/ino comparison that would normally
1281         accompany a virtual `chdir ("..")'.
1282
1283         * modules/fts (Depends-on): Add i-ring.
1284         * modules/i-ring: New module.
1285         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
1286         * m4/i-ring.m4: New file.
1287
1288 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1289
1290         * gnulib-tool (func_create_testdir): Fix replacement of
1291         `build-aux' in configure.ac.  Run autotools in gltests
1292         subdirectory.
1293         (func_create_testdir, func_create_megatestdir, test): There is
1294         no need for '--force' in most autotool invocations in a new
1295         tree.  Actually fail the whole test if any of the tools, or the
1296         configure or make stages fail.
1297
1298         Sync from Automake.
1299         * build-aux/gnupload: Revert last change.  Add pointer to upload
1300         instructions of the GNU Maintenance Instructions.
1301         Suggestion by Karl Berry.
1302
1303 2006-11-10  Jim Meyering  <jim@meyering.net>
1304
1305         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
1306
1307 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1308
1309         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
1310         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
1311         (bind_textdomain_codeset) [! ENABLE_NLS]:
1312         Evaluate all the arguments.  That way, callers get compatible behavior
1313         if the arguments have side effects.  Also, it avoids some GCC
1314         diagnostics in some cases; Joel E. Denny reported problems when Bison
1315         was configured with --enable-gcc-warnigs.
1316
1317 2006-11-10  Jim Meyering  <jim@meyering.net>
1318
1319         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
1320         relevant options in CFLAGS (like -O, -fno-inline) are taken into
1321         account.
1322
1323 2006-11-10  Jim Meyering  <jim@meyering.net>
1324
1325         * modules/inline: New file/module.
1326         * modules/xalloc (Files): Remove m4/inline.m4.
1327         (Depends-on): Add inline, instead.
1328         * modules/oset: Likewise.
1329         * modules/list: Likewise.
1330
1331 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1332
1333         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
1334         Problem reported by Matthew Woehlke.
1335
1336 2006-11-09  Bruno Haible  <bruno@clisp.org>
1337
1338         * lib/tempname.c (gen_tempname): Remove variant that invokes
1339         __gen_tempname.
1340         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
1341         __gen_tempname.
1342
1343 2006-11-08  Bruno Haible  <bruno@clisp.org>
1344
1345         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
1346         to 'yes' instead of 'cross-compiling'.
1347
1348 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
1349
1350         * lib/quotearg.h (quotearg_free): New decl.
1351         * lib/quotearg.c (quotearg_free): New function.
1352         (slot0, nslots, slotvec0, slotvec):
1353         Now file-scope so that quotearg_free can get at them.
1354
1355 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1356
1357         Sync from Automake.
1358         * build-aux/gnupload: Add missing 'gnu' to example URL.
1359         Report by Karl Berry.
1360
1361 2006-11-08  Bruno Haible  <bruno@clisp.org>
1362
1363         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
1364         Suggested by Paul Eggert.
1365
1366 2006-11-08  Jim Meyering  <jim@meyering.net>
1367
1368         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
1369         It's already included if !_LIBC.
1370         (fts_safe_changedir): Add a comment.
1371
1372 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1373
1374         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
1375         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
1376         Matthew Woehlke.
1377
1378         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
1379         definitions up, to avoid colliding with change below.
1380         (static_inline) [HAVE_INLINE]: New macro.
1381         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
1382         Provide extern decls when !HAVE_INLINE.  Do not define unless
1383         static_inline is defined, either by us or by xmalloc.c.  Use
1384         static_inline rather than static inline.
1385         (XCALLOC): Optimize sizeof(T) = 1 case.
1386         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
1387
1388 2006-11-07  Bruno Haible  <bruno@clisp.org>
1389
1390         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
1391         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
1392         AC_C_INLINE.
1393         * modules/xalloc (Files): Add m4/inline.m4.
1394
1395 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1396
1397         * README: Fix typo.
1398         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
1399         (Miscellanous Notes): ...from this.
1400
1401 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1402
1403         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
1404         Mention that offsetof should be used instead of sizeof.
1405         From Bruno Haible.
1406
1407 2006-11-07  Bruno Haible  <bruno@clisp.org>
1408
1409         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
1410
1411 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1412
1413         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1414         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
1415         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1416         (gl_tree_add_before, gl_tree_add_after):
1417         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
1418         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
1419         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1420         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
1421         (gl_linked_add_after, gl_linked_add_at): Likewise.
1422         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
1423         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1424         (gl_tree_add_before, gl_tree_add_after): Likewise.
1425         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
1426         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
1427         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
1428
1429 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1430
1431         * lib/gl_oset.h: Use C comment style, not C++ comment style.
1432
1433 2006-11-06  Bruno Haible  <bruno@clisp.org>
1434
1435         * m4/inline.m4: New file.
1436         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
1437         * modules/list (Files): Add m4/inline.m4.
1438         * modules/oset (Files): Likewise.
1439
1440 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1441
1442         * lib/idcache.c: Include <stddef.h>, for offsetof.
1443         (struct userid.name): Change from char * to a flexible array member.
1444         All uses changed.
1445         * modules/idcache (Depends-on): Add flexmember.
1446
1447         * MODULES.html.sh (Core language properties): New module flexmember.
1448         * modules/flexmember, m4/flexmember.m4: New files.
1449
1450         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
1451         inline functions that are identical with the old xnmalloc_inline,
1452         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
1453         that we can avoid some unnecessary integer multiplications and
1454         divisions in the common case where the element size is known at
1455         compile time.
1456         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
1457         needed.
1458         (xnboundedmalloc): Remove.
1459         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
1460         arguments, for consistency with rest of this header.
1461         (xcharalloc): Rewrite using XNMALLOC.
1462         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
1463         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
1464         versions have been moved to lib/xalloc.h and renamed to be the
1465         non-*_inline versions.
1466         (xmalloc, xrealloc): Implement without reference to the xnmalloc
1467         and xnrealloc functions, since those functions are now inline and
1468         now call us.
1469         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
1470         renaming described above.
1471         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
1472         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
1473         captures the dependency in AC_C_INLINE.
1474
1475         New module canonicalize-lgpl, proposed by Charles Wilson in
1476         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
1477         with a few small changes afterwards.
1478         * MODULES.html.sh (File system functions): New module
1479         canonicalize-lgpl.
1480         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
1481         and canonicalize_file_name.
1482         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
1483         * modules/canonicalize-lgpl: New files.
1484
1485 2006-11-05  Bruno Haible  <bruno@clisp.org>
1486
1487         * gnulib-tool (func_import, func_create_testdir): Create directories
1488         also for files in subdirectories of lib/.
1489
1490 2006-11-05  Bruno Haible  <bruno@clisp.org>
1491
1492         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
1493         ANSI C compliant.
1494
1495 2006-11-03  Bruno Haible  <bruno@clisp.org>
1496
1497         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1498         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
1499         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
1500         (xnboundedmalloc): New inline function.
1501         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
1502         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
1503         xmalloc.
1504         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
1505         xmalloc.
1506         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
1507         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
1508         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
1509         xmalloc.
1510         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1511         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
1512         xmalloc.
1513         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
1514         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1515         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
1516         xmalloc.
1517         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1518         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
1519         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1520         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
1521         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
1522         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
1523         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
1524
1525 2006-11-03  Bruno Haible  <bruno@clisp.org>
1526
1527         * lib/c-ctype.h [C++]: Define functions without name mangling.
1528         * lib/fwriteerror.h [C++]: Likewise.
1529         * lib/gcd.h [C++]: Likewise.
1530         * lib/linebreak.h [C++]: Likewise.
1531
1532 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
1533
1534         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
1535         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
1536         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
1537         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1538         Check for functions and headers just once.
1539         Check for declaration of canonicalize_file_name.
1540         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
1541
1542 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1543
1544         * gnulib-tool (func_import): Fix typo in actioncmd.
1545
1546 2006-11-02  Bruno Haible  <bruno@clisp.org>
1547
1548         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
1549         newline sequence in the Makefile.am snippet as a space, like "make"
1550         does.
1551         Reported by Roger Persson <perrog@gmail.com>.
1552
1553 2006-11-01  Bruno Haible  <bruno@clisp.org>
1554
1555         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
1556         already declared in <string.h>.
1557         * lib/strcase.h (strncasecmp): Don't declare it if yes.
1558
1559 2006-11-01  Bruno Haible  <bruno@clisp.org>
1560
1561         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
1562         * lib/strcase.h: Include <string.h>.
1563         (strcasecmp): Define to rpl_strcasecmp here.
1564
1565 2006-11-01  Bruno Haible  <bruno@clisp.org>
1566
1567         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
1568
1569 2006-11-01  Eric Blake  <ebb9@byu.net>
1570
1571         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
1572
1573         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
1574
1575 2006-10-29  Bruno Haible  <bruno@clisp.org>
1576
1577         Make it compile in C++ mode.
1578         * lib/full-write.c (full_rw): Add a cast.
1579
1580 2006-11-01  Bruno Haible  <bruno@clisp.org>
1581
1582         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
1583         be POSIX compliant.
1584         Reported by Roger Persson <perrog@gmail.com>.
1585
1586 2006-11-01  Eric Blake  <ebb9@byu.net>
1587
1588         * lib/getopt_.h: Fix comments.
1589
1590 2006-10-31  Eric Blake  <ebb9@byu.net>
1591
1592         * modules/tmpdir (Depends-on): Add sys_stat.
1593         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
1594         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
1595         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
1596         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
1597         tempname.
1598
1599 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
1600
1601         Avoid some C++ diagnostics reported by Bruno Haible.
1602         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
1603         xmalloc.
1604         (quotearg_alloc): Use xcharalloc rather than xmalloc.
1605         (struct slotvec): Move to top level.
1606         (quotearg_n_options): Rewrite to avoid xmalloc.
1607         * lib/xalloc.h (xcharalloc): New function.
1608         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
1609         [defined __cplusplus]: Add function template that provides result
1610         type propagation.  This part of the change is from Bruno Haible.
1611
1612 2006-10-29  Bruno Haible  <bruno@clisp.org>
1613
1614         Make it compile in C++ mode.
1615         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
1616         * lib/strnlen1.c (strnlen1): Cast memchr result.
1617         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
1618         * lib/clean-temp.c (string_equals, string_hash): Add casts.
1619         (create_temp_dir): Rename local variable 'template'.
1620         (compile_csharp_using_sscli): Add cast.
1621         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
1622         * lib/findprog.c (find_in_path): Likewise.
1623         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
1624         * lib/wait-process.c (register_slave_subprocess): Likewise.
1625
1626 2006-10-22  Bruno Haible  <bruno@clisp.org>
1627
1628         * modules/tsearch: New file.
1629         * lib/tsearch.h: New file.
1630         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
1631         * m4/tsearch.m4: New file.
1632         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
1633
1634 2006-10-29  Eric Blake  <ebb9@byu.net>
1635
1636         * lib/arcfour.c: Assume config.h.
1637         * lib/arctwo.c: Likewise.
1638         * lib/base64.c: Likewise.
1639         * lib/check-version.c: Likewise.
1640         * lib/crc.c: Likewise.
1641         * lib/des.c: Likewise.
1642         * lib/gc-gnulib.c: Likewise.
1643         * lib/gc-libgcrypt.c: Likewise.
1644         * lib/gc-pbkdf2-sha1.c: Likewise.
1645         * lib/getaddrinfo.c: Likewise.
1646         * lib/getdelim.c: Likewise.
1647         * lib/getline.c: Likewise.
1648         * lib/hmac-md5.c: Likewise.
1649         * lib/hmac-sha1.c: Likewise.
1650         * lib/iconvme.c: Likewise.
1651         * lib/md2.c: Likewise.
1652         * lib/md4.c: Likewise.
1653         * lib/memxor.c: Likewise.
1654         * lib/read-file.c: Likewise.
1655         * lib/readline.c: Likewise.
1656         * lib/rijndael-alg-fst.c: Likewise.
1657         * lib/rijndael-api-fst.c: Likewise.
1658         * lib/xgetdomainname.c: Likewise.
1659
1660 2006-10-28  Eric Blake  <ebb9@byu.net>
1661
1662         * lib/xstrndup.c: Assume config.h.
1663
1664 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
1665
1666         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
1667         stat-macros.h is now for our own macros, whereas stat_h is for
1668         macros in the <sys/stat.h> name space.
1669         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
1670         (STAT_MACROS_H): Remove.
1671         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
1672         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
1673         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
1674         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
1675         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
1676         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
1677         Move these macros to ...
1678         * lib/stat_.h: here.  Don't include stat-macros.h.
1679         * lib/canonicalize.c: Don't include stat-macros.h.
1680         * lib/chown.c: Likewise.
1681         * lib/euidaccess.c: Likewise.
1682         * lib/file-type.c: Likewise.
1683         * lib/filemode.c: Likewise.
1684         * lib/glob.c: Likewise.
1685         * lib/isapipe.c: Likewise.
1686         * lib/lchown.c: Likewise.
1687         * lib/lstat.c: Likewise.
1688         * lib/mkdir-p.c: Likewise.
1689         * lib/rmdir.c: Likewise.
1690         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
1691         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
1692         unless mkdir isn't declared, to speed up 'configure'.
1693         Always create sys/stat.h, since it's unlikely any real sys/stat.h
1694         would define all the S_* symbols.
1695         * modules/canonicalize (Depends-on):
1696         Depend on sys_stat, not stat-macros.
1697         * modules/chown: Likewise.
1698         * modules/euidaccess: Likewise.
1699         * modules/filemode: Likewise.
1700         * modules/file-type: Likewise.
1701         * modules/glob: Likewise.
1702         * modules/isapipe: Likewise.
1703         * modules/lchown: Likewise.
1704         * modules/lstat: Likewise.
1705         * modules/mkancesdirs: Likewise.
1706         * modules/rmdir: Likewise.
1707         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
1708         * modules/modechange: Likewise.
1709         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
1710         (configure.ac): Remove gl_STAT_MACROS.
1711         * modules/sys_stat (Depends-on): Remove stat-macros.
1712
1713 2006-10-27  Bruno Haible  <bruno@clisp.org>
1714
1715         * m4/signed.m4: Remove file.
1716         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
1717         invocation.
1718         * modules/vasnprintf (Files): Remove m4/signed.m4.
1719
1720 2006-10-27  Bruno Haible  <bruno@clisp.org>
1721
1722         Update to GNU gettext 0.16.
1723         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
1724         m4/inttypes-h.m4, m4/signed.m4.
1725         * m4/gettext.m4: Update to GNU gettext 0.16.
1726         * m4/intl.m4: New file, from GNU gettext.
1727         * m4/intldir.m4: New file, from GNU gettext.
1728         * config/srclist.txt: Update
1729
1730 2006-10-27  Eric Blake  <ebb9@byu.net>
1731
1732         * MODULES.html.sh: Document tempname.
1733         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
1734         dependencies.
1735         (Files): Move lib/tempname.c...
1736         * modules/tempname: ...to this new module.
1737         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
1738         (gl_PREREQ_TEMPNAME): Move...
1739         * m4/tempname.m4: ...to this new file.
1740         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
1741         * modules/sys_stat (Depends-on): Add stat-macros.
1742         * lib/stat_.h (includes): Pick up stat macros.
1743         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
1744         if stat macros are broken.
1745         * lib/tempname.c (includes): No need to include "stat-macros.h".
1746         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
1747         (direxists, __path_search) [!_LIBC]: Don't compile these in
1748         gnulib; the tmpdir module covers that.
1749         * lib/tempname.h: New file.
1750
1751 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
1752
1753         * COPYING: Explain how gnulib-tool converts licence headers.
1754         Almost all wording by Eric Blake.
1755
1756 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
1757
1758         * lib/mbchar.h (is_basic_table): Make read-only.
1759         * lib/mbchar.c (is_basic_table): Likewise.
1760         Reported by John Darrington.
1761
1762 2006-10-25  Bruno Haible  <bruno@clisp.org>
1763
1764         * lib/progname.h (set_program_name): Undefine before defining.
1765
1766 2006-10-25  Bruno Haible  <bruno@clisp.org>
1767
1768         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
1769         false for non-gcc C++ compilers.
1770         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
1771
1772 2006-10-24  Bruno Haible  <bruno@clisp.org>
1773
1774         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
1775         iconv implementations like Irix iconv.
1776
1777 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1778
1779         * modules/vararrays: New file.
1780         * m4/vararrays.m4: New file, taken from diffutils.
1781         * MODULES.html.sh: New module vararrays.
1782
1783 2006-10-24  Karl Berry  <karl@gnu.org>
1784
1785         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
1786         Don't call GNU Unix.
1787
1788 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1789
1790         * users.txt: Add Libtool.
1791
1792         Sync from Libtool:
1793
1794         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1795
1796         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
1797         to gnulib's policy of including config.h unconditionally.
1798
1799 2006-10-24  Bruno Haible  <bruno@clisp.org>
1800
1801         * modules/wcwidth (Files): Add m4/wint_t.m4.
1802         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
1803         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
1804
1805 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1806
1807         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
1808         to pacify GCC with some -W flags enabled.  Problem reported by
1809         Bruno Haible.
1810
1811 2006-10-24  Jim Meyering  <jim@meyering.net>
1812
1813         * MODULES.html.sh: Remove uinttostr.  It's not a module.
1814         Reported by Karl Berry.
1815
1816 2006-10-23  Bruno Haible  <bruno@clisp.org>
1817
1818         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
1819
1820 2006-10-24  Bruno Haible  <bruno@clisp.org>
1821
1822         * lib/gl_list.h: Use C comment style, not C++ comment style.
1823
1824 2006-10-23  Eric Blake  <ebb9@byu.net>
1825
1826         * lib/getaddrinfo.c (includes): Add missing include.
1827
1828 2006-10-23  Bruno Haible  <bruno@clisp.org>
1829             Paul Eggert  <eggert@cs.ucla.edu>
1830
1831         Ability to rename obstack_free.
1832         * lib/obstack.h (__obstack_free): New macro. Declare instead of
1833         obstack_free.
1834         (obstack_free): Invoke the __obstack_free macro.
1835         * lib/obstack.c (obstack_free): Use __obstack_free macro.
1836
1837 2006-10-23  Bruno Haible  <bruno@clisp.org>
1838             Paul Eggert  <eggert@cs.ucla.edu>
1839
1840         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
1841         __argc, __argv from the declaration. (They are defined as macros on
1842         mingw.)
1843
1844 2006-10-22  Bruno Haible  <bruno@clisp.org>
1845
1846         * doc/gnulib-intro.texi: New file.
1847         * doc/gnulib.texi: Include it.
1848
1849 2006-10-21  Bruno Haible  <bruno@clisp.org>
1850
1851         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
1852         "Introduction", "Miscellanous Notes", "Particular Modules".
1853
1854 2006-10-21  Bruno Haible  <bruno@clisp.org>
1855
1856         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1857         Change mostlyclean-local rule to avoid sh syntax error from bash
1858         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
1859
1860 2006-10-23  Jim Meyering  <jim@meyering.net>
1861
1862         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
1863         in place of snprintf.
1864
1865         * modules/inttostr (Files): Add lib/uinttostr.c.
1866         * lib/uinttostr.c (inttostr): New file/function.
1867         * lib/inttostr.h (uinttostr): Declare.
1868         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
1869         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
1870         Add uinttostr.
1871         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
1872
1873 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1874
1875         * lib/canonicalize.c (ELOOP): Define if not already defined.
1876         Problem reported by Bruno Haible in
1877         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
1878
1879 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1880
1881         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
1882         Problem reported by Perry Smith and Ville Laurikari.
1883
1884         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
1885         uses.
1886
1887 2006-10-19  Bruno Haible  <bruno@clisp.org>
1888
1889         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
1890         for mingw.
1891
1892 2006-10-19  Bruno Haible  <bruno@clisp.org>
1893
1894         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
1895         Needed for mingw.
1896
1897 2006-10-19  Bruno Haible  <bruno@clisp.org>
1898
1899         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
1900
1901 2006-10-19  Bruno Haible  <bruno@clisp.org>
1902
1903         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
1904         it.
1905
1906 2006-10-19  Bruno Haible  <bruno@clisp.org>
1907
1908         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
1909         invocation.
1910
1911 2006-10-19  Bruno Haible  <bruno@clisp.org>
1912
1913         * gnulib-tool (func_create_testdir): Don't include ftruncate and
1914         mountlist by default.
1915
1916 2006-10-16  Bruno Haible  <bruno@clisp.org>
1917
1918         * lib/c-strstr.c: Include c-strstr.h.
1919
1920 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1921
1922         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
1923         in a slash.
1924
1925 2006-10-18  Bruno Haible  <bruno@clisp.org>
1926
1927         * lib/lock.h [C++]: Wrap definitions in extern "C".
1928
1929 2006-10-18  Bruno Haible  <bruno@clisp.org>
1930
1931         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
1932         gl_LIBOBJS list.
1933
1934 2006-10-18  Bruno Haible  <bruno@clisp.org>
1935
1936         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
1937
1938 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
1939
1940         * lib/xstrtol.h: Include gettext.h.
1941         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
1942         Problem reported by Eric Blake.
1943         * modules/xstrtol (Depends-on): Add gettext-h.
1944
1945 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
1946
1947         * lib/strftime.c (advance): New macro.
1948         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
1949         incomplete type, so you can't add 0 to it.  Problem and patch
1950         reported by Eelco Dolstra for dietlibc.
1951
1952 2006-10-18  Jim Meyering  <jim@meyering.net>
1953
1954         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
1955         type for a local, and rename it: s/up/user_proc/.
1956
1957 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
1958
1959         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
1960         READ_UTMP_USER_PROCESS.
1961         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
1962
1963 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
1964
1965         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
1966         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
1967
1968 2006-10-17  Eric Blake  <ebb9@byu.net>
1969
1970         * lib/sigprocmask.c (sigprocmask): Fix typo.
1971
1972         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
1973
1974         * modules/clean-temp (Makefile.am): Don't add to make output...
1975         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
1976         config.h.
1977
1978 2006-10-17  Bruno Haible  <bruno@clisp.org>
1979
1980         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
1981         differently if DEFAULT_TEXT_DOMAIN is set.
1982
1983 2006-10-16  Bruno Haible  <bruno@clisp.org>
1984
1985         * lib/clean-temp.c: Include fwriteerror.h.
1986
1987 2006-10-16  Bruno Haible  <bruno@clisp.org>
1988
1989         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
1990
1991 2006-10-16  Bruno Haible  <bruno@clisp.org>
1992
1993         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
1994         * lib/sigprocmask.h: Include <sys/types.h>.
1995         (sigset_t): Use the system's definition if present.
1996
1997 2006-10-17  Eric Blake  <ebb9@byu.net>
1998
1999         * lib/xvasprintf.c (includes): Assume config.h.
2000         * lib/xasprintf.c (includes): Likewise.
2001
2002 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
2003
2004         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
2005         at least as wide as intmax_t.
2006
2007 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
2008
2009         (Imported from Automake.)
2010         * build-aux/gnupload: Update to version 1.1 of directive file.
2011
2012 2006-10-16  Eric Blake  <ebb9@byu.net>
2013
2014         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
2015         match Automake 1.10a.
2016
2017 2006-10-14  Bruno Haible  <bruno@clisp.org>
2018
2019         * modules/sigprocmask: New file.
2020         * lib/sigprocmask.h: New file.
2021         * lib/sigprocmask.c: New file.
2022         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
2023         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
2024         request sigprocmask.o.
2025         (gl_PREREQ_SIGPROCMASK): New macro.
2026         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
2027         (Depends-on): Add sigprocmask.
2028         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
2029         gt_SIGNALBLOCKING. Test for 'raise' only once.
2030         * lib/fatal-signal.c: Include sigprocmask.h.
2031         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
2032         unblock_fatal_signals): Define always.
2033         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
2034         sigprocmask.
2035
2036 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
2037
2038         Sync from Automake.
2039         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
2040         which incorrectly sets the mode of an existing destination
2041         directory.  In some cases the unpatched install-sh could do the
2042         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
2043         system.  We hope this is rare in practice, but it's clearly worth
2044         fixing.  Problem reported by Alex Unleashed in
2045         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
2046         Also, don't bother to check for -m bugs unless we're using -m;
2047         suggested by Stepan Kasal.
2048
2049 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2050
2051         Sync from Automake.
2052         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
2053         `-c' flag, so they appear at the same position as in %FASTDEP%
2054         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
2055         which ignores unknown options only after the first non-option.
2056         Bug report against M4 by Nelson H. F. Beebe.
2057
2058 2006-10-13  Jim Meyering  <jim@meyering.net>
2059
2060         Fix a bug in yesterday's change.
2061         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
2062         p->fts_statp->st_dev would be used uninitialized.
2063         Ensures that we always call fts_stat on the very first entry.
2064         Miklos Szeredi reported that find -xdev stopped working.
2065
2066 2006-10-12  Bruno Haible  <bruno@clisp.org>
2067
2068         * gnulib-tool (func_get_automake_snippet): Append an automatically
2069         computed EXTRA_DIST augmentation.
2070         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
2071         * modules/alloca-opt (Makefile.am): Likewise.
2072         * modules/allocsa (Makefile.am): Likewise.
2073         * modules/arcfour (Makefile.am): Likewise.
2074         * modules/arctwo (Makefile.am): Likewise.
2075         * modules/argmatch (Makefile.am): Likewise.
2076         * modules/argz (Makefile.am): Likewise.
2077         * modules/atexit (Makefile.am): Likewise.
2078         * modules/backupfile (Makefile.am): Likewise.
2079         * modules/byteswap (Makefile.am): Likewise.
2080         * modules/c-strtod (Makefile.am): Likewise.
2081         * modules/c-strtold (Makefile.am): Likewise.
2082         * modules/calloc (Makefile.am): Likewise.
2083         * modules/canon-host (Makefile.am): Likewise.
2084         * modules/canonicalize (Makefile.am): Likewise.
2085         * modules/chdir-long (Makefile.am): Likewise.
2086         * modules/chdir-safer (Makefile.am): Likewise.
2087         * modules/check-version (Makefile.am): Likewise.
2088         * modules/chown (Makefile.am): Likewise.
2089         * modules/cloexec (Makefile.am): Likewise.
2090         * modules/close-stream (Makefile.am): Likewise.
2091         * modules/closeout (Makefile.am): Likewise.
2092         * modules/crc (Makefile.am): Likewise.
2093         * modules/csharpexec (Makefile.am): Likewise.
2094         * modules/cycle-check (Makefile.am): Likewise.
2095         * modules/des (Makefile.am): Likewise.
2096         * modules/dev-ino (Makefile.am): Likewise.
2097         * modules/dirfd (Makefile.am): Likewise.
2098         * modules/dirname (Makefile.am): Likewise.
2099         * modules/dup2 (Makefile.am): Likewise.
2100         * modules/eealloc (Makefile.am): Likewise.
2101         * modules/error (Makefile.am): Likewise.
2102         * modules/euidaccess (Makefile.am): Likewise.
2103         * modules/exclude (Makefile.am): Likewise.
2104         * modules/exitfail (Makefile.am): Likewise.
2105         * modules/fcntl-safer (Makefile.am): Likewise.
2106         * modules/fcntl (Makefile.am): Likewise.
2107         * modules/file-type (Makefile.am): Likewise.
2108         * modules/fileblocks (Makefile.am): Likewise.
2109         * modules/filemode (Makefile.am): Likewise.
2110         * modules/filenamecat (Makefile.am): Likewise.
2111         * modules/fnmatch (Makefile.am): Likewise.
2112         * modules/fopen-safer (Makefile.am): Likewise.
2113         * modules/fpending (Makefile.am): Likewise.
2114         * modules/fprintftime (Makefile.am): Likewise.
2115         * modules/free (Makefile.am): Likewise.
2116         * modules/fsusage (Makefile.am): Likewise.
2117         * modules/ftruncate (Makefile.am): Likewise.
2118         * modules/fts (Makefile.am): Likewise.
2119         * modules/gc-arcfour (Makefile.am): Likewise.
2120         * modules/gc-des (Makefile.am): Likewise.
2121         * modules/gc-hmac-md5 (Makefile.am): Likewise.
2122         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
2123         * modules/gc-md4 (Makefile.am): Likewise.
2124         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2125         * modules/gc-sha1 (Makefile.am): Likewise.
2126         * modules/gc (Makefile.am): Likewise.
2127         * modules/getaddrinfo (Makefile.am): Likewise.
2128         * modules/getcwd (Makefile.am): Likewise.
2129         * modules/getdelim (Makefile.am): Likewise.
2130         * modules/getdomainname (Makefile.am): Likewise.
2131         * modules/getgroups (Makefile.am): Likewise.
2132         * modules/gethostname (Makefile.am): Likewise.
2133         * modules/gethrxtime (Makefile.am): Likewise.
2134         * modules/getline (Makefile.am): Likewise.
2135         * modules/getloadavg (Makefile.am): Likewise.
2136         * modules/getlogin_r (Makefile.am): Likewise.
2137         * modules/getndelim2 (Makefile.am): Likewise.
2138         * modules/getopt (Makefile.am): Likewise.
2139         * modules/getpagesize (Makefile.am): Likewise.
2140         * modules/getpass-gnu (Makefile.am): Likewise.
2141         * modules/getpass (Makefile.am): Likewise.
2142         * modules/getsubopt (Makefile.am): Likewise.
2143         * modules/gettime (Makefile.am): Likewise.
2144         * modules/gettimeofday (Makefile.am): Likewise.
2145         * modules/getugroups (Makefile.am): Likewise.
2146         * modules/getusershell (Makefile.am): Likewise.
2147         * modules/glob (Makefile.am): Likewise.
2148         * modules/group-member (Makefile.am): Likewise.
2149         * modules/hard-locale (Makefile.am): Likewise.
2150         * modules/hash (Makefile.am): Likewise.
2151         * modules/hmac-md5 (Makefile.am): Likewise.
2152         * modules/hmac-sha1 (Makefile.am): Likewise.
2153         * modules/human (Makefile.am): Likewise.
2154         * modules/idcache (Makefile.am): Likewise.
2155         * modules/imaxabs (Makefile.am): Likewise.
2156         * modules/imaxdiv (Makefile.am): Likewise.
2157         * modules/inet_ntop (Makefile.am): Likewise.
2158         * modules/inet_pton (Makefile.am): Likewise.
2159         * modules/intprops (Makefile.am): Likewise.
2160         * modules/inttostr (Makefile.am): Likewise.
2161         * modules/inttypes (Makefile.am): Likewise.
2162         * modules/isapipe (Makefile.am): Likewise.
2163         * modules/javaversion (Makefile.am): Likewise.
2164         * modules/lchmod (Makefile.am): Likewise.
2165         * modules/lchown (Makefile.am): Likewise.
2166         * modules/localcharset (Makefile.am): Likewise.
2167         * modules/long-options (Makefile.am): Likewise.
2168         * modules/lstat (Makefile.am): Likewise.
2169         * modules/malloc (Makefile.am): Likewise.
2170         * modules/mathl (Makefile.am): Likewise.
2171         * modules/mbchar (Makefile.am): Likewise.
2172         * modules/md2 (Makefile.am): Likewise.
2173         * modules/md4 (Makefile.am): Likewise.
2174         * modules/md5 (Makefile.am): Likewise.
2175         * modules/memcasecmp (Makefile.am): Likewise.
2176         * modules/memchr (Makefile.am): Likewise.
2177         * modules/memcmp (Makefile.am): Likewise.
2178         * modules/memcoll (Makefile.am): Likewise.
2179         * modules/memcpy (Makefile.am): Likewise.
2180         * modules/memmem (Makefile.am): Likewise.
2181         * modules/memmove (Makefile.am): Likewise.
2182         * modules/mempcpy (Makefile.am): Likewise.
2183         * modules/memrchr (Makefile.am): Likewise.
2184         * modules/memset (Makefile.am): Likewise.
2185         * modules/memxor (Makefile.am): Likewise.
2186         * modules/mkancesdirs (Makefile.am): Likewise.
2187         * modules/mkdir-p (Makefile.am): Likewise.
2188         * modules/mkdir (Makefile.am): Likewise.
2189         * modules/mkdtemp (Makefile.am): Likewise.
2190         * modules/mkstemp (Makefile.am): Likewise.
2191         * modules/mktime (Makefile.am): Likewise.
2192         * modules/modechange (Makefile.am): Likewise.
2193         * modules/mountlist (Makefile.am): Likewise.
2194         * modules/nanosleep (Makefile.am): Likewise.
2195         * modules/obstack (Makefile.am): Likewise.
2196         * modules/openat (Makefile.am): Likewise.
2197         * modules/pagealign_alloc (Makefile.am): Likewise.
2198         * modules/pathmax (Makefile.am): Likewise.
2199         * modules/physmem (Makefile.am): Likewise.
2200         * modules/poll (Makefile.am): Likewise.
2201         * modules/posixtm (Makefile.am): Likewise.
2202         * modules/posixver (Makefile.am): Likewise.
2203         * modules/putenv (Makefile.am): Likewise.
2204         * modules/quote (Makefile.am): Likewise.
2205         * modules/quotearg (Makefile.am): Likewise.
2206         * modules/raise (Makefile.am): Likewise.
2207         * modules/read-file (Makefile.am): Likewise.
2208         * modules/readline (Makefile.am): Likewise.
2209         * modules/readlink (Makefile.am): Likewise.
2210         * modules/readtokens (Makefile.am): Likewise.
2211         * modules/readutmp (Makefile.am): Likewise.
2212         * modules/realloc (Makefile.am): Likewise.
2213         * modules/regex (Makefile.am): Likewise.
2214         * modules/rename-dest-slash (Makefile.am): Likewise.
2215         * modules/rename (Makefile.am): Likewise.
2216         * modules/rijndael (Makefile.am): Likewise.
2217         * modules/rmdir (Makefile.am): Likewise.
2218         * modules/rpmatch (Makefile.am): Likewise.
2219         * modules/safe-read (Makefile.am): Likewise.
2220         * modules/safe-write (Makefile.am): Likewise.
2221         * modules/same-inode (Makefile.am): Likewise.
2222         * modules/same (Makefile.am): Likewise.
2223         * modules/save-cwd (Makefile.am): Likewise.
2224         * modules/savedir (Makefile.am): Likewise.
2225         * modules/setenv (Makefile.am): Likewise.
2226         * modules/settime (Makefile.am): Likewise.
2227         * modules/sha1 (Makefile.am): Likewise.
2228         * modules/sig2str (Makefile.am): Likewise.
2229         * modules/snprintf (Makefile.am): Likewise.
2230         * modules/stat-macros (Makefile.am): Likewise.
2231         * modules/stat-time (Makefile.am): Likewise.
2232         * modules/stdbool (Makefile.am): Likewise.
2233         * modules/stdint (Makefile.am): Likewise.
2234         * modules/stdlib-safer (Makefile.am): Likewise.
2235         * modules/stpcpy (Makefile.am): Likewise.
2236         * modules/stpncpy (Makefile.am): Likewise.
2237         * modules/strcase (Makefile.am): Likewise.
2238         * modules/strcasestr (Makefile.am): Likewise.
2239         * modules/strchrnul (Makefile.am): Likewise.
2240         * modules/strcspn (Makefile.am): Likewise.
2241         * modules/strdup (Makefile.am): Likewise.
2242         * modules/strerror (Makefile.am): Likewise.
2243         * modules/strftime (Makefile.am): Likewise.
2244         * modules/strndup (Makefile.am): Likewise.
2245         * modules/strnlen (Makefile.am): Likewise.
2246         * modules/strpbrk (Makefile.am): Likewise.
2247         * modules/strsep (Makefile.am): Likewise.
2248         * modules/strstr (Makefile.am): Likewise.
2249         * modules/strtod (Makefile.am): Likewise.
2250         * modules/strtoimax (Makefile.am): Likewise.
2251         * modules/strtok_r (Makefile.am): Likewise.
2252         * modules/strtol (Makefile.am): Likewise.
2253         * modules/strtoll (Makefile.am): Likewise.
2254         * modules/strtoul (Makefile.am): Likewise.
2255         * modules/strtoull (Makefile.am): Likewise.
2256         * modules/strtoumax (Makefile.am): Likewise.
2257         * modules/strverscmp (Makefile.am): Likewise.
2258         * modules/sys_socket (Makefile.am): Likewise.
2259         * modules/sys_stat (Makefile.am): Likewise.
2260         * modules/sysexits (Makefile.am): Likewise.
2261         * modules/time_r (Makefile.am): Likewise.
2262         * modules/timegm (Makefile.am): Likewise.
2263         * modules/timespec (Makefile.am): Likewise.
2264         * modules/tmpfile-safer (Makefile.am): Likewise.
2265         * modules/trim (Makefile.am): Likewise.
2266         * modules/unistd-safer (Makefile.am): Likewise.
2267         * modules/unlinkdir (Makefile.am): Likewise.
2268         * modules/unlocked-io (Makefile.am): Likewise.
2269         * modules/userspec (Makefile.am): Likewise.
2270         * modules/utime (Makefile.am): Likewise.
2271         * modules/utimecmp (Makefile.am): Likewise.
2272         * modules/utimens (Makefile.am): Likewise.
2273         * modules/vasnprintf (Makefile.am): Likewise.
2274         * modules/vasprintf (Makefile.am): Likewise.
2275         * modules/vsnprintf (Makefile.am): Likewise.
2276         * modules/xalloc (Makefile.am): Likewise.
2277         * modules/xgetcwd (Makefile.am): Likewise.
2278         * modules/xnanosleep (Makefile.am): Likewise.
2279         * modules/xreadlink (Makefile.am): Likewise.
2280         * modules/xstrtod (Makefile.am): Likewise.
2281         * modules/xstrtol (Makefile.am): Likewise.
2282         * modules/xstrtold (Makefile.am): Likewise.
2283         * modules/yesno (Makefile.am): Likewise.
2284         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
2285
2286 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2287
2288         * modules/error (Makefile.am): Distribute files through
2289         EXTRA_DIST, not lib_SOURCES.
2290
2291 2006-10-12  Eric Blake  <ebb9@byu.net>
2292
2293         * modules/error (Makefile.am): Distribute files in /lib.
2294         * modules/obstack (Makefile.am): Likewise.
2295
2296 2006-10-12  Bruno Haible  <bruno@clisp.org>
2297
2298         * modules/acl (Makefile.am): Distribute all files in lib/ through
2299         EXTRA_DIST.
2300         * modules/arcfour (Makefile.am): Likewise.
2301         * modules/arctwo (Makefile.am): Likewise.
2302         * modules/argmatch (Makefile.am): Likewise.
2303         * modules/argz (Makefile.am): Likewise.
2304         * modules/atexit (Makefile.am): Likewise.
2305         * modules/backupfile (Makefile.am): Likewise.
2306         * modules/c-strtod (Makefile.am): Likewise.
2307         * modules/c-strtold (Makefile.am): Likewise.
2308         * modules/calloc (Makefile.am): Likewise.
2309         * modules/canon-host (Makefile.am): Likewise.
2310         * modules/canonicalize (Makefile.am): Likewise.
2311         * modules/chdir-long (Makefile.am): Likewise.
2312         * modules/chdir-safer (Makefile.am): Likewise.
2313         * modules/check-version (Makefile.am): Likewise.
2314         * modules/chown (Makefile.am): Likewise.
2315         * modules/cloexec (Makefile.am): Likewise.
2316         * modules/close-stream (Makefile.am): Likewise.
2317         * modules/closeout (Makefile.am): Likewise.
2318         * modules/crc (Makefile.am): Likewise.
2319         * modules/cycle-check (Makefile.am): Likewise.
2320         * modules/des (Makefile.am): Likewise.
2321         * modules/dirfd (Makefile.am): Likewise.
2322         * modules/dirname (Makefile.am): Likewise.
2323         * modules/dup2 (Makefile.am): Likewise.
2324         * modules/euidaccess (Makefile.am): Likewise.
2325         * modules/exclude (Makefile.am): Likewise.
2326         * modules/exitfail (Makefile.am): Likewise.
2327         * modules/fcntl-safer (Makefile.am): Likewise.
2328         * modules/file-type (Makefile.am): Likewise.
2329         * modules/fileblocks (Makefile.am): Likewise.
2330         * modules/filemode (Makefile.am): Likewise.
2331         * modules/filenamecat (Makefile.am): Likewise.
2332         * modules/fnmatch (Makefile.am): Likewise.
2333         * modules/fopen-safer (Makefile.am): Likewise.
2334         * modules/fpending (Makefile.am): Likewise.
2335         * modules/fprintftime (Makefile.am): Likewise.
2336         * modules/free (Makefile.am): Likewise.
2337         * modules/fsusage (Makefile.am): Likewise.
2338         * modules/ftruncate (Makefile.am): Likewise.
2339         * modules/fts (Makefile.am): Likewise.
2340         * modules/gc (Makefile.am): Likewise.
2341         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2342         * modules/getaddrinfo (Makefile.am): Likewise.
2343         * modules/getcwd (Makefile.am): Likewise.
2344         * modules/getdelim (Makefile.am): Likewise.
2345         * modules/getdomainname (Makefile.am): Likewise.
2346         * modules/getgroups (Makefile.am): Likewise.
2347         * modules/gethostname (Makefile.am): Likewise.
2348         * modules/gethrxtime (Makefile.am): Likewise.
2349         * modules/getline (Makefile.am): Likewise.
2350         * modules/getloadavg (Makefile.am): Likewise.
2351         * modules/getlogin_r (Makefile.am): Likewise.
2352         * modules/getopt (Makefile.am): Likewise.
2353         * modules/getpass (Makefile.am): Likewise.
2354         * modules/getpass-gnu (Makefile.am): Likewise.
2355         * modules/getsubopt (Makefile.am): Likewise.
2356         * modules/gettime (Makefile.am): Likewise.
2357         * modules/gettimeofday (Makefile.am): Likewise.
2358         * modules/getugroups (Makefile.am): Likewise.
2359         * modules/getusershell (Makefile.am): Likewise.
2360         * modules/glob (Makefile.am): Likewise.
2361         * modules/group-member (Makefile.am): Likewise.
2362         * modules/hard-locale (Makefile.am): Likewise.
2363         * modules/hash (Makefile.am): Likewise.
2364         * modules/hmac-md5 (Makefile.am): Likewise.
2365         * modules/hmac-sha1 (Makefile.am): Likewise.
2366         * modules/human (Makefile.am): Likewise.
2367         * modules/idcache (Makefile.am): Likewise.
2368         * modules/imaxabs (Makefile.am): Likewise.
2369         * modules/imaxdiv (Makefile.am): Likewise.
2370         * modules/inet_ntop (Makefile.am): Likewise.
2371         * modules/inet_pton (Makefile.am): Likewise.
2372         * modules/inttostr (Makefile.am): Likewise.
2373         * modules/isapipe (Makefile.am): Likewise.
2374         * modules/lchown (Makefile.am): Likewise.
2375         * modules/long-options (Makefile.am): Likewise.
2376         * modules/lstat (Makefile.am): Likewise.
2377         * modules/malloc (Makefile.am): Likewise.
2378         * modules/mathl (Makefile.am): Likewise.
2379         * modules/mbchar (Makefile.am): Likewise.
2380         * modules/md2 (Makefile.am): Likewise.
2381         * modules/md4 (Makefile.am): Likewise.
2382         * modules/md5 (Makefile.am): Likewise.
2383         * modules/memcasecmp (Makefile.am): Likewise.
2384         * modules/memchr (Makefile.am): Likewise.
2385         * modules/memcmp (Makefile.am): Likewise.
2386         * modules/memcoll (Makefile.am): Likewise.
2387         * modules/memcpy (Makefile.am): Likewise.
2388         * modules/memmem (Makefile.am): Likewise.
2389         * modules/memmove (Makefile.am): Likewise.
2390         * modules/mempcpy (Makefile.am): Likewise.
2391         * modules/memrchr (Makefile.am): Likewise.
2392         * modules/memset (Makefile.am): Likewise.
2393         * modules/memxor (Makefile.am): Likewise.
2394         * modules/mkancesdirs (Makefile.am): Likewise.
2395         * modules/mkdir (Makefile.am): Likewise.
2396         * modules/mkdir-p (Makefile.am): Likewise.
2397         * modules/mkdtemp (Makefile.am): Likewise.
2398         * modules/mkstemp (Makefile.am): Likewise.
2399         * modules/mktime (Makefile.am): Likewise.
2400         * modules/modechange (Makefile.am): Likewise.
2401         * modules/mountlist (Makefile.am): Likewise.
2402         * modules/nanosleep (Makefile.am): Likewise.
2403         * modules/openat (Makefile.am): Likewise.
2404         * modules/pagealign_alloc (Makefile.am): Likewise.
2405         * modules/physmem (Makefile.am): Likewise.
2406         * modules/poll (Makefile.am): Likewise.
2407         * modules/posixtm (Makefile.am): Likewise.
2408         * modules/posixver (Makefile.am): Likewise.
2409         * modules/putenv (Makefile.am): Likewise.
2410         * modules/quote (Makefile.am): Likewise.
2411         * modules/quotearg (Makefile.am): Likewise.
2412         * modules/raise (Makefile.am): Likewise.
2413         * modules/read-file (Makefile.am): Likewise.
2414         * modules/readline (Makefile.am): Likewise.
2415         * modules/readlink (Makefile.am): Likewise.
2416         * modules/readtokens (Makefile.am): Likewise.
2417         * modules/readutmp (Makefile.am): Likewise.
2418         * modules/realloc (Makefile.am): Likewise.
2419         * modules/regex (Makefile.am): Likewise.
2420         * modules/rename (Makefile.am): Likewise.
2421         * modules/rename-dest-slash (Makefile.am): Likewise.
2422         * modules/rijndael (Makefile.am): Likewise.
2423         * modules/rmdir (Makefile.am): Likewise.
2424         * modules/rpmatch (Makefile.am): Likewise.
2425         * modules/safe-read (Makefile.am): Likewise.
2426         * modules/safe-write (Makefile.am): Likewise.
2427         * modules/same (Makefile.am): Likewise.
2428         * modules/save-cwd (Makefile.am): Likewise.
2429         * modules/savedir (Makefile.am): Likewise.
2430         * modules/setenv (Makefile.am): Likewise.
2431         * modules/settime (Makefile.am): Likewise.
2432         * modules/sha1 (Makefile.am): Likewise.
2433         * modules/sig2str (Makefile.am): Likewise.
2434         * modules/snprintf (Makefile.am): Likewise.
2435         * modules/stdlib-safer (Makefile.am): Likewise.
2436         * modules/stpcpy (Makefile.am): Likewise.
2437         * modules/stpncpy (Makefile.am): Likewise.
2438         * modules/strcase (Makefile.am): Likewise.
2439         * modules/strcasestr (Makefile.am): Likewise.
2440         * modules/strchrnul (Makefile.am): Likewise.
2441         * modules/strcspn (Makefile.am): Likewise.
2442         * modules/strdup (Makefile.am): Likewise.
2443         * modules/strerror (Makefile.am): Likewise.
2444         * modules/strftime (Makefile.am): Likewise.
2445         * modules/strndup (Makefile.am): Likewise.
2446         * modules/strnlen (Makefile.am): Likewise.
2447         * modules/strpbrk (Makefile.am): Likewise.
2448         * modules/strsep (Makefile.am): Likewise.
2449         * modules/strstr (Makefile.am): Likewise.
2450         * modules/strtod (Makefile.am): Likewise.
2451         * modules/strtoimax (Makefile.am): Likewise.
2452         * modules/strtok_r (Makefile.am): Likewise.
2453         * modules/strtol (Makefile.am): Likewise.
2454         * modules/strtoll (Makefile.am): Likewise.
2455         * modules/strtoul (Makefile.am): Likewise.
2456         * modules/strtoull (Makefile.am): Likewise.
2457         * modules/strtoumax (Makefile.am): Likewise.
2458         * modules/strverscmp (Makefile.am): Likewise.
2459         * modules/time_r (Makefile.am): Likewise.
2460         * modules/timegm (Makefile.am): Likewise.
2461         * modules/tmpfile-safer (Makefile.am): Likewise.
2462         * modules/unistd-safer (Makefile.am): Likewise.
2463         * modules/unlinkdir (Makefile.am): Likewise.
2464         * modules/userspec (Makefile.am): Likewise.
2465         * modules/utime (Makefile.am): Likewise.
2466         * modules/utimecmp (Makefile.am): Likewise.
2467         * modules/utimens (Makefile.am): Likewise.
2468         * modules/vasnprintf (Makefile.am): Likewise.
2469         * modules/vasprintf (Makefile.am): Likewise.
2470         * modules/vsnprintf (Makefile.am): Likewise.
2471         * modules/xalloc (Makefile.am): Likewise.
2472         * modules/xgetcwd (Makefile.am): Likewise.
2473         * modules/xnanosleep (Makefile.am): Likewise.
2474         * modules/xreadlink (Makefile.am): Likewise.
2475         * modules/xstrtod (Makefile.am): Likewise.
2476         * modules/xstrtol (Makefile.am): Likewise.
2477         * modules/xstrtold (Makefile.am): Likewise.
2478         * modules/yesno (Makefile.am): Likewise.
2479
2480 2006-10-12  Jim Meyering  <jim@meyering.net>
2481
2482         * m4/getloadavg.m4: Revert the change below.
2483
2484         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
2485         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
2486         fail with a symlink, which is what coreutils' ./bootstrap now
2487         creates by default.
2488
2489 2006-10-12  Bruno Haible  <bruno@clisp.org>
2490
2491         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
2492         mingw.
2493         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
2494         MSVC and mingw explicitly.
2495
2496 2006-10-11  Simon Josefsson  <jas@extundo.com>
2497             Bruno Haible  <bruno@clisp.org>
2498
2499         Add support for multiple gnulib-tool invocations in the scope of a
2500         single configure.ac file.
2501         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
2502         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
2503         with the same contents as the _LIBADD variable.
2504         (func_emit_initmacro_start, func_emit_initmacro_end,
2505         func_emit_initmacro_done): New functions.
2506         (func_import, func_create_testdir): Invoke them. Allow the identifiers
2507         gl_LIBOBJS and gl_LTLIBOBJS.
2508
2509 2006-10-11  Bruno Haible  <bruno@clisp.org>
2510
2511         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
2512         (func_create_testdir): Don't create po/Makefile.am, don't invoke
2513         autoreconf. Instead, invoke autopoint explicitly but move back the
2514         *.m4 files from gnulib.
2515
2516 2006-10-11  Bruno Haible  <bruno@clisp.org>
2517
2518         * gnulib-tool (func_usage): Make module names after --create-testdir
2519         optional.
2520         (func_create_testdir): If no module was specified, use nearly all
2521         modules.
2522
2523 2006-10-12  Jim Meyering  <jim@meyering.net>
2524
2525         Big performance improvement for fts-based tools that use FTS_NOSTAT.
2526         Avoid spurious inode-mismatch problems on non-POSIX file systems.
2527         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
2528         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
2529         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
2530         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
2531         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
2532         (fts_set_stat_required): New function.
2533         (fts_open): Defer the calls to fts_stat, if possible or requested.
2534         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
2535         into fts_stat itself.
2536         (fts_read): Perform any required (deferred) fts_stat call.
2537         (fts_build): Likewise, for the directory we're about to open and read.
2538         In the readdir loop, carefully decide whether each entry will require
2539         an eventual call to fts_stat, using dirent.d_type info if available.
2540         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
2541         a command line argument into this function.  Update all callers.
2542         Map a return value of FTS_DOT to FTS_D for a command line argument.
2543         * modules/fts (Depends-on): Add d-type.  Alphabetize.
2544         Thanks to Miklos Szeredi for his tenacity and for the initial
2545         bug report about "find" failing on a FUSE-based file system.
2546
2547         * lib/fts.c (fts_open): Use consistent indentation.
2548
2549 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2550
2551         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
2552         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
2553         reported by Jim Meyering.  All uses of cache variables renamed
2554         to match Autoconf's.
2555         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
2556         the other one.
2557
2558         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
2559         Fix misspelling in diagnostic.
2560
2561 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2562
2563         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
2564         defined.  Problem reported by Matthew Woehlke.
2565
2566         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
2567         Add support for Tandem NonStop R series.
2568         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
2569         Use new macro.
2570
2571         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
2572         (has_trailing_slash): Omit size arg; all callers changed.
2573         Omit 'inline', since it doesn't help performance and we'd
2574         need to configure it.
2575         Don't count //, ///, etc. as having a trailing slash.
2576         As a side effect, this removes a C99ism reported by Matthew Woehlke.
2577         (rpl_rename_dest_slash): On failure, use rename's errno rather
2578         than (in some cases) an incorrect or junk errno.
2579         Simplify code by removing need to compute length; this does
2580         cause it to make two passes instead of one over the file name,
2581         but it's worth it.
2582
2583         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
2584         change, since Autoconf's version may no longer be appropriate now
2585         that we are using CVS Autoconf's version.  Add support for Tandem.
2586
2587 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2588             Bruno Haible  <bruno@clisp.org>
2589
2590         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
2591         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
2592         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
2593         gl_AC_TYPE_LONG_LONG.
2594
2595         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
2596         instead of HAVE_LONG_LONG.
2597         * lib/printf-args.c (printf_fetchargs): Likewise.
2598         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
2599         * lib/vasnprintf.c (VASNPRINTF): Likewise.
2600         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
2601         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
2602         gl_AC_TYPE_LONG_LONG.
2603
2604 2006-10-11  Bruno Haible  <bruno@clisp.org>
2605
2606         * m4/longlong.m4: Add comments.
2607         * m4/ulonglong.m4: Likewise.
2608
2609 2006-10-10  Bruno Haible  <bruno@clisp.org>
2610
2611         Make it possible to #define stpcpy, strdup to aliases.
2612         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
2613         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
2614
2615 2006-10-10  Bruno Haible  <bruno@clisp.org>
2616
2617         Make it possible to #define gcd to an alias.
2618         * lib/gcd.c: Include config.h.
2619
2620 2006-10-10  Bruno Haible  <bruno@clisp.org>
2621
2622         Make it possible to #define c_isascii to an alias.
2623         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
2624         defined. Undefine the macros before defining them, to avoid gcc
2625         warnings.
2626         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
2627         define NO_C_CTYPE_MACROS early.
2628
2629 2006-10-10  Bruno Haible  <bruno@clisp.org>
2630
2631         Make it possible to #define set_program_name to an alias.
2632         * lib/progname.c: Don't undefine set_program_name; instead, undefine
2633         ENABLE_RELOCATABLE early.
2634
2635 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
2636
2637         Port to Tandem NSK OSS, which has 64-bit signed int but at most
2638         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
2639         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
2640         More generally, don't assume that 64-bit signed int is available
2641         if unsigned int is, and vice versa.
2642         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
2643         unsigned symbols, not on their signed counterparts.
2644         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
2645         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
2646         (UINT64_C, UINTMAX_C):
2647         Likewise.
2648         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
2649         unsigned counterparts.
2650         (Have_long_long, Unsigned): New macros.
2651         (Int): Renamed from INT.
2652         (strtoimax): Use the new macros.
2653         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
2654         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
2655         * modules/inttypes (inttypes.h): Substitute
2656         HAVE_UNSIGNED_LONG_LONG_INT.
2657         * modules/stdint (stdint.h): Likewise.
2658         (Files): Add m4/ulonglong.m4.
2659
2660 2006-10-10  Bruno Haible  <bruno@clisp.org>
2661
2662         Fix a gcc -Wshadow warning.
2663         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
2664         to 'bucket'.
2665         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
2666         gl_linked_indexof_from_to): Likewise.
2667         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
2668         Likewise.
2669         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
2670         Likewise.
2671         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
2672         Reported by Eric Blake.
2673
2674 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2675
2676         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
2677         for NetBSD.  Problem reported by Bruno Haible.
2678
2679 2006-10-09  Jim Meyering  <jim@meyering.net>
2680
2681         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
2682         Patch from Bruno Haible.
2683
2684 2006-10-09  Jim Meyering  <jim@meyering.net>
2685
2686         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
2687         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
2688         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
2689
2690 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
2691
2692         Don't include <config.h> twice; this doesn't work in some cases,
2693         e.g., when config.h has "#define intmax_t long long int" and
2694         we include <config.h>, <inttypes.h>, <config.h> in that order.
2695         Problem reported by Matthew Woehlke in:
2696         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
2697         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
2698         * lib/fts-cycle.c: Don't include config.h.
2699         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
2700         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
2701         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
2702         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
2703         inttypes.h.
2704         * lib/xstrtoumax.c: Likewise.
2705         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
2706         __strtol and the like, so that this module is more like its siblings.
2707         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
2708         Remove; no longer needed now that we assume gnulib inttypes.h.
2709
2710 2006-10-08  Bruno Haible  <bruno@clisp.org>
2711
2712         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
2713         option.
2714
2715 2006-10-07  Jim Meyering  <jim@meyering.net>
2716
2717         * modules/inttypes (inttypes.h): Revert what seems to have been
2718         an inadvertent part of today's change: use "|", not "/" in the
2719         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
2720
2721 2006-10-07  Bruno Haible  <bruno@clisp.org>
2722
2723         * modules/sublist: New file.
2724
2725 2006-10-07  Bruno Haible  <bruno@clisp.org>
2726
2727         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
2728         * modules/argz (argz.h): Likewise.
2729         * modules/arpa_inet (arpa/inet.h): Likewise.
2730         * modules/byteswap (byteswap.h): Likewise.
2731         * modules/configmake (configmake.h): Likewise.
2732         * modules/fcntl (fcntl.h): Likewise.
2733         * modules/fnmatch (fnmatch.h): Likewise.
2734         * modules/getopt (getopt.h): Likewise.
2735         * modules/glob (glob.h): Likewise.
2736         * modules/inttypes (inttypes.h): Likewise.
2737         * modules/netinet_in (netinet/in.h): Likewise.
2738         * modules/poll (poll.h): Likewise.
2739         * modules/stdbool (stdbool.h): Likewise.
2740         * modules/stdint (stdint.h): Likewise.
2741         * modules/sys_select (sys/select.h): Likewise.
2742         * modules/sys_socket (sys/socket.h): Likewise.
2743         * modules/sys_stat (sys/stat.h): Likewise.
2744         * modules/sysexits (sysexits.h): Likewise.
2745         * modules/unistd (unistd.h): Likewise.
2746         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2747         Add a "DO NOT EDIT" comment to the generated file.
2748         (func_import): Likewise for gnulib-comp.m4.
2749
2750 2006-10-07  Bruno Haible  <bruno@clisp.org>
2751
2752         * lib/gl_sublist.h: New file.
2753         * lib/gl_sublist.c: New file.
2754
2755 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
2756
2757         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
2758         name (relative to the original working directory) and the file
2759         name component (relative to the temporary working directory).  All
2760         callers changed.
2761         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
2762         * lib/mkdir-p.c (make_dir_parents): Likewise.
2763         * lib/mkdir-p.h (make_dir_parents): Likewise.
2764
2765 2006-10-06  Eric Blake  <ebb9@byu.net>
2766
2767         Define several macros for use by the clean-temp module.
2768         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
2769         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
2770         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
2771
2772         * lib/clean-temp.h (close_stream_temp): New declaration.
2773         * lib/clean-temp.c (includes): Pull in headers according to what
2774         other modules are in use.
2775         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
2776
2777 2006-10-06  Bruno Haible  <bruno@clisp.org>
2778
2779         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
2780         instead of fopen, fwriteerror.
2781
2782 2006-10-06  Bruno Haible  <bruno@clisp.org>
2783
2784         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
2785         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
2786         int.
2787         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
2788         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
2789         Return an error indicator.
2790         Suggested by Eric Blake.
2791
2792 2006-10-06  Bruno Haible  <bruno@clisp.org>
2793
2794         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
2795         Reported by Eric Blake.
2796
2797 2006-10-06  Bruno Haible  <bruno@clisp.org>
2798
2799         * modules/closeout (Description): Mention stderr too.
2800
2801 2006-10-06  Bruno Haible  <bruno@clisp.org>
2802         and Paul Eggert  <eggert@cs.ucla.edu>
2803
2804         * lib/closeout.c (close_stdout): Also close stderr.
2805         * lib/closeout.h: Update comment.
2806
2807 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
2808
2809         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
2810         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
2811         * lib/dirchownmod.c: Include lchown.h.
2812         * lib/lchown.c: Don't include files that lchown.h now includes.
2813         Don't declare chown, since lchown.h now does that.
2814         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
2815         (lchown): Define to rpl_chown if lchown is declared but
2816         does not exist.  Declare using a prototype if lchown is not
2817         declared.  Add a copyright notice.
2818         * lib/mkstemp.h: Include <unistd.h>.
2819         * lib/openat.c: Include lchown.h.
2820
2821         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
2822         we now test for that separately.
2823         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
2824         rather than O_NOFOLLOW, when testing whether it's possible to
2825         avoid a race condition reliably.
2826         * lib/savewd.c (savewd_chdir): Likewise.
2827
2828         Remove macros that are no longer needed now that stdint.h is
2829         reliable.
2830         * lib/fsusage.c (UINTMAX_MAX): Remove.
2831         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
2832         * lib/utimecmp.c (SIZE_MAX): Remove.
2833
2834         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
2835
2836         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
2837         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
2838         O_NOATIME works.
2839
2840 2006-10-05  Bruno Haible  <bruno@clisp.org>
2841
2842         * lib/gl_list.h (gl_sortedlist_search_from_to,
2843         gl_sortedlist_indexof_from_to): New declarations.
2844         (gl_list_implementation): New fields sortedlist_search_from_to,
2845         sortedlist_indexof_from_to.
2846         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
2847         inline functions.
2848         * lib/gl_list.c (gl_sortedlist_search_from_to,
2849         gl_sortedlist_indexof_from_to): New functions.
2850         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
2851         function.
2852         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
2853         (gl_array_sortedlist_search_from_to): New function.
2854         (gl_array_list_implementation): Update.
2855         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
2856         function.
2857         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
2858         (gl_carray_sortedlist_search_from_to): New function.
2859         (gl_carray_list_implementation): Update.
2860         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
2861         gl_linked_sortedlist_indexof_from_to): New functions.
2862         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2863         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2864         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
2865         gl_tree_sortedlist_indexof_from_to): New functions.
2866         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2867         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2868         Update.
2869         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2870         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
2871         Update.
2872
2873 2006-10-05  Bruno Haible  <bruno@clisp.org>
2874
2875         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
2876         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
2877         (struct gl_list_implementation): Add fields search_from_to,
2878         indexof_from_to. Remove fields search, indexof.
2879         (gl_list_search): Use the search_from_to method.
2880         (gl_list_search_from, gl_list_search_from_to): New functions.
2881         (gl_list_indexof): Use the indexof_from_to method.
2882         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2883         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
2884         (gl_list_search_from, gl_list_search_from_to): New functions.
2885         (gl_list_indexof): Use the indexof_from_to method.
2886         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2887         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
2888         gl_array_indexof. Add start_index, end_index arguments.
2889         (gl_array_search_from_to): Renamed from gl_array_search. Add
2890         start_index, end_index arguments.
2891         (gl_array_remove, gl_array_list_implementation): Update.
2892         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
2893         gl_carray_indexof. Add start_index, end_index arguments.
2894         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
2895         start_index, end_index arguments.
2896         (gl_carray_remove, gl_carray_list_implementation): Update.
2897         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
2898         gl_linked_search. Add start_index, end_index arguments.
2899         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
2900         start_index, end_index arguments.
2901         (gl_linked_remove): Update.
2902         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2903         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2904         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
2905         field to 'size_t'.
2906         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
2907         gl_tree_search. Add start_index, end_index arguments.
2908         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2909         start_index, end_index arguments.
2910         (gl_tree_remove): Update.
2911         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2912         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2913         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
2914         function.
2915         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
2916         gl_tree_search. Add start_index, end_index arguments.
2917         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2918         start_index, end_index arguments.
2919         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2920         Update.
2921         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
2922
2923 2006-10-05  Bruno Haible  <bruno@clisp.org>
2924
2925         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
2926
2927         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
2928         fwriteerror_temp): New declarations.
2929         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
2930         (descriptors): New variable.
2931         (cleanup): First, close the descriptors.
2932         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
2933         fclose_temp, fwriteerror_temp): New functions.
2934
2935 2006-10-04  Jim Meyering  <jim@meyering.net>
2936
2937         * lib/fts.c (fts_open): Tiny comment change.
2938
2939 2006-10-04  Bruno Haible  <bruno@clisp.org>
2940
2941         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
2942         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
2943         gl_LOCK_BODY.
2944         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
2945         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
2946         gl_LOCK_EARLY_BODY.
2947         (gl_LOCK): Require gl_LOCK_BODY.
2948
2949 2006-10-04  Bruno Haible  <bruno@clisp.org>
2950
2951         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
2952         (gl_oset_search_atleast): New declaration.
2953         (struct gl_oset_implementation): Add field 'search_atleast'.
2954         (gl_oset_search_atleast): New inline function.
2955         * lib/gl_oset.c (gl_oset_search_atleast): New function.
2956         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
2957         (gl_array_oset_implementation): Update.
2958         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
2959         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
2960         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
2961
2962 2006-10-04  Bruno Haible  <bruno@clisp.org>
2963
2964         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
2965
2966 2006-10-03  Bruno Haible  <bruno@clisp.org>
2967
2968         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
2969         from gl_avltreehash_list_implementation.
2970
2971 2006-10-03  Bruno Haible  <bruno@clisp.org>
2972
2973         * lib/gl_oset.c (gl_oset_add): Fix return type.
2974
2975 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
2976
2977         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
2978
2979 2006-10-02  Eric Blake  <ebb9@byu.net>
2980
2981         * modules/strnlen (Depends-on): Add extensions.
2982
2983 2006-10-02  Eric Blake  <ebb9@byu.net>
2984
2985         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
2986         definition in 2.60+.
2987
2988 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
2989
2990         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
2991         checks.
2992
2993 2006-10-02  Bruno Haible  <bruno@clisp.org>
2994
2995         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
2996         to the AUTOMAKE_OPTIONS.
2997         Reported by Jim Meyering.
2998
2999 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
3000
3001         Work around bug in Solaris 10 /proc file system:
3002         /proc/self/fd/NNN/.. isn't the parent directory of
3003         the directory whose file descriptor is NNN.  This needs to
3004         be worked around at run time, not compile time, since a
3005         program might be built on Solaris 8, where things work, and
3006         run on Solaris 10.
3007         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
3008         to use the following interface instead:
3009         (OPENAT_BUFFER_SIZE): New macro.
3010         (openat_proc_name): New function.
3011         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
3012         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
3013         Likewise.
3014         * lib/openat-proc.c: New file.
3015         * modules/openat (Files): Add lib/openat-proc.c.
3016         (Depends-on): Add same-inode, stdbool.
3017         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
3018
3019 2006-09-29  Bruno Haible  <bruno@clisp.org>
3020
3021         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
3022         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
3023         argument. Set stdout_closed before testing for ferror, not after.
3024         (fwriteerror, fwriteerror_no_ebadf): New functions.
3025
3026 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3027
3028         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
3029
3030 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
3031
3032         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
3033         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
3034
3035 2006-09-28  Jim Meyering  <jim@meyering.net>
3036
3037         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
3038         Include <unistd.h>.
3039
3040 2006-09-28  Bruno Haible  <bruno@clisp.org>
3041
3042         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
3043         * modules/linkedhash-list (Depends-on): Likewise.
3044         * modules/rbtreehash-list (Depends-on): Likewise.
3045
3046 2006-09-28  Bruno Haible  <bruno@clisp.org>
3047
3048         * lib/strndup.h: Simplify the redefinition of strndup.
3049         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
3050         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
3051
3052 2006-09-28  Bruno Haible  <bruno@clisp.org>
3053
3054         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
3055         * lib/gl_linkedhash_list.c: Likewise.
3056         * lib/gl_rbtreehash_list.c: Likewise.
3057
3058 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
3059
3060         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
3061         getaddrinfo.
3062
3063         * lib/__fpending.h: Don't include <stdio_ext.h> unless
3064         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
3065         it causes <stdio_ext.h> to cause a compile-time error.
3066         Problem reported by Nelson H. F. Beebe.
3067         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
3068         of HAVE_DECL___PENDING.
3069
3070         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
3071         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
3072         declaration.
3073
3074 2006-09-27  Jim Meyering  <jim@meyering.net>
3075
3076         This file could end up with a definition for a function
3077         named __strndup, rather than rpl_strndup on a system with
3078         incomplete weak_alias support.
3079         * lib/strndup.c (strndup): Rename from __strndup.
3080         Remove #defines that used to map __strndup to strndup.
3081         Don't use K&R prototypes.
3082         Remove LIBC-related code, since this file is not sync'd with glibc.
3083         * lib/strndup.h: Revamp, accordingly.
3084         * m4/strndup.m4: Modernize.
3085
3086 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
3087
3088         * modules/savewd (Depends-on): Add 'raise'.
3089         * lib/savewd.c: Include <signal.h>, for 'raise'.
3090
3091 2006-09-26  Jim Meyering  <jim@meyering.net>
3092
3093         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
3094         when we detect Darwin 8.7.0's acl_get_file bug.
3095         Rearrange to perform the new (below) run-test while $LIBS
3096         contains any acl-related library.  Set USE_ACL at the end.
3097         (gl_ACL_GET_FILE): New function.
3098
3099 2006-09-26  Eric Blake  <ebb9@byu.net>
3100
3101         * lib/verror.c: Include <config.h> unconditionally.
3102
3103 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
3104
3105         * modules/clock-time (Maintainer): Add self.
3106         * modules/getlogin_r (Depends-on): Add extensions.
3107
3108 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3109
3110         * modules/clock-time: New module.
3111         * modules/nanosleep (Depends-on): Add clock-time.
3112         * modules/gethrxtime (Depends-on): Likewise.
3113         * modules/gettime (Depends-on): Likewise.
3114         * modules/settime (Depends-on): Likewise.
3115
3116         * modules/fts-lgpl: Depend on openat.
3117         * modules/mkancesdirs: Depend on savewd.
3118         * modules/mkdir-p: Likewise.
3119
3120 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3121
3122         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
3123
3124         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
3125         `gl_have_arbitrary_file_name_length_limit' to
3126         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
3127         actually works between configure runs.
3128
3129 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3130             Bruno Haible  <bruno@clisp.org>
3131
3132         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
3133
3134 2006-09-25  Jim Meyering  <jim@meyering.net>
3135
3136         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
3137         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
3138
3139 2006-09-25  Eric Blake  <ebb9@byu.net>
3140
3141         * gnulib-tool (func_import, func_create_testdir): Fix typos in
3142         exec's in 2006-09-18 patch when shuffling fds.
3143
3144 2006-09-25  Bruno Haible  <bruno@clisp.org>
3145
3146         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
3147         Reported by Jim Meyering.
3148
3149 2006-09-24  Jim Meyering  <jim@meyering.net>
3150
3151         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
3152         compare a pointer against a literal "0".  That caused failures with
3153         at least HP-UX's hpcc.
3154
3155 2006-09-22  Simon Josefsson  <jas@extundo.com>
3156
3157         * modules/gc-sha1:
3158         * modules/gc-md4:
3159         * modules/gc-hmac-sha1:
3160         * modules/gc-hmac-md5:
3161         * modules/gc-des:
3162         * modules/gc-arcfour: Distribute more files.
3163
3164 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3165
3166         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
3167         (gl_linked_iterator_from_to): Initialize struct completely.
3168         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
3169         (gl_tree_iterator_from_to): Likewise
3170         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
3171         * lib/gl_array_list.c [lint] (gl_array_iterator)
3172         (gl_array_iterator_from_to): Likewise.
3173         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
3174         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
3175         (gl_carray_iterator_from_to): Likewise.
3176
3177         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
3178         * lib/md4.c (md4_process_block): Remove unused variable.
3179         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
3180         parentheses for clarity.
3181
3182 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3183
3184         * modules/bison-i18n (Depends-on): Add gettext.
3185
3186 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3187
3188         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
3189         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
3190         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
3191         also add missing comma that caused broken test.
3192         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
3193         stdlib.h, for `abort'.
3194         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
3195         variables.
3196         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
3197         include unistd.h if present, for `rmdir'.
3198         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
3199         variables.
3200         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
3201         in the process include standard headers for prototypes.
3202         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
3203         gets declared on GNU/Linux.
3204         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
3205         unistd.h, for `rmdir'.
3206         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
3207
3208         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
3209         always true.
3210         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
3211
3212         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
3213
3214 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3215
3216         * gnulib-tool (func_version): Create output all at once.  This
3217         may help avoid triggering unnecessary SIGPIPEs, and at any
3218         rate it doesn't hurt.
3219
3220 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3221             Bruno Haible  <bruno@clisp.org>
3222
3223         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
3224         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
3225         * m4/signed.m4 (bh_C_SIGNED): Likewise.
3226
3227         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
3228         (gl_FUNC_VASPRINTF): Invoke it.
3229
3230 2006-09-22  Bruno Haible  <bruno@clisp.org>
3231
3232         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
3233         getloadavg.c as first argument.
3234
3235 2006-09-22  Bruno Haible  <bruno@clisp.org>
3236
3237         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
3238         at the beginning of the gl_INIT macro.
3239         * modules/getloadavg (configure.ac): Pass $gl_source_base to
3240         gl_GETLOADAVG.
3241
3242 2006-09-22  Bruno Haible  <bruno@clisp.org>
3243
3244         * gnulib-tool (func_create_megatestdir): Don't include the config-h
3245         module.
3246         Suggested by Ralf Wildenhues.
3247
3248 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
3249
3250         Import this patch from libc:
3251
3252         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
3253
3254         * lib/regex_internal.c (re_string_reconstruct): Handle
3255         offset < pstr->valid_raw_len && pstr->offsets_needed case.
3256         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
3257         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
3258         re_string_context_at.
3259
3260         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
3261         now requires it.
3262         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
3263         gl_REGEX now does it for us.
3264         (gl_REGEX): Add test taken from
3265         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
3266
3267         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
3268         Check that large offsets work.  Modernize Autoconf usages.
3269         Prefer "yes" to mean a good thing rather than a bad.
3270         Don't put "#define mkstemp" in config.h, as this might interfere
3271         with standard system headers that "#define mkstemp mkstemp64".
3272
3273         * modules/mkstemp (Depends-on): Add extensions, so that
3274         mkstemp is visible on some platforms.
3275         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
3276         (Include): Change to "mkstemp.h" from <stdlib.h>.
3277         (Files): Add mkstemp.h.
3278
3279         * lib/mkstemp.h: New file, since some standard headers
3280         #define mkstemp.
3281         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
3282         Include "mkstemp.h".
3283         Make the _LIBC code resemble glibc original more,
3284         e.g., use K&R style.
3285         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
3286         (mkstemp): Remove, since mkstemp.h does this for us.
3287         * lib/stdlib--.h: Include mkstemp.h.
3288
3289         Import this patch from libc:
3290
3291         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3292
3293         * lib/tempname.c (__gen_tempname): Change attempts_min
3294         into a macro.  Use preprocessor to decide how to initialize
3295         attempts [Coverity CID 67].
3296
3297 2006-09-20  Bruno Haible  <bruno@clisp.org>
3298
3299         * lib/mkdtemp.c: Import from libc.
3300         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3301                 * sysdeps/posix/tempname.c (__gen_tempname): Change
3302                 attempts_min into a macro.  Use preprocessor to decide how to
3303                 initialize attempts [Coverity CID 67].
3304         2001-11-27  Paul Eggert  <eggert@twinsun.com>
3305                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
3306                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
3307
3308 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3309
3310         * gnulib-tool (func_exit): New function, to allow to pass the
3311         exit status portably through the trap.  Use everywhere.
3312         (--help, --version): Signal a write error.
3313         (trap): catch SIGPIPE, for write errors.
3314         Exit at the end of the trap, with the correct exit status.
3315
3316 2006-09-19  Karl Berry  <karl@gnu.org>
3317
3318         * doc/gnulib.texi: note about the license texinfo files.
3319
3320 2006-09-19  Eric Blake  <ebb9@byu.net>
3321
3322         * gnulib-tool: Avoid space-tab.
3323
3324 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3325
3326         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
3327         that prevented coreutils 6.1 from building.  Problem reported
3328         by Petter Reinholdtsen.
3329
3330 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3331
3332         * gnulib-tool (avoidlist): Fix typo that broke options like
3333         --avoid=lock that are used by coreutils bootstrap.
3334
3335 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
3336
3337         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
3338         more systematically.
3339
3340 2006-09-18  Jim Meyering  <jim@meyering.net>
3341
3342         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
3343
3344 2006-09-18  Bruno Haible  <bruno@clisp.org>
3345
3346         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
3347
3348 2006-09-18  Bruno Haible  <bruno@clisp.org>
3349
3350         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
3351         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
3352         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
3353         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
3354         * m4/gettext.m4: Require autoconf >= 2.52.
3355         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
3356         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
3357         of gl_cv_header_inttypes_h.
3358
3359 2006-09-18  Bruno Haible  <bruno@clisp.org>
3360
3361         * lib/javaversion.c: Include configmake.h.
3362
3363 2006-09-18  Bruno Haible  <bruno@clisp.org>
3364
3365         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
3366         avoid that the while loops be executed in a subshell.
3367
3368 2006-09-18  Bruno Haible  <bruno@clisp.org>
3369
3370         * MODULES.html.sh (func_module): Break long lines.
3371         Suggested by Bruce Korb <bkorb@gnu.org>.
3372
3373 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3374
3375         Speed up by a factor of 1.12.
3376         * gnulib-tool (nl): New variable.
3377         (func_import): Rewrite include directive extraction to only read each
3378         directive once.
3379
3380 2006-09-17  Bruno Haible  <bruno@clisp.org>
3381
3382         * modules/javaversion (Makefile.am): Remove DEFS setting.
3383         (Depends-on): Add configmake, for PKGDATADIR definition.
3384
3385 2006-09-17  Bruno Haible  <bruno@clisp.org>
3386
3387         * gnulib-tool (func_create_testdir): Rewrite all files at once.
3388
3389 2006-09-17  Bruno Haible  <bruno@clisp.org>
3390
3391         * gnulib-tool (func_append): New function, stolen from libtool.m4.
3392         (func_modules_transitive_closure, func_modules_add_dummy,
3393         func_modules_to_filelist, func_import, func_create_testdir,
3394         func_create_megatestdir, ...): Use it wherever possible.
3395         Suggested by Ralf Wildenhues.
3396
3397 2006-09-16  Karl Berry  <karl@gnu.org>
3398
3399         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
3400         to avoid sectioning errors.
3401         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
3402         [ifinfo]: blank line after @center-ed titles.
3403         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
3404         Spell FSF address consistently with others.
3405         (These changes approved by rms.)
3406
3407 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3408
3409         Speed up by a factor of 1.61.
3410         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
3411         already checked module names again.
3412
3413 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3414
3415         Speed up by a factor of 1.13.
3416         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
3417         for new_files, and the input to func_add_or_update.
3418
3419 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3420
3421         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
3422         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
3423
3424 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3425
3426         * modules/mkancesdirs (Depends-on): Add fcntl.
3427         * modules/savewd: New file.
3428         * MODULES.html.sh (File system functions): Add savewd.
3429
3430         * modules/configmake (Makefile.am): Add support for the
3431         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
3432
3433 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3434
3435         * m4/savewd.m4: New file.
3436
3437 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3438
3439         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
3440         (dirchownmod): New arg FD.  All callers changed.
3441         Use FD rather than opening the directory ourself, as opening is
3442         now the caller's responsibility.
3443         * lib/dirchownmod.h: Likewise.
3444         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
3445         hosts that require <sys/types.h> before <sys/stat.h>.  Include
3446         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
3447         (test_dir): Remove.
3448         (mkancesdirs): Return length of prefix of FILE that has already
3449         been made, or -2 if there is a child doing the work.  Redo
3450         algorithm so that it is O(N) rather than O(N**2).  Optimize away
3451         ".", and treat ".." specially since it might stray back into
3452         already-created areas.  Use a subprocess if necessary.  New arg
3453         WD; all users changed.  MAKE_DIR function should now return 1
3454         if it creates a directory that is not readable.  Return -2 if
3455         a child process is spun off.
3456         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
3457         Adjust signature to match code.
3458         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
3459         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
3460         all users changed.
3461         * lib/savewd.c, lib/savewd.h: New files.
3462
3463 2006-09-15  Jim Meyering  <jim@meyering.net>
3464
3465         * modules/rename-dest-slash: New module.
3466         * MODULES.html.sh (posix_compat): Add it here.
3467
3468         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
3469
3470 2006-09-15  Jim Meyering  <jim@meyering.net>
3471
3472         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
3473         file.
3474
3475         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
3476
3477 2006-09-15  Jim Meyering  <jim@meyering.net>
3478
3479         * lib/rename-dest-slash.c (has_trailing_slash): Use
3480         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
3481         (rpl_rename_dest_slash): Perform the cheaper trailing slash
3482         test before testing whether SRC is a directory.
3483         Suggestions from Bruno Haible.
3484
3485         Avoid a warning about an unused variable.
3486         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
3487         into the #ifdef block where it's used.
3488
3489         * lib/rename-dest-slash.c: New file.
3490
3491 2006-09-14  Bruno Haible  <bruno@clisp.org>
3492
3493         * lib/allocsa.c: Include <config.h> unconditionally.
3494         * lib/asnprintf.c: Likewise.
3495         * lib/asprintf.c: Likewise.
3496         * lib/c-strcasecmp.c: Likewise.
3497         * lib/c-strcasestr.c: Likewise.
3498         * lib/c-strncasecmp.c: Likewise.
3499         * lib/c-strstr.c: Likewise.
3500         * lib/classpath.c: Likewise.
3501         * lib/clean-temp.c: Likewise.
3502         * lib/concatpath.c: Likewise.
3503         * lib/copy-file.c: Likewise.
3504         * lib/csharpcomp.c: Likewise.
3505         * lib/csharpexec.c: Likewise.
3506         * lib/execute.c: Likewise.
3507         * lib/fatal-signal.c: Likewise.
3508         * lib/findprog.c: Likewise.
3509         * lib/fwriteerror.c: Likewise.
3510         * lib/gl_array_list.c: Likewise.
3511         * lib/gl_array_oset.c: Likewise.
3512         * lib/gl_avltree_list.c: Likewise.
3513         * lib/gl_avltree_oset.c: Likewise.
3514         * lib/gl_avltreehash_list.c: Likewise.
3515         * lib/gl_carray_list.c: Likewise.
3516         * lib/gl_linked_list.c: Likewise.
3517         * lib/gl_linkedhash_list.c: Likewise.
3518         * lib/gl_list.c: Likewise.
3519         * lib/gl_oset.c: Likewise.
3520         * lib/gl_rbtree_list.c: Likewise.
3521         * lib/gl_rbtree_oset.c: Likewise.
3522         * lib/gl_rbtreehash_list.c: Likewise.
3523         * lib/imaxabs.c: Likewise.
3524         * lib/imaxdiv.c: Likewise.
3525         * lib/javacomp.c: Likewise.
3526         * lib/javaexec.c: Likewise.
3527         * lib/javaversion.c: Likewise.
3528         * lib/linebreak.c: Likewise.
3529         * lib/localcharset.c: Likewise.
3530         * lib/lock.c: Likewise.
3531         * lib/mbchar.c: Likewise.
3532         * lib/mbswidth.c: Likewise.
3533         * lib/mkdtemp.c: Likewise.
3534         * lib/pipe.c: Likewise.
3535         * lib/printf-args.c: Likewise.
3536         * lib/printf-parse.c: Likewise.
3537         * lib/progname.c: Likewise.
3538         * lib/progreloc.c: Likewise.
3539         * lib/readlink.c: Likewise.
3540         * lib/sh-quote.c: Likewise.
3541         * lib/stpcpy.c: Likewise.
3542         * lib/stpncpy.c: Likewise.
3543         * lib/strcasecmp.c: Likewise.
3544         * lib/strcasestr.c: Likewise.
3545         * lib/strcspn.c: Likewise.
3546         * lib/striconv.c: Likewise.
3547         * lib/strncasecmp.c: Likewise.
3548         * lib/strnlen1.c: Likewise.
3549         * lib/strstr.c: Likewise.
3550         * lib/strtok_r.c: Likewise.
3551         * lib/tls.c: Likewise.
3552         * lib/tmpdir.c: Likewise.
3553         * lib/unicodeio.c: Likewise.
3554         * lib/unsetenv.c: Likewise.
3555         * lib/vasnprintf.c: Likewise.
3556         * lib/vasprintf.c: Likewise.
3557         * lib/wait-process.c: Likewise.
3558         * lib/xallocsa.c: Likewise.
3559         * lib/xsetenv.c: Likewise.
3560         * lib/xstriconv.c: Likewise.
3561
3562 2006-09-13  Simon Josefsson  <jas@extundo.com>
3563
3564         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
3565         that internally, suggested by Ralf Wildenhues
3566         <Ralf.Wildenhues@gmx.de>.
3567
3568 2006-09-13  Simon Josefsson  <jas@extundo.com>
3569
3570         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
3571         @LIBOBJS@.
3572         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3573
3574 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
3575
3576         * lib/_fpending.c: Include <config.h> unconditionally, since we no
3577         longer worry about uses that don't define HAVE_CONFIG_H.
3578         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
3579         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
3580         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
3581         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
3582         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
3583         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
3584         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
3585         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
3586         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
3587         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
3588         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
3589         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
3590         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
3591         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
3592         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
3593         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
3594         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
3595         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
3596         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
3597         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
3598         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
3599         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
3600         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
3601         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
3602         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
3603         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
3604         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
3605         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
3606         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
3607         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
3608         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
3609         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
3610         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
3611         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
3612         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
3613         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
3614         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
3615         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
3616         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
3617         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
3618         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
3619         Likewise.
3620
3621 2006-09-13  Eric Blake  <ebb9@byu.net>
3622
3623         * lib/getopt.c: Fix typo in last commit.
3624
3625 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
3626
3627         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
3628         dgettext.
3629
3630 2006-09-12  Jim Meyering  <jim@meyering.net>
3631
3632         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
3633         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
3634         Reported by Nelson H. F. Beebe.
3635
3636 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
3637
3638         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
3639         program_invocation_name and program_invocation_short_name are
3640         initialized.
3641         * lib/argp-namefrob.h: Move declarations of program_invocation_name
3642         and program_invocation_short_name to argp.h, so they are visible
3643         to user programs.
3644         * lib/argp.h: Likewise
3645
3646 2006-09-10  Bruno Haible  <bruno@clisp.org>
3647
3648         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
3649         m4/inttypes_h.m4, m4/uintmax_t.m4.
3650
3651 2006-09-10  Bruno Haible  <bruno@clisp.org>
3652
3653         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
3654         gl_AC_TYPE_UINTMAX_T.
3655
3656 2006-09-10  Bruno Haible  <bruno@clisp.org>
3657
3658         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
3659
3660 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
3661
3662         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
3663         convention.  Text proposed by Bruno Haible.
3664         (struct argp_option): Document the use of N_() wrappers.
3665
3666         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
3667         '\v', and translate the two parts separately, instead of feeding
3668         the whole string to gettext.  This allows to exclude
3669         '\v' from the strings visible to the translator by writing doc
3670         strings as N_("..") "\v" N_("..").
3671
3672 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
3673
3674         * config/srclist.txt: Undo latest change; the bug was fixed.
3675
3676 2006-09-09  Bruno Haible  <bruno@clisp.org>
3677
3678         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
3679         assignments if building a library without libtool.
3680         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
3681         in func_emit_lib_Makefile_am.
3682         (func_import): When building a static library libfoo.a, arrange to
3683         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
3684         (func_create_testdir): Likewise.
3685         * modules/gc (configure.ac, Makefile.am): If building statically,
3686         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
3687         * modules/iconvme (configure.ac, Makefile.am): Likewise.
3688         * modules/striconv (configure.ac, Makefile.am): Likewise.
3689         Based on a suggestion by Ralf Wildenhues.
3690
3691 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3692
3693         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
3694         Check for unistd.h too, since Autoconf doesn't assume POSIX.
3695         Also:
3696
3697         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3698         Add year_2050_test to catch glibc bug 2821
3699         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3700
3701         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
3702         Prefer #ifdef to #if.
3703
3704         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
3705         Return from 'main' instead of calling 'exit'.
3706
3707 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3708
3709         * lib/mktime.c (guess_time_tm): Fix bug where mktime
3710         returned the maximum time_t value rather than (time_t) -1.
3711         Problem originally reported by William Bardwell
3712         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3713
3714         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3715         Moved to here ...
3716         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3717         ... from here.
3718
3719 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3720
3721         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
3722         2821 is fixed.
3723
3724 2006-09-08  Jim Meyering  <jim@meyering.net>
3725
3726         Don't make generated files read-only.  That would bother too many
3727         people.  However, do retain the ability to work when targets are
3728         read-only: remove the destination and temporary files before writing
3729         them (when generated via sed or echo), or by using the -f option for
3730         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
3731         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3732         * modules/byteswap, modules/configmake, modules/fcntl:
3733         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3734         * modules/localcharset, modules/netinet_in, modules/poll:
3735         * modules/stdbool, modules/stdint, modules/sys_select:
3736         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3737
3738 2006-09-08  Jim Meyering  <jim@meyering.net>
3739
3740         Avoid new build failure on FreeBSD 6.0.
3741         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
3742         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
3743         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
3744
3745 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3746
3747         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
3748
3749 2006-09-07  Jim Meyering  <jim@meyering.net>
3750
3751         Fix global typo in last change: use chmod u-w, not chmod u-x.
3752         Spotted by Paul Eggert and Bruce Korb.
3753         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3754         * modules/byteswap, modules/configmake, modules/fcntl:
3755         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3756         * modules/localcharset, modules/netinet_in, modules/poll:
3757         * modules/stdbool, modules/stdint, modules/sys_select:
3758         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3759
3760 2006-09-06  Jim Meyering  <jim@meyering.net>
3761
3762         Make generated files be read-only.
3763         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
3764         Ensure that each generated file is now read-only.
3765         * modules/argz: Likewise.
3766         * modules/arpa_inet: Likewise.
3767         * modules/byteswap: Likewise.
3768         * modules/configmake: Likewise.
3769         * modules/fcntl: Likewise.
3770         * modules/fnmatch: Likewise.
3771         * modules/getopt: Likewise.
3772         * modules/glob: Likewise.
3773         * modules/inttypes: Likewise.
3774         * modules/netinet_in: Likewise.
3775         * modules/poll: Likewise.
3776         * modules/stdbool: Likewise.
3777         * modules/stdint: Likewise.
3778         * modules/sys_select: Likewise.
3779         * modules/sys_socket: Likewise.
3780         * modules/sys_stat: Likewise.
3781         * modules/sysexits: Likewise.
3782         * modules/localcharset: Same as above, but continue using temporary
3783         file named "t-$@" (why different?) rather than the "$@-t" used
3784         everywhere else.
3785
3786         * modules/sysexits (Makefile.am): Replace literal occurrences
3787         of "sysexit.h" more readable, and more consistent, "$@".
3788
3789 2006-09-06  Bruno Haible  <bruno@clisp.org>
3790
3791         * modules/striconv: New file.
3792         * modules/xstriconv: New file.
3793         * MODULES.html.sh (Internationalization functions): Add striconv,
3794         xstriconv.
3795
3796 2006-09-06  Bruno Haible  <bruno@clisp.org>
3797
3798         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
3799         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
3800         not using libtool correctly.
3801
3802 2006-09-06  Bruno Haible  <bruno@clisp.org>
3803
3804         * lib/striconv.h: New file.
3805         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
3806         iconvstring.c.
3807         * lib/xstriconv.h: New file.
3808         * lib/xstriconv.c: New file.
3809
3810 2006-09-06  Bruno Haible  <bruno@clisp.org>
3811
3812         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
3813         lib_..._LDFLAGS.
3814
3815 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3816
3817         * lib/argz_.h: Sync from Libtool.
3818
3819         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
3820                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3821
3822         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
3823
3824 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3825
3826         * modules/trim: New file.
3827
3828 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3829
3830         * lib/trim.h: New file.
3831         * lib/trim.c: New file.
3832
3833 2006-09-05  Bruno Haible  <bruno@clisp.org>
3834
3835         * MODULES.html.sh (String handling): Add trim.
3836
3837 2006-09-04  Karl Berry  <karl@gnu.org>
3838
3839         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
3840         until next release.
3841
3842 2006-09-03  Bruno Haible  <bruno@clisp.org>
3843
3844         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
3845         correctly.
3846
3847 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3848
3849         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
3850         not gl_GETLOADAVG.  Omit unneeded semicolons.
3851         Problems reported by Ralf Wildenhues in
3852         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3853         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
3854         at the end, which is the usual gnulib style.
3855
3856         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
3857         of doing all the work ourselves.
3858         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
3859         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
3860
3861 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3862
3863         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
3864         Problem reported by Ralf Wildenhues in
3865         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3866
3867         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
3868         HAVE_STRUCT_STATFS_F_FSTYPENAME.
3869
3870 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3871
3872         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
3873         yesterday's patch by changing test -n to test -z.
3874
3875 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3876
3877         * modules/getloadavg (Files): Add m4/getloadavg.m4.
3878         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
3879         the former is now obsolescent.
3880
3881         * modules/chdir-long (Depends-on): Add fcntl.
3882
3883 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3884
3885         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
3886         obsolescent, and programs should use gnulib instead.
3887         * m4/getloadavg.m4: New file, with contents taken from Autoconf
3888         but with prefixes changed.
3889
3890 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3891
3892         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
3893         or stdbool.h, because they might not exist while configuring.
3894
3895         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
3896         Don't include unistd.h or limits.h; not needed, since chdir-long.h
3897         does that for us.
3898         (O_DIRECTORY): Remove.
3899
3900 2006-08-31  Eric Blake  <ebb9@byu.net>
3901
3902         * gnulib-tool: Don't let emacs change spaces to TAB.
3903
3904 2006-08-31  Bruno Haible  <bruno@clisp.org>
3905
3906         * gnulib-tool: When calling func_import more than once, do it in a
3907         subshell.
3908         Reported by Eric Blake <ebb9@byu.net>.
3909
3910 2006-08-31  Bruno Haible  <bruno@clisp.org>
3911
3912         * gnulib-tool (nl): Remove variable.
3913         (sed_transform_lib_file): Use more robust test for config-h module.
3914         (func_import): Fix typo in 2006-08-25 patch.
3915
3916 2006-08-31  Bruno Haible  <bruno@clisp.org>
3917
3918         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
3919         specified, augment Makefile.am variables instead of assigning them.
3920
3921 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3922
3923         Work around a bug in both the Linux and SunOS 64-bit kernels:
3924         nanosleep mishandles sleeps for longer than 2**31 seconds.
3925         Problem reported by Frank v Waveren in
3926         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3927         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
3928         Check for nanosleep bug.
3929         (LIB_NANOSLEEP): Append clock_gettime library if needed.
3930
3931 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3932
3933         Work around a bug in both the Linux and SunOS 64-bit kernels:
3934         nanosleep mishandles sleeps for longer than 2**31 seconds.
3935         Problem reported by Frank v Waveren in
3936         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3937         * lib/nanosleep.c (BILLION): New constant.
3938         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
3939         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
3940         implementation.
3941
3942 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3943
3944         * modules/nanosleep (Depends-on): Add gettime.
3945
3946 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3947         and Simon Josefsson  <jas@extundo.com>
3948         and Oskar Liljeblad  <oskar@osk.mine.nu>
3949
3950         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
3951         * gnulib-tool (func_import): New license type 'unmodifiable license
3952         text'.
3953         * modules/fdl: Use it.  Longer description.
3954         * module/gpl, module/lgpl: New files.
3955
3956 2006-08-30  Jim Meyering  <jim@meyering.net>
3957
3958         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
3959         shadowing the parameter.
3960
3961 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3962
3963         Sync from Libtool:
3964
3965         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3966
3967         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
3968         sharing with gnulib.  Report by Eric Blake.
3969
3970 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3971
3972         * modules/isapipe: New file.
3973         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
3974
3975 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3976
3977         * modules/configmake (Makefile.am): Add a comment, and omit
3978         the CONFIGMAKE_ prefix from generated macro names.  Suggested
3979         by Bruno Haible.
3980
3981 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3982
3983         * m4/isapipe.m4: New file.
3984
3985 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3986
3987         * lib/isapipe.c, lib/isapipe.h: New files.
3988
3989 2006-08-29  Jim Meyering  <jim@meyering.net>
3990
3991         * modules/configmake (Makefile.am): Make configmake.h depend on
3992         Makefile.  Otherwise, a stale configmake.h could hang around.
3993
3994 2006-08-29  Eric Blake  <ebb9@byu.net>
3995
3996         * lib/error.c (error_at_line, print_errno_message): Match libc, after
3997         resolution of upstream bug 3044.
3998
3999 2006-08-29  Bruno Haible  <bruno@clisp.org>
4000
4001         * modules/localcharset (Depends-on): Add configmake.
4002         (Makefile.am): Remove setting of LIBDIR through DEFS.
4003
4004 2006-08-29  Bruno Haible  <bruno@clisp.org>
4005
4006         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
4007         defined.
4008
4009 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4010
4011         * modules/fcntl: New file.
4012         * modules/chdir-safer (Depends-on): Add fcntl.
4013         * modules/fts: Likewise.
4014         * modules/mkdir-p: Likewise.
4015
4016         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
4017         This undoes the most recent change, since we're now addressing the
4018         problem in a different way.
4019
4020         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
4021         into output, since the output might be called Makefile.am even
4022         if $makefile_name is something different.
4023         (func_import): Use $makefile_am rather than
4024         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
4025         empty.
4026
4027         * modules/inttypes (Files): Add m4/inttypes-h.m4.
4028
4029 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4030
4031         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
4032         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
4033         recent change to stdint.m4, since we're now addressing the problem in a
4034         different way.
4035
4036 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4037
4038         * m4/fcntl_h.m4: New file.
4039
4040 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4041
4042         * lib/fcntl_.h: New file.
4043         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
4044         the fcntl module.
4045         * lib/dirchownmod.c: Likewise.
4046         * lib/fts.c: Likewise.
4047
4048         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
4049         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
4050         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
4051         just before including <inttypes.h>, to avoid circular inclusion.
4052
4053 2006-08-28  Jim Meyering  <jim@meyering.net>
4054
4055         * doc/visibility.texi: Actually read and correct the grammar of the
4056         sentence affected by yesterday's change.
4057
4058 2006-08-28  Eric Blake  <ebb9@byu.net>
4059
4060         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
4061         needs wrapper.
4062
4063 2006-08-28  Eric Blake  <ebb9@byu.net>
4064
4065         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
4066
4067 2006-08-28  Eric Blake  <ebb9@byu.net>
4068
4069         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
4070
4071 2006-08-28  Bruno Haible  <bruno@clisp.org>
4072
4073         * modules/c-strstr: New file, from GNU gettext.
4074         * MODULES.html.sh (String handling): Add c-strstr.
4075
4076 2006-08-28  Bruno Haible  <bruno@clisp.org>
4077
4078         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
4079         macros.
4080         Reported by Eric Blake.
4081
4082 2006-08-28  Bruno Haible  <bruno@clisp.org>
4083
4084         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
4085         (VASNPRINTF): Return a string of length > INT_MAX without failing.
4086         * lib/vasprintf.c: Include errno.h, limits.h.
4087         (EOVERFLOW): New fallback definition.
4088         (vasprintf): Test here whether the string length is > INT_MAX.
4089         * lib/vsnprintf.c: Include errno.h, limits.h.
4090         (EOVERFLOW): New fallback definition.
4091         (vsnprintf): Fix bug when generated string was too long for the buffer.
4092         Test here whether the string length is > INT_MAX.
4093
4094 2006-08-28  Bruno Haible  <bruno@clisp.org>
4095
4096         * lib/inttypes_.h (SCNX*): Remove definitions.
4097         Reported by Eric Blake.
4098
4099 2006-08-28  Bruno Haible  <bruno@clisp.org>
4100
4101         * lib/c-strstr.h: New file, from GNU gettext.
4102         * lib/c-strstr.c: New file, from GNU gettext.
4103
4104 2006-08-28  Bruno Haible  <bruno@clisp.org>
4105
4106         * gnulib-tool: Reorder some statements.
4107
4108 2006-08-28  Bruno Haible  <bruno@clisp.org>
4109
4110         * gnulib-tool: New option --makefile-name.
4111         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
4112         $makefile_name.
4113         (func_import): Write $makefile_name to the cache file, and read it from
4114         there unless explicitly specified. Use $makefile_name as file name
4115         instead of Makefile.am. Adjust the recommendations accordingly.
4116
4117 2006-08-28  Bruno Haible  <bruno@clisp.org>
4118
4119         * gnulib-tool (func_verify_module): Check against misapplying patch.
4120
4121 2006-08-28  Bruno Haible  <bruno@clisp.org>
4122
4123         * gnulib-tool (func_relativize, func_relconcat): New functions.
4124         Give an error if --local-dir is given with --update.
4125         Remove trailing slashes from $local_gnulib_dir.
4126         (func_import): Store the relativized $local_gnulib_dir in
4127         gnulib-cache.m4, and read it from there if not specified explicitly.
4128
4129 2006-08-28  Bruno Haible  <bruno@clisp.org>
4130
4131         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
4132         is the current directory. Respect also $local_gnulib_dir.
4133
4134 2006-08-28  Bruno Haible  <bruno@clisp.org>
4135             Simon Josefsson  <jas@extundo.com>
4136
4137         BeOS portability.
4138         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
4139
4140 2006-08-27  Jim Meyering  <jim@meyering.net>
4141
4142         * doc/visibility.texi: Remove duplicate word: "pointer".
4143
4144 2006-08-26  Bruno Haible  <bruno@clisp.org>
4145
4146         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
4147         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
4148         (Makefile.am): Create inttypes.h from inttypes_.h.
4149         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
4150
4151         * modules/imaxabs: New file.
4152
4153         * modules/imaxdiv: New file.
4154
4155 2006-08-26  Bruno Haible  <bruno@clisp.org>
4156
4157         * m4/inttypes.m4: New file.
4158         * m4/_inttypes_h.m4: Remove file.
4159         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
4160         PRI_MACROS_BROKEN.
4161         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
4162
4163         * m4/imaxabs.m4: New file.
4164
4165         * m4/imaxdiv.m4: New file.
4166
4167 2006-08-26  Bruno Haible  <bruno@clisp.org>
4168
4169         * lib/inttypes_.h: New file.
4170         * lib/inttypes.h: Remove file.
4171         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
4172
4173         * lib/imaxabs.c: New file.
4174
4175         * lib/imaxdiv.c: New file.
4176
4177 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4178
4179         New config-h module, so that "make" output needn't be cluttered
4180         by -DHAVE_CONFIG_H.
4181         * MODULES.html.sh (Support for building libraries and executables):
4182         Add config-h.
4183         * modules/config-h: New file.
4184         * gnulib-tool (nl, sed_transform_lib_file): New vars.
4185         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
4186         the config-h module is used.
4187
4188         New configmake module, so that "make" output needn't be cluttered
4189         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
4190         * MODULES.html.sh (Support for building libraries and executables):
4191         Add configmake.
4192         * modules/configmake: New file.
4193
4194 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4195
4196         * m4/config-h.m4: New file.
4197
4198 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4199
4200         * config/srclist.txt: Add elisp-comp.
4201
4202 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4203
4204         * MODULES.html.sh (Support for building libraries and executables):
4205         Add elisp-comp.
4206         * build-aux/elisp-comp: New file.
4207         * modules/elisp-comp: New file.
4208
4209 2006-08-24  Bruno Haible  <bruno@clisp.org>
4210
4211         * gnulib-tool (func_create_testdir): Use non-default values of
4212         sourcebase and m4base.
4213
4214 2006-08-24  Bruno Haible  <bruno@clisp.org>
4215
4216         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
4217         HTML structure.
4218
4219 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
4220
4221         * modules/openat (Depends-on): Add lchown.
4222
4223 2006-08-23  Bruno Haible  <bruno@clisp.org>
4224
4225         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
4226         of gl_LOCK_EARLY instead of gl_LOCK.
4227
4228 2006-08-23  Bruno Haible  <bruno@clisp.org>
4229
4230         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
4231         on OSF/1 to no.
4232         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
4233
4234 2006-08-23  Bruno Haible  <bruno@clisp.org>
4235
4236         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
4237         as unusable.
4238
4239         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
4240         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
4241         (gl_LOCK): New macro.
4242
4243 2006-08-22  Simon Josefsson  <jas@extundo.com>
4244
4245         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
4246         to md5 module.
4247
4248 2006-08-22  Simon Josefsson  <jas@extundo.com>
4249
4250         * MODULES.html.sh: Add "Support for maintaining and release
4251         projects".
4252
4253         * build-aux/gnupload: New file, from coreutils.
4254
4255 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4256
4257         Avoid the need for AC_LIBSOURCES in m4 macros.
4258         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
4259         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
4260         * modules/check-version (EXTRA_DIST): Add check-version.h.
4261         * modules/crc (EXTRA_DIST): Add crc.h.
4262         * modules/des (EXTRA_DIST): Add des.h.
4263         * modules/gc (EXTRA_DIST): Add gc.h.
4264         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
4265         * modules/getline (EXTRA_DIST): Add getline.h.
4266         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
4267         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
4268         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
4269         * modules/md2 (EXTRA_DIST): Add md2.h.
4270         * modules/md4 (EXTRA_DIST): Add md4.h.
4271         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
4272         * modules/read-file (EXTRA_DIST): Add read-file.h.
4273         * modules/readline (EXTRA_DIST): Add readline.h.
4274         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
4275         rijndael-api-fst.h.
4276
4277 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4278
4279         * m4/rijndael.m4 (gl_ARCFOUR):
4280         * m4/arctwo.m4 (gl_ARCTWO):
4281         * m4/check-version.m4 (gl_CHECK_VERSION):
4282         * m4/crc.m4 (gl_CRC):
4283         * m4/des.m4 (gl_DES):
4284         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
4285         * m4/gc.m4 (gl_GC):
4286         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
4287         * m4/getline.m4 (gl_FUNC_GETLINE):
4288         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
4289         * m4/hmac-md5.m4 (gl_HMAC_MD5):
4290         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
4291         * m4/md2.m4 (gl_MD2):
4292         * m4/md4.m4 (gl_MD4):
4293         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
4294         * m4/read-file.m4 (gl_FUNC_READ_FILE):
4295         * m4/readline.m4 (gl_FUNC_READLINE):
4296         * m4/rijndael.m4 (gl_RIJNDAEL):
4297         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4298         to get the necessary .h files and whatnot.
4299
4300 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4301
4302         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
4303         gnulib rather than the other way around.
4304         * config/srclistvars.sh (COREUTILS): Remove.
4305
4306 2006-08-22  Jim Meyering  <jim@meyering.net>
4307
4308         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
4309
4310         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
4311
4312 2006-08-22  Eric Blake  <ebb9@byu.net>
4313
4314         * modules/regexprops-generic: New file.
4315         * MODULES.html.sh (Support for building documentation): List it.
4316
4317 2006-08-22  Eric Blake  <ebb9@byu.net>
4318
4319         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
4320         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
4321         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
4322         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
4323
4324 2006-08-22  Bruno Haible  <bruno@clisp.org>
4325
4326         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
4327         and lib_LTLIBRARIES like the other lib_* variables.
4328
4329 2006-08-22  Bruno Haible  <bruno@clisp.org>
4330
4331         * build-aux/x-to-1.in: New file, from GNU gettext.
4332
4333 2006-08-22  Bruno Haible  <bruno@clisp.org>
4334
4335         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
4336         <utmpx.h> exists.
4337
4338 2006-08-22  Bruno Haible  <bruno@clisp.org>
4339
4340         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
4341         <utmpx.h> exists.
4342
4343 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4344
4345         BeOS portability.
4346         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
4347         exist.
4348         Problem reported by Bruno Haible.
4349
4350 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4351
4352         Avoid the need for AC_LIBSOURCES in m4 macros.
4353         * modules/acl (EXTRA_DIST): Add acl.h.
4354         * modules/argmatch (Files): Add m4/argmatch.m4.
4355         (configure.ac): Add gl_ARGMATCH.
4356         (EXTRA_DIST): Renamed from lib_SOURCES, for
4357         consistency with the other modules.  Remove argmatch.c.
4358         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
4359         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
4360         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
4361         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
4362         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
4363         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
4364         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
4365         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
4366         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
4367         * modules/closeout (EXTRA_DIST): Add closeout.h.
4368         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
4369         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
4370         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
4371         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
4372         dirname.h; remove basename.c and stripslash.c.
4373         * modules/exclude (EXTRA_DIST): Add exclude.h.
4374         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
4375         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
4376         * modules/file-type (EXTRA_DIST): Add file-type.h.
4377         * modules/filemode (EXTRA_DIST): Add filemode.h.
4378         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
4379         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4380         * modules/fpending (EXTRA_DIST): Add __fpending.h.
4381         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
4382         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
4383         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
4384         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
4385         * modules/getdate (EXTRA_DIST): Add getdate.c.
4386         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
4387         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
4388         * modules/getpass (EXTRA_DIST): Add getpass.h.
4389         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
4390         * modules/group-member (EXTRA_DIST): Add group-member.h.
4391         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
4392         * modules/hash (EXTRA_DIST): Add hash.h.
4393         * modules/human (EXTRA_DIST): Add human.h.
4394         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
4395         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
4396         * modules/lchown (EXTRA_DIST): Add lchown.h.
4397         * modules/long-options (EXTRA_DIST): Add long-options.h.
4398         * modules/lstat (EXTRA_DIST): Add lstat.h.
4399         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
4400         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
4401         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
4402         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
4403         * modules/memxor (EXTRA_DIST): Add memxor.h.
4404         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
4405         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
4406         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
4407         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
4408         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
4409         * modules/physmem (EXTRA_DIST): Add physmem.h.
4410         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
4411         * modules/posixver (EXTRA_DIST): Add posixver.h.
4412         * modules/quote (EXTRA_DIST): Add quote.h.
4413         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
4414         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
4415         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
4416         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
4417         regex_internal.h regexec.c.
4418         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
4419         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
4420         * modules/same (EXTRA_DIST): Add same.h.
4421         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
4422         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
4423         * modules/savedir (EXTRA_DIST): Add savedir.h.
4424         * modules/sha1 (EXTRA_DIST): Add sha1.h.
4425         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
4426         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
4427         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
4428         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
4429         * modules/strdup (EXTRA_DIST): Add strdup.h.
4430         * modules/strftime (EXTRA_DIST): Add strftime.h.
4431         * modules/strndup (EXTRA_DIST): Add strndup.h.
4432         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
4433         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
4434         * modules/time_r (EXTRA_DIST): Add time_r.h.
4435         * modules/timespec (EXTRA_DIST): Add timespec.h.
4436         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4437         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
4438         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
4439         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
4440         * modules/userspec (EXTRA_DIST): Add userspec.h.
4441         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
4442         * modules/utimens (EXTRA_DIST): Add utimens.h.
4443         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
4444         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
4445         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
4446         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
4447         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
4448         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
4449         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
4450         * modules/yesno (EXTRA_DIST): Add yesno.h.
4451
4452 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4453
4454         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
4455
4456         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
4457         * m4/dev-ino.m4, same-inode.m4: Remove.
4458
4459         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
4460         * m4/acl.m4 (AC_FUNC_ACL):
4461         * m4/backupfile.m4 (gl_BACKUPFILE):
4462         * m4/c-strtod.m4 (gl_C99_STRTOLD):
4463         * m4/canon-host.m4 (gl_CANON_HOST):
4464         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4465         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
4466         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
4467         * m4/cloexec.m4 (gl_CLOEXEC):
4468         * m4/close-stream.m4 (gl_CLOSE_STREAM):
4469         * m4/closeout.m4 (gl_CLOSEOUT):
4470         * m4/dirfd.m4 (gl_FUNC_DIRFD):
4471         * m4/dirname.m4 (gl_DIRNAME):
4472         * m4/exclude.m4 (gl_EXCLUDE):
4473         * m4/exitfail.m4 (gl_EXITFAIL):
4474         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
4475         * m4/file-type.m4 (gl_FILE_TYPE):
4476         * m4/filemode.m4 (gl_FILEMODE):
4477         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
4478         * m4/fpending.m4 (gl_FUNC_FPENDING):
4479         * m4/fprintftime.m4 (gl_FPRINTFTIME):
4480         * m4/fts.m4 (gl_FUNC_FTS):
4481         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
4482         * m4/getdate.m4 (gl_GETDATE):
4483         * m4/gethrxtime.m4 (gl_GETHRXTIME):
4484         * m4/getpagesize.m4 (gl_GETPAGESIZE):
4485         * m4/getpass.m4 (gl_FUNC_GETPASS):
4486         * m4/gettime.m4 (gl_GETTIME):
4487         * m4/getugroups.m4 (gl_GETUGROUPS):
4488         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
4489         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
4490         * m4/hard-locale.m4 (gl_HARD_LOCALE):
4491         * m4/hash.m4 (gl_HASH):
4492         * m4/idcache.m4 (gl_IDCACHE):
4493         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
4494         * m4/lchown.m4 (gl_FUNC_LCHOWN):
4495         * m4/long-options.m4 (gl_LONG_OPTIONS):
4496         * m4/lstat.m4 (gl_FUNC_LSTAT):
4497         * m4/md5.m4 (gl_MD5):
4498         * m4/memcasecmp.m4 (gl_MEMCASECMP):
4499         * m4/memcoll.m4 (gl_MEMCOLL):
4500         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
4501         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
4502         * m4/memxor.m4 (gl_MEMXOR):
4503         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
4504         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
4505         * m4/modechange.m4 (gl_MODECHANGE):
4506         * m4/mountlist.m4 (gl_MOUNTLIST):
4507         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4508         * m4/openat.m4 (gl_FUNC_OPENAT):
4509         * m4/pathmax.m4 (gl_PATHMAX):
4510         * m4/physmem.m4 (gl_PHYSMEM):
4511         * m4/posixtm.m4 (gl_POSIXTM):
4512         * m4/posixver.m4 (gl_POSIXVER):
4513         * m4/quote.m4 (gl_QUOTE):
4514         * m4/quotearg.m4 (gl_QUOTEARG):
4515         * m4/readtokens.m4 (gl_READTOKENS):
4516         * m4/readutmp.m4 (gl_READUTMP):
4517         * m4/regex.m4 (gl_REGEX):
4518         * m4/safe-read.m4 (gl_SAFE_READ):
4519         * m4/safe-write.m4 (gl_SAFE_WRITE):
4520         * m4/same.m4 (gl_SAME):
4521         * m4/save-cwd.m4 (gl_SAVE_CWD):
4522         * m4/savedir.m4 (gl_SAVEDIR):
4523         * m4/settime.m4 (gl_SETTIME):
4524         * m4/sha1.m4 (gl_SHA1):
4525         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
4526         * m4/stat-macros.m4 (gl_STAT_MACROS):
4527         * m4/stat-time.m4 (gl_STAT_TIME):
4528         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
4529         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
4530         * m4/strdup.m4 (gl_FUNC_STRDUP):
4531         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
4532         * m4/strndup.m4 (gl_FUNC_STRNDUP):
4533         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
4534         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
4535         * m4/time_r.m4 (gl_TIME_R):
4536         * m4/timespec.m4 (gl_TIMESPEC):
4537         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
4538         * m4/unlinkdir.m4 (gl_UNLINKDIR):
4539         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
4540         * m4/userspec.m4 (gl_USERSPEC):
4541         * m4/utimecmp.m4 (gl_UTIMECMP):
4542         * m4/utimens.m4 (gl_UTIMENS):
4543         * m4/xalloc.m4 (gl_XALLOC):
4544         * m4/xgetcwd.m4 (gl_XGETCWD):
4545         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
4546         * m4/xreadlink.m4 (gl_XREADLINK):
4547         * m4/xstrtod.m4 (gl_XSTRTOD):
4548         * m4/yesno.m4 (gl_YESNO):
4549         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4550         to get the necessary .h files and whatnot.
4551
4552 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
4553             Bruno Haible  <bruno@clisp.org>
4554
4555         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
4556         /bin/sh understanding of '!' conditional negation.
4557
4558 2006-08-21  Jim Meyering  <jim@meyering.net>
4559
4560         * modules/openat (Depends-on): Really alphabetize.
4561
4562         * modules/acl (Depends-on): Add error and quote.
4563
4564         * check-module (find_included_lib_files): Add at-func.c to the
4565         ok-to-include-more-than-once white list.
4566
4567         * modules/openat (Depends-on): Add lstat.  Alphabetize.
4568
4569 2006-08-21  Bruno Haible  <bruno@clisp.org>
4570
4571         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4572         Emit a pkgdata_DATA variable only if some snippets add contents to it.
4573         Reported by Martin Lambers <marlam@marlam.de>.
4574
4575 2006-08-21  Bruno Haible  <bruno@clisp.org>
4576
4577         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
4578         specify an installation location, don't emit a noinst_LIBRARIES or
4579         noinst_LTLIBRARIES assignment.
4580
4581 2006-08-21  Bruno Haible  <bruno@clisp.org>
4582
4583         BeOS portability.
4584         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
4585         BeOS has mbrtowc() but no <wctype.h>.
4586
4587 2006-08-21  Bruno Haible  <bruno@clisp.org>
4588
4589         BeOS portability.
4590         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
4591         exist.
4592
4593 2006-08-21  Bruno Haible  <bruno@clisp.org>
4594
4595         BeOS portability.
4596         * lib/mbchar.h: Include <wctype.h> only if it exists.
4597
4598 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4599
4600         Remove files that are no longer needed by their respective modules.
4601         * m4/obstack.m4: Remove.
4602         * m4/strerror_r.m4: Remove.
4603         * m4/uint32_t.m4: Remove.
4604         * m4/uintptr_t.m4: Remove.
4605         * m4/ullong_max.m4: Remove.
4606         * m4/xstrtoimax.m4: Remove.
4607         * m4/xstrtoumax.m4: Remove.
4608
4609         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
4610         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
4611         dependencies now capture this.
4612
4613         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
4614         Do not use AC_LIBSOURCES, since gnulib modules now do this.
4615         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
4616         * m4/human.m4 (gl_HUMAN): Likewise.
4617         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
4618         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
4619
4620         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
4621
4622         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
4623         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
4624         stdint.
4625         * m4/human.m4 (gl_HUMAN): Likewise.
4626         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
4627         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
4628         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4629         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4630         * m4/xstrtol (gl_XSTRTOL): Likewise.
4631
4632         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
4633         AC_TYPE_LONG_LONG_INT.
4634         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4635         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
4636         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
4637         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4638
4639         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
4640         on stdbool.
4641
4642         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
4643         (gl_PREREQ_XSTRTOUL): Remove.
4644
4645         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
4646
4647         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
4648         mode.
4649
4650 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4651
4652         Add and change modules to make it easier for coreutils to use
4653         gnulib-tool.
4654         * modules/backupfile (Files): Remove m4/d-ino.m4.
4655         (Depends-on): Add d-ino.
4656         * modules/cycle-check (Depends-on): Add stdint.
4657         (lib_SOURCES): Add cycle-check.h.
4658         * modules/d-ino: New module.
4659         * modules/d-type: New module.
4660         * modules/error (Files): Remove m4/strerror_r.m4.
4661         * modules/filemode (Files): Add m4/st_dm_mode.m4.
4662         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4663         m4/inttypes_h.m4, m4/uintmax_t.m4.
4664         (Depends-on): Add stdint.
4665         (lib_SOURCES): Add fsusage.h.
4666         * modules/getcwd (Files): Remove d-ino.m4.
4667         (Depends-on): Add d-ino.
4668         * modules/getndelim2 (Depends-on): Add stdint.
4669         * modules/glob (Files): Remove m4/d-type.m4.
4670         (Depends-on): Add d-type.
4671         * modules/host-os: New module.
4672         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
4673         m4/inttypes_h.m4, m4/uintmax_t.m4.
4674         * Depends-on: Add stdint.
4675         (lib_SOURCES): Add human.h.
4676         * modules/inttostr (Files): Remove m4/intmax_t.m4,
4677         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
4678         m4/uintmax_t.m4, m4/ulonglong.m4.
4679         (Depends-on): Add stdint.
4680         (EXTRA_DIST): Add inttostr.h.
4681         * modules/lchmod: New module.
4682         * modules/link-follow: New module.
4683         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
4684         (Depends-on): Add lchmod.
4685         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
4686         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
4687         (Depends-on): Add stdint.
4688         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
4689         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
4690         (Depends-on): Add stdint.
4691         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
4692         * modules/perl: New module.
4693         * modules/regex (Depends-on): Add stdint.
4694         * modules/rmdir-errno: New module.
4695         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4696         m4/intmax_t.m4.
4697         (Depends-on): Add stdint.
4698         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4699         m4/uintmax_t.m4.
4700         (Depends-on): Add stdint.
4701         * modules/unlink-busy: New module.
4702         * modules/utimecmp (Depends-on): Add stdint.
4703         * modules/uptime: New module.
4704         * modules/winsz-ioctl: New module.
4705         * modules/winsz-termios: New module.
4706         * modules/xnanosleep (Depends-on): Add nanosleep.
4707         * modules/ullong_max: Remove.
4708         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
4709         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
4710         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
4711         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
4712         (Depends-on): Add inttypes.
4713         (lib_SOURCES): Add xstrtol.h.
4714         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
4715         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
4716         * MODULES.html.sh: Move 'assert' into the assert section.
4717         Move 'dummy' into the linking section.
4718         Remove ullong_max.
4719         Add section for compatibility checks for POSIX:2001 functions,
4720         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
4721         winsz-ioctl, and winsz-termios into it.
4722         Add lchmod.
4723         Add top-level Misc section and put host-os, perl, and uptime
4724         into it.
4725
4726 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4727
4728         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
4729         now assume the stdint module.  Do not include inttypes.h.
4730         * lib/fsusage.h: Likewise.
4731         * lib/getndelim2.c: Likewise.
4732         * lib/human.h: Likewise.
4733         * lib/inttostr.h: Likewise.
4734         * lib/obstack.c: Likewise.
4735         * lib/regex_internal.h: Likewise.
4736         * lib/tempname.c: Likewise.
4737         * lib/utimecmp.c: Likewise.
4738         * lib/xstrtol.h: Likewise.
4739
4740         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
4741
4742         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
4743         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
4744         * lib/xtime.h: Likewise.
4745
4746 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4747
4748         * modules/openat (Files): Add lib/fchmodat.c.
4749         Fixes problem reported by Jay Youngman.
4750
4751 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4752
4753         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
4754         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
4755
4756 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
4757             Bruno Haible  <bruno@clisp.org>
4758
4759         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
4760         and is a script that invokes bison. Tighten the code. Add comments.
4761
4762 2006-08-18  Jim Meyering  <jim@meyering.net>
4763
4764         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
4765         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
4766         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
4767         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
4768
4769 2006-08-18  Bruno Haible  <bruno@clisp.org>
4770
4771         * modules/bison-i18n: New file.
4772         * MODULES.html.sh (Internationalization functions): Add it.
4773
4774 2006-08-18  Bruno Haible  <bruno@clisp.org>
4775
4776         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
4777         sys/statvfs.h. When getmntinfo was found, check its declaration and
4778         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
4779
4780 2006-08-18  Bruno Haible  <bruno@clisp.org>
4781
4782         * m4/bison-i18n.m4: New file, from bison.
4783
4784 2006-08-18  Bruno Haible  <bruno@clisp.org>
4785
4786         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
4787         (ME_DUMMY): Treat "kernfs" as a dummy.
4788         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
4789
4790 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4791
4792         Update from coreutils.
4793
4794         2006-08-15  Jim Meyering  <jim@meyering.net>
4795
4796         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
4797
4798         2006-01-17  Jim Meyering  <jim@meyering.net>
4799
4800         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
4801
4802         2006-01-11  Jim Meyering  <jim@meyering.net>
4803
4804         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
4805         Check for the lchmod function.
4806
4807 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4808
4809         Update from coreutils.
4810
4811         * lib/__fpending.h: Add copyright notice.
4812         * lib/fprintftime.h: Likewise.
4813         * lib/savedir.c: Use (C) in copyright notice.
4814         * lib/savedir.h: Likewise.
4815
4816         2006-08-15  Jim Meyering  <jim@meyering.net>
4817
4818         * lib/at-func.c: New file, with the logic of all emulated at-functions.
4819         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
4820         in support of the EXPECTED_ERRNO macro.
4821         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
4822         definitions.  Instead, define the appropriate symbols and include
4823         "at-func.c".
4824         * lib/mkdirat.c (mkdirat): Likewise.
4825         * lib/fchmodat.c (fchmodat): Likewise.
4826         (ENOSYS): Remove definition.
4827         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
4828         it.  Don't include "unistd--.h" -- it wasn't ever used.
4829
4830         2006-01-17  Jim Meyering  <jim@meyering.net>
4831
4832         Rewrite fts.c not to change the current working directory,
4833         by using openat, fstatat, fdopendir, etc..
4834
4835         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
4836         (HAVE_OPENAT_SUPPORT): Define.
4837         [_LIBC] (fchdir): Don't undef or define; no longer used.
4838         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
4839         Now, this `function' always succeeds, and consumes its file descriptor
4840         parameter -- so callers must not close such FDs.  Update callers.
4841         (diropen_fd, opendirat, cwd_advance_fd): New functions.
4842         (diropen): Add parameter, SP.  Adjust all callers.
4843         Implement using diropen_fd, rather than open.
4844         (fts_open): Initialize new member, fts_cwd_fd.
4845         Remove fts_rft-setting code.
4846         (fts_close): Close fts_cwd_fd, if necessary.
4847         (__opendir2): Define in terms of opendir or opendirat,
4848         depending on whether the FST_NOCHDIR flag is set.
4849         (fts_build): Since fts_safe_changedir consumes its FD, and since
4850         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
4851         and close the dup'd file descriptor upon failure.
4852         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
4853         (fts_safe_changedir): Tweak semantics to reflect that this function
4854         now calls cwd_advance_fd and hence consumes its FD argument.
4855         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
4856         [struct FTS] (fts_rft): Remove now-unused member.
4857         [struct FTS] (fts_cycle.state): Improve comment.
4858
4859         * lib/openat.c (openat_needs_fchdir): New function.
4860         * lib/openat.h (openat_needs_fchdir): Declare it.
4861
4862 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
4863
4864         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
4865         Problem and fix reported by Pádraig Brady in
4866         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
4867
4868 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4869
4870         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
4871
4872 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4873
4874         * lib/memcoll.c (memcoll): Optimize for the common case where the
4875         arguments are bytewise equal.
4876
4877 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4878
4879         * doc/regexprops-generic.texi: Add a copyright notice.
4880
4881 2006-08-15  Bruno Haible  <bruno@clisp.org>
4882
4883         * modules/tmpdir (License): Change to LGPL.
4884
4885 2006-08-15  Bruno Haible  <bruno@clisp.org>
4886
4887         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
4888         module.
4889
4890 2006-08-14  Simon Josefsson  <jas@extundo.com>
4891
4892         * config/srclist.txt: Add gnupload.
4893
4894 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4895
4896         Change copyright notice from LGPL 2 to GPL 2, since that's the
4897         standard form used in the gnulib repository.
4898         * tests/test-lock.c: Likewise.
4899         * tests/test-stdint.c: Likewise.
4900         * tests/test-tls.c: Likewise.
4901
4902         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
4903         prelude-manager.  User shorter URLs for GNU projects, without '?'.
4904         Add copyright notice.
4905
4906         * check-module: Add copyright notice.  Output a copyright
4907         notice if "--version" is specified.
4908         * modules/COPYING: New file.
4909         * tests/test-getaddrinfo.c: Add copyright notice.
4910         * tests/test-verify.c: Likewise.
4911
4912 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4913
4914         Change copyright notice from LGPL 2 to GPL 2, since that's the
4915         standard form used in the gnulib repository.
4916         * lib/lock.c: LGPL -> GPL.
4917         * lib/lock.h: Likewise.
4918         * lib/strnlen1.c: Likewise.
4919         * lib/strnlen1.h: Likewise.
4920         * lib/tls.c: Likewise.
4921         * lib/tls.h: Likewise.
4922         * lib/tmpdir.c: Likewise.
4923
4924         * lib/TODO: Remove; this belongs only in coreutils.
4925
4926 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4927
4928         Add copyright notices to long-enough files that lack them, since
4929         otherwise the files aren't clearly free.  Use the same notice that
4930         getdate.texi already uses.
4931         * doc/alloca-opt.texi: Add copyright notice.
4932         * doc/alloca.texi: Likewise.
4933         * doc/ctime.texi: Likewise.
4934         * doc/functions.texi: Likewise.
4935         * doc/gcd.texi: Likewise.
4936         * doc/gnulib-tool.texi: Likewise.
4937         * doc/inet_ntoa.texi: Likewise.
4938         * doc/visibility.texi: Likewise.
4939
4940         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
4941         * doc/quote.texi: Add copyright notice.
4942
4943         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
4944         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
4945         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
4946         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
4947         is now obsolete, and give a pointer to the Sun list.
4948         Add copyright notice.
4949
4950 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4951
4952         * config/srclistvars.sh: Add copyright notice.
4953
4954 2006-08-14  Eric Blake  <ebb9@byu.net>
4955
4956         Import the following change from libc:
4957
4958         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
4959
4960         Upstream bug 2997.
4961         * lib/misc/error.c: Add space between program name and message if file
4962         name is missing.
4963
4964 2006-08-12  Karl Berry  <karl@gnu.org>
4965
4966         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
4967         remove, these originate in gnulib now.
4968
4969 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4970
4971         * doc/Makefile (standards.info standards.html standards.dvi):
4972         Also depend on make-stds.texi.
4973
4974 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
4975
4976         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
4977         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
4978
4979         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
4980         in wchar_t.  Problem reported by Eric Blake.
4981
4982         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
4983         LEN is smaller than SIZE.  Suggested by Bruno Haible.
4984         Also, help the compiler to keep LEN in a register.
4985
4986 2006-08-11  Eric Blake  <ebb9@byu.net>
4987
4988         * users.txt: Sort.  Add tar.
4989
4990 2006-08-11  Bruno Haible  <bruno@clisp.org>
4991
4992         * users.txt: New file.
4993
4994 2006-08-11  Bruno Haible  <bruno@clisp.org>
4995
4996         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
4997         before <wchar.h>. Needed for OSF/1 and BSD/OS.
4998
4999 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5000
5001         * modules/snprintf (Depends-on): Remove minmax.
5002         (Maintainer): Add self and Bruno.
5003
5004 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5005
5006         * lib/.cppi-disable: Add snprintf.h, socket_.h.
5007         * lib/snprintf.c: Include <errno.h> and <limits.h>.
5008         (EOVERFLOW): Define if the system does not.
5009         Do not include "minmax.h"; it wasn't used.
5010         (snprintf): Don't assume size_t promotes to an unsigned type.
5011         Fix bug when generated string was too long for the buffer: the
5012         buffer's contents are supposed to be the initial prefix of the
5013         output.  Don't assume vasnprintf returns EOVERFLOW if the size
5014         exceeds INT_MAX; do the check ourselves.
5015
5016         Import the following changes from libc:
5017
5018         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
5019
5020         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
5021         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
5022         set wc to the byte which couldn't be converted.
5023         (re_string_reconstruct): Don't clear valid_raw_len before calling
5024         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
5025         tip_context using re_string_context_at.
5026
5027         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
5028
5029         * lib/posix/regex.h: g++ still cannot handled [restrict].
5030
5031         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
5032
5033         * lib/posix/regex.h: Remove special handling for VMS.
5034
5035 2006-08-10  Jim Meyering  <jim@meyering.net>
5036
5037         * modules/same-inode: New module.
5038         * modules/dev-ino: New module.
5039         * modules/cycle-check: Depend on these modules, rather than simply
5040         including their .h files.
5041         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
5042         required via m4/cycle-check.m4.
5043         * modules/same: Depend on new same-inode module, rather than
5044         including same-inode.h.
5045         * modules/chdir-safer: New file.
5046
5047         * modules/chown (Depends-on): Add stat-macros.
5048
5049 2006-08-10  Jim Meyering  <jim@meyering.net>
5050
5051         * m4/cycle-check.m4: New file.
5052         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
5053         * m4/dev-ino.m4, m4/same-inode.m4: New files.
5054
5055 2006-08-10  Eric Blake  <ebb9@byu.net>
5056
5057         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
5058         in from original proposal.
5059
5060 2006-08-10  Eric Blake  <ebb9@byu.net>
5061         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
5062
5063         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
5064         namespace.
5065
5066 2006-08-10  Bruno Haible  <bruno@clisp.org>
5067
5068         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
5069         as well.
5070
5071 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5072
5073         Sync from coreutils.
5074
5075         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
5076
5077         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
5078         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
5079
5080 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5081
5082         * modules/restrict: Remove; no longer needed now that we assume
5083         Autoconf 2.59 or later.
5084         * MODULES.html.sh: Remove 'restrict'.
5085         * modules/argp (Depends-on): Remove 'restrict'.
5086         * modules/base64 (Depends-on): Likewise.
5087         * modules/gc (Depends-on): Likewise.
5088         * modules/getaddrinfo (Depends-on): Likewise.
5089         * modules/glob (Depends-on): Likewise.
5090         * modules/inet_ntop (Depends-on): Likewise.
5091         * modules/inet_pton (Depends-on): Likewise.
5092         * modules/memxor (Depends-on): Likewise.
5093         * modules/regex (Depends-on): Likewise.
5094         * modules/strtok_r (Depends-on): Likewise.
5095         * modules/time_r (Depends-on): Likewise.
5096
5097 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5098
5099         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
5100         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
5101         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5102         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
5103         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
5104         * m4/memxor.m4 (gl_MEMXOR): Likewise.
5105         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
5106         gl_C_RESTRICT replaced by AC_C_RESTRICT.
5107
5108         Merge from coreutils.
5109         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
5110         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
5111         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
5112         * m4/time_r.m4 (gl_TIME_R): Likewise.
5113
5114 2006-08-09  Karl Berry  <karl@gnu.org>
5115
5116         * config/srclist.txt: no more gettext-tools, per Bruno.
5117
5118 2006-08-08  Eric Blake  <ebb9@byu.net>
5119
5120         * modules/verror: New module.
5121         * MODULES.html.sh: Document it.
5122
5123 2006-08-08  Eric Blake  <ebb9@byu.net>
5124
5125         * lib/verror.h, lib/verror.c: New files.
5126
5127 2006-08-08  Eric Blake  <ebb9@byu.net>
5128
5129         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
5130         verror_at_line output complies with GNU Coding Standards even when
5131         file is NULL.
5132
5133 2006-08-07  Bruno Haible  <bruno@clisp.org>
5134
5135         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
5136         versions of AIX.
5137         Reported by Ralf Wildenhues.
5138
5139 2006-08-07  Bruno Haible  <bruno@clisp.org>
5140
5141         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
5142         in an AC_DEFUN. Needed so that the autoconf snippets can use
5143         AC_REQUIRE.
5144
5145 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5146
5147         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5148         Initialize pkgdata_DATA.
5149         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
5150         overriding it.
5151
5152 2006-08-06  Eric Blake  <ebb9@byu.net>
5153
5154         * lib/error.h: Fold in some upstream changes from glibc.
5155         * lib/error.c: Likewise.
5156
5157 2006-08-04  Bruno Haible  <bruno@clisp.org>
5158
5159         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5160         Make the mostlyclean-local rule depend on mostlyclean-generic.
5161         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
5162
5163 2006-07-31  Bruno Haible  <bruno@clisp.org>
5164
5165         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
5166         <stdlib.h>, <string.h>.
5167
5168 2006-07-30  Bruno Haible  <bruno@clisp.org>
5169
5170         * modules/readlink (License): Change to LGPL.
5171
5172 2006-07-30  Bruno Haible  <bruno@clisp.org>
5173
5174         * modules/javaversion (Makefile.am): Distribute javaversion.java and
5175         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
5176         set PKGDATADIR to point to it.
5177
5178 2006-07-30  Bruno Haible  <bruno@clisp.org>
5179
5180         * modules/csharpexec (configure.ac): Comment out macro invocation.
5181         * modules/javaexec (configure.ac): Likewise.
5182         * modules/javacomp-script (configure.ac): Likewise.
5183
5184         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
5185
5186 2006-07-30  Bruno Haible  <bruno@clisp.org>
5187
5188         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
5189         linked-list.
5190
5191 2006-07-30  Bruno Haible  <bruno@clisp.org>
5192
5193         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
5194
5195 2006-07-30  Bruno Haible  <bruno@clisp.org>
5196
5197         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5198         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
5199         get removed.
5200
5201 2006-07-29  Bruno Haible  <bruno@clisp.org>
5202
5203         Make it possible for gnulib-tool to work with locally modified or
5204         augmented gnulib repositories.
5205         * gnulib-tool (func_usage): Document --local-dir option.
5206         (local_gnulib_dir): New variable.
5207         Handle --local-dir option.
5208         (func_lookup_file): New function.
5209         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
5210         (func_get_description, func_get_filelist, func_get_description,
5211         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
5212         func_get_automake_snippet, func_get_include_directive,
5213         func_get_license, func_get_maintainer): Use func_lookup_file.
5214         (func_import, func_create_testdir): Use func_lookup_file.
5215
5216 2006-07-29  Bruno Haible  <bruno@clisp.org>
5217
5218         * modules/setenv (Depends-on): Add unistd.
5219
5220 2006-07-29  Bruno Haible  <bruno@clisp.org>
5221
5222         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
5223
5224 2006-07-29  Bruno Haible  <bruno@clisp.org>
5225
5226         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
5227
5228 2006-07-29  Bruno Haible  <bruno@clisp.org>
5229
5230         * gnulib-tool (import, update): If there is no Makefile.am, look at
5231         aclocal.m4, instead of bailing out.
5232
5233 2006-07-29  Bruno Haible  <bruno@clisp.org>
5234
5235         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
5236         Categorize the options by when they are useful.
5237
5238 2006-07-29  Bruno Haible  <bruno@clisp.org>
5239
5240         * gnulib-tool (func_usage): Document option --no-libtool.
5241         Handle option --no-libtool.
5242         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
5243         for changed semantics of $libtool variable.
5244         (func_import): Likewise. If libtool is not used, show this through
5245         an option --no-libtool.
5246         (func_create_testdir): Update.
5247
5248 2006-07-29  Bruno Haible  <bruno@clisp.org>
5249
5250         * gnulib-tool (func_import): Extend error message about missing
5251         --doc-base.
5252
5253 2006-07-29  Bruno Haible  <bruno@clisp.org>
5254
5255         * gnulib-tool (func_import): Don't create the $docbase directory if
5256         there is no file to store there.
5257
5258 2006-07-29  Bruno Haible  <bruno@clisp.org>
5259
5260         * gnulib-tool (autoconf_minversion): If a --dir option is given and
5261         relevant, look for configure.ac there, not in the current directory.
5262         Also use a simple search for AC_PREREQ, not "autoconf --trace".
5263
5264 2006-07-29  Bruno Haible  <bruno@clisp.org>
5265
5266         * gnulib-tool (SORT): New variable.
5267         (func_usage): Undocument --assume-autoconf option.
5268         Remove --assume-autoconf option handling.
5269         (autoconf_minversion): Determine from the contents of configure.ac.
5270         (func_import): Remove autoconf_minversion handling.
5271         Suggested by Eric Blake.
5272
5273 2006-07-29  Bruno Haible  <bruno@clisp.org>
5274
5275         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
5276
5277 2006-07-29  Bruno Haible  <bruno@clisp.org>
5278
5279         * config/srclist.txt (*setenv.[ch]): Remove rules.
5280
5281 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5282
5283         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
5284
5285 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5286
5287         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
5288         arpa/inet.h.
5289
5290 2006-07-28  Simon Josefsson  <jas@extundo.com>
5291
5292         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
5293         * modules/inet_pton (Depends-on): Likewise.
5294
5295 2006-07-28  Simon Josefsson  <jas@extundo.com>
5296
5297         * m4/netinet_in_h.m4: New file.
5298
5299 2006-07-28  Simon Josefsson  <jas@extundo.com>
5300
5301         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
5302         #include's.
5303
5304 2006-07-28  Simon Josefsson  <jas@extundo.com>
5305
5306         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
5307         #include's.
5308
5309 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
5310
5311         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
5312         setgid on directories only if they set these bits.
5313         * lib/modechange.h: Remove obsolete comment about masks.
5314
5315 2006-07-28  Eric Blake  <ebb9@byu.net>
5316
5317         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
5318         macro expansion.
5319
5320 2006-07-28  Bruno Haible  <bruno@clisp.org>
5321
5322         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
5323
5324 2006-07-28  Bruno Haible  <bruno@clisp.org>
5325
5326         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
5327
5328 2006-07-28  Bruno Haible  <bruno@clisp.org>
5329
5330         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
5331         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
5332         Define fallbacks.
5333         Avoids link error on FreeBSD 4.x.
5334         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
5335
5336         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
5337         encoding.
5338         * lib/mbswidth.c (iswcntrl): Likewise.
5339
5340 2006-07-27  Bruno Haible  <bruno@clisp.org>
5341
5342         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
5343         test.
5344
5345 2006-07-27  Bruno Haible  <bruno@clisp.org>
5346
5347         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
5348         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
5349         defined.
5350
5351 2006-07-26  Eric Blake  <ebb9@byu.net>
5352
5353         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
5354
5355 2006-07-26  Eric Blake  <ebb9@byu.net>
5356
5357         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
5358         like mingw that lack mkstemp.
5359         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
5360         avoid compilation warning on mingw.
5361
5362 2006-07-26  Bruno Haible  <bruno@clisp.org>
5363
5364         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
5365         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
5366         INT_FAST*_MIN, INTPTR_MIN.
5367
5368 2006-07-25  Bruno Haible  <bruno@clisp.org>
5369
5370         * modules/version-etc (Depends-on): Add stdarg.
5371
5372 2006-07-25  Bruno Haible  <bruno@clisp.org>
5373
5374         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
5375         complex commands.
5376
5377 2006-07-25  Bruno Haible  <bruno@clisp.org>
5378
5379         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
5380         defined in <stdarg.h> or config.h.
5381
5382 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5383
5384         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
5385         (gl_STDIO_SAFER): Remove.
5386
5387 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5388
5389         * MODULES.html.sh (File stream based Input/Output):
5390         Add fopen-safer, tmpfile-safer; remove stdio-safer.
5391         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
5392         * modules/fopen-safer, modules/tmpfile-safer: New files.
5393         * modules/stdio-safer: Remove.
5394
5395 2006-07-24  Bruno Haible  <bruno@clisp.org>
5396
5397         * modules/tmpdir: New file.
5398         * MODULES.html.sh (File system functions): Add it.
5399
5400 2006-07-24  Bruno Haible  <bruno@clisp.org>
5401
5402         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
5403         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
5404
5405 2006-07-24  Bruno Haible  <bruno@clisp.org>
5406
5407         * modules/clean-temp: New file.
5408
5409 2006-07-24  Bruno Haible  <bruno@clisp.org>
5410
5411         * m4/tmpdir.m4: New file, from GNU gettext.
5412
5413 2006-07-24  Bruno Haible  <bruno@clisp.org>
5414
5415         * lib/tmpdir.h: New file, from GNU gettext.
5416         * lib/tmpdir.c: New file, from GNU gettext.
5417
5418 2006-07-24  Bruno Haible  <bruno@clisp.org>
5419
5420         * lib/clean-temp.h: New file, from GNU gettext.
5421         * lib/clean-temp.c: New file, from GNU gettext.
5422
5423 2006-07-23  Eric Blake  <ebb9@byu.net>
5424
5425         * modules/stdio-safer (Files): Add tmpfile-safer.c.
5426         (Depends-on): Add binary-io.
5427
5428 2006-07-23  Eric Blake  <ebb9@byu.net>
5429
5430         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
5431
5432 2006-07-23  Eric Blake  <ebb9@byu.net>
5433
5434         * lib/tmpfile-safer.c: New file.
5435         * lib/stdio-safer.h (fopen_safer): Add prototype.
5436         * lib/stdio--.h (tmpfile): Make safer.
5437
5438 2006-07-23  Bruno Haible  <bruno@clisp.org>
5439
5440         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
5441         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
5442         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
5443         gl_linked_remove_at): Use it.
5444
5445 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5446         and Simon Josefsson <jas@extundo.com>
5447
5448         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
5449
5450         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
5451
5452 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5453
5454         * modules/close-stream: New file.
5455         * modules/closeout (Description): Make it clear that it exits
5456         with a diagnostic on error.
5457         (Depends-on): Add close-stream.  Remove fpending, stdbool.
5458         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
5459
5460 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5461
5462         * m4/close-stream.m4: New file.
5463
5464 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5465
5466         * lib/close-stream.c, lib/close-stream.h: New files.
5467
5468 2006-07-22  Bruno Haible  <bruno@clisp.org>
5469
5470         Merge from GNU gettext 0.15.
5471
5472         2006-05-01  Bruno Haible  <bruno@clisp.org>
5473
5474                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
5475
5476         2006-07-22  Bruno Haible  <bruno@clisp.org>
5477
5478                 * modules/javaversion: New file.
5479                 * MODULES.html.sh (Java): Add javaversion.
5480
5481         2006-03-12  Bruno Haible  <bruno@clisp.org>
5482
5483                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
5484
5485         2005-12-04  Bruno Haible  <bruno@clisp.org>
5486
5487                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
5488                 (untested).
5489
5490         2006-06-21  Bruno Haible  <bruno@clisp.org>
5491
5492                 Avoid warnings from recent versions of mcs.
5493                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
5494                 -o, -L, -r any more. Use options documented since mcs-1.0
5495                 instead. Similarly for -g.
5496
5497         2005-12-04  Bruno Haible  <bruno@clisp.org>
5498
5499                 * build-aux/csharpcomp.sh.in: Suffix for resources is
5500                 .resources, not .resource.
5501
5502         2005-07-09  Bruno Haible  <bruno@clisp.org>
5503
5504                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
5505                 add a .dll suffix.
5506                 Reported by Mark Junker <mjscod@gmx.de>.
5507
5508         2006-07-22  Bruno Haible  <bruno@clisp.org>
5509
5510                 * modules/gettext: Upgrade to gettext-0.15.
5511                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
5512                 m4/visibility.m4.
5513                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
5514
5515 2006-07-22  Bruno Haible  <bruno@clisp.org>
5516
5517         Merge from GNU gettext 0.15.
5518
5519         2006-03-25  Bruno Haible  <bruno@clisp.org>
5520
5521                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
5522
5523         2006-07-21  Bruno Haible  <bruno@clisp.org>
5524
5525                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
5526                 "1.1".
5527
5528         2006-05-09  Bruno Haible  <bruno@clisp.org>
5529
5530                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
5531                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
5532                 for the conftestver execution.
5533
5534         2006-05-01  Bruno Haible  <bruno@clisp.org>
5535
5536                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
5537                 optional target-version argument. Verify that the compiler
5538                 groks source of the specified source-version, or add -source
5539                 option as necessary. Verify that the compiler produces
5540                 bytecode in the specified target-version, or add -target and
5541                 -source options as necessary. Make the result of the test
5542                 available as variable CONF_JAVAC. Also log error output in
5543                 config.log.
5544
5545         2006-03-11  Bruno Haible  <bruno@clisp.org>
5546
5547                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
5548
5549         2006-05-09  Bruno Haible  <bruno@clisp.org>
5550
5551                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
5552                 CLASSPATH_SEPARATOR to a semicolon.
5553
5554         2006-03-12  Bruno Haible  <bruno@clisp.org>
5555
5556                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
5557                 available as variable CONF_JAVA, for subsequent autoconf
5558                 tests. Also log error output in config.log.
5559
5560         2006-07-19  Bruno Haible  <bruno@clisp.org>
5561
5562                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
5563                 that getline works on glibc2 systems. Needed to avoid trouble
5564                 in relocatable.c.
5565                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
5566
5567         2005-12-04  Bruno Haible  <bruno@clisp.org>
5568
5569                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
5570                 launcher (untested).
5571
5572         2005-12-04  Bruno Haible  <bruno@clisp.org>
5573
5574                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
5575
5576         2006-07-22  Bruno Haible  <bruno@clisp.org>
5577
5578                 * gettext.m4: Update from GNU gettext-0.15.
5579                 * nls.m4: Likewise.
5580                 * po.m4: Likewise.
5581                 * inttypes-pri.m4: Likewise.
5582                 * inttypes-h.m4: Renamed from inttypes.m4.
5583                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
5584
5585 2006-07-22  Bruno Haible  <bruno@clisp.org>
5586
5587         Merge from GNU gettext 0.15.
5588
5589         2005-07-05  Bruno Haible  <bruno@clisp.org>
5590
5591                 * printf-args.c (printf_fetchargs): Work around broken
5592                 definition of wint_t on mingw.
5593
5594         2005-02-12  Bruno Haible  <bruno@clisp.org>
5595
5596                 * xallocsa.h: Add extern "C" for C++.
5597
5598         2006-05-17  Bruno Haible  <bruno@clisp.org>
5599
5600                 Cygwin portability.
5601                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
5602
5603         2006-04-30  Bruno Haible  <bruno@clisp.org>
5604
5605                 * progreloc.c: Include <mach-o/dyld.h> if available.
5606                 (find_executable): Use _NSGetExecutablePath when possible.
5607
5608         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5609
5610                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
5611                 function.
5612
5613         2005-12-29  Bruno Haible  <bruno@clisp.org>
5614
5615                 * progreloc.c (set_program_name_and_installdir): Fix
5616                 compilation error.
5617
5618         2005-12-04  Bruno Haible  <bruno@clisp.org>
5619
5620                 Cygwin portability.
5621                 * progreloc.c: Include <windows.h> also on Cygwin.
5622                 (find_executable): Add support for Cygwin.
5623                 (set_program_name_and_installdir): Handle also platforms with
5624                 nonempty EXEEXT.
5625
5626         2006-07-11  Bruno Haible  <bruno@clisp.org>
5627
5628                 * javacomp.c: Fix a comment.
5629                 Reported by Jim Meyering.
5630
5631         2006-04-30  Bruno Haible  <bruno@clisp.org>
5632
5633                 * javacomp.h (compile_java_class): Add source_version,
5634                 target_version arguments.
5635                 * javacomp.c: Rewritten to choose only a compiler that
5636                 respects the specified source_version and target_version.
5637
5638         2006-06-27  Bruno Haible  <bruno@clisp.org>
5639
5640                 Assume correct S_ISDIR macro.
5641                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
5642
5643         2006-07-22  Bruno Haible  <bruno@clisp.org>
5644
5645                 * javaversion.h: New file, from GNU gettext.
5646                 * javaversion.c: New file, from GNU gettext.
5647                 * javaversion.java: New file, from GNU gettext.
5648                 * javaversion.class: New file, from GNU gettext.
5649
5650         2006-05-17  Bruno Haible  <bruno@clisp.org>
5651
5652                 Cygwin portability.
5653                 * javaexec.c (execute_java_class): Test for jview program
5654                 also on Cygwin.
5655
5656         2006-04-09  Bruno Haible  <bruno@clisp.org>
5657
5658                 * fatal-signal.c: Don't include string.h.
5659                 (at_fatal_signal): Use a copying loop instead of memcpy.
5660
5661         2005-12-04  Bruno Haible  <bruno@clisp.org>
5662
5663                 * csharpexec.c: Add support for 'clix' launcher (untested).
5664                 (execute_csharp_using_sscli): New function.
5665                 (execute_csharp_program): Call it.
5666
5667         2006-06-21  Bruno Haible  <bruno@clisp.org>
5668
5669                 Avoid warnings from recent versions of mcs.
5670                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
5671                 -o, -L, -r any more. Use options documented since mcs-1.0
5672                 instead. Similarly for -g.
5673
5674         2005-07-09  Bruno Haible  <bruno@clisp.org>
5675
5676                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
5677                 add a .dll suffix.
5678                 Reported by Mark Junker <mjscod@gmx.de>.
5679
5680         2006-06-17  Bruno Haible  <bruno@clisp.org>
5681
5682                 * config.charset: Update for NetBSD 3.0.
5683
5684         2006-05-17  Bruno Haible  <bruno@clisp.org>
5685
5686                 Cygwin portability.
5687                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
5688
5689         2006-05-16  Bruno Haible  <bruno@clisp.org>
5690
5691                 * localcharset.c [CYGWIN]: Include <windows.h>.
5692                 (get_charset_aliases): For Cygwin, return the same CPxxx
5693                 aliases list as under WIN32.
5694                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
5695                 the environment variables. Fall back to GetACP().
5696
5697         2006-04-05  Bruno Haible  <bruno@clisp.org>
5698
5699                 * config.charset: Update Juan Manuel Guerrero's address.
5700
5701         2005-02-12  Bruno Haible  <bruno@clisp.org>
5702
5703                 * allocsa.h: Add extern "C" for C++.
5704
5705         2005-02-10  Bruno Haible  <bruno@clisp.org>
5706
5707                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
5708                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
5709
5710         2006-07-22  Bruno Haible  <bruno@clisp.org>
5711
5712                 * gettext.h: Update to GNU gettext-0.15.
5713
5714 2006-07-22  Bruno Haible  <bruno@clisp.org>
5715
5716         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
5717         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
5718         lib-prefix.m4, longdouble.m4, ssize_t.m4.
5719
5720 2006-07-21  Eric Blake  <ebb9@byu.net>
5721
5722         * modules/stdlib-safer: New file.
5723         * MODULES.html.sh (File stream based Input/Output): Add
5724         stdlib-safer.
5725
5726 2006-07-21  Eric Blake  <ebb9@byu.net>
5727
5728         * lib/stdlib-safer.h: New file from coreutils, required by
5729         stdlib--.h.
5730
5731 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
5732
5733         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
5734
5735 2006-07-20  Bruno Haible  <bruno@clisp.org>
5736
5737         * gnulib-tool: Recognize new option --assume-autoconf.
5738         (autoconf_minversion): New variable.
5739         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
5740
5741 2006-07-20  Bruno Haible  <bruno@clisp.org>
5742
5743         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
5744
5745 2006-07-19  Derek R. Price  <derek@ximbiot.com>
5746
5747         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
5748         Reindent and repaginate.
5749
5750 2006-07-19  Derek Price  <derek@ximbiot.com>
5751
5752         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
5753         Correct grammar.
5754
5755 2006-07-17  Bruno Haible  <bruno@clisp.org>
5756
5757         * modules/list: New file.
5758         * modules/array-list: New file.
5759         * modules/carray-list, modules/carray-list-tests: New files.
5760         * modules/linked-list, modules/linked-list-tests: New files.
5761         * modules/avltree-list, modules/avltree-list-tests: New files.
5762         * modules/rbtree-list, modules/rbtree-list-tests: New files.
5763         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
5764         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
5765         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
5766         * modules/oset: New file.
5767         * modules/array-oset: New file.
5768         * modules/avltree-oset, modules/avltree-oset-tests: New files.
5769         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
5770         * tests/test-carray_list.c: New file.
5771         * tests/test-linked_list.c: New file.
5772         * tests/test-avltree_list.c: New file.
5773         * tests/test-rbtree_list.c: New file.
5774         * tests/test-linkedhash_list.c: New file.
5775         * tests/test-avltreehash_list.c: New file.
5776         * tests/test-rbtreehash_list.c: New file.
5777         * tests/test-avltree_oset.c: New file.
5778         * tests/test-rbtree_oset.c: New file.
5779         * MODULES.html.sh (Container data structures): New section.
5780
5781 2006-07-17  Bruno Haible  <bruno@clisp.org>
5782
5783         * m4/gl_list.m4: New file.
5784
5785 2006-07-17  Bruno Haible  <bruno@clisp.org>
5786
5787         * lib/gl_list.h: New file.
5788         * lib/gl_list.c: New file.
5789         * lib/gl_array_list.h: New file.
5790         * lib/gl_array_list.c: New file.
5791         * lib/gl_carray_list.h: New file.
5792         * lib/gl_carray_list.c: New file.
5793         * lib/gl_linked_list.h: New file.
5794         * lib/gl_linked_list.c: New file.
5795         * lib/gl_anylinked_list1.h: New file.
5796         * lib/gl_anylinked_list2.h: New file.
5797         * lib/gl_avltree_list.h: New file.
5798         * lib/gl_avltree_list.c: New file.
5799         * lib/gl_anyavltree_list1.h: New file.
5800         * lib/gl_anyavltree_list2.h: New file.
5801         * lib/gl_rbtree_list.h: New file.
5802         * lib/gl_rbtree_list.c: New file.
5803         * lib/gl_anyrbtree_list1.h: New file.
5804         * lib/gl_anyrbtree_list2.h: New file.
5805         * lib/gl_anytree_list1.h: New file.
5806         * lib/gl_anytree_list2.h: New file.
5807         * lib/gl_linkedhash_list.h: New file.
5808         * lib/gl_linkedhash_list.c: New file.
5809         * lib/gl_anyhash_list1.h: New file.
5810         * lib/gl_anyhash_list2.h: New file.
5811         * lib/gl_avltreehash_list.h: New file.
5812         * lib/gl_avltreehash_list.c: New file.
5813         * lib/gl_rbtreehash_list.h: New file.
5814         * lib/gl_rbtreehash_list.c: New file.
5815         * lib/gl_anytreehash_list1.h: New file.
5816         * lib/gl_anytreehash_list2.h: New file.
5817
5818         * lib/gl_oset.h: New file.
5819         * lib/gl_oset.c: New file.
5820         * lib/gl_array_oset.h: New file.
5821         * lib/gl_array_oset.c: New file.
5822         * lib/gl_avltree_oset.h: New file.
5823         * lib/gl_avltree_oset.c: New file.
5824         * lib/gl_rbtree_oset.h: New file.
5825         * lib/gl_rbtree_oset.c: New file.
5826         * lib/gl_anytree_oset.h: New file.
5827
5828 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5829
5830         * m4/mkancesdirs.m4: New file.
5831         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
5832         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
5833         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
5834         it.
5835
5836 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5837
5838         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
5839         * lib/mkancesdirs.h: New files.
5840         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
5841         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
5842         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
5843         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
5844         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
5845         callers changed.  Revamp internals significantly, by not
5846         attempting to create directories that are temporarily more
5847         permissive than the final results.  Do not attempt to use
5848         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
5849         This removes some race conditions, fixes some bugs, and simplifies
5850         things.  Use new dirchownmod function to do owner and mode changes.
5851         * lib/mkdir-p.h: Likewise.
5852         * lib/modechange.c (octal_to_mode): New function.
5853         (struct mode_change): New member mentioned.
5854         (make_node_op_equals): New arg mentioned.  All callers changed.
5855         (mode_compile): Keep track of which mode bits the user has explicitly
5856         mentioned.
5857         (mode_adjust): New arg DIR, so that we implement the X op correctly.
5858         New arg PMODE_BITS, to keep track of which mode bits the user
5859         mentioned; it treats S_ISUID and S_ISGID speciall.
5860         All callers changed.
5861         * lib/modechange.h: Likewise.
5862
5863 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5864
5865         * MODULES.html.sh: Add mkancestors.
5866         * modules/mkancesdirs: New module.
5867         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
5868         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
5869         The chdir-safer and afs files are now orphans; I'll remove them
5870         unless someone speaks up.
5871         Add lib/dirchownmod.c, lib/dirchownmod.h.
5872         (Depends-on): Remove alloca, chown, save-cwd, dirname.
5873         Add lchown, mkancesdirs.
5874         (Maintainer): Add self.
5875
5876 2006-07-15  Karl Berry  <karl@gnu.org>
5877
5878         * gnulib-tool: help message wording/arrangement.
5879
5880 2006-07-14  Simon Josefsson  <jas@extundo.com>
5881
5882         * doc/gnulib.texi (Libtool and Windows): New section.
5883
5884 2006-07-12  Simon Josefsson  <jas@extundo.com>
5885
5886         * modules/gendocs (License): Fix license, approved by Karl.
5887
5888 2006-07-12  Eric Blake  <ebb9@byu.net>
5889
5890         * MODULES.html.sh: Add gendocs.
5891
5892 2006-07-11  Eric Blake  <ebb9@byu.net>
5893
5894         * modules/fdl: New module, to install doc/fdl.texi.
5895         * MODULES.html.sh: Add new section for documentation modules.
5896         * gnulib-tool: Avoid space-tab.
5897         (--doc-base): New option, to manage files from doc.
5898
5899 2006-07-11  Eric Blake  <ebb9@byu.net>
5900
5901         * m4/absolute-header.m4: Fix comments to match recent change.
5902
5903 2006-07-11  Eric Blake  <ebb9@byu.net>
5904
5905         * gnulib-tool: List --doc-base before --tests-base.
5906
5907 2006-07-11  Derek R. Price  <derek@ximbiot.com>
5908
5909         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
5910
5911 2006-07-11  Bruno Haible  <bruno@clisp.org>
5912
5913         * README: Mention where to put documentation.
5914
5915 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5916
5917         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
5918
5919 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5920
5921         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
5922         to stdint.m4.
5923
5924 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5925
5926         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
5927         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
5928         "no/such/file/stdint.h" when there is no such file, so that
5929         the resulting C code can be parsed by dodgy compilers.
5930         Problems reported by Bob Proulx.
5931
5932 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5933
5934         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
5935         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5936         macros into the GNU _D_EXACT_NAMLEN.
5937         * lib/savedir.c:  Likewise.
5938         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
5939
5940 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5941         and Paul Eggert  <eggert@cs.ucla.edu>
5942
5943         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
5944         * m4/savedir.m4:
5945         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5946         macros into the GNU _D_EXACT_NAMLEN.
5947
5948 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5949
5950         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
5951         around the absolute name, to work around a problem with the HP-UX
5952         11.23 native C compiler, reported by Bob Proulx.
5953
5954 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5955
5956         * doc/maintain.texi, make-stds.texi: Sync from
5957         <http://savannah.gnu.org/projects/gnustandards>.
5958
5959 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5960
5961         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
5962
5963 2006-07-09  Jim Meyering  <jim@meyering.net>
5964
5965         * m4/glob.m4: Remove a doubled word in a comment.
5966
5967 2006-07-09  Jim Meyering  <jim@meyering.net>
5968
5969         * lib/argp-pv.c: Remove a doubled word in a comment.
5970         * lib/check-version.c (check_version): Likewise.
5971         * lib/javacomp.c (compile_java_class): Likewise.
5972
5973 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
5974
5975         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
5976         for the benefit of people using Autoconf 2.60.  If you want to
5977         support older Autoconf versions you can copy m4/onceonly_2_57.m4
5978         (or m4/onceonly.m4, if pre-2.57) manually.
5979
5980 2006-07-08  Jim Meyering  <jim@meyering.net>
5981
5982         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
5983         comment.
5984         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
5985         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
5986         comment.
5987
5988 2006-07-08  Jim Meyering  <jim@meyering.net>
5989
5990         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
5991
5992 2006-07-07  Simon Josefsson  <jas@extundo.com>
5993
5994         * tests/test-crc.c: Change expected crc value, the test vector
5995         were probably computed using the old broken crc.c?
5996
5997 2006-07-06  Simon Josefsson  <jas@extundo.com>
5998
5999         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
6000         now the canonical place for the M4 file).
6001
6002         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
6003         from the sys_socket dependency now.
6004
6005         * modules/inet_pton (Files): Ditto.
6006
6007         * modules/inet_ntop (Files): Ditto.
6008
6009 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
6010
6011         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
6012         not gl_PREREQ_GETUSERSHELL.
6013
6014 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6015
6016         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
6017         with only one argument, for Autoconf 2.60.
6018         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
6019         expand to nothing, so add a shell command to avoid syntax error.
6020         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
6021
6022 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6023
6024         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
6025
6026 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6027
6028         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
6029         no longer needed.  Check for isblank decl.
6030         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
6031         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
6032         of existence.
6033
6034 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6035
6036         * lib/getloadavg.c: Use __VMS, not VMS.
6037         * lib/getopt.c: Likewise.
6038         * lib/getpagesize.h: Likewise.
6039         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
6040         and probably does not work.
6041
6042 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6043
6044         * lib/.cppi-disable: Add wcwidth.
6045         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
6046         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
6047         (ISGRAPH): Remove.  All uses changed to isgraph.
6048         (FOLD) [!defined _LIBC]: Remove special case.
6049         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
6050         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
6051         HAVE_ISBLANK.
6052         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
6053         case.
6054
6055 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6056
6057         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
6058         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
6059         brackets.  Other minor changes to suppress some compiler
6060         warnings.
6061
6062 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6063         and Paul Eggert  <eggert@cs.ucla.edu>
6064
6065         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
6066         of invoking obsolescent AC_HEADER_DIRENT macro.
6067         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
6068         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
6069         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
6070         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
6071         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
6072         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
6073         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
6074         * m4/readdir.m4: Remove; no longer needed.
6075
6076 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6077         and Paul Eggert  <eggert@cs.ucla.edu>
6078
6079         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
6080         Don't worry about this obsolete case any more.
6081         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
6082         directories.
6083         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
6084         worry about this obsolete case any more.
6085         * lib/fts.c: Likewise.
6086         * lib/getcwd.c: Likewise.
6087         * lib/glob.h: Likewise.
6088         * lib/savedir.c: Likewise.
6089
6090 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6091
6092         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
6093         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
6094         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
6095         needed.
6096         All uses removed.
6097         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6098         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6099         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
6100         needed.
6101         * m4/getdate.m4 (gl_GETDATE): Likewise.
6102         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6103         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6104         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6105         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6106         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6107         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6108         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
6109         needed.
6110
6111 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6112
6113         * lib/memcasecmp.c: Include <limits.h>.
6114         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
6115         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
6116         Don't assume isdigit succeeds only on '0' through '9'.
6117
6118 2006-07-05  Eric Blake  <ebb9@byu.net>
6119
6120         * modules/getaddrinfo (Depends-on): Add snprintf.
6121
6122 2006-07-05  Eric Blake  <ebb9@byu.net>
6123
6124         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
6125         to avoid 'header present but could not be compiled' on cygwin.
6126
6127 2006-07-05  Eric Blake  <ebb9@byu.net>
6128
6129         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
6130         missing from netdb.h.
6131         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
6132
6133 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6134
6135         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
6136         no longer needed.
6137         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
6138         * m4/getdate.m4 (gl_GETDATE): Likewise.
6139         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6140         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6141         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6142         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6143         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6144
6145 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6146
6147         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
6148         All uses of is_space replaced by isspace.
6149         * lib/exit.h: Don't talk about STDC_HEADERS.
6150         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
6151         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
6152         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
6153         replaced by isprint etc.
6154         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
6155         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6156         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
6157         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
6158         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
6159         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6160
6161 2006-07-05  Bruno Haible  <bruno@clisp.org>
6162
6163         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
6164         the function exists, before testing against AIX.
6165         Reported by Martin Lambers <marlam@marlam.de>.
6166
6167 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6168
6169         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
6170         From Mark D. Baushke.
6171
6172 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6173
6174         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
6175         to the absolute name, not just one, to bypass Sun C 5.8's
6176         "warning: #include of /usr/include/... may be non-portable".
6177
6178 2006-07-04  Eric Blake  <ebb9@byu.net>
6179
6180         * modules/dirname-tests: New test module.
6181         * tests/test-dirname.c: New file, replacing dirname.c
6182         TEST_DIRNAME section that was recently deleted.
6183
6184 2006-07-04  Bruno Haible  <bruno@clisp.org>
6185
6186         Assume ANSI C header files and <ctype.h> functions.
6187         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
6188         (mbsnwidth): Use isprint, iscntrl instead.
6189
6190 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6191
6192         Merge from coreutils.
6193         * MODULES.html.sh: Add xstrtold.
6194         * modules/xstrtold: New file.
6195         * modules/cycle-check (Files): Add lib/same-inode.h.
6196         * modules/dirname (Files): Add m4/double-slash-root.m4.
6197         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
6198         * modules/mkdir-p (Files): Add lib/same-inode.h.
6199         * modules/same (Files): Add lib/same-inode.h.
6200
6201 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6202
6203         * m4/absolute-header.m4: Renamed from full-header-path.m4.
6204         This is to keep the terminology clean; POSIX talks about
6205         "absolute pathnames", not "full pathnames", but the GNU
6206         Coding Standards say to use "path" for something else;
6207         so use "absolute" to keep both sides happy.
6208         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
6209         Set gl_absolute_header, not gl_full_header_path.
6210         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
6211         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
6212         All uses changed.
6213
6214         Merge from coreutils.
6215
6216         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6217
6218         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
6219         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
6220         want to require the building of c-strtod.o.
6221         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
6222         needs -lm directly.
6223         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
6224
6225         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6226
6227         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
6228         --as-needed option if available.  Problem reported by Albert Chin in
6229         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
6230         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
6231         cc merely issues a bunch of annoying warnings for --as-needed
6232         (this problem was reported by Bob Proulx).  Also, try linking with
6233         -lm to detect a bug in binutils 2.16 (this problem was reported
6234         by Ralf Wildenhues).
6235
6236         2006-06-18  Jim Meyering  <jim@meyering.net>
6237
6238         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
6239         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
6240         macro.
6241         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
6242         also check for glibc-2.4's abort-inducing bug.
6243
6244         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
6245         Low-probability clean-up should be to use rmdir to get rid of
6246         the just-created directory, not unlink.
6247
6248         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
6249         configure fail, and request a bug report to inform us about it.
6250         Add a comment that, barring reports to the contrary, in 2007 we'll
6251         assume ftruncate is universally available.
6252
6253         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6254
6255         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
6256
6257         2006-03-12  Jim Meyering  <jim@meyering.net>
6258
6259         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
6260         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
6261         * m4/same.m4 (gl_SAME): Likewise.
6262         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
6263
6264         2006-03-11  Eric Blake  <ebb9@byu.net>
6265
6266         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
6267         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
6268         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
6269         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
6270
6271 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6272
6273         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
6274         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
6275         reported by Mark D. Baushke, one in
6276         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
6277
6278         Merge from coreutils.
6279
6280         * lib/.cppi-disable: Add stdint_.h.
6281         * lib/.cvsignore: Add stdint.h.
6282
6283         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6284
6285         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
6286         both double and long double versions.
6287         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
6288         * lib/xstrtold.c: New file.
6289         * lib/xstrtod.h (xstrtold): New decl.
6290
6291         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
6292
6293         * lib/filemode.c (setst): Remove.
6294         (strmode): Rewrite to avoid setst.  This makes the code shorter,
6295         (arguably) clearer, and the generated code is a bit smaller on my
6296         Debian GNU/Linux stable x86 host.
6297
6298         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6299
6300         * lib/filemode.c: Include "filemode.h" first, to test the interface.
6301         Assume that filemode.h includes sys/types.h and sys/stat.h.
6302         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
6303         (ftypelet): Reorder to put common cases first, for efficiency.
6304         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
6305         to do 'M'.
6306         (strmode): Renamed from mode_string, and now stores 12 bytes instead
6307         of 10, for compatibility with FreeBSD.  All callers changed.
6308         (filemodestring): Now stores 12 bytes instead of 10, and sets file
6309         types that can't be deduced solely from st_mode.  First arg is now a
6310         const pointer.
6311         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
6312         (strmode): Renamed from mode_string.
6313         (filemodestring): New decl.
6314         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
6315         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
6316         needed.
6317         (S_ISPORT, S_ISWHT): New macros, if not already defined.
6318
6319         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
6320
6321         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
6322         fsusage.h now does that.  Include fsusage.h first, to test interface.
6323         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
6324         at most one method (the old code could have generated decls that
6325         didn't conform to C89, not that this was ever exercised).
6326         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
6327
6328         2006-03-19  Jim Meyering  <jim@meyering.net>
6329
6330         Work even in a chroot where d_ino values for entries in "/"
6331         don't match the stat.st_ino values for the same names.
6332         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
6333         number, iterate through all entries again, using lstat instead.
6334         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
6335         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
6336
6337         * lib/getcwd.c (__getcwd): Clarify a comment.
6338         Use memcpy in place of a call to strcpy.
6339
6340         2006-03-12  Jim Meyering  <jim@meyering.net>
6341
6342         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
6343         matches that of the current directory (which we're about to chdir ".."
6344         out of), then save the dev-ino of the parent, instead.
6345
6346         * lib/same-inode.h (SAME_INODE): New file/macro.
6347         * lib/chdir-safer.c (SAME_INODE): Remove definition.
6348         Include "same-inode.h", instead.
6349         * lib/same.c: Likewise.
6350         * lib/cycle-check.h: Include "same-inode.h".
6351         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
6352         * lib/cycle-check.c (SAME_INODE): Remove definition.
6353         * lib/root-dev-ino.h: Include "same-inode.h".
6354
6355         2006-03-11  Eric Blake  <ebb9@byu.net>
6356
6357         * lib/same.c (same_name): s/base_name/last_component/
6358         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
6359         * lib/filenamecat.c (file_name_concat): Likewise.
6360
6361         2006-03-11  Eric Blake  <ebb9@byu.net>,
6362                     Paul Eggert  <eggert@cs.ucla.edu>
6363
6364         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
6365         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
6366         drive prefix.
6367         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
6368         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
6369         (last_component): New method.
6370         * lib/dirname.c (dir_len): Determine when drive letters need a
6371         subsequent slash.  Preserve // when it is special.
6372         (dir_name): Don't append dot when drive letter is absolute.
6373         [TEST_DIRNAME]: Move into a full-blown gnulib test.
6374         * lib/basename.c (base_name): New semantics - malloc the result.
6375         Preserve // when it is special.  Preserve relative files that look
6376         like drive letters.
6377         (base_len): Preserve // when it is special.
6378         (last_component): New method, similar to old base_name semantics.
6379         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
6380         base_name.  Strip redundant slashes from ///.
6381
6382 2006-07-03  Jim Meyering  <jim@meyering.net>
6383
6384         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
6385         macro is used before the first cycle_check call.
6386
6387 2006-07-03  Eric Blake  <ebb9@byu.net>
6388
6389         * modules/dirname (Depends-on): Add xstrndup.
6390
6391 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6392
6393         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
6394         test cases, so that config.log is a bit easier to follow.
6395
6396 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6397
6398         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
6399         both are 64 bits, since this seems to be the tradition, and this
6400         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
6401         we ever run into a host that prefers long long to long in this
6402         case, we'll need another configure-time test.  Problem reported by
6403         Jim Meyering.
6404
6405 2006-07-02  Eric Blake  <ebb9@byu.net>
6406
6407         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
6408
6409 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6410
6411         * modules/inttypes (Depends-on): No longer depends on stdint.
6412         * modules/stdint (Description): Say more about assumptions.
6413         Say that the fast types might differ.  Say macros are used.
6414         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
6415         (Makefile.am): Revise list of substituted symbols to match
6416         new stdint.m4.
6417         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
6418         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
6419         * tests/test-stdint.c (verify_same_types)
6420         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
6421         the code conforms to C99/C89.
6422         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
6423         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
6424
6425 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6426
6427         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
6428         but fix a bug, by requiring at least 64 bits.
6429         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
6430         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
6431         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
6432         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
6433
6434         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
6435         changes.  Make 2.59 a prerequisite.  Check and substitute for
6436         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
6437         inttypes.h.  Do not use special include files; just use the
6438         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
6439         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
6440         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
6441         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
6442         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
6443         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
6444         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
6445         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
6446         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
6447         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
6448         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
6449         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
6450         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
6451         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
6452         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
6453         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
6454         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
6455         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
6456         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
6457         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
6458         WINT_MAX.  Check for C99 conformance more strictly, by detecting
6459         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
6460         not check for things that C99 does not require, e.g., int8_t.  If
6461         a test isn't needed unless <stdint.h> isn't working, and is
6462         unlikely to be needed for any other reason, then don't do it
6463         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
6464         size_t, since we assume C89 freestanding at least.  Do not check
6465         for sig_atomic_t, wchar_t, or wint_t, since the code now does
6466         the right thing even if the types are not defined.  Instead use:
6467         (gl_STDINT_TYPE_PROPERTIES): New macro.
6468         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
6469         testing whether <sys/types.h> clashes, as Autoconf does this for
6470         us now.  All uses removed.
6471         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
6472         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
6473         (gl_CHECK_TYPE_SAME):
6474         Remove; no longer needed.
6475         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
6476         exists, since we'll return 0 anyway in that case.
6477         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
6478
6479 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6480
6481         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
6482         possible collision with system files.
6483         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
6484         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
6485         WCHAR_MIN and WCHAR_MAX in this case.
6486         (<stddef.h>): Do not include; no longer needed.
6487         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
6488         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
6489         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
6490         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
6491         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
6492         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
6493         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
6494         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
6495         !defined(__c99))]: Include in this case too, since it's harmless
6496         now.
6497         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
6498         dangerous to do so.
6499         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
6500         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
6501         (_STDINT_MIN, _STDINT_MAX): New macros.
6502         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
6503         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
6504         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
6505         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
6506         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
6507         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
6508         macros, not typedefs; this simplifies things quite a bit.
6509         Use long int for all types narrower than int64_t.
6510         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
6511         Define in terms of long long int or int64_t or long int,
6512         not int64_t or int32_t.  This saves some compile-time testing.
6513         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
6514         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
6515         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
6516         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
6517         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
6518         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
6519         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
6520         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
6521         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
6522         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
6523         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6524         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6525         undef any previous version and define our own version, for
6526         simplicity and consistency with the new macros for types.
6527         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6528         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6529         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
6530         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
6531         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
6532         @WINT_T_SUFFIX@ to keep things simple here.
6533         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
6534         Simplify by assuming typical 8/16/32/64 host, since we're
6535         already doing that elsewhere anyway.
6536         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
6537         and assume long long int is 64 bits if available.  This
6538         speeds up 'configure'.
6539
6540 2006-07-01  Eric Blake  <ebb9@byu.net>
6541
6542         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
6543         Reported by Andreas Buening.
6544
6545 2006-07-01  Eric Blake  <ebb9@byu.net>
6546
6547         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
6548
6549 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6550
6551         * lib/getaddrinfo.c: fixed typo
6552
6553 2006-06-29  Jim Meyering  <jim@meyering.net>
6554
6555         * modules/strftime (Maintainer): Add my name, since with the
6556         FPRINTFTIME changes strftime.c has forked from glibc.
6557
6558 2006-06-29  Eric Blake  <ebb9@byu.net>
6559
6560         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
6561
6562 2006-06-29  Eric Blake  <ebb9@byu.net>
6563
6564         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
6565
6566 2006-06-29  Eric Blake  <ebb9@byu.net>
6567
6568         * lib/stat_.h: New file.
6569
6570 2006-06-29  Eric Blake  <ebb9@byu.net>
6571
6572         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
6573         unused static function.
6574
6575 2006-06-29  Eric Blake  <ebb9@byu.net>
6576
6577         * doc/functions.texi (Function Portability): Document missing lstat
6578         on mingw.
6579
6580 2006-06-29  Eric Blake  <ebb9@byu.net>
6581
6582         * MODULES.html.sh: Add sys_stat.
6583         * modules/sys_stat: New module.
6584         * modules/mkstemp (Depends-on): Add sys_stat.
6585
6586 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6587
6588         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
6589
6590 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6591
6592         * m4/c-bs-a.m4: Removed.
6593
6594 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6595
6596         * lib/strftime.c: Assume strftime() exists.
6597
6598 2006-06-29  Derek Price  <derek@ximbiot.com>
6599
6600         * modules/c-bs-a: Removed - \a is C89.
6601         * MODULES.html.sh: Remove c-bs-a.
6602
6603 2006-06-29  Bruno Haible  <bruno@clisp.org>
6604
6605         * modules/wcwidth (License): Change to LGPL.
6606
6607 2006-06-28  Simon Josefsson  <jas@extundo.com>
6608
6609         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
6610         on _WIN32.
6611
6612         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
6613         getnameinfo.
6614
6615 2006-06-28  Simon Josefsson  <jas@extundo.com>
6616
6617         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
6618
6619 2006-06-28  Simon Josefsson  <jas@extundo.com>
6620
6621         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
6622         functions there.  It will succeed on Windows XP, but on Windows
6623         2000 and (presumably) earlier, it will fail, and use the internal
6624         re-implementation.
6625         (use_win32_p): New function.
6626         (getaddrinfo): Use strtoul on servname, to support numeric ports.
6627         Support AI_NUMERICSERV to disable getservbyname.
6628         (getnameinfo): New function, only supports
6629         NI_NUMERICHOST|NI_NUMERICSERV for now.
6630
6631         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
6632         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
6633         getnameinfo.
6634
6635 2006-06-28  Eric Blake  <ebb9@byu.net>
6636
6637         * modules/wcwidth: New file.
6638         * modules/mbchar (Depends-on): Add wcwidth.
6639         * modules/mbswidth (Depends-on): Add wcwidth.
6640         * MODULES.html.sh: Add wcwidth.
6641
6642 2006-06-28  Eric Blake  <ebb9@byu.net>
6643
6644         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
6645         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
6646
6647 2006-06-28  Eric Blake  <ebb9@byu.net>
6648
6649         * lib/xvasprintf.h: Fix comments.
6650
6651 2006-06-28  Eric Blake  <ebb9@byu.net>
6652
6653         * lib/mbchar.h (wcwidth): Include wcwidth.h.
6654         * lib/mbswidth.c (wcwidth): Move from here...
6655         * lib/wcwidth.h: ...to this new file.
6656
6657 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6658
6659         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
6660
6661         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
6662         it's obsolete.
6663         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
6664
6665 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6666
6667         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
6668         Autoconf 2.60 says this stuff was obsolete.
6669
6670 2006-06-28  Bruno Haible  <bruno@clisp.org>
6671
6672         * modules/wcwidth (Files): Add m4/wchar_t.m4.
6673
6674 2006-06-28  Bruno Haible  <bruno@clisp.org>
6675
6676         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
6677         gt_TYPE_WCHAR_T.
6678
6679 2006-06-28  Bruno Haible  <bruno@clisp.org>
6680
6681         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
6682         declaration for wcwidth.
6683         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
6684
6685 2006-06-28  Bruno Haible  <bruno@clisp.org>
6686
6687         * lib/mkdtemp.c [MINGW]: Include <io.h>.
6688         (mkdir): Define using _mkdir.
6689
6690 2006-06-28  Bruno Haible  <bruno@clisp.org>
6691
6692         * lib/getaddrinfo.h: Fix POSIX URL.
6693         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
6694         _WIN32.
6695         (use_win32_p): Make static.
6696         (getaddrinfo): Reject service name if it is empty or does not consist
6697         solely of decimal digits, or if its value is > 65535.
6698         (getnameinfo): Remove useless casts.
6699
6700 2006-06-27  Simon Josefsson  <jas@extundo.com>
6701
6702         * modules/sys_select: New file, suggested by Bruno Haible, Paul
6703         Eggert and Martin Lambers.
6704
6705 2006-06-27  Simon Josefsson  <jas@extundo.com>
6706
6707         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
6708         Eggert and Martin Lambers.
6709
6710 2006-06-27  Bruno Haible  <bruno@clisp.org>
6711
6712         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
6713         result to 0, not to empty.
6714         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
6715
6716 2006-06-27  Bruno Haible  <bruno@clisp.org>
6717
6718         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
6719
6720 2006-06-26  Simon Josefsson  <jas@extundo.com>
6721
6722         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
6723         present.
6724
6725 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
6726
6727         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
6728         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
6729         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
6730
6731 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
6732
6733         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
6734
6735 2006-06-26  Bruno Haible  <bruno@clisp.org>
6736
6737         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
6738
6739 2006-06-26  Bruno Haible  <bruno@clisp.org>
6740
6741         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
6742
6743 2006-06-26  Bruno Haible  <bruno@clisp.org>
6744
6745         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
6746         SGI C compiler in pre-C99 mode.
6747         Suggested by Mark D. Baushke and Larry Jones.
6748
6749 2006-06-26  Bruno Haible  <bruno@clisp.org>
6750
6751         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
6752         WCHAR_MAX.
6753         Reported by Mark D. Baushke and Larry Jones.
6754
6755 2006-06-26  Bruno Haible  <bruno@clisp.org>
6756
6757         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
6758         in pre-C99 mode.
6759         Suggested by Mark D. Baushke and Larry Jones.
6760
6761 2006-06-23  Simon Josefsson  <jas@extundo.com>
6762             Bruno Haible  <bruno@clisp.org>
6763
6764         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
6765         Emit mostlyclean-local rule.
6766         (func_emit_tests_Makefile_am): Likewise.
6767         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
6768
6769 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
6770
6771         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
6772
6773 2006-06-23  Bruno Haible  <bruno@clisp.org>
6774
6775         * tests/test-stdint.c: Update to match ISO C 99 Technical
6776         Corrigendum 1.
6777
6778 2006-06-23  Bruno Haible  <bruno@clisp.org>
6779
6780         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
6781
6782 2006-06-23  Bruno Haible  <bruno@clisp.org>
6783
6784         * lib/stdint_.h: Treat IRIX like OpenBSD.
6785
6786 2006-06-23  Bruno Haible  <bruno@clisp.org>
6787
6788         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
6789         ISO C 99 Technical Corrigendum 1.
6790
6791 2006-06-22  Simon Josefsson  <jas@extundo.com>
6792
6793         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
6794         MinGW.
6795
6796 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
6797
6798         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
6799         needed.  Some compiler complained about some of them.  Problem reported
6800         by Larry Jones in
6801         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
6802
6803 2006-06-21  Simon Josefsson  <jas@extundo.com>
6804
6805         * tests/test-getaddrinfo.c: New file.
6806
6807         * modules/getaddrinfo-tests: New file.
6808
6809         * MODULES.html.sh: Add inet_pton.
6810
6811         * modules/inet_pton: New file.
6812
6813 2006-06-21  Simon Josefsson  <jas@extundo.com>
6814
6815         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
6816         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
6817         of using the (limited) gnulib implementation on Windows XP.
6818
6819         * m4/inet_pton.m4: New file.
6820
6821 2006-06-21  Simon Josefsson  <jas@extundo.com>
6822
6823         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
6824         variable.
6825
6826         * lib/socket_.h: Don't define WINVER.
6827
6828         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
6829         slightly modified to work in gnulib.
6830
6831 2006-06-21  Simon Josefsson  <jas@extundo.com>
6832
6833         * doc/gnulib.texi (Windows sockets): Add.
6834
6835 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
6836
6837         * lib/read-file.c (fread_file): Start with buffer allocation of
6838         0 bytes rather than 1 byte; this simplifies the code.
6839         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
6840         code to free buffer and save/restore errno.
6841         (internal_read_file): Remove unused local.
6842
6843 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
6844
6845         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
6846         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
6847         Problem reported by Denis Excoffier in
6848         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
6849
6850 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6851
6852         * modules/sys_socket, modules/socklen: Include sys/types since
6853         FreeBSD 4.x's sys/socket.h needs it.
6854
6855 2006-06-19  Simon Josefsson  <jas@extundo.com>
6856
6857         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
6858
6859 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6860
6861         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
6862
6863 2006-06-19  Bruno Haible  <bruno@clisp.org>
6864
6865         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
6866         and FULL_PATH_INTTYPES_H in angle brackets.
6867         Reported by Mark D. Baushke <mdb@gnu.org>.
6868
6869 2006-06-17  Eric Blake  <ebb9@byu.net>
6870
6871         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
6872         errno.
6873
6874 2006-06-17  Bruno Haible  <bruno@clisp.org>
6875
6876         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
6877         <sys/inttypes.h>.
6878
6879 2006-06-17  Bruno Haible  <bruno@clisp.org>
6880
6881         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
6882         whether errno is declared. Assume <errno.h> declares errno.
6883
6884 2006-06-17  Bruno Haible  <bruno@clisp.org>
6885
6886         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
6887
6888 2006-06-17  Bruno Haible  <bruno@clisp.org>
6889
6890         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
6891         problem on Solaris 2.5.1.
6892
6893 2006-06-16  Eric Blake  <ebb9@byu.net>
6894
6895         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
6896         * lib/unicodeio.c [!defined errno]: Likewise.
6897         * lib/strtol.c [!defined errno]: Likewise.
6898         * lib/strtod.c [!defined errno]: Likewise.
6899
6900 2006-06-15  Eric Blake  <ebb9@byu.net>
6901
6902         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
6903
6904 2006-06-15  Eric Blake  <ebb9@byu.net>
6905
6906         * config/srclist.txt (ssize_t.m4): Lose sync.
6907
6908 2006-06-15  Bruno Haible  <bruno@clisp.org>
6909
6910         * modules/stdint (Files): Include m4/full-header-path.m4,
6911         m4/size_max.m4, m4/wchar_t.m4.
6912         (Makefile.am): Many more substitutions.
6913         * modules/stdint-tests: New file.
6914         * tests/test-stdint.c: New file.
6915
6916 2006-06-15  Bruno Haible  <bruno@clisp.org>
6917
6918         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
6919         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
6920         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
6921         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
6922         gl_CHECK_TYPE_SAME): New macros.
6923
6924 2006-06-15  Bruno Haible  <bruno@clisp.org>
6925
6926         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
6927
6928 2006-06-15  Bruno Haible  <bruno@clisp.org>
6929
6930         * lib/stdint_.h: Rewritten to be fully auto-configured.
6931         Fixes bug on HP-UX/IA64.
6932
6933 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
6934
6935         * lib/getdate.y (__attribute__): Don't define if already defined.
6936         Problem reported by Larry Jones.
6937         * lib/utimens.c (__attribute__): Likewise.
6938
6939 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
6940
6941         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
6942         reported by Andreas Schwab.
6943
6944 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6945             Bruno Haible  <bruno@clisp.org>
6946
6947         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
6948         check for the declaration of strnlen and a run test that exposes the
6949         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
6950         rpl_strndup.
6951
6952 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6953             Bruno Haible  <bruno@clisp.org>
6954
6955         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
6956
6957 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6958
6959         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
6960         compile test, for Tru64 4.0D.
6961
6962 2006-05-28  Karl Berry  <karl@gnu.org>
6963
6964         * config/srclist.txt (printf-args.c): lose sync.
6965
6966 2006-05-26  Martin Lambers  <marlam@marlam.de>
6967
6968         * lib/getpass.c: Updates the test for the native W32 API, and adds
6969         missing includes, thus fixing compilation warnings.
6970
6971 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
6972
6973         * lib/exclude.c (exclude_fnmatch): New function.
6974         (excluded_file_name): Call exclude_fnmatch.
6975         * lib/exclude.h (excluded_file_name): New prototype
6976
6977 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
6978
6979         * lib/tempname.c (small_open, large_open): New macros.
6980         (__open, __open64) [!_LIBC]: Remove.
6981         (__gen_tempname): Use small_open and large_open instead of __open
6982         and __open64.  This fixes a portability bug on HP-UX 11.11i
6983         reported by Simon Wing-Tang in
6984         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
6985
6986 2006-05-24  Bruno Haible  <bruno@clisp.org>
6987
6988         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
6989         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
6990         Reported by Thorsten Maerz <torte@netztorte.de> via
6991         Aaron Stone <aaron@serendipity.cx>.
6992
6993 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6994
6995         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
6996         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
6997         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
6998         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
6999         not really conditional on the cache.
7000         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
7001
7002 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7003
7004         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
7005         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
7006         (my_usleep): Don't mishandle maximum value.
7007
7008 2006-05-19  Jim Meyering  <jim@meyering.net>
7009
7010         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
7011
7012 2006-05-17  Bruno Haible  <bruno@clisp.org>
7013
7014         Cygwin portability.
7015         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
7016
7017 2006-05-17  Bruno Haible  <bruno@clisp.org>
7018
7019         * lib/stdint_.h: Fix recognition of Cygwin.
7020
7021 2006-05-15  Bruno Haible  <bruno@clisp.org>
7022
7023         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
7024         on libtool patch by Ralf Wildenhues.
7025
7026 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
7027
7028         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
7029         test for C99 conformance; (bool) 0.5 is an integer constant
7030         expression, but (bool) -0.5 is not.  Problem reported by Fedor
7031         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
7032
7033 2006-05-11  Simon Josefsson  <jas@extundo.com>
7034
7035         * m4/xvasprintf.m4: Fix obvious typo.
7036
7037 2006-05-11  Jim Meyering  <jim@meyering.net>
7038
7039         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
7040         James Lemley.
7041
7042 2006-05-10  Simon Josefsson  <jas@extundo.com>
7043
7044         * lib/md4.c: Typo fix, update copyright years.
7045         (K1, K2): Don't use L because it turn computations into 64-bit on
7046         64-bit platforms.
7047
7048 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
7049
7050         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
7051         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
7052         unwanted sign propagation, e.g., on hosts with 64-bit int.
7053         There still are some problems with reeelly weird theoretical hosts
7054         (e.g., 33-bit int) but it's not worth worrying about now.
7055         * lib/sha1.c (rol): Likewise.
7056         (K1, K2, K3, K4): Remove unnecessary L suffix.
7057
7058 2006-05-10  Bruno Haible  <bruno@clisp.org>
7059
7060         * lib/des.c: Cast to avoid warnings.
7061
7062 2006-05-09  Bruno Haible  <bruno@clisp.org>
7063
7064         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
7065         (Depends-on): Depend also on xsize, stdarg.
7066         (configure.ac): Add gl_XVASPRINTF.
7067
7068 2006-05-09  Bruno Haible  <bruno@clisp.org>
7069
7070         * m4/xvasprintf.m4: New file.
7071
7072 2006-05-09  Bruno Haible  <bruno@clisp.org>
7073
7074         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
7075         (EOVERFLOW): Define fallback value.
7076         (xstrcat): New function.
7077         (xvasprintf): Recognize the special case of a string concatenation.
7078
7079 2006-05-08  Eric Blake  <ebb9@byu.net>
7080
7081         * gnulib-tool (func_version): Base copyright year on CVS date.
7082         (func_emit_copyright_notice): New function.
7083         (func_emit_lib_Makefile_am): Use it.
7084         (func_emit_tests_Makefile_am): Likewise.
7085         (func_import): Likewise.
7086
7087 2006-05-08  Bruno Haible  <bruno@clisp.org>
7088
7089         * modules/stdarg: New file.
7090         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
7091
7092 2006-05-08  Bruno Haible  <bruno@clisp.org>
7093
7094         * m4/stdarg.m4: New file, from GNU gettext.
7095
7096 2006-05-08  Bruno Haible  <bruno@clisp.org>
7097
7098         * config/srclist.txt (build-aux/config.rpath): different from latest
7099         release.
7100
7101 2006-05-08  Bruno Haible  <bruno@clisp.org>
7102
7103         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
7104
7105 2006-05-05  Jim Meyering  <jim@meyering.net>
7106
7107         * m4/warning.m4: New file, derived from bison's file by the same name.
7108
7109 2006-05-03  Bruno Haible  <bruno@clisp.org>
7110
7111         * lib/stdint_.h: Shorter URL.
7112         * lib/inttypes.h: Likewise.
7113
7114 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7115
7116         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
7117
7118 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7119
7120         * lib/verify.h: Document the internals better.  Most of this change
7121         was written by Bruno Haible.
7122
7123 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7124
7125         * doc/verify.texi: New file, partly based on a proposal by
7126         Bruno Haible.
7127
7128 2006-05-02  Bruno Haible  <bruno@clisp.org>
7129
7130         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
7131         test from here...
7132         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
7133
7134 2006-04-29  Bruno Haible  <bruno@clisp.org>
7135
7136         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
7137         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
7138
7139 2006-04-29  Bruno Haible  <bruno@clisp.org>
7140
7141         * gnulib-tool: Make --update option actually work.
7142
7143 2006-04-29  Bruno Haible  <bruno@clisp.org>
7144
7145         * doc/gcd.texi: New file.
7146         * doc/gnulib.texi: Include it.
7147
7148 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
7149
7150         * lib/getdate.y (get_date): When adding relative date, start with the
7151         initial time, not with the result of the first mktime call.
7152
7153 2006-04-25  Bruno Haible  <bruno@clisp.org>
7154
7155         * gnulib-tool (func_import): Output the include directives in three
7156         blocks, sorted separately.
7157         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7158
7159 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7160
7161         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
7162         to define main with arguments, for C++.  Reported by Eric Blake.
7163         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
7164         Prefer 'int main ()' to 'int main (void)', for C++.
7165         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
7166         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
7167         for 'main', for C99 and C++.
7168
7169 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7170
7171         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
7172         Don't assume that exit status -1 is valid.
7173         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7174         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
7175         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7176         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
7177         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
7178         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
7179         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
7180         functions can be used without declaring them, or that you can
7181         exit with status -1.
7182         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7183
7184 2006-04-24  Karl Berry  <karl@gnu.org>
7185
7186         * config/srclist.txt (longdouble.m4): sync lost.
7187
7188 2006-04-24  Eric Blake  <ebb9@byu.net>
7189
7190         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
7191
7192 2006-04-24  Bruno Haible  <bruno@clisp.org>
7193
7194         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
7195         poll() implementation in AIX.
7196         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7197
7198 2006-04-24  Bruno Haible  <bruno@clisp.org>
7199
7200         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
7201         assigned exactly once.
7202
7203 2006-04-23  Claudio Fontana  <claudio@gnu.org>
7204             Bruno Haible  <bruno@clisp.org>
7205
7206         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
7207         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
7208         for AM_CPPFLAGS.
7209
7210 2006-04-23  Bruno Haible  <bruno@clisp.org>
7211
7212         * modules/copy-file: Depend on unistd.
7213         * modules/execute: Likewise.
7214         * modules/fatal-signal: Likewise.
7215         * modules/findprog: Likewise.
7216         * modules/mkdtemp : Likewise.
7217         * modules/pipe: Likewise.
7218         * modules/wait-process: Likewise.
7219
7220 2006-04-23  Bruno Haible  <bruno@clisp.org>
7221
7222         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
7223         condition was already detected.
7224         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7225
7226 2006-04-23  Bruno Haible  <bruno@clisp.org>
7227
7228         * lib/copy-file.c: Include <unistd.h> unconditionally.
7229         * lib/execute.c: Likewise.
7230         * lib/fatal-signal.c: Likewise.
7231         * lib/findprog.c: Likewise.
7232         * lib/mkdtemp.c: Likewise.
7233         * lib/pipe.h: Likewise.
7234         * lib/pipe.c: Likewise.
7235         * lib/wait-process.h: Likewise.
7236
7237 2006-04-23  Bruno Haible  <bruno@clisp.org>
7238
7239         * gnulib-tool (func_usage): Fix --import description. Document
7240         --update.
7241         (func_import): Create temporary file in a temporary directory, if
7242         --dry-run is specified. Silence errors from 'grep' when there are no
7243         m4 files in $m4dir.
7244         (func_create_testdir): Silence errors from 'grep' when there are no
7245         m4 files in $m4dir.
7246         Reported by Karl Berry <karl@freefriends.org>.
7247
7248 2006-04-20  Bruno Haible  <bruno@clisp.org>
7249
7250         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
7251         one argument, so that the code will be portable to Autoconf 2.60.
7252         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
7253         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7254         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
7255
7256 2006-04-19  Derek Price  <derek@ximbiot.com>
7257             Eric Blake  <ebb9@byu.net>
7258
7259         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
7260         rather than "/full/path.h".  Update comment to match.  Shorten &
7261         generalize m4_translit call via AS_TR_CPP.
7262
7263 2006-04-19  Derek Price  <derek@ximbiot.com>
7264             Eric Blake  <ebb9@byu.net>
7265
7266         * lib/inttypes.h: Correct grammar in comment.
7267
7268 2006-04-18  Derek Price  <derek@ximbiot.com>
7269             Paul Eggert  <eggert@cs.ucla.edu>
7270
7271         * modules/inttypes: New file.
7272         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
7273
7274 2006-04-18  Derek Price  <derek@ximbiot.com>
7275             Paul Eggert  <eggert@cs.ucla.edu>
7276
7277         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
7278         New files.
7279
7280 2006-04-18  Derek Price  <derek@ximbiot.com>
7281             Paul Eggert  <eggert@cs.ucla.edu>
7282
7283         * lib/inttypes.h: New file.
7284         * lib/strtoimax.c: Assume <inttypes.h>.
7285
7286 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
7287
7288         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
7289         isn't mounted.  Problem reported by Kir Kolyshkin.
7290
7291 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
7292
7293         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
7294         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
7295         Derek R. Price.
7296         * lib/regex.h (RE_DUP_MAX): Update comment to match current
7297         implementation.
7298
7299 2006-04-12  Eric Blake  <ebb9@byu.net>
7300
7301         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
7302         is now done automatically by the corresponding Autoconf macro.
7303
7304 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
7305
7306         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
7307         time_r.h.
7308
7309 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7310
7311         Merge regex changes from libc, removing some of our
7312         POSIX-conformance changes that were rejected and redoing them in a
7313         less-intrusive way.
7314
7315         * lib/regcomp.c (re_compile_internal, init_dfa):
7316         Length arg is now size_t, not Idx.  All uses changed.
7317         (peek_token): Forward decl now says internal_function.
7318         (__re_error_msgid, __re_error_msgid_idx):
7319         Now static rather than extern with attribute_hidden.
7320         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
7321         For some reason libc prefers K&R style defns for external functions.
7322         (regerror) [!defined _LIBC]: Likewise.
7323         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
7324         (seek_collating_symbol_entry, lookup_collation_sequence_value):
7325         (build_range_exp, build_collating_symbol):
7326         Use K&R-style defn.
7327         (re_compile_fastmap): Use '\0' to memset, not 0.
7328         (utf8_sb_map): Make the calculations more obvious.
7329         (init_dfa, parse_bracket_exp, build_charclass_op):
7330         Call calloc and cast result, as glibc does.
7331         (init_word_char, fetch_token, peek_token, peek_token_bracket):
7332         (build_range_exp, build_collating_symbol):
7333         Now internal functions.
7334
7335         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
7336
7337         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
7338         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
7339         Don't depend on VMS; depend on __VMS instead, for POSIX
7340         namespace cleanness.
7341         (regoff_t): Define to ssize_t, not long int.
7342
7343         Remove the REG_ macros named below.  Instead, make the old names
7344         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
7345         __USE_GNU_REGEX.
7346         (REG_BACKSLASH_ESCAPE_IN_LISTS):
7347         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
7348         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
7349         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
7350         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
7351         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
7352         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
7353         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
7354         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
7355         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
7356         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
7357         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
7358         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
7359         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
7360         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
7361         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
7362         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
7363         (REG_NREGS):
7364         Remove.  All uses replaced by the old RE_* names.
7365         (RE_BACKSLASH_ESCAPE_IN_LISTS):
7366         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
7367         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
7368         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
7369         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
7370         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
7371         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
7372         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
7373         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
7374         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
7375         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
7376         Don't bother having these macros be independent of each others'
7377         values, since they no longer exist in the POSIX name space.
7378
7379         Rename the following member names back to their old names,
7380         unless !__USE_GNU_REGEX.  All uses changed back.
7381         (buffer): Renamed from re_buffer.
7382         (allocated): Renamed from re_allocated.
7383         (used): Renamed from re_used.
7384         (syntax): Renamed from re_syntax.
7385         (fastmap): Renamed from re_fastmap.
7386         (translate): Renamed from re_translate.
7387         (can_be_null): Renamed from re_can_be_null.
7388         (regs_allocated): Renamed from re_regs_allocated.
7389         (fastmap_accurate): Renamed from re_fastmap_accurate.
7390         (no_sub): Renamed from re_no_sub.
7391         (not_bol): Renamed from re_not_bol.
7392         (not_eol): Renamed from re_not_eol.
7393         (newline_anchor): Renamed from re_newline_anchor.
7394         (num_regs): Renamed from rm_num_regs.
7395         (start): Renamed from rm_start.
7396         (end): Renamed from rm_end.
7397
7398         (free_state): Move up a bit.
7399
7400         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
7401         #define to be empty.
7402         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
7403         when that is what is intended.
7404         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
7405         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
7406         (MAX): New macro.
7407         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
7408         All uses changed back to re_malloc, etc.  It's now the caller's
7409         responsibility to check for overflow; all callers changed.
7410         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
7411         (re_x2nrealloc): Remove.
7412         (free_state): Remove decl.
7413
7414         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
7415         (re_set_registers, re_exec):
7416         Use K&R-style defn.
7417
7418         2006-01-31  Roland McGrath  <roland@redhat.com>
7419
7420         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
7421         Reported by Mike Frysinger <vapier@gentoo.org>.
7422
7423         2006-01-15  Andreas Jaeger  <aj@suse.de>
7424
7425         [BZ #1950]
7426         * lib/regex_internal.c (re_string_reconstruct): Adjust for
7427         build_wcs_upper_buffer change.
7428         (build_wcs_upper_buffer): Change return type.
7429
7430         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
7431
7432         * lib/regex_internal.h: Include <stdint.h> if available.
7433
7434         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
7435
7436         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
7437
7438         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7439
7440         * lib/regcomp.c: Adjust for changed secondary hash function.
7441
7442         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
7443
7444         * lib/regex.h: Pretty printing.
7445         Clean up namespace a bit.
7446
7447         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
7448
7449         * lib/regexec.c (update_cur_sifted_state, check_arrival,
7450         check_arrival_add_next_nodes): Avoid using uninitialized variable.
7451
7452         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7453                     Ulrich Drepper  <drepper@redhat.com>
7454
7455         [BZ #1302]
7456         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
7457         changed.
7458         (bitset_word_t): Renamed from bitset_word.  All uses changed.
7459
7460         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
7461
7462         [BZ #281]
7463         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
7464         * lib/regcomp.c: Remove unnecessary uses of
7465         unsigned RE_TRANSLATE_TYPE.
7466         * lib/regex_internal.h: Likewise.
7467         * lib/regex_internal.c: Likewise.
7468         * lib/regexec.c: Likewise.
7469         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
7470
7471         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
7472
7473         * lib/regexec.c (find_recover_state): Remove unnecessary
7474         initialization.
7475         (transit_state_bkref): Make DFA a const pointer.
7476         (get_subexp): Likewise.
7477         (check_arrival): Likewise.
7478         (update_cur_sifted_state): Likewise.
7479         (re_search_internal): Likewise.
7480         (prune_impossible_nodes): Likewise.
7481         (acquire_init_state_context): Likewise.
7482         (proceed_next_node): Likewise.
7483         (set_regs): Likewise.
7484         (free_fail_stack_return): Likewise.
7485         (check_arrival_expand_ecl): Mark DFA parameter as const.
7486         (check_arrival_expand_ecl_sub): Likewise.
7487         (check_subexp_limits): Likewise.
7488         (sub_epsilon_src_nodes):  Likewise.
7489         (add_epsilon_src_nodes):  Likewise.
7490         (merge_state_array): Likewise.
7491         (update_regs): Likewise.
7492         (build_trtable): Likewise.
7493         (sift_states_backward): Mark MCTX parameter as const.
7494         (build_sifted_states): Likewise.
7495         (update_cur_sifted_state): Likewise.
7496         (sift_states_mkref): Likewise.
7497         (check_arrival_expand_ecl): Mark eclosure as const.
7498         (check_dst_limits_calc_pos_1): Likewise.
7499         * lib/regex_internal.h (re_match_context_t): Make dfa a const
7500         pointer.
7501
7502         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
7503
7504         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
7505         (transit_state_sb): Likewise.
7506         (transit_state_mb): Likewise.
7507         (sift_states_iter_mb): Likewise.
7508         (check_arrival_add_next_nodes): Likewise.
7509         (check_node_accept_bytes): Change first parameter to pointer-to-const.
7510         [_LIBC] (re_search_2_stub): Use mempcpy.
7511
7512         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
7513         mbrtowc for very simple UTF-8 case.
7514
7515         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
7516         a pointer-to-const.
7517         (re_acquire_state_context): Likewise.
7518         * lib/regex_internal.h: Adjust prototypes.
7519
7520         * lib/regex.c: Prevent using C++ compilers.
7521
7522         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
7523         (re_acquire_state_context): Likewise.
7524
7525 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7526
7527         * modules/regex (Depends-on): Add ssize_t.
7528
7529 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7530
7531         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
7532         translation table.
7533
7534 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7535
7536         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
7537
7538 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
7539             Bruno Haible  <bruno@clisp.org>
7540
7541         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
7542         <sys/types.h> and <inttypes.h>.
7543
7544 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7545
7546         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
7547         `__error_t_defined', so argp.h will not typedef the former.
7548
7549 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
7550
7551         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
7552         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
7553         glibc names.  Even if glibc is changed to conform to POSIX, the
7554         traditional names will be available anyway, since regex depends on
7555         the extensions module.  Also, fix a longstanding typo in the
7556         implementation of Spencer ERE test #75 from grep 2.3.  Problems
7557         reported by Emanuele Giaquinta.  Also, change sense of cached
7558         variable, so that the message makes sense.
7559
7560 2006-03-24  Simon Josefsson  <jas@extundo.com>
7561
7562         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
7563         including some doc fixes.
7564         (base64_encode_alloc): Fix +1 bug on allocation failures.
7565
7566 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7567
7568         * lib/base64.c (base64_encode): Do not read past end of array with
7569         unsanitized input on systems with CHAR_BIT > 8.
7570
7571 2006-03-24  Eric Blake  <ebb9@byu.net>
7572
7573         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
7574
7575 2006-03-22  Karl Berry  <karl@gnu.org>
7576
7577         * config/srclist.txt (*setenv.[ch]): get from coreutils.
7578         * config/srclistvars.sh (COREUTILS): new var.
7579
7580 2006-03-17  Jim Meyering  <jim@meyering.net>
7581
7582         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
7583         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
7584
7585 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7586
7587         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
7588         no longer needs it.  Instead, check that regoff_t is as least
7589         as wide as ptrdiff_t.
7590
7591         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
7592         so that our regex.h stays compatible with the installed regex.
7593         This is helpful for installers who configure --without-included-regex.
7594         Problem reported by Emanuele Giaquinta.
7595
7596 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7597
7598         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
7599         Typedef to long int, not to off_, as POSIX will likely change
7600         in that direction.
7601
7602 2006-03-15  Eric Blake  <ebb9@byu.net>
7603
7604         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
7605
7606 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7607
7608         * lib/argp-help.c (validate_uparams): Fix typo
7609         * lib/argp-parse.c (argp_default_options): Consistently begin help
7610         messages with a lowercase letter.
7611
7612 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
7613
7614         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
7615         overrun buffers and shouldn't be used (much as gets shouldn't be
7616         used).
7617         * lib/time_r.c (asctime_r, ctime_r): Likewise.
7618
7619 2006-03-08  Simon Josefsson  <jas@extundo.com>
7620
7621         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
7622         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7623
7624 2006-03-08  Simon Josefsson  <jas@extundo.com>
7625
7626         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
7627         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7628
7629 2006-03-08  Simon Josefsson  <jas@extundo.com>
7630
7631         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
7632         signal that configure disabled the device.
7633
7634 2006-03-08  Simon Josefsson  <jas@extundo.com>
7635
7636         * build-aux/maint.mk: Fix refresh-po, to handle no translated
7637         languages.
7638
7639 2006-03-07  Simon Josefsson  <jas@extundo.com>
7640
7641         * modules/getopt (Depends-on): Add unistd.
7642
7643         * modules/unistd: New file.
7644
7645 2006-03-07  Simon Josefsson  <jas@extundo.com>
7646
7647         * modules/gc-random: New file.
7648
7649 2006-03-07  Simon Josefsson  <jas@extundo.com>
7650
7651         * m4/unistd_h.m4: New file.
7652
7653 2006-03-07  Simon Josefsson  <jas@extundo.com>
7654
7655         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
7656         test to be side-effect free by storing the result in the cache
7657         variable gl_cv_lib_readline, and moving the assignment of
7658         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
7659         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7660
7661 2006-03-07  Simon Josefsson  <jas@extundo.com>
7662
7663         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
7664         error on missing devices (the functions will return an error).
7665
7666         * m4/gc.m4: Move random stuff to gc-random.m4
7667
7668 2006-03-07  Simon Josefsson  <jas@extundo.com>
7669
7670         * lib/unistd_.h: New file.
7671
7672 2006-03-07  Simon Josefsson  <jas@extundo.com>
7673
7674         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
7675
7676 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7677
7678         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
7679         Problem reported by Juan Manuel Guerrero.
7680
7681 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7682
7683         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
7684         the unistd module.
7685         * lib/getlogin_r.c: Likewise.
7686         * lib/getlogin_r.h: Likewise.
7687         * lib/glob.c: Likewise.
7688         * lib/pagealign_alloc.c: Likewise.
7689         * lib/unistd_.h: Remove; no longer needed.
7690
7691 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7692
7693         * MODULES.html.sh (Support for systems lacking POSIX:2001):
7694         Add unistd.
7695         * modules/c-stack (Depends-on): Add unistd.
7696         * modules/getlogin_r: Likewise.
7697         * modules/glob: Likewise.
7698         * modules/pagealign_alloc: Likewise.
7699         * modules/unistd (Files): Remove lib/unistd_.h.
7700         (EXTRA_DIST): Remove.
7701         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
7702         need unistd_.h.
7703         (MOSTLYCLEANFILES): Remove unistd.h-t.
7704
7705 2006-03-03  Simon Josefsson  <jas@extundo.com>
7706
7707         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
7708
7709 2006-03-03  Simon Josefsson  <jas@extundo.com>
7710
7711         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
7712         libidn and bison.
7713
7714 2006-03-03  Simon Josefsson  <jas@extundo.com>
7715
7716         * build-aux/maint.mk: Add indent target.
7717
7718 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
7719
7720         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
7721         our replacement poll.h in any case, to avoid a differing
7722         declaration from a system header.  Seen on AIX.
7723
7724 2006-03-01  Simon Josefsson  <jas@extundo.com>
7725
7726         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
7727         <kasal@ucw.cz>.
7728
7729 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7730
7731         * modules/gettime (Depends-on): Add extensions module.
7732         * modules/nanosleep (Depends-on): Likewise.
7733         * modules/settime (Depends-on): Likewise.
7734
7735 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7736
7737         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
7738         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
7739         pedantically.
7740         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7741         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
7742
7743         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
7744         not "==".  Reported by Ralf Wildenhues.
7745
7746 2006-03-01  Karl Berry  <karl@gnu.org>
7747
7748         * doc/Copyright/request-*: new files, synced from gnuorg.
7749
7750 2006-03-01  Karl Berry  <karl@gnu.org>
7751
7752         * config/srclist.txt (Copyright/*): new entries.
7753
7754 2006-02-28  Simon Josefsson  <jas@extundo.com>
7755
7756         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
7757
7758 2006-02-27  Simon Josefsson  <jas@extundo.com>
7759
7760         * lib/base64.h: Indent #define's.  From Jim Meyering
7761         <jim@meyering.net>.
7762
7763 2006-02-27  Jim Meyering  <jim@meyering.net>
7764
7765         Revert the change of 2006-02-24, so these files can continue
7766         to be sync'd from gettext.
7767         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
7768         of `config.h'.
7769
7770 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
7771
7772         * modules/intprops: New file.
7773         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7774         Add intprops.
7775         * modules/getloadavg (Files): Remove lib/intprops.h.
7776         (Depends-on): Add intprops.
7777         * modules/human: Likewise.
7778         * modules/inttostr: Likewise.
7779         * modules/openat: Likewise.
7780         * modules/sig2str: Likewise.
7781         * modules/userspec: Likewise.
7782         * modules/utimecmp: Likewise.
7783         * modules/xnanosleep: Likewise.
7784         * modules/xstrtol: Likewise.
7785
7786 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
7787
7788         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
7789         * modules/lock-tests (TESTS): Use $(EXEEXT).
7790         * modules/tls-tests: Likewise.
7791         * modules/argp-tests: Likewise.
7792         (check_PROGRAMS): New var, replacing...
7793         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
7794
7795 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7796
7797         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
7798         `config.h'.
7799
7800 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
7801
7802         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
7803
7804 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7805
7806         Sync from coreutils.
7807         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
7808         gl_CHDIR_SAFER.
7809
7810 2006-02-22  Jim Meyering  <jim@meyering.net>
7811
7812         Sync from coreutils.
7813         * m4/chdir-safer.m4: New file.
7814
7815 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
7816
7817         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
7818         AT_FDCWD exceeds INT_MAX.
7819         * lib/openat.h (AT_FDCWD): Likewise.
7820
7821 2006-02-17  Eric Blake  <address@hidden>
7822
7823         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
7824
7825 2006-02-16  Simon Josefsson  <jas@extundo.com>
7826
7827         * modules/getaddrinfo (Depends-on): Add sys_socket.
7828
7829 2006-02-15  Simon Josefsson  <jas@extundo.com>
7830
7831         * build-aux/maint.mk: Add dsyntax-check rule.
7832
7833 2006-02-15  Eric Blake  <ebb9@byu.net>
7834
7835         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
7836         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
7837         'present but cannot compile' warnings on cygwin.
7838         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
7839         use ws2tcpip.h if sys/socket.h works.
7840         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
7841         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
7842
7843 2006-02-14  Simon Josefsson  <jas@extundo.com>
7844
7845         * modules/maintainer-makefile (Files): Rename.
7846
7847         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
7848         and (the local) Makefile.cfg to maint-cfg.mk.
7849
7850         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
7851         to the latter.
7852
7853         * modules/maintainer-makefile: New module.
7854
7855         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
7856         severaly stripped to make it possible to build it up from scratch
7857         with reliable tests.
7858
7859         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
7860         fixes to permit overriding the default actions when configure and
7861         makefile are not available.
7862
7863 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
7864
7865         Sync from coreutils.
7866         * modules/lstat (Depends-on): Don't depend on xalloc.
7867         (License): Change from GPL to LGPL, since this is now simply a
7868         replacement for a libc function.
7869
7870 2006-02-14  Jim Meyering  <jim@meyering.net>
7871
7872         Sync from coreutils.
7873
7874         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
7875         failure on deficient systems, and simplify gnulib lgpl dependencies.
7876         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
7877         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
7878
7879         * lib/xalloc-die.c: Remove unused definition of N_.
7880
7881 2006-02-14  Jim Meyering  <jim@meyering.net>
7882
7883         Sync from coreutils.
7884         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
7885         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
7886         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
7887         double-quote uses of that variable, to accommodate the rare case in
7888         which getmntent is available in none of the libraries checked.  This
7889         happens at least on FreeBSD 5.0.
7890
7891 2006-02-13  Simon Josefsson  <jas@extundo.com>
7892
7893         * gnulib-tool (Usage): Fix --import, from
7894         karl@freefriends.org (Karl Berry).
7895
7896 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7897
7898         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
7899
7900 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
7901
7902         * lib/argp-namefrob.h: Restore changes accidentally lost during the
7903         "autoupdate" on 2005-12-12.
7904
7905 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7906
7907         * modules/closeout (Depends-on): Remove atexit.
7908
7909 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7910
7911         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
7912         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
7913
7914 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
7915
7916         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
7917         __EXTENSIONS__ if this causes compilation to fail.  Problem
7918         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
7919         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
7920
7921 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
7922
7923         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
7924         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
7925         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
7926         All uses changed.
7927
7928 2006-01-26  Simon Josefsson  <jas@extundo.com>
7929
7930         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
7931         prototype is visible on mingw32.
7932
7933         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
7934         for mingw32.
7935
7936         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
7937         mingw32).
7938
7939 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7940
7941         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
7942         attempt to open for write; this always fails, at least on POSIX
7943         hosts.  This reinstates the 2006-01-09 change, which was
7944         inadvertently removed.
7945
7946 2006-01-26  Bruno Haible  <bruno@clisp.org>
7947
7948         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
7949         Reported by Paul Eggert.
7950
7951 2006-01-26  Bruno Haible  <bruno@clisp.org>
7952             Paul Eggert  <eggert@cs.ucla.edu>
7953
7954         * lib/stdbool_.h (_Bool)
7955         [(! (defined __cplusplus || defined __BEOS__)
7956           && !defined __GNUC__
7957           && !(defined __HP_cc || defined __xlc__
7958                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
7959                || defined __sgi))]:
7960         #define to signed char in these cases too; this simplifies
7961         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
7962         etc., separately) and makes it more conservative.
7963
7964 2006-01-25  Simon Josefsson  <jas@extundo.com>
7965
7966         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
7967         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
7968         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
7969
7970 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7971
7972         * lib/argp-namefrob.h: Bugfix. Remove stray #
7973
7974 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
7975
7976         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
7977         so that we test the test.
7978         Check for yet another HP-UX cc bug involving *bool |= bool.
7979
7980 2006-01-25  Karl Berry  <karl@gnu.org>
7981
7982         * config/srclist.txt (vasnprintf.c): sync lost.
7983
7984 2006-01-25  Jim Meyering  <jim@meyering.net>
7985
7986         Sync from the stable (b5) branch of coreutils:
7987
7988         * lib/fts.c (fts_children): Don't let close() clobber errno from
7989         failed fchdir().
7990
7991         * lib/fts.c (fts_stat): When following a symlink-to-directory,
7992         don't necessarily interpret stat-fails+lstat-succeeds as indicating
7993         a dangling symlink.  That can also happen at least for ELOOP.
7994         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
7995         FYI, this bug predates the inclusion of fts.c in coreutils.
7996
7997         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
7998         in their own block, so pre-c99 compilers don't object.
7999
8000         Avoid the double-free (first in fts_read, second in fts_close) that
8001         would occur when an `active' directory is made inaccessible (e.g.,
8002         via chmod a-x) during a traversal.
8003         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8004         before returning.  Reproduce this failure by
8005         mkdir -p a/b; cd a; chmod a-x . b
8006         Reported by Stavros Passas.
8007
8008 2006-01-25  Jim Meyering  <jim@meyering.net>
8009
8010         * lib/fileblocks.c: Remove more useless parentheses.
8011         * lib/readutmp.h: Likewise.
8012
8013 2006-01-25  Bruno Haible  <bruno@clisp.org>
8014
8015         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
8016         warnings.
8017         Reported by Paul Eggert.
8018
8019 2006-01-25  Bruno Haible  <bruno@clisp.org>
8020
8021         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
8022         rid of a trap command. For Solaris sh.
8023         Reported by Mark D. Baushke <mdb@gnu.org>.
8024
8025 2006-01-24  Simon Josefsson  <jas@extundo.com>
8026
8027         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
8028         Bruno.
8029
8030 2006-01-24  Karl Berry  <karl@gnu.org>
8031
8032         * config/srclist.txt (argp-namefrob.h): sync lost.
8033
8034 2006-01-24  Jim Meyering  <jim@meyering.net>
8035
8036         * modules/openat (Files): Add lib/intprops.h.
8037         From Mark D. Baushke.
8038
8039 2006-01-24  Jim Meyering  <jim@meyering.net>
8040
8041         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
8042         Reported by Mark D. Baushke.
8043
8044 2006-01-24  Jim Meyering  <jim@meyering.net>
8045
8046         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
8047
8048 2006-01-24  Bruno Haible  <bruno@clisp.org>
8049
8050         * modules/strnlen (Maintainer): Change from glibc to all.
8051
8052 2006-01-24  Bruno Haible  <bruno@clisp.org>
8053
8054         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
8055         Patch by Paul Eggert.
8056
8057 2006-01-24  Bruno Haible  <bruno@clisp.org>
8058
8059         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
8060         already has it.
8061         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
8062         2005-11-26.
8063
8064         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
8065         'signed char' to avoid problems with the built-in _Bool type.
8066         Reported by Paul Eggert on 2005-11-26.
8067
8068 2006-01-24  Bruno Haible  <bruno@clisp.org>
8069
8070         * gnulib-tool (func_import): Avoid constructing complicated sed
8071         expressions inside backquote.
8072         Report and solution by Mark D. Baushke <mdb@gnu.org>.
8073
8074 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
8075
8076         These changes imported from libc.
8077         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
8078         test and two separate function calls.
8079         * lib/strndup.c (__strndup): Add libc_hidden_def.
8080
8081 2006-01-23  Simon Josefsson  <jas@extundo.com>
8082
8083         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
8084         Remove the test_*_SOURCES variable: automake infers it by default.
8085         * modules/tls-tests: Likewise.
8086
8087 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8088
8089         Work around porting bugs reported by Dieter in
8090         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
8091         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
8092         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
8093         Include "getopt.h" first, to check interface.
8094         (getenv): Declare only if defined HAVE_DECL_GETENV &&
8095         !HAVE_DECL_GETENV.
8096         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
8097         (__strndup): Revert to K&R-style function dfns, the glibc style.
8098         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
8099         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
8100         Include strnlen.h first, to get prototype properly.
8101         (strnlen): Renamed from __strnlen.
8102         Remove weak alias.
8103
8104 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8105
8106         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
8107
8108 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8109
8110         * config/srclist.txt: Adjust to reflect glibc reorganization.
8111         This affects only comments.
8112
8113 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
8114
8115          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
8116          Reported by Bruce Korb <bkorb@gnu.org>.
8117
8118 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
8119
8120         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
8121         to pacify gcc -Wswitch-default.
8122
8123 2006-01-22  Bruno Haible  <bruno@clisp.org>
8124
8125         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
8126         temporary buffer for sprintf, take into account the precision also
8127         for 'd', 'i', 'u', 'o', 'x', 'X'.
8128
8129 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8130
8131         * modules/argp-tests: New module
8132         * tests/test-argp.c: New file
8133         * tests/test-argp-2.sh: New file
8134
8135 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8136
8137         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
8138         (__argp_base_name): Removed
8139         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
8140         typo.
8141         (__argp_base_name): Provide macro definition or extern declaration
8142         depending on the configuration
8143
8144 2006-01-20  Simon Josefsson  <jas@extundo.com>
8145
8146         * modules/inet_ntop (Depends-on): Depend on sys_socket.
8147
8148 2006-01-20  Simon Josefsson  <jas@extundo.com>
8149
8150         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
8151
8152 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
8153
8154         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
8155         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
8156         Suggested by Bruno Haible.
8157
8158 2006-01-20  Karl Berry  <karl@gnu.org>
8159
8160         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
8161         until changes propagate, I guess.
8162
8163 2006-01-19  Simon Josefsson  <jas@extundo.com>
8164
8165         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
8166
8167 2006-01-19  Simon Josefsson  <jas@extundo.com>
8168
8169         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
8170
8171 2006-01-19  Simon Josefsson  <jas@extundo.com>
8172
8173         * gnulib-tool: Set check_PROGRAMS.
8174
8175         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8176         modules/des-tests, modules/gc-arcfour-tests,
8177         modules/gc-arctwo-tests, modules/gc-des-tests,
8178         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8179         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8180         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8181         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8182         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8183         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
8184         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
8185         test_*_SOURCES.
8186
8187 2006-01-18  Simon Josefsson  <jas@extundo.com>
8188
8189         * modules/socklen (Depends-on): Depend on sys_socket.
8190
8191 2006-01-18  Simon Josefsson  <jas@extundo.com>
8192
8193         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8194         modules/des-tests, modules/gc-arcfour-tests,
8195         modules/gc-arctwo-tests, modules/gc-des-tests,
8196         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8197         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8198         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8199         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8200         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8201         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
8202         $(EXEEXT) to automake TESTS variable, for mingw32.
8203
8204 2006-01-17  Simon Josefsson  <jas@extundo.com>
8205
8206         * modules/socklen (Include): Need sys/socket.h.
8207
8208 2006-01-17  Bruno Haible  <bruno@clisp.org>
8209
8210         * modules/ssize_t (Include): Add <sys/types.h>.
8211
8212 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
8213
8214         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
8215         it's not portable and it doesn't work with cross-compiles.
8216         Problem reported by Bruno Haible.  Fix missing-$ typo in
8217         'test "gl_cv_ignore_unused_libraries" ...' that prevented
8218         -zignore from being used with Sun's C compiler.
8219
8220 2006-01-12  Simon Josefsson  <jas@extundo.com>
8221
8222         * lib/base64.c: Fix warning, reported by Bruno Haible
8223         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
8224
8225 2006-01-12  Bruno Haible  <bruno@clisp.org>
8226
8227         * modules/ldd: New file.
8228         * build-aux/ldd.sh.in: New file.
8229         * MODULES.html.sh (Support for building libraries and executables): Add
8230         ldd.
8231
8232 2006-01-12  Bruno Haible  <bruno@clisp.org>
8233
8234         * m4/ldd.m4: New file.
8235
8236 2006-01-12  Bruno Haible  <bruno@clisp.org>
8237
8238         * gnulib-tool (func_import, func_create_testdir): Don't go into an
8239         endless loop while replacing $auxdir with build-aux.
8240
8241 2006-01-11  Simon Josefsson  <jas@extundo.com>
8242
8243         * lib/stdint_.h (SIZE_MAX): Add missing (.
8244
8245 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
8246
8247         Sync from coreutils.
8248         * lib/md5.c: Fix commentary typos.
8249         (alignof, UNALIGNED_P): No need for a GCC-specific version.
8250         * lib/md5.h (__attribute__): Remove; unused.
8251         * lib/sha1.c: Fix commentary to match md5 better.
8252         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
8253         so that we don't need to worry about alignment.  All uses changed.
8254         This merges the 2005-10-28 md5 change into sha1.
8255
8256 2006-01-11  Jim Meyering  <jim@meyering.net>
8257
8258         Sync from coreutils.
8259         * lib/md5.c (OP): Fix spacing.
8260
8261 2006-01-11  Bruno Haible  <bruno@clisp.org>
8262
8263         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8264         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
8265         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
8266
8267 2006-01-11  Bruno Haible  <bruno@clisp.org>
8268
8269         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8270         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
8271         the "early" section as well.
8272
8273 2006-01-11  Bruno Haible  <bruno@clisp.org>
8274
8275         Avoid "ar: no archive members specified" error on MacOS X.
8276         * gnulib-tool (func_modules_add_dummy): New function.
8277         (func_import, func_create_testdir): Invoke it.
8278
8279 2006-01-11  Bruno Haible  <bruno@clisp.org>
8280
8281         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
8282         with $auxdir in AC_CONFIG_FILES statements.
8283
8284 2006-01-11  Bruno Haible  <bruno@clisp.org>
8285
8286         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8287         Initialize also noinst_HEADERS to empty.
8288
8289 2006-01-11  Bruno Haible  <bruno@clisp.org>
8290
8291         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
8292         variables.
8293         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
8294         autoreconf.
8295
8296 2006-01-11  Bruno Haible  <bruno@clisp.org>
8297
8298         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
8299         overridable by the user.
8300         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8301
8302 2006-01-10  Simon Josefsson  <jas@extundo.com>
8303
8304         * modules/sys_socket: New file.
8305
8306 2006-01-10  Simon Josefsson  <jas@extundo.com>
8307
8308         * m4/sys_socket_h.m4: New file.
8309
8310 2006-01-10  Simon Josefsson  <jas@extundo.com>
8311
8312         * lib/socket_.h: New file.
8313
8314 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8315
8316         * modules/readutmp (Maintainer): Add myself.
8317
8318 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8319
8320         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
8321         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
8322         People who are still concerned with buggy memcmp implementations
8323         can invoke gl_FUNC_MEMCMP themselves.
8324
8325 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8326
8327         * lib/regex_internal.h (BITSET_WORD_BITS):
8328         Work around a bug in 64-bit PGC (before version 6.1-2), where the
8329         preprocessor mishandles large unsigned values as if they were signed.
8330         Problem reported by Claudio Fontana in
8331         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
8332
8333 2006-01-10  Jim Meyering  <jim@meyering.net>
8334
8335         Avoid the double-free (first in fts_read, second in fts_close) that
8336         would occur when an `active' directory is made inaccessible (e.g.,
8337         via chmod a-x) during a traversal.
8338         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8339         before returning.  Reproduce this failure by
8340         mkdir -p a/b; cd a; chmod a-x . b
8341         Reported by Stavros Passas.
8342
8343         Sync from coreutils.
8344         * lib/sha1.c: Tweak grammar in a comment.
8345
8346 2006-01-10  Jim Meyering  <jim@meyering.net>
8347
8348         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
8349         Patch by Joerg Sonnenberger.
8350
8351 2006-01-10  Bruno Haible  <bruno@clisp.org>
8352
8353         * modules/readutmp: Depend on module free.
8354         * modules/strtok_r: Depend on module restrict.
8355
8356 2006-01-10  Bruno Haible  <bruno@clisp.org>
8357
8358         * modules/gettext (configure.ac): Add an invocation of
8359         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
8360
8361 2006-01-10  Bruno Haible  <bruno@clisp.org>
8362
8363         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
8364         Reported by Werner Lemberg <wl@gnu.org>.
8365
8366 2006-01-10  Bruno Haible  <bruno@clisp.org>
8367
8368         * lib/localcharset.c: Update from GNU gettext.
8369
8370 2006-01-10  Bruno Haible  <bruno@clisp.org>
8371
8372         * lib/argp.h (__const): Remove macro. Use const instead.
8373         * lib/argp-fmtstream.h (__const): Likewise.
8374         * lib/glob_.h (__const): Remove macro.
8375         * lib/glob-libc.h: Use const instead of __const.
8376
8377 2006-01-10  Bruno Haible  <bruno@clisp.org>
8378
8379         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
8380         variable.
8381         Needed to avoid an automake error regarding the 'gettext' module.
8382
8383 2006-01-09  Simon Josefsson  <jas@extundo.com>
8384
8385         * modules/inet_ntop (Depends-on): Add restrict.
8386
8387 2006-01-09  Simon Josefsson  <jas@extundo.com>
8388
8389         * modules/gc-rijndael-tests (License): Put under LGPL.
8390
8391         * modules/gc-des-tests (License): Likewise.
8392
8393         * modules/gc-arcfour-tests (License): Likewise.
8394
8395         * modules/gc-arctwo-tests (License): Likewise.
8396
8397         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
8398
8399         * modules/gc-hmac-sha1-tests (Files): Likewise.
8400
8401         * modules/gc-hmac-md5-tests (License): Likewise.
8402
8403         * modules/gc-sha1-tests (License): Likewise.
8404
8405         * modules/gc-md5-tests (License): Likewise.
8406
8407         * modules/gc-md4-tests (License): Likewise.
8408
8409         * modules/gc-md2-tests (License): Likewise.
8410
8411         * modules/gc-tests (License): Likewise.
8412
8413         * modules/des-tests (License): Likewise.
8414
8415         * modules/md4-tests (License): Likewise.
8416
8417         * modules/md2-tests (License): Likewise.
8418
8419 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8420
8421         Sync from coreutils:
8422
8423         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
8424         * modules/lib-ignore: New file.
8425         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
8426         chdir-safer.m4, lchmod.m4.
8427         * modules/openat: Add mkdirat.c, openat-priv.h.
8428
8429 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8430
8431         Sync from coreutils.
8432         * m4/lib-ignore.m4: New file.
8433         * m4/lchmod.m4: New file.
8434
8435 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8436
8437         Sync from coreutils.
8438         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
8439         for write access: POSIX says that must fail.
8440         * lib/fts.c (diropen): Likewise.
8441         * lib/save-cwd.c (save_cwd): Likewise.
8442         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
8443         well, for minor improvements on hosts that lack O_DIRECTORY.
8444         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
8445         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
8446         Fall back on chown if open failed with EACCES.
8447
8448         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
8449         Report an error at compile-time if only a 1-second nominal clock
8450         resolution is found.
8451
8452         * lib/lchmod.h: New file.
8453         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
8454         (make_dir_parents): Use lchown rather than chown, and
8455         lchmod rather than chmod.
8456
8457         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
8458         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
8459         "proc" reported by n0dalus.
8460
8461         * lib/mountlist.c: Include <limits.h>.
8462         (dev_from_mount_options)
8463         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
8464         New function.  It no longer assumes "dev=" has the System V meaning
8465         on Linux (since it doesn't).  It also parses "dev=" more carefully.
8466         (read_file_system_list)
8467         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
8468         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
8469         dev= in that case.
8470
8471         * lib/posixtm.h (PDS_PRE_2000): New macro.
8472         * lib/posixtm.c (year): Arg is now syntax_bits rather than
8473         allow_century.  All usages changed.  Reject dates outside the range
8474         1969-1999 if PDS_PRE_2000 is used.
8475
8476 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8477
8478         Sync from coreutils.
8479         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
8480         (Time of day items): Mention the possibility of leap seconds.
8481         Problem reported by Dr. David Alan Gilbert.
8482
8483 2006-01-09  Jim Meyering  <jim@meyering.net>
8484
8485         Sync from coreutils.
8486
8487         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
8488
8489         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
8490
8491         * lib/modechange.c (mode_compile): Reject an invalid mode string
8492         that starts with an octal digit.  From Andreas Gruenbacher.
8493
8494         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
8495         and dup to open_safer and dup_safer, respectively.
8496         (openat_permissive): Fix typo in comment.
8497
8498         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
8499         "gettext.h"; either no longer needed or are guaranteed by openat.h.
8500         (_): Remove; no longer needed.
8501         (openat): Renamed from rpl_openat; no need for rpl_openat
8502         since openat.h renames openat for us.
8503         Replace most of the body with a call to openat_permissive,
8504         to avoid duplicate code.
8505         Port to (probably hypothetical) environments were mode_t is
8506         wider than int.
8507         (openat_permissive): Require mode arg, so that we can check
8508         types better.  Put it just after flags.  Change cwd failure
8509         indicator from pointer-to-bool to pointer-to-errno-value.
8510         All callers changed.
8511         Invoke openat_save_fail and/or openat_restore_fail if
8512         cwd_errno is null, so that openat can call us.
8513         (openat_permissive, fdopendir, fstatat, unlinkat):
8514         Simplify errno handling to avoid some duplicate code,
8515         as it's OK to set errno on success.
8516         * lib/openat.h: Revamp code so that function macros depend on
8517         __OPENAT_PREFIX only, not also on AT_FDCWD.
8518         (openat_ro): Remove.  Caller changed to use openat_permissive.
8519         (openat_permissive): Now a macro, if not a function.
8520         (openat_restore_fail, openat_save_fail): Now always functions,
8521         since mkdirat needs them even if __OPENAT_PREFIX is defined.
8522
8523         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
8524         and openat.c.
8525         * lib/mkdirat.c: Include openat-priv.h.
8526         Remove definitions of macros defined therein.
8527         * lib/openat.c: Likewise.
8528
8529         * lib/mkdirat.c (mkdirat): New file and function.
8530         * lib/openat.h (mkdirat): Declare.
8531
8532         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
8533
8534         * lib/openat.h (openat_permissive): Declare.
8535         (openat_ro): Define.
8536
8537         * lib/openat.c (EXPECTED_ERRNO): New macro.
8538         (openat_permissive): New function -- used in remove.c rewrite.
8539         (all functions): Set errno just before returning, only if there
8540         was an actual failure.
8541         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
8542
8543         Emulate openat-family functions using Linux's procfs, if possible.
8544         Idea and some code based on Ulrich Drepper's glibc changes.
8545
8546         * lib/openat.c: (BUILD_PROC_NAME): New macro.
8547         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
8548         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
8549         before falling back on save_cwd and restore_cwd.
8550         (fdopendir, fstatat, unlinkat): Likewise.
8551
8552         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
8553         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
8554
8555         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
8556         as second argument to va_arg.  Otherwise, some versions of gcc
8557         warn that `if this code is reached, the program will abort'.
8558
8559 2006-01-09  Jim Meyering  <jim@meyering.net>
8560
8561         Sync from coreutils.
8562         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
8563         Require openat-priv.h.
8564
8565 2006-01-09  Bruno Haible  <bruno@clisp.org>
8566
8567         * modules/strnlen (Include): Use strnlen.h.
8568
8569 2006-01-09  Bruno Haible  <bruno@clisp.org>
8570
8571         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
8572
8573 2006-01-09  Bruno Haible  <bruno@clisp.org>
8574
8575         * lib/sysexit_.h (EX_OK): New macro.
8576         Suggested by Martin Lambers <marlam@marlam.de>.
8577
8578 2006-01-09  Bruno Haible  <bruno@clisp.org>
8579
8580         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
8581         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
8582
8583 2006-01-09  Bruno Haible  <bruno@clisp.org>
8584
8585         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
8586         numbers.
8587
8588 2006-01-09  Bruno Haible  <bruno@clisp.org>
8589
8590         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
8591         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
8592         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
8593         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
8594
8595 2006-01-09  Bruno Haible  <bruno@clisp.org>
8596
8597         * build-aux/javacomp.sh.in: New file, moved from lib/.
8598         * modules/javacomp-script (Files): Update.
8599         (configure.ac): Add AC_CONFIG_FILES invocation.
8600         (EXTRA_DIST): Remove variable.
8601
8602         * build-aux/javaexec.sh.in: New file, moved from lib/.
8603         * modules/javaexec (Files): Update.
8604         (configure.ac): Add AC_CONFIG_FILES invocation.
8605         (EXTRA_DIST): Remove javaexec.sh.in.
8606
8607         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
8608         * modules/csharpcomp-script (Files): Update.
8609         (configure.ac): Add AC_CONFIG_FILES invocation.
8610         (EXTRA_DIST): Remove variable.
8611
8612         * build-aux/csharpexec.sh.in: New file, moved from lib/.
8613         * modules/csharpexec (Files): Update.
8614         (configure.ac): Add AC_CONFIG_FILES invocation.
8615         (EXTRA_DIST): Remove csharpexec.sh.in.
8616
8617 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8618
8619         Sync from coreutils.
8620
8621         Add POSIX ACL support
8622         * lib/acl.h (copy_acl, set_acl): Add declarations.
8623         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
8624         systems other than Linux.
8625         (chmod_or_fchmod): New function: use fchmod when possible,
8626         and chmod otherwise.
8627         (file_has_acl): Add a POSIX ACL implementation, with a
8628         Linux-specific subcase.
8629         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
8630         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
8631         acls are unsupported.
8632         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
8633         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
8634         are unsupported.
8635
8636 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8637
8638         Sync from coreutils.
8639         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
8640
8641 2006-01-07  Bruno Haible  <bruno@clisp.org>
8642
8643         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
8644         gl_EARLY.
8645
8646 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8647
8648         * lib/strftime.c (tzname): Don't declare if it is already #defined.
8649         Problem reported for Mingw by Mark Junker.
8650
8651 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8652
8653         * README: Gnulib normally doesn't generate a tarball.
8654
8655 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
8656
8657         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
8658         long int, not int, for nanosecond counts, so that people who are
8659         used to POSIX struct timespec won't be surprised.  Reported by Jim
8660         Meyering.
8661
8662 2005-12-28  Bruno Haible  <bruno@clisp.org>
8663
8664         * build-aux/config.rpath: Update from GNU gettext.
8665
8666 2005-12-16  Jim Meyering  <jim@meyering.net>
8667
8668         * modules/fprintftime: New module.
8669         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
8670
8671 2005-12-16  Jim Meyering  <jim@meyering.net>
8672
8673         * m4/fprintftime.m4: New file.
8674
8675 2005-12-16  Jim Meyering  <jim@meyering.net>
8676
8677         * lib/fprintftime.c, lib/fprintftime.h: New files.
8678
8679 2005-12-15  Simon Josefsson  <jas@extundo.com>
8680
8681         * modules/socklen (configure.ac): Fix M4 macro name, to align with
8682         new m4/socklen.m4.
8683
8684 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8685
8686         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
8687         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
8688
8689 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8690
8691         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
8692         * lib/argp-help.c (fill_in_uparams): Check if the constructed
8693         struct uparams is valid. Fall back to the default values if it is
8694         not.
8695
8696 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8697
8698         * modules/argp (Files): Add argp-pin.c
8699         (Depends-on): dirname
8700         (lib_SOURCES): Add argp-pin.c
8701
8702 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8703
8704         * m4/argp.m4:  Check if program_invocation_name and
8705         program_invocation_short_name are declared and define appropriate
8706         macros if they are not.
8707
8708 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8709
8710         * lib/argp-help.c (__argp_base_name): New function
8711         (__argp_short_program_name): Rewrite using __argp_base_name
8712         * lib/argp-namefrob.h: Define program_invocation_name and
8713         program_invocation_short_name if requested
8714         (__argp_base_name): Add prototype
8715         * lib/argp-parse.c (argp_def): Use gettext wrappers
8716         (argp_default_parser): Use __argp_base_name
8717         * lib/argp-pin.c: New file. Defines program_invocation_name and
8718         program_invocation_short_name on systems that lack them.
8719
8720 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8721
8722         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
8723         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8724         porting problem reported by Georg Schwarz in
8725         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8726
8727 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8728
8729         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
8730         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8731         porting problem reported by Georg Schwarz in
8732         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8733
8734 2005-12-05  Bruno Haible  <bruno@clisp.org>
8735
8736         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
8737         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
8738         Reported by Mark Junker <mjscod@gmx.de>.
8739
8740 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
8741
8742         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
8743         Use implementation from Albert Chin, with some
8744         comments/corrections by Stepan Kasal and myself.
8745
8746 2005-12-02  Bruno Haible  <bruno@clisp.org>
8747
8748         * gnulib-tool (func_import): Accept GPLed build tool modules when
8749         --lgpl is given.
8750         * modules/csharpcomp-script: New file.
8751         * modules/csharpcomp: Depend on it.
8752         * modules/javacomp-script: New file.
8753         * modules/javacomp: Depend on it.
8754         Suggested by Simon Josefsson.
8755
8756 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
8757
8758         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
8759         statement, to work around an HP-UX 10.20 compiler bug reported by
8760         Peter O'Gorman.
8761
8762 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8763
8764         * modules/savedir (Depends-on): Add openat.
8765
8766 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8767
8768         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
8769         (uintmax_t) [defined uintmax_t]: Do not declare.
8770         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
8771         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
8772         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
8773         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
8774         sake of portability to weird hosts that C allows (though we don't
8775         know of any practical examples).
8776
8777         * lib/savedir.h (fdsavedir): New decl.
8778         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
8779         contains most of the former guts of savedir.
8780         (savedir): Use savedirstream.
8781         Include "openat.h".
8782
8783 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
8784
8785         * modules/obstack (Files): Add m4/ulonglong.m4.
8786         Problem reported by Davide Angelocola.
8787
8788 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
8789
8790         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
8791         coreutils no longer futzes with rounding modes.
8792
8793 2005-11-14  Jim Meyering  <jim@meyering.net>
8794
8795         * lib/mkstemp-safer.c: Include <config.h>, required for possible
8796         replacement of mkstemp.
8797
8798 2005-11-10  Simon Josefsson  <jas@extundo.com>
8799
8800         * lib/readline.c: Remove EOL.
8801
8802 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8803
8804         * modules/gethrxtime (Depends-on): Add gettime.
8805
8806 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8807
8808         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
8809         or gettimeofday; no longer needed.
8810
8811 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8812
8813         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
8814         time business.
8815         (gethrxtime) [! (HAVE_NANOUPTIME
8816         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
8817         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
8818         our own approximation.
8819
8820 2005-11-08  Eric Blake  <ebb9@byu.net>
8821
8822         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8823
8824 2005-11-08  Eric Blake  <ebb9@byu.net>
8825
8826         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8827
8828 2005-11-04  Bruno Haible  <bruno@clisp.org>
8829
8830         * gnulib-tool: Implement --update mode.
8831
8832 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8833
8834         Fix porting problem reported by Theodoros V. Kalamatianos.
8835         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
8836         Don't assume that futimes failing means we must fail.
8837
8838 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8839
8840         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
8841         variables to suggest the intended function of the PATH_MAX check.
8842
8843 2005-10-30  Kean Johnston  <jkj@sco.com>
8844
8845         Trivial changes to support SCO systems.
8846         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
8847         as PATH_MAX.
8848         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
8849         where __ptr is null when no I/O is pending.
8850
8851 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
8852
8853         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
8854         leave errno alone.  Problem reported by Dmitry V. Levin.
8855
8856 2005-10-28  Simon Josefsson  <jas@extundo.com>
8857
8858         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
8859         Test more.
8860
8861         * tests/test-gc-md2.c, tests/test-md2.c: New files.
8862
8863         * modules/md2, modules/md2-tests: New files.
8864
8865 2005-10-28  Simon Josefsson  <jas@extundo.com>
8866
8867         * m4/inet_ntop.m4: More tests.
8868
8869         * m4/gc-md2.m4, md2.m4: New file.
8870
8871 2005-10-28  Simon Josefsson  <jas@extundo.com>
8872
8873         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
8874         "restrict" keywords, as per POSIX.  Protect the function
8875         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
8876         Don't use K&R prototypes.  Check the sprintf return values.
8877         Re-define EAFNOSUPPORT if not present.  Indent.
8878
8879         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
8880         suggested by Bruno Haible <bruno@clisp.org>.
8881
8882         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
8883
8884         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
8885
8886         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
8887         libgcrypt).
8888
8889         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
8890
8891         * lib/md2.h, lib/md2.c: New files.
8892
8893 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
8894
8895         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
8896         errno alone.  Problem reported by Frederic Jolliton.
8897
8898 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8899
8900         * modules/verify (License): Change from GPL to LGPL.  This is a
8901         tiny module and there are apparently near-equivalents that are
8902         under the BSD license.
8903
8904 2005-10-24  Simon Josefsson  <jas@extundo.com>
8905
8906         * modules/sha1: Relicense to LGPL.
8907
8908 2005-10-24  Simon Josefsson  <jas@extundo.com>
8909
8910         * lib/md4.h: Shrink buffer size, now that we changed the type.
8911
8912 2005-10-23  Simon Josefsson  <jas@extundo.com>
8913
8914         * gnulib-tool (func_import): Fix --tests-base.
8915
8916 2005-10-22  Simon Josefsson  <jas@extundo.com>
8917
8918         * modules/arcfour (Depends-on): Need stdint.
8919
8920 2005-10-22  Simon Josefsson  <jas@extundo.com>
8921
8922         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
8923         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
8924
8925 2005-10-22  Simon Josefsson  <jas@extundo.com>
8926
8927         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
8928         suggested by Bruno Haible <bruno@clisp.org>.
8929
8930 2005-10-22  Simon Josefsson  <jas@extundo.com>
8931
8932         * lib/crc.h: Include stddef.h, for size_t.
8933
8934 2005-10-22  Simon Josefsson  <jas@extundo.com>
8935
8936         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
8937         arcfour_context struct (simplify test vector testing in GNU
8938         Shishi).
8939
8940 2005-10-21  Simon Josefsson  <jas@extundo.com>
8941
8942         * modules/des, modules/des-tests: New files.
8943
8944         * modules/gc-des, modules/gc-des-tests: New files.
8945
8946         * tests/test-des.c, tests/test-gc-des.c: New file.
8947
8948 2005-10-21  Simon Josefsson  <jas@extundo.com>
8949
8950         * modules/arctwo, modules/arctwo-tests: New files.
8951
8952         * tests/test-arctwo.c: New file.
8953
8954         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
8955
8956         * tests/test-gc-arctwo.c: New file.
8957
8958 2005-10-21  Simon Josefsson  <jas@extundo.com>
8959
8960         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
8961         Bruno Haible <bruno@clisp.org>.
8962
8963         * m4/gc-des.m4: New file.
8964
8965 2005-10-21  Simon Josefsson  <jas@extundo.com>
8966
8967         * m4/arctwo.m4: New file.
8968
8969         * m4/gc-arctwo.m4: New file.
8970
8971 2005-10-21  Simon Josefsson  <jas@extundo.com>
8972
8973         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
8974         block.
8975
8976 2005-10-21  Simon Josefsson  <jas@extundo.com>
8977
8978         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
8979         <bruno@clisp.org>.
8980
8981         * lib/hmac-sha1.c (hmac_sha1): Likewise.
8982
8983         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
8984         Bruno Haible <bruno@clisp.org>.
8985
8986         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
8987         <bruno@clisp.org>.
8988
8989 2005-10-21  Simon Josefsson  <jas@extundo.com>
8990
8991         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
8992
8993 2005-10-21  Simon Josefsson  <jas@extundo.com>
8994
8995         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
8996
8997 2005-10-21  Simon Josefsson  <jas@extundo.com>
8998
8999         * lib/des.h, lib/des.c: New files.
9000
9001         * lib/gc-gnulib.c: Support DES.c
9002
9003 2005-10-21  Simon Josefsson  <jas@extundo.com>
9004
9005         * lib/arctwo.h, lib/arctwo.c: New files.
9006
9007         * lib/gc-gnulib.c: Support ARCTWO.
9008
9009 2005-10-21  Simon Josefsson  <jas@extundo.com>
9010
9011         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
9012         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
9013
9014 2005-10-21  Simon Josefsson  <jas@extundo.com>
9015
9016         * gnulib-tool (func_import, func_create_testdir): Define automake
9017         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
9018         Makefile.am snippet),
9019         suggested by Bruno Haible <bruno@clisp.org>.
9020
9021         * modules/gc (Makefile.am): Use it.
9022
9023 2005-10-21  Bruno Haible  <bruno@clisp.org>
9024
9025         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
9026         patch.
9027
9028 2005-10-19  Simon Josefsson  <jas@extundo.com>
9029
9030         * tests/test-gc-rijndael.c: New file.
9031
9032         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
9033
9034 2005-10-19  Simon Josefsson  <jas@extundo.com>
9035
9036         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
9037         interface too.
9038
9039 2005-10-19  Simon Josefsson  <jas@extundo.com>
9040
9041         * tests/test-gc-arcfour.c: New file.
9042
9043         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
9044
9045 2005-10-19  Simon Josefsson  <jas@extundo.com>
9046
9047         * modules/gc-md4, modules/gc-md4-tests: New file.
9048
9049         * tests/test-gc-md4.c: New file.
9050
9051 2005-10-19  Simon Josefsson  <jas@extundo.com>
9052
9053         * m4/gc-md4.m4: New file.
9054
9055 2005-10-19  Simon Josefsson  <jas@extundo.com>
9056
9057         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
9058         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
9059         <kasal@ucw.cz>.
9060
9061 2005-10-19  Simon Josefsson  <jas@extundo.com>
9062
9063         * m4/gc-arcfour.m4: New file.
9064
9065         * m4/gc-rijndael.m4: New file.
9066
9067 2005-10-19  Simon Josefsson  <jas@extundo.com>
9068
9069         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
9070
9071 2005-10-19  Simon Josefsson  <jas@extundo.com>
9072
9073         * lib/gc-gnulib.c: Support ARCFOUR.
9074
9075 2005-10-19  Simon Josefsson  <jas@extundo.com>
9076
9077         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
9078         support.
9079
9080         * lib/gc.h: Add ECB enum type.
9081
9082         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
9083
9084 2005-10-18  Simon Josefsson  <jas@extundo.com>
9085
9086         * tests/test-md5.c: New file.
9087
9088         * modules/md5-tests: New file.
9089
9090 2005-10-18  Simon Josefsson  <jas@extundo.com>
9091
9092         * tests/test-md4.c: New file.
9093
9094         * modules/md4, modules/md4-tests: New files.
9095
9096 2005-10-18  Simon Josefsson  <jas@extundo.com>
9097
9098         * m4/md4.m4: New file.
9099
9100 2005-10-18  Simon Josefsson  <jas@extundo.com>
9101
9102         * lib/md4.h, lib/md4.c: New files, based on md5.?.
9103
9104 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
9105
9106         * gnulib-tool (func_create_testdir): Omit the second check whether
9107         BUILT_SOURCES in nonempty.
9108
9109 2005-10-17  Simon Josefsson  <jas@extundo.com>
9110
9111         * tests/test-rijndael.c: New file.
9112
9113 2005-10-17  Simon Josefsson  <jas@extundo.com>
9114
9115         * modules/sha1: Depend on stdint instead of md5.
9116
9117         * modules/md5: Depend on stdint, remove uint32_t.
9118
9119 2005-10-17  Simon Josefsson  <jas@extundo.com>
9120
9121         * modules/gc-sha1-tests: New file.
9122
9123         * tests/test-gc-sha1.c: New file.
9124
9125 2005-10-17  Simon Josefsson  <jas@extundo.com>
9126
9127         * m4/md5.m4: Remove call to uint32_t.m4.
9128
9129 2005-10-17  Simon Josefsson  <jas@extundo.com>
9130
9131         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
9132
9133         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
9134         md5.h.
9135
9136         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
9137
9138         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
9139
9140 2005-10-17  Simon Josefsson  <jas@extundo.com>
9141
9142         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
9143
9144 2005-10-17  Simon Josefsson  <jas@extundo.com>
9145
9146         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
9147
9148 2005-10-17  Simon Josefsson  <jas@extundo.com>
9149
9150         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
9151
9152         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
9153
9154 2005-10-17  Bruno Haible  <bruno@clisp.org>
9155
9156         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
9157         that it can also be used in a test.
9158
9159 2005-10-16  Bruno Haible  <bruno@clisp.org>
9160
9161         * gnulib-tool (func_emit_tests_Makefile_am): Also define
9162         TESTS_ENVIRONMENT, so that individual tests can augment it.
9163
9164         * gnulib-tool (func_create_testdir): Use an intermediate target for
9165         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
9166         macros, like $(ALLOCA_H), which cannot be passed through the command
9167         line.
9168
9169 2005-10-15  Simon Josefsson  <jas@extundo.com>
9170
9171         * modules/rijndael-tests: New file.
9172
9173         * modules/rijndael: New file.
9174
9175 2005-10-15  Simon Josefsson  <jas@extundo.com>
9176
9177         * m4/rijndael.m4: New file.
9178
9179 2005-10-15  Simon Josefsson  <jas@extundo.com>
9180
9181         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
9182
9183         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
9184
9185 2005-10-14  Simon Josefsson  <jas@extundo.com>
9186
9187         * tests/test-arcfour.c: New file.
9188
9189         * modules/arcfour, modules/arcfour-tests: New files.
9190
9191 2005-10-14  Simon Josefsson  <jas@extundo.com>
9192
9193         * m4/arcfour.m4: New file.
9194
9195 2005-10-14  Simon Josefsson  <jas@extundo.com>
9196
9197         * lib/arcfour.h, lib/arcfour.c: New files.
9198
9199 2005-10-14  Roland McGrath  <roland@redhat.com>
9200
9201         Import from libc.  [BZ #1331]
9202         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
9203         macro argument.
9204         Reported by Matej Vela <vela@debian.org>.
9205
9206 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9207
9208         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
9209         include <wchar.h>; no longer needed.
9210
9211 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9212
9213         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
9214
9215 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
9216         and  Ulrich Drepper  <drepper@redhat.com>
9217
9218         Import from libc.
9219         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
9220         instead of inline stream orientation test and two separate
9221         function calls.  Pay no attention to USE_IN_LIBIO.
9222
9223 2005-10-13  Simon Josefsson  <jas@extundo.com>
9224
9225         * modules/gc-hmac-md5-tests: New file.
9226
9227         * tests/test-gc-hmac-sha1.c: New file.
9228
9229         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
9230
9231         * modules/gc-hmac-md5-tests: New file.
9232
9233         * tests/test-gc-md5.c: New file.
9234
9235         * modules/gc-md5-tests: New file.
9236
9237 2005-10-13  Simon Josefsson  <jas@extundo.com>
9238
9239         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
9240         Move memory allocation outside of loop.
9241
9242 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
9243
9244         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
9245         intermediate directory is in a read-only file system.  Problem
9246         reported by Eric Blake.
9247
9248 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
9249
9250         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
9251
9252 2005-10-12  Simon Josefsson  <jas@extundo.com>
9253
9254         * tests/test-hmac-sha1.c: New file.
9255
9256         * modules/hmac-sha1-tests: New file.
9257
9258         * modules/hmac-sha1: New file.
9259
9260 2005-10-12  Simon Josefsson  <jas@extundo.com>
9261
9262         * modules/gc-sha1: New file.
9263
9264 2005-10-12  Simon Josefsson  <jas@extundo.com>
9265
9266         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
9267
9268         * tests/test-gc-pbkdf2-sha1.c: New file.
9269
9270 2005-10-12  Simon Josefsson  <jas@extundo.com>
9271
9272         * modules/gc-md5, modules/gc-hmac-md5: New files.
9273
9274         * modules/gc (Files): Remove md5, memxor and hmac files.
9275
9276 2005-10-12  Simon Josefsson  <jas@extundo.com>
9277
9278         * m4/gc-pbkdf2-sha1.m4: New file.
9279
9280         * m4/gc-hmac-sha1.m4: New file.
9281
9282         * m4/gc-sha1: New file.
9283
9284         * m4/hmac-sha1.m4: New file.
9285
9286 2005-10-12  Simon Josefsson  <jas@extundo.com>
9287
9288         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
9289
9290         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
9291
9292 2005-10-12  Simon Josefsson  <jas@extundo.com>
9293
9294         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
9295         suggested by Bruno Haible <bruno@clisp.org>.
9296
9297 2005-10-12  Simon Josefsson  <jas@extundo.com>
9298
9299         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
9300
9301 2005-10-12  Simon Josefsson  <jas@extundo.com>
9302
9303         * lib/gc-pbkdf2-sha1.c: New file.
9304
9305         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
9306
9307 2005-10-12  Simon Josefsson  <jas@extundo.com>
9308
9309         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
9310
9311         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
9312
9313 2005-10-12  Simon Josefsson  <jas@extundo.com>
9314
9315         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
9316         GC_USE_HMAC_MD5, respectively.
9317
9318         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
9319         (gc_md5): Fix typo.
9320
9321         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
9322
9323         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
9324
9325         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
9326
9327 2005-10-12  Bruno Haible  <bruno@clisp.org>
9328
9329         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
9330         Reported by Stepan Kasal <kasal@ucw.cz>.
9331
9332 2005-10-11  Simon Josefsson  <jas@extundo.com>
9333
9334         * tests/test-crc.c: New file.
9335
9336         * modules/crc, modules/crc-tests: New files.
9337
9338 2005-10-11  Simon Josefsson  <jas@extundo.com>
9339
9340         * m4/crc.m4: New file.
9341
9342 2005-10-11  Simon Josefsson  <jas@extundo.com>
9343
9344         * lib/gc.h: Add gc_hash and gc_hash_buffer.
9345
9346         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
9347
9348         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
9349
9350 2005-10-11  Simon Josefsson  <jas@extundo.com>
9351
9352         * lib/crc.h, lib/crc.c: New files.
9353
9354         * lib/gc.h (gc_hash_buffer): Add doc.
9355
9356 2005-10-11  Bruno Haible  <bruno@clisp.org>
9357
9358         * modules/c-strcasestr: New file.
9359         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
9360
9361 2005-10-11  Bruno Haible  <bruno@clisp.org>
9362
9363         * modules/c-strcase: New file.
9364         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
9365
9366 2005-10-11  Bruno Haible  <bruno@clisp.org>
9367
9368         * lib/strcasecmp.c: Include limits.h.
9369         (strcasecmp): Avoid integer overflow on exotic platforms.
9370         * lib/strncasecmp.c: Include limits.h.
9371         (strncasecmp): Avoid integer overflow on exotic platforms.
9372         Reported by Paul Eggert.
9373
9374 2005-10-11  Bruno Haible  <bruno@clisp.org>
9375
9376         * lib/c-strcasestr.h: New file, from GNU gettext.
9377         * lib/c-strcasestr.c: New file, from GNU gettext.
9378
9379 2005-10-11  Bruno Haible  <bruno@clisp.org>
9380
9381         * lib/c-strcase.h: New file, from GNU gettext.
9382         * lib/c-strcasecmp.c: New file, from GNU gettext.
9383         * lib/c-strncasecmp.c: New file, from GNU gettext.
9384
9385 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9386
9387         * modules/mempcpy (License): GPL -> LGPL.
9388         * modules/strchrnul (License): Likewise.
9389         * modules/sysexits (License): Likewise.
9390
9391 2005-10-08  Simon Josefsson  <jas@extundo.com>
9392
9393         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
9394
9395 2005-10-07  Simon Josefsson  <jas@extundo.com>
9396
9397         * m4/memxor.m4: Remove gl_C_RESTRICT call.
9398
9399 2005-10-06  Simon Josefsson  <jas@extundo.com>
9400
9401         * tests/test-hmac-md5.c: New file.
9402
9403         * modules/hmac-md5-tests: New file.
9404
9405         * modules/hmac-md5: New file.
9406
9407 2005-10-06  Simon Josefsson  <jas@extundo.com>
9408
9409         * m4/hmac-md5.m4: New file.
9410
9411         * m4/memxor.m4: Require gl_C_RESTRICT.
9412
9413 2005-10-06  Simon Josefsson  <jas@extundo.com>
9414
9415         * lib/memxor.c (memxor): Avoid casts and warnings.
9416
9417 2005-10-06  Simon Josefsson  <jas@extundo.com>
9418
9419         * lib/hmac-md5.c: New file.
9420
9421         * lib/hmac.h: New file.
9422
9423 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9424
9425         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
9426         promotes to int, not unsigned int, to catch the AIX 5.3
9427         compiler bug.
9428
9429 2005-10-05  Simon Josefsson  <jas@extundo.com>
9430
9431         * modules/memxor: New file.
9432
9433         * modules/iconv (Files): Move config.rpath to havelib, it is used
9434         there.
9435
9436         * modules/havelib (Files): Add config.rpath.
9437
9438 2005-10-05  Simon Josefsson  <jas@extundo.com>
9439
9440         * m4/memxor.m4: New file.
9441
9442 2005-10-05  Simon Josefsson  <jas@extundo.com>
9443
9444         * lib/memxor.c (memxor): Fix compiler error.
9445
9446         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
9447         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
9448
9449         * lib/memxor.h, lib/memxor.c: New files.
9450
9451         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
9452         we assume all systems have it, suggested by Jim Meyering
9453         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
9454         any systems lack sys/socket.h; mingw32 is known to lack it, but we
9455         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
9456         same reasons.
9457
9458 2005-10-05  Simon Josefsson  <jas@extundo.com>
9459
9460         * config/srclist.txt: Add glibc bug 1423 for md5.h.
9461
9462 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9463
9464         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
9465         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
9466         needed, since the source code now assumes these .h files.
9467
9468 2005-10-05  Derek Price  <derek@ximbiot.com>
9469
9470         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
9471
9472 2005-10-05  Bruno Haible  <bruno@clisp.org>
9473
9474         * modules/stdint (License): Change to LGPL.
9475
9476 2005-10-04  Simon Josefsson  <jas@extundo.com>
9477
9478         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
9479         D. Baushke" <mdb@gnu.org>.
9480
9481 2005-10-04  Bruno Haible  <bruno@clisp.org>
9482
9483         * lib/verify.h (verify_true): Provide alternative definition for C++.
9484
9485 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
9486
9487         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
9488         (SSIZE_MAX): New macro, if not already defined.
9489         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
9490         than 2 GiB.
9491
9492 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9493
9494         Sync from coreutils.
9495         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
9496         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
9497         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
9498         ULLONG_MAX doesn't work with 2.7.2.1.
9499
9500 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9501
9502         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
9503         From Ben Pfaff.
9504
9505         * modules/exclude (Depends-on): Depend on verify.
9506         * modules/strtoimax (Depends-on): Likewise.
9507         * modules/utimecmp (Depends-on): Likewise.
9508
9509 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9510
9511         * lib/exclude.c: Include verify.h.
9512         (verify): Remove.  All callers changed to use verify.h's version.
9513         * lib/strtoimax.c: Likewise.
9514         * lib/utimecmp.c: Likewis.e
9515
9516         Sync from coreutils.
9517         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
9518         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
9519         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
9520         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
9521         bother returning ENOSYS if settimeofday or stime fails; just let
9522         them return whatever errno they want to return.
9523         * lib/utimens.c: Include unistd.h, for dup2.
9524         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
9525         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
9526
9527 2005-10-02  Jim Meyering  <jim@meyering.net>
9528
9529         Sync from coreutils.
9530         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
9531         from glibc-2.2.5 that fails for read-only files.
9532
9533 2005-10-02  Jim Meyering  <jim@meyering.net>
9534
9535         Sync from coreutils.
9536         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
9537         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
9538         `#if HAVE_CONFIG_H'.
9539         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
9540         Remove AT_FDCWD test.
9541         Do not consume the fd unless successful.
9542         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
9543         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
9544         block, so that we don't even try to compile it if settimeofday is
9545         available.  This works around a compilation failure on OSF1 V5.1,
9546         due to stime requiring a `long int*' while tv_sec is `int'.
9547
9548 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
9549
9550         Sync from coreutils.
9551         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
9552         against `yes', rather than just testing for nonempty.
9553
9554 2005-10-01  Simon Josefsson  <jas@extundo.com>
9555
9556         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
9557         and Darwin.
9558
9559         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
9560         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
9561         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
9562         freeaddrinfo and gai_strerror are declared by the POSIX headers.
9563         Check if struct addrinfo is declared.
9564
9565 2005-10-01  Simon Josefsson  <jas@extundo.com>
9566
9567         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
9568         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
9569         AI_* and EAI_* definitions.  Protect function declarations.
9570
9571 2005-10-01  Jim Meyering  <jim@meyering.net>
9572
9573         Sync from coreutils.
9574
9575         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
9576         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
9577         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
9578         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9579         in the inet and nsl libraries.  Required on Solaris 5.7.
9580
9581 2005-10-01  Jim Meyering  <jim@meyering.net>
9582
9583         Sync from coreutils.
9584         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9585         in the inet and nsl libraries.  Required on Solaris 5.7.
9586
9587 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
9588
9589         * lib/getdelim.c (getdelim): Remove unused variables.
9590
9591 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9592
9593         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
9594         so that the code works even with ancient cpp.  Portability problem
9595         with GCC 2.7.2.1 reported by Thomas M.Ott.
9596
9597 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9598
9599         * modules/regex (Depends-on): Add strcase.
9600
9601         * modules/gethostname (Licence): Change from GPL to LGPL, since
9602         gethostname.c is a trivial implementation of a standard library
9603         function.
9604         * modules/poll (License): Change from GPL to LGPL, since it's
9605         derived from LGPL code.
9606
9607 2005-09-27  Jim Meyering  <jim@meyering.net>
9608
9609         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
9610         HAVE_CONFIG_H.
9611
9612         * lib/intprops.h (signed_type_or_expr__): Define.
9613         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
9614         for unsigned types.
9615
9616 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9617
9618         * lib/verify.h (verify_expr): Remove, replacing with:
9619         (verify_true): New macro that returns true instead of void.
9620         (verify_type__): Remove.
9621         (verify): Use verify_true rather than verify_type__.
9622
9623 2005-09-26  Bruno Haible  <bruno@clisp.org>
9624
9625         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
9626         is necessary.
9627         (lib_SOURCES): Remove mbchar.c.
9628         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
9629         (Files): Add m4/mbrtowc.m4.
9630         * modules/mbiter: Likewise.
9631         * modules/mbuiter: Likewise.
9632
9633 2005-09-26  Bruno Haible  <bruno@clisp.org>
9634
9635         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
9636         compile mbchar.c if they are not both present.
9637         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
9638         * m4/mbiter.m4 (gl_MBITER): Likewise.
9639         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
9640         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
9641         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
9642
9643 2005-09-25  Jim Meyering  <jim@meyering.net>
9644
9645         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
9646         also uses socklen_t.
9647
9648 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
9649
9650         * lib/utimens.c (ENOSYS): Define if not already defined.
9651         (futimens): Support having a null PATH if the file descriptor
9652         is nonnegative.
9653
9654         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
9655         Remove.
9656         (__attribute): Define to empty unless GCC 3.1 or later.
9657         This works around a core dump on OpenBSD 3.4, which has GCC
9658         2.95.3, which dumps core when given __attribute__(()).  It also
9659         simplifies other tests, since we really don't want to bother with
9660         worrying about which ancient version of GCC supported what.
9661         Original problem reported by Yoann Vandoorselaere, with part of
9662         the fix suggested by Derek Price.
9663
9664 2005-09-24  Jim Meyering  <jim@meyering.net>
9665
9666         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
9667         so we can once again use a positive bitfield width of 1 -- now we
9668         don't have to explain why we were using a bitfield width of 2.
9669
9670 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9671
9672         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
9673         and similarly for the other external symbols.  Problem reported
9674         by James Gallager.
9675
9676         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
9677         bug reported by Jim Meyering.
9678
9679         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
9680         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
9681         not needed, since socklen is a prerequisite module.
9682
9683 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9684
9685         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
9686         Problem reported by Eric Blake.
9687         (getaddrinfo): Initialize se so that it's not garbage.
9688         Redo internal storage allocation so that it doesn't make unportable
9689         assumptions about alignment.
9690         Fix a memory leak.
9691
9692         * lib/utimens.c (futimens): Use futimesat if available.
9693         Prefer it to futimes since it doesn't have the futimes bug.
9694
9695         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
9696         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
9697         Instead, declare a function that returns a pointer to an array,
9698         and use verify_type__ to declare the size of the array.
9699         Problem and germ of a solution reported by Bruno Haible.
9700         (verify_type__): Use 2, not 1, for bitfield size, to avoid
9701         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
9702
9703 2005-09-23  Jim Meyering  <jim@meyering.net>
9704
9705         Sync from coreutils.
9706         Correct build failure (socklen_t not defined) on at least
9707         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
9708         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
9709
9710 2005-09-23  Jim Meyering  <jim@meyering.net>
9711
9712         * modules/getaddrinfo (Depends-on): Add socklen.
9713
9714 2005-09-23  Bruno Haible  <bruno@clisp.org>
9715
9716         * tests/test-verify.c: New file.
9717
9718 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9719
9720         Sync from coreutils.
9721
9722         * modules/argmatch (Depends-on): Add verify.
9723         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
9724         unistd-safer.
9725         * modules/save-cwd (Depends-on): Likewise.
9726
9727         * modules/openat (Files): Add lib/openat-die.c.
9728         (Depends-on): Remove error, exitfail.
9729         Add dirname.
9730
9731         * modules/verify: New file.
9732         * MODULES.html.sh (Diagnostics <assert.h>): New section,
9733         with "verify" module.
9734
9735 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9736
9737         Sync from coreutils.
9738
9739         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
9740         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
9741         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
9742         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
9743         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
9744         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
9745         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
9746         Don't bother checking for string.h, stdlib.h, unistd.h.
9747         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
9748         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
9749         module's job.
9750         * m4/jm-macros.m4 (gl_MACROS): Likewise.
9751         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
9752
9753         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
9754         (gl_GETDATE): Use it.
9755
9756         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
9757
9758 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9759
9760         Sync from coreutils.
9761
9762         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
9763         stat-time.h.
9764         * lib/argmatch.h: Include verify.h
9765         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
9766         (ARGMATCH_ASSERT): Remove; unused.
9767         * lib/canonicalize.c: Assume STDC_HEADERS.
9768         * lib/exclude.c: Include "strcase.h".
9769         * lib/regex_internal.h [!defined _LIBC]: Likewise.
9770         * lib/getusershell.c: Include stdio--.h rather than stdio.h
9771         and stdio-safer.h.
9772         (getusershell): Call fopen, not fopen_safer.
9773         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
9774         Do not include unistd-safer.h.
9775         (save_cwd): Don't call fd_safer; no longer needed
9776         now that we include fcntl--.h.
9777
9778         * lib/getdate.y (relative_time): New type.
9779         (RELATIVE_TIME_0): New constant.
9780         (parser_control): Use relative_time instead of doing it ourselves.
9781         (%union): Add new relative_time rel member.
9782         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
9783         Now typeless.
9784         (relunit, relunit_snumber): Now of type rel.
9785         (zone, rel, relunit, get_date): Adjust to above changes.
9786
9787         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
9788         Do not include unistd-safer.h.
9789         (getloadavg): Don't call fd_safer; no longer needed
9790         now that we include fcntl--.h.
9791
9792         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
9793         (make_dir_parents): Treat ENOSYS like EEXIST.
9794
9795         Improve quality of diagnostics on restore_cwd failure.
9796         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
9797         (make_dir_parents): Last arg is now int * (for errno), not bool *.
9798         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
9799         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
9800         each time through the loop.  Do not diagnose restore_cwd failure;
9801         that is the caller's job (and perhaps the caller does not care).
9802
9803         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
9804         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
9805         If the file already exists but is not a directory, don't bother
9806         to try to make its parents.
9807         Close potential file descriptor leak if we can't chdir("/") (!).
9808         Don't always return true if chdir($PWD) fails; return true only
9809         if the requested action was done successfully (except for the
9810         chdir($PWD)).
9811         Don't log final directory unless we actually made it.
9812         Refactor to avoid duplicate code to fix up permissions.
9813         Don't attempt to fix up parent permissions if chdir($PWD) fails.
9814
9815         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
9816         to make it a bit faster and (I hope) clearer.
9817         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
9818         Fix bug in formats like %2N.
9819
9820         * lib/verify.h: New file.
9821
9822 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9823
9824         Sync from coreutils.
9825         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
9826
9827 2005-09-22  Jim Meyering  <jim@meyering.net>
9828
9829         Sync from coreutils.
9830
9831         * m4/lstat.m4 (gl_FUNC_LSTAT):
9832         Use AC_LIBSOURCES to require lstat.c and lstat.h.
9833         Remove obsolete comment.
9834         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
9835         * m4/xstrtod.m4: Likewise.
9836
9837         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
9838
9839 2005-09-22  Jim Meyering  <jim@meyering.net>
9840
9841         Sync from coreutils.
9842
9843         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
9844
9845         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
9846         the .tm_year member, since otherwise gcc-4.0 would now warn about
9847         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
9848
9849         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
9850         order to avoid an unsuppressible warning from gcc on 64-bit systems.
9851
9852         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
9853         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
9854         when run in a time zone for which daylight savings time is in effect
9855         for the starting date.
9856
9857         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
9858         stop us from restricting permissions of just-created absolute-named
9859         directories.
9860         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
9861         to restore initial working directory.
9862         * lib/mkdir-p.c (make_dir_parents): New parameter:
9863         different_working_dir, to tell caller if/when we change the working
9864         directory and are unable to return to the initial one.
9865         * lib/mkdir-p.h (make_dir_parents): Update prototype.
9866         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
9867         `return false'.  This fixes a bug introduced on 2004-07-30.
9868
9869         * lib/openat.c (fdopendir): Be sure to close the supplied
9870         file descriptor before returning.  This makes our replacement
9871         implementation a little closer to Solaris's, where fdopendir
9872         ties the file descriptor to the returned DIR* pointer.
9873         * lib/openat.c (unlinkat): New function.
9874         * lib/openat.h (unlinkat): Add prototype.
9875         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
9876         (openat_restore_fail): Rename from openat_restore_die.
9877         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
9878
9879         Provide an alternative to exiting immediately upon save_cwd or
9880         restore_cwd failure.  Now, an application can arrange e.g.,
9881         to perform a longjump in that case.
9882         * lib/openat.c: Include dirname.h.
9883         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
9884         (rpl_openat, fdopendir, fstatat): Call openat_save_die
9885         and openat_restore_die rather than calling error directly.
9886         Don't include "error.h" or "exitfail.h"; they're no longer needed.
9887
9888         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
9889         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
9890         define.
9891
9892         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
9893         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
9894                             int utc, int nanoseconds);
9895         Background:
9896         date should not have to allocate a megabyte of virtual memory to
9897         handle a format argument like +%1048575T.  When implemented with
9898         strftime, it must allocate such a buffer, use strftime to fill it
9899         in, print it, then free it.
9900         With fprintftime, it simply prints everything and exits.
9901         With no need for memory allocation, that's one fewer way to fail.
9902         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
9903         optional field width, not before, so we accept %9:z, not %:9z.
9904         (my_strftime): Be sure to use L_('x') for literals.
9905
9906         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
9907         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
9908         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
9909         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
9910         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
9911         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
9912         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
9913         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
9914         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
9915         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
9916         * lib/xgethostname.c, lib/xreadlink.c:
9917         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
9918
9919         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
9920         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
9921         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
9922         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
9923         and don't include <sys/file.h>).
9924
9925 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
9926
9927         Sync from coreutils.
9928
9929         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
9930         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
9931         [!LDAV_DONE]: Avoid unused variable warning.
9932
9933 2005-09-21  Bruno Haible  <bruno@clisp.org>
9934
9935         * lib/unicodeio.h (unicode_to_mb): New declaration.
9936
9937 2005-09-20  Derek Price  <derek@ximbiot.com>
9938
9939         * lib/getaddrinfo.c: Don't include <netdb.h> included from
9940         getaddrinfo.h.
9941
9942 2005-09-20  Bruno Haible  <bruno@clisp.org>
9943
9944         * gnulib-tool: Remove trailing slashes from the values specified for
9945         --source-base, --m4-base, --tests-base, --aux-dir.
9946         Suggested by Simon Josefsson <jas@extundo.com>.
9947
9948 2005-09-20  Bruno Haible  <bruno@clisp.org>
9949
9950         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
9951         func_modules_to_filelist, func_import, func_create_testdir): Make all
9952         sorting results locale-independent, so that gnulib-cache.m4 doesn't
9953         change when gnulib-tool is invoked in a different locale.
9954
9955 2005-09-19  Simon Josefsson  <jas@extundo.com>
9956
9957         * m4/socklen.m4: Fix typo.
9958
9959 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9960
9961         Use a consistent style for including <config.h>.
9962         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
9963         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
9964         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
9965         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
9966         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
9967         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
9968         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
9969         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
9970         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
9971         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
9972         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
9973         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
9974         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
9975         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
9976         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
9977         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
9978         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
9979         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
9980         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
9981         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
9982         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
9983         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
9984         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
9985         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
9986         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
9987         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
9988         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
9989         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
9990         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
9991         lib/xstrtoumax.c, lib/yesno.c:
9992         Standardize inclusion of config.h.
9993         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
9994         lib/inttostr.h:  Removed inclusion of config.h from header files.
9995         * lib/inttostr.c:  Adjusted in-tree users.
9996         * lib/timespec.h: Remove superfluous warning to include config.h.
9997         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
9998         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
9999         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
10000         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
10001         config.h with HAVE_CONFIG_H.
10002
10003 2005-09-19  Jim Meyering  <jim@meyering.net>
10004
10005         * modules/pathmax (License): Change to LGPL.
10006
10007 2005-09-19  Derek Price  <derek@ximbiot.com>
10008
10009         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
10010
10011 2005-09-19  Bruno Haible  <bruno@clisp.org>
10012
10013         * gnulib-tool (import): Provide default for --tests-base.
10014
10015 2005-09-19  Bruno Haible  <bruno@clisp.org>
10016
10017         * doc/quote.texi: New file, extracted from gnulib.texi.
10018         * doc/ctime.texi: New file, extracted from gnulib.texi.
10019         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
10020         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
10021         * doc/gnulib.texi: Include them.
10022
10023 2005-09-18  Bruno Haible  <bruno@clisp.org>
10024
10025         Portability fix.
10026         * gnulib-tool (func_readlink): New function.
10027         (func_ln_if_changed): Use it.
10028
10029 2005-09-18  Bruno Haible  <bruno@clisp.org>
10030
10031         * gnulib-tool: Support --with-tests also with --import.
10032         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
10033         (func_import): Use variables $testsbase and $inctests. Emit a
10034         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
10035         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
10036         SUBDIRS += $testsdir.
10037         (func_create_testdir): Update.
10038
10039 2005-09-18  Bruno Haible  <bruno@clisp.org>
10040
10041         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
10042         instead of $dry_run.
10043         (func_cp_if_changed, func_mv_if_changed): Remove functions.
10044         (func_ln_if_changed): Don't handle dry-run here.
10045         (func_import): In dry-run mode, detect more precisely which actions
10046         would be performed, and don't use "...ing" verbs.
10047
10048 2005-09-18  Bruno Haible  <bruno@clisp.org>
10049
10050         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
10051         (func_import): Use join on two temporary files instead of three nested
10052         loops, in order to determine which files are new or old.
10053
10054 2005-09-18  Bruno Haible  <bruno@clisp.org>
10055
10056         * gnulib-tool (func_import): Comment out code that spits out the
10057         new files with --dry-run.
10058
10059 2005-09-18  Bruno Haible  <bruno@clisp.org>
10060
10061         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
10062
10063 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10064
10065         * lib/stat-time.h: New file.
10066         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
10067         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
10068         in a different way.
10069         (timespec_cmp): New function.
10070         * lib/utimecmp.c: Include stat-time.h.
10071         (SYSCALL_RESOLUTION): Depend on whether various struct stat
10072         members exist, not on the obsolescent ST_MTIM_NSEC.
10073         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
10074
10075 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10076
10077         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
10078
10079 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10080
10081         * MODULES.html.sh (File system functions): Add stat-time.
10082         * modules/stat-time: New file.
10083         * modules/timespec (Files): Remove m4/st_mtim.m4; this
10084         is now done in a different way, by the stat-time module.
10085         * modules/utimecmp (Depends-on): Add stat-time.
10086
10087 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10088
10089         * m4/st_mtim.m4: Remove.  Superseded by...
10090         * m4/stat-time.m4: New file.
10091         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
10092         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
10093
10094 2005-09-15  Derek Price  <derek@ximbiot.com>
10095
10096         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
10097
10098 2005-09-15  Derek Price  <derek@ximbiot.com>
10099
10100         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
10101         * lib/regex_internal.c: Ditto, using this...
10102         (__GNUC_PREREQ): ...new macro.
10103         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
10104         using...
10105         (__GNUC_PREREQ): ...this new macro.
10106
10107         * lib/strstr.h: Include string.h. Define strstr as a macro here.
10108
10109 2005-09-15  Derek Price  <derek@ximbiot.com>
10110             Paul Eggert  <eggert@cs.ucla.edu>
10111
10112         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
10113         changes, consolidating in...
10114         * lib/regex_internal.h: ...this file.
10115
10116 2005-09-13  Jim Meyering  <jim@meyering.net>
10117
10118         * lib/canon-host.c: Filter through gnu indent and reword comments
10119         slightly.
10120         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
10121
10122 2005-09-13  Derek Price  <derek@ximbiot.com>
10123
10124         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
10125         failure.
10126         Reported by Jim Meyering  <jim@meyering.net>.
10127
10128 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10129
10130         * lib/base64.c: Typo.
10131         (base64_encode): Put b64str in initialized data section.
10132
10133 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
10134
10135         Merge glibc and coreutils changes into gnulib, plus a few
10136         extra fixes.
10137         * lib/md5.c: Use #error rather than a string.
10138         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
10139         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
10140         (__attribute__): Define to empty for non recent-GCC.
10141         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
10142         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
10143         Renamed from their non-__ counterparts, with new macros replacing
10144         them if not _LIBC.  Add __THROW attribute.
10145         (rol): Remove.
10146         (struct md5_ctx): Align buffer if using GCC.
10147         * lib/sha1.h (struct sha1_ctx): Likewise.
10148         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
10149         The old name was backwards.
10150         (NOTSWAP): Remove; not used.
10151         (rol): New macro, moved here from md5.h.
10152         (sha1_process_block): Remove a FIXME that doesn't make sense.
10153
10154 2005-09-12  Derek Price  <derek@ximbiot.com>
10155
10156         Return usable errors from canon-host.
10157         * lib/canon-host.h: New file.
10158         * lib/canon-host.c (canon_host): Wrap...
10159         (canon_host_r): ...this new function, which now relies exclusively on
10160         getaddrinfo.
10161         (ch_strerror): New function.
10162         (last_cherror): New global.
10163         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
10164         interface.
10165         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
10166         void *.
10167         (freeaddrinfo): Free ai->ai_canonname when set.
10168
10169 2005-09-12  Derek Price  <derek@ximbiot.com>
10170
10171         Make canon-host require getaddrinfo.
10172         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
10173         AC_LIBSOURCE canon-host.h.  Call...
10174         (gl_PREREQ_CANON_HOST): ...this new function, which requires
10175         gl_GETADDRINFO.
10176         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
10177
10178 2005-09-12  Derek Price  <derek@ximbiot.com>
10179
10180         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
10181         LGPL.
10182         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
10183
10184 2005-09-12  Derek Price  <derek@ximbiot.com>
10185
10186         * lib/gai_strerror.c: Include config.h when available.  Include
10187         getaddrinfo.h before other headers to test interface.
10188         Reported by Larry Jones <lawrence.jones@ugs.com>.
10189
10190 2005-09-12  Derek Price  <derek@ximbiot.com>
10191             Paul Eggert  <eggert@cs.ucla.edu>
10192
10193         * modules/glob (Files): Add glob-libc.h.
10194
10195 2005-09-12  Derek Price  <derek@ximbiot.com>
10196             Paul Eggert  <eggert@cs.ucla.edu>
10197
10198         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
10199         glob_.h, glob-libc.h.
10200         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
10201
10202 2005-09-12  Derek Price  <derek@ximbiot.com>
10203             Paul Eggert  <eggert@cs.ucla.edu>
10204
10205         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
10206         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
10207         protecting things that should be done only in gnulib contexts.
10208         * lib/glob_.h: New file, containing only the glob things needed for
10209         gnulib.
10210         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
10211         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
10212         (glob, globfree, glob_pattern_p): Now defined simply in terms of
10213         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
10214         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
10215         and to respect the namespace rules better.
10216
10217 2005-09-08  Simon Josefsson  <jas@extundo.com>
10218
10219         * modules/socklen: New file.
10220
10221 2005-09-08  Simon Josefsson  <jas@extundo.com>
10222
10223         * m4/socklen.m4: New file.
10224
10225 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10226
10227         * modules/utimens (Files): Add m4/utimbuf.m4, since
10228         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
10229         Reported by Sergey Poznyakoff.
10230
10231 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10232
10233         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
10234         definitions, since that's the preferred style in glibc.
10235         Fix a minor spacing issue, and update copyright notice to match
10236         glibc's.
10237
10238 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10239
10240         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
10241
10242 2005-09-06  Simon Josefsson  <jas@extundo.com>
10243
10244         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
10245         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
10246
10247 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10248
10249         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
10250         warning.
10251
10252 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10253
10254         * config/srclist.txt: Add glibc bug 1302.
10255
10256 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
10257
10258         Change bitset word type from unsigned int to unsigned long int,
10259         as this has better performance on typical 64-bit hosts.
10260         Port bitset code to hosts with unusual word sizes.
10261         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
10262         (build_collating_symbol):
10263         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
10264         argument is a bitset.  This is merely a style issue, but it makes
10265         it clearer that an entire array is expected.
10266         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
10267         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
10268         Port to the case where bitset_word is not the same as unsigned int.
10269         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10270         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
10271         Likewise.
10272         * lib/regexec.c (check_dst_limits_calc_pos_1,
10273         check_subexp_matching_top):
10274         (build_trtable, group_nodes_into_DFAstates):
10275         Likewise.
10276         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
10277         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
10278         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
10279         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
10280         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
10281         * lib/regcomp.c (optimize_subexps, lower_subexp):
10282         Work even if bitset_word has holes in its bitwise representation.
10283         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
10284         * lib/regexec.c (check_dst_limits_calc_pos_1,
10285         check_subexp_matching_top):
10286         Likewise.
10287         * lib/regex_internal.c (re_string_reconstruct):
10288         Don't assume UCHAR_MAX == 255.
10289         * lib/regex_internal.h (bitset_set_all): Likewise.
10290         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
10291         All uses changed.
10292         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
10293         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
10294         All uses changed.
10295         (BITSET_WORD_MAX): New macro.
10296         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
10297         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
10298         (bitset_empty, bitset_copy):
10299         Prefer sizeof (bitset) to multiplying it out ourselves.
10300         (bitset_not_merge): Remove; unused.
10301         (bitset_contain): Return bool, not unsigned int with one bit on.
10302         All callers changed.
10303         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
10304         alignment than re_node_set; do this by defining a new internal
10305         type struct dests_alloc and using it to allocate memory.
10306
10307 2005-09-05  Bruno Haible  <bruno@clisp.org>
10308
10309         * gnulib-tool (func_import): Fix comparison in handling of symbolic
10310         links.
10311
10312 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
10313
10314         * modules/size_max (Makefile.am): Add size_max.h
10315
10316 2005-09-04  Derek Price  <derek@ximbiot.com>
10317
10318         * gnulib-tool (func_import): Fix reversed $symbolic logic.
10319
10320 2005-09-03  Simon Josefsson  <jas@extundo.com>
10321
10322         * gnulib-tool: Fix typo.
10323
10324 2005-09-03  Simon Josefsson  <jas@extundo.com>
10325
10326         * config/srclist.txt: Add glibc bug 1293.
10327
10328 2005-09-03  Derek Price  <derek@ximbiot.com>
10329
10330         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
10331         From Larry Jones <lawrence.jones@ugs.com>.
10332
10333 2005-09-02  Simon Josefsson  <jas@extundo.com>
10334
10335         * modules/socklen: New file.
10336
10337 2005-09-02  Simon Josefsson  <jas@extundo.com>
10338
10339         * modules/havelib: New module.
10340
10341         * modules/gettext, modules/iconv, modules/lock, modules/readline:
10342         Use havelib.
10343
10344 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10345
10346         Check for arithmetic overflow when calculating sizes, to prevent
10347         some buffer-overflow issues.  These patches are conservative, in the
10348         sense that when I couldn't determine whether an overflow was possible,
10349         I inserted a run-time check.
10350         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
10351         macros.
10352         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
10353         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
10354         (re_xnrealloc, re_x2nrealloc): New inline functions.
10355         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
10356         parse_bracket_exp):
10357         (build_equiv_class, build_charclass): Check for arithmetic overflow
10358         in size expression calculations.
10359         * lib/regex_internal.c (re_string_realloc_buffers):
10360         (build_wcs_upper_buffer, re_node_set_add_intersect):
10361         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
10362         (re_dfa_add_node, register_state): Likewise.
10363         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
10364         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
10365         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
10366         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
10367
10368 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10369
10370         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
10371         m4/ulonglong.m4.  Problem reported by Martin Lambers.
10372
10373 2005-09-02  Bruno Haible  <bruno@clisp.org>
10374
10375         Support for lib vs. lib64 distinction on biarch platforms.
10376         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
10377         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
10378         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
10379
10380 2005-09-02  Bruno Haible  <bruno@clisp.org>
10381
10382         * gnulib-tool (import): In the other first-use case, provide defaults
10383         as well.
10384
10385 2005-09-02  Bruno Haible  <bruno@clisp.org>
10386
10387         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
10388         patches not yet found in the latest gettext release.
10389
10390 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10391
10392         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
10393         to avoid a collision with bits/local_lim.h in glibc.
10394         All uses changed.  Problem reported by Dmitry V. Levin in
10395         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
10396
10397         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
10398         bugs in int versus size_t comparisons.
10399         (re_string_context_at): Fix bug where the code assumed that
10400         Idx is signed.
10401
10402         Use bool where appropriate.
10403         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
10404         All callers changed.
10405         (calc_eclosure_iter): Likewise, for ROOT arg.
10406         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
10407         (build_charclass_op): Likewise, for NON_MATCH arg.
10408         * lib/regex_internal.c (re_string_allocate, re_string_construct):
10409         (re_string_construct_common): Likewise, for ICASE arg.
10410         * lib/regexec.c (re_search_2_stub, re_search_stub):
10411         Likewise, for RET_LEN arg.
10412         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
10413         (set_regs): Likewise, for FL_BACKTRACK arg.
10414         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
10415         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
10416         (calc_eclosure_iter, parse_bracket_exp):
10417         Use bool for internal variables that are booleans.
10418         * lib/regexec.c (re_search_internal, check_matching,
10419         proceed_next_node):
10420         (set_regs, build_sifted_states, sift_states_bkref):
10421         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
10422         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
10423         (find_collation_sequence_value):
10424         Likewise.
10425         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
10426         (re_node_set_compare):
10427         Return bool, not int. All callers changed.
10428         * lib/regexec.c (check_halt_node_context, check_dst_limits):
10429         (build_trtable, check_node_accept): Likewise.
10430         * lib/regex_internal.h: Include stdbool.h.
10431
10432         Fix bugs uncovered when converting to bool.
10433         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
10434         failure instead of charging ahead blindly.
10435         * lib/regex_internal.c (register_state): Likewise.
10436         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
10437         for freeing internal storage.
10438         (group_nodes_into_DFA_states): Use unsigned int, not int, for
10439         bitset pieces used as boolean, to avoid undefined behavior
10440         on hosts that do int overflow checking.
10441
10442 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10443
10444         * config/srclist.txt: Add glibc bugs 1285-1287.
10445
10446 2005-09-01  Jim Meyering  <jim@meyering.net>
10447
10448         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
10449         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
10450         Require gl_STAT_MACROS, too.
10451
10452 2005-09-01  Bruno Haible  <bruno@clisp.org>
10453
10454         * gnulib-tool (import): In the first-use case, provide defaults.
10455
10456 2005-09-01  Bruno Haible  <bruno@clisp.org>
10457
10458         * gnulib-tool (func_import): Remove the .tmp files.
10459
10460 2005-09-01  Bruno Haible  <bruno@clisp.org>
10461
10462         * gnulib-tool (func_import): Fix handling of symbolic links.
10463
10464 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10465
10466         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
10467         old glibc regex code mishandles strings longer than 2**31 bytes.
10468         This patch fixes this when the regex code is used in gnulib
10469         (i.e., outside glibc).
10470
10471         This patch should not affect the use of the regex code inside
10472         glibc.  No doubt this problem also needs to be handled for glibc
10473         as well, but the result will be an incompatible change to the
10474         glibc ABI, and the old ABI will have to be supported too.  That
10475         can be the the subject for another patch.
10476
10477         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
10478         governing whether the rest of this patch is active.  By default,
10479         the macro is disabled and the patch has no effect.
10480         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
10481         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
10482         (struct re_pattern_buffer, re_search, re_search_2, re_match):
10483         (re_match_2, re_set_registers): Use the new types.
10484         * lib/regex_internal.h (Idx, re_hashval_t): New types.
10485         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
10486         New macros.
10487         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
10488         (re_string_context_at, bin_tree_t, re_dfastate_t):
10489         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
10490         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
10491         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
10492         (re_string_char_size_at, re_string_wchar_at):
10493         (re_string_elem_size_at):
10494         Use the new types and macros to port to 64-bit hosts.
10495         Use unsigned types for internal values, so that the code
10496         mostly works even for arrays larger than SSIZE_MAX.
10497         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
10498         (search_duplicated_node, calc_eclosure_iter, fetch_number):
10499         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
10500         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
10501         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
10502         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
10503         (calc_inveclosure, parse_dup_op, build_range_exp):
10504         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
10505         (fetch_number, create_token_tree, mark_opt_subexp):
10506         Likewise.
10507         * lib/regex_internal.c (re_string_construct_common,
10508         create_ci_newstate):
10509         (create_cd_newstate, re_string_allocate, re_string_construct):
10510         (re_string_realloc_buffers, build_wcs_upper_buffer):
10511         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
10512         (re_string_reconstruct, re_string_peek_byte_case):
10513         (re_string_fetch_byte_case, re_string_context_at):
10514         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
10515         (re_node_set_init_copy, re_node_set_add_intersect):
10516         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10517         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10518         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
10519         (re_acquire_state, re_acquire_state_context, register_state):
10520         Likewise.
10521         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
10522         search_cur_bkref_entry):
10523         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
10524         (re_search_internal, re_search_2_stub, re_search_stub)
10525         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
10526         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
10527         (update_cur_sifted_state, check_dst_limits):
10528         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10529         (check_subexp_limits, sift_states_bkref, merge_state_array):
10530         (check_subexp_matching_top, get_subexp, get_subexp_sub):
10531         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
10532         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
10533         (expand_bkref_cache, check_node_accept_bytes):
10534         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
10535         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
10536         (acquire_init_state_context, check_halt_node_context):
10537         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
10538         (sift_states_backward, clean_state_log_if_needed):
10539         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
10540         (find_recover_state, transit_state_sb, transit_state_mb):
10541         (transit_state_bkref, build_trtable, match_ctx_clean):
10542         Likewise.
10543         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
10544         to work around an assumption that REG_MISSING is negative.
10545
10546         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
10547         (seek_collating_symbol_entry) [defined _LIBC]:
10548         (lookup_collation_sequence_value) [defined _LIBC]:
10549         (build_range_exp, build_collating_symbol) [defined _LIBC]:
10550         Use prototypes rather than old-style function definitions.
10551         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
10552         (transit_state_sb) [0]:
10553         (find_collation_sequence_value) [defined _LIBC]: Likewise.
10554
10555         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
10556         rm_eo.
10557
10558         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
10559         (optimize_subexps, lower_subexp):
10560         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
10561         since the signed shift might overflow.  Use 1u<<31 instead.
10562         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10563         Likewise.
10564         * lib/regexec.c (check_dst_limits_calc_pos_1,
10565         check_subexp_matching_top): Likewise.
10566
10567         * lib/regcomp.c (optimize_subexps, lower_subexp):
10568         Use CHAR_BIT rather than 8, for clarity.
10569         * lib/regexec.c (check_dst_limits_calc_pos_1):
10570         (check_subexp_matching_top): Likewise.
10571         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
10572         have to worry about portability issues when shifting it left.
10573         Remove no-longer-needed test for table_size > 0.
10574         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
10575         in a word, as the resulting behavior is undefined.
10576         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
10577         in one case, a <= should have been an <, and in another case the
10578         whole test was missing.
10579         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
10580         the standard name CHAR_BIT.
10581         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
10582         this is not true on one's complement and signed-magnitude hosts.
10583
10584         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
10585         next_last_offset.
10586         (struct re_dfa_t): Remove unused member states_alloc.
10587         * lib/regcomp.c (init_dfa): Don't initialize unused members.
10588
10589 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10590
10591         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
10592         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
10593         and large-file glibc and in 32-bit large-file Solaris.
10594
10595 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10596
10597         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
10598         lengths fit in regoff_t; this isn't true if regoff_t is the same
10599         width as size_t.
10600         * lib/regex.c (re_search_internal): 5th arg is LAST_START
10601         (= START + RANGE) instead of RANGE.  This avoids overflow
10602         problems when regoff_t is the same width as size_t.
10603         All callers changed.
10604         (re_search_2_stub): Check for overflow when adding the
10605         sizes of the two strings.
10606         (re_search_stub): Check for overflow when adding START
10607         to RANGE; if it occurs, substitute the extreme value.
10608
10609 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10610
10611         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
10612
10613 2005-08-31  Jim Meyering  <jim@meyering.net>
10614
10615         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
10616         a pointer-to-const.
10617         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
10618         (register_state): Likewise.
10619         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
10620         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10621         (group_nodes_into_DFAstates): Likewise.
10622
10623 2005-08-31  Jim Meyering  <jim@meyering.net>
10624
10625         * check-module: Add a FIXME comment.
10626
10627 2005-08-31  Eric Blake  <ebb9@byu.net>
10628
10629         * modules/unistd-safer (Files): Add unistd--.h.
10630         * modules/stdio-safer (Files): Add stdio--.h.
10631
10632 2005-08-31  Derek Price  <derek@ximbiot.com>
10633
10634         * lib/getdelim.c (getdelim): Return EOF on EOF.
10635         Reported by Larry Jones <lawrence.jones@ugs.com>.
10636
10637 2005-08-31  Bruno Haible  <bruno@clisp.org>
10638
10639         Avoid unnecessary diffs in the generated lib/Makefile.am.
10640         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
10641         the generated files.
10642         (func_import): Don't set cmd.
10643
10644 2005-08-31  Bruno Haible  <bruno@clisp.org>
10645
10646         * lib/strstr.c: Include <stddef.h>, for NULL.
10647         * lib/strcasestr.c: Likewise.
10648         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10649
10650 2005-08-31  Bruno Haible  <bruno@clisp.org>
10651
10652         * gnulib-tool: New option --macro-prefix.
10653         (func_import): Use macro_prefix.
10654         (import): Handle option --macro-prefix.
10655
10656 2005-08-31  Bruno Haible  <bruno@clisp.org>
10657
10658         * gnulib-tool (import): Rename most ac_* variables to cached_*.
10659         Also use new variables cached_lgpl, cached_libtool.
10660
10661 2005-08-31  Bruno Haible  <bruno@clisp.org>
10662
10663         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
10664         always instantiating them.
10665
10666 2005-08-31  Bruno Haible  <bruno@clisp.org>
10667
10668         * gnulib-tool (func_import): Read the previous cached settings
10669         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
10670         earlier added by gnulib but are now dropped. Warn when a gnulib file
10671         overwrites a non-gnulib file.
10672
10673 2005-08-31  Bruno Haible  <bruno@clisp.org>
10674
10675         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
10676         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
10677         projects that don't keep autogenerated files in CVS. Put into
10678         actioncmd only the specified modules, not the transitive closure.
10679
10680 2005-08-31  Bruno Haible  <bruno@clisp.org>
10681
10682         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
10683         Create directories that shall be filled.
10684         (import): Don't look for gl_* macros in configure.ac. Recurse across
10685         all directories containing a gnulib-cache.m4 files, if meaningful.
10686
10687 2005-08-31  Bruno Haible  <bruno@clisp.org>
10688
10689         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
10690         (import): Set seen_libtool when we see gl_LIBTOOL.
10691
10692 2005-08-31  Bruno Haible  <bruno@clisp.org>
10693
10694         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
10695         declaration macro definitions from generated gnulib.m4.
10696
10697 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
10698
10699         * lib/iconvme.h: Add prototype for iconv_alloc.
10700
10701 2005-08-29  Simon Josefsson  <jas@extundo.com>
10702
10703         * lib/iconvme.c: Fix errno.
10704
10705 2005-08-29  Bruno Haible  <bruno@clisp.org>
10706
10707         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
10708         that it works when the directory contains spaces.
10709
10710 2005-08-29  Bruno Haible  <bruno@clisp.org>
10711
10712         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
10713
10714 2005-08-29  Bruno Haible  <bruno@clisp.org>
10715
10716         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
10717         Emit more advice.
10718
10719 2005-08-29  Bruno Haible  <bruno@clisp.org>
10720         and Stepan Kasal  <kasal@ucw.cz>
10721
10722         * check-module: If more parameters are given, check each of them
10723         separately; add more exceptions, as noted by Jim Meyering.
10724         (check_module): New procedure.
10725         (%exempt_header): Now contains all exceptions.
10726
10727 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
10728
10729         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
10730
10731 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
10732
10733         * lib/iconvme.c: Split iconv_string into iconv_alloc.
10734
10735 2005-08-28  Bruno Haible  <bruno@clisp.org>
10736
10737         * m4/gnulib-tool.m4: New file.
10738
10739 2005-08-27  Jim Meyering  <jim@meyering.net>
10740
10741         * modules/unistd-safer (Files): Add pipe-safer.c.
10742         * modules/fcntl-safer (Files): Add creat-safer.c.
10743
10744 2005-08-27  Jim Meyering  <jim@meyering.net>
10745
10746         * m4/stdlib-safer.m4: New file.  From coreutils.
10747         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
10748         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
10749         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
10750         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
10751         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
10752
10753 2005-08-27  Jim Meyering  <jim@meyering.net>
10754
10755         * lib/fopen-safer.c: Merge minor changes from coreutils.
10756         * lib/dup-safer.c: Likewise.
10757         * lib/fd-safer.c: Likewise.
10758
10759         Merge from coreutils.
10760         * lib/stdio--.h: New file.
10761         * lib/stdlib--.h: New file.
10762         * lib/mkstemp-safer.c: New file.
10763
10764         GNU tar needs these.
10765         * lib/pipe-safer.c: New file.
10766         * lib/creat-safer.c: New file.
10767         * lib/fcntl--.h (creat): Define to creat_safer.
10768         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
10769         * lib/unistd--.h (pipe): Define to pipe_safer.
10770         * lib/unistd-safer.h: Declare pipe_safer.
10771
10772 2005-08-26  Simon Josefsson  <jas@extundo.com>
10773
10774         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
10775         Haible <bruno@clisp.org>.
10776
10777 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
10778
10779         * lib/regex_internal.h: Remove all references to
10780         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
10781         or better.
10782         (bitset_not, bitset_merge, bitset_not_merge):
10783         (bitset_mask, re_string_allocate, re_string_construct):
10784         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
10785         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
10786         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
10787         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
10788         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10789         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10790         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
10791         (re_acquire_state_context):
10792         Remove unnecessary forward decls.
10793         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
10794         Put __attribute at function definition,
10795         now that the function decl has been removed.
10796         * lib/regex_internal.c (re_string_peek_byte_case):
10797         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
10798         Likewise.
10799
10800 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
10801
10802         * m4/regex.m4: Add AC_PREREQ(2.50).
10803         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
10804
10805 2005-08-25  Simon Josefsson  <jas@extundo.com>
10806
10807         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
10808         __fsetlocking.
10809
10810 2005-08-25  Simon Josefsson  <jas@extundo.com>
10811
10812         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
10813         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
10814         GLIBC specific code.
10815
10816 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10817
10818         Make regex safe for g++.  This fixes one real bug (an "err"
10819         that should have been "*err").  g++ problem reported by
10820         Sam Steingold.
10821         * lib/regex_internal.h (re_calloc): New macro, consistent with
10822         re_malloc etc.  All callers of calloc changed to use re_calloc.
10823         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
10824         not int.  All callers changed.
10825         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
10826         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
10827         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
10828         (find_recover_state): Change "err" to "*err"; this fixes what
10829         appears to be a real bug.
10830         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
10831         versus int.
10832
10833 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10834
10835         * modules/regex (Depends-on): Add malloc, since the code
10836         assumes that !malloc(0) means failure.
10837
10838 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10839
10840         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
10841
10842         alloca modernization/simplification for regex.
10843         * lib/regex.c: Remove portability cruft for alloca.  This no longer
10844         needs to be at the start of the file, and can be moved into
10845         regex_internal.h and simplified.
10846         * lib/regex_internal.h: Include <alloca.h>.
10847         (__libc_use_alloca) [!defined _LIBC]: New macro.
10848         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
10849         now works outside glibc.
10850
10851 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10852
10853         * config/srclist.txt: Add glibc bugs 1241, 1245.
10854
10855 2005-08-25  Jim Meyering  <jim@meyering.net>
10856
10857         * lib/open-safer.c: Include <config.h>.
10858         Otherwise, we'd lose LARGEFILE support in any file using
10859         e.g. "fcntl--.h"
10860
10861 2005-08-25  Bruno Haible  <bruno@clisp.org>
10862
10863         * m4/minmax.m4: Require autoconf 2.52.
10864         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
10865         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
10866         alternatives of translit over the alphabet.
10867         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
10868
10869 2005-08-24  Simon Josefsson  <jas@extundo.com>
10870
10871         * tests/test-getpass.c: New file.
10872
10873 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10874
10875         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
10876         for GNU regex features.
10877
10878 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10879
10880         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
10881         * lib/regex.h (regerror): Likewise.
10882
10883         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
10884         requires this.  (The code never needed it.)
10885
10886         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
10887         All uses of recently-renamed identifiers changed to use the new,
10888         POSIX-compliant names.  The code will build and run just fine
10889         without these changes, but it's better to eat our own dog food
10890         and use the standard-conforming names.
10891
10892         * lib/regex.h: Fix a multitude of POSIX name space violations.
10893         These changes have an effect only for programs that define
10894         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
10895         do not change anything for programs compiled in the normal way.
10896         Also, there is no effect on the ABI.
10897
10898         (_REGEX_SOURCE): New macro.
10899         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
10900         defined and _GNU_SOURCE is not; this fixes a name space violation.
10901
10902         Rename the following macros to obey POSIX requirements.
10903         The old names are still visible as macros if _REGEX_SOURCE is defined.
10904         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
10905         RE_BACKSLASH_ESCAPE_IN_LISTS.
10906         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
10907         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
10908         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
10909         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
10910         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
10911         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
10912         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
10913         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
10914         (REG_INTERVALS): renamed from RE_INTERVALS.
10915         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
10916         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
10917         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
10918         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
10919         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
10920         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
10921         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
10922         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
10923         RE_UNMATCHED_RIGHT_PAREN_ORD.
10924         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
10925         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
10926         (REG_DEBUG): renamed from RE_DEBUG.
10927         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
10928         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
10929         unusual, since we can't clash with the POSIX REG_ICASE.
10930         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
10931         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
10932         (REG_NO_SUB): renamed from RE_NO_SUB.
10933         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
10934         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
10935         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
10936         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
10937         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
10938         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
10939         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
10940         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
10941         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
10942         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
10943         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
10944         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
10945         RE_SYNTAX_POSIX_MINIMAL_BASIC.
10946         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
10947         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
10948         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
10949         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
10950         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
10951         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
10952         (REG_FIXED): Renamed from REGS_FIXED.
10953         (REG_NREGS): Renamed from RE_NREGS.
10954
10955         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
10956         of other REG_* macros, since POSIX says the user is allowed to
10957         #undef these macros selectively.
10958
10959         (reg_errcode_t): Update comment stating what other tables need
10960         to be consistent.
10961
10962         Rename the following enum values to obey POSIX requirements.
10963         The old names are still visible as macros.
10964         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
10965         is not defined, since GNU is supposed to be a superset of POSIX as
10966         much as possible, and since we want reg_errcode_t to be a signed
10967         type for implementation consistency.
10968         (_REG_NOERROR): Renamed from REG_NOERROR.
10969         (_REG_NOMATCH): Renamed from REG_NOMATCH.
10970         (_REG_BADPAT): Renamed from REG_BADPAT.
10971         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
10972         (_REG_ECTYPE): Renamed from REG_ECTYPE.
10973         (_REG_EESCAPE): Renamed from REG_EESCAPE.
10974         (_REG_ESUBREG): Renamed from REG_ESUBREG.
10975         (_REG_EBRACK): Renamed from REG_EBRACK.
10976         (_REG_EPAREN): Renamed from REG_EPAREN.
10977         (_REG_EBRACE): Renamed from REG_EBRACE.
10978         (_REG_BADBR): Renamed from REG_BADBR.
10979         (_REG_ERANGE): Renamed from REG_ERANGE.
10980         (_REG_ESPACE): Renamed from REG_ESPACE.
10981         (_REG_BADRPT): Renamed from REG_BADRPT.
10982         (_REG_EEND): Renamed from REG_EEND.
10983         (_REG_ESIZE): Renamed from REG_ESIZE.
10984         (_REG_ERPAREN): Renamed from REG_ERPAREN.
10985         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
10986         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
10987         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
10988         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
10989
10990         (_REG_RE_NAME, _REG_RM_NAME): New macros.
10991         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
10992         changed.  But support the old name if the new one is not defined
10993         and if _REGEX_SOURCE.
10994
10995         Change the following member names in struct re_pattern_buffer.
10996         The old names are still supported if !_REGEX_SOURCE.
10997         The new names are always supported, regardless of _REGEX_SOURCE.
10998         (re_buffer): Renamed from buffer.
10999         (re_allocated): Renamed from allocated.
11000         (re_used): Renamed from used.
11001         (re_syntax): Renamed from syntax.
11002         (re_fastmap): Renamed from fastmap.
11003         (re_translate): Renamed from translate.
11004         (re_can_be_null): Renamed from can_be_null.
11005         (re_regs_allocated): Renamed from regs_allocated.
11006         (re_fastmap_accurate): Renamed from fastmap_accurate.
11007         (re_no_sub): Renamed from no_sub.
11008         (re_not_bol): Renamed from not_bol.
11009         (re_not_eol): Renamed from not_eol.
11010         (re_newline_anchor): Renamed from newline_anchor.
11011
11012         Change the following member names in struct re_registers.
11013         The old names are still supported if !_REGEX_SOURCE.
11014         The new names are always supported, regardless of _REGEX_SOURCE.
11015         (rm_num_regs): Renamed from num_regs.
11016         (rm_start): Renamed from start.
11017         (rm_end): Renamed from end.
11018
11019         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
11020         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
11021         Prepend __ to parameter names.
11022
11023         Undo yesterday's changes.
11024
11025 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11026
11027         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
11028         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
11029         lib/regex.c.
11030
11031 2005-08-24  Jim Meyering  <jim@meyering.net>
11032
11033         Sync from coreutils.
11034         * m4/fcntl-safer.m4: New file.
11035
11036         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
11037         and object files for this module.
11038
11039 2005-08-24  Jim Meyering  <jim@meyering.net>
11040
11041         Sync from coreutils.
11042         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
11043
11044 2005-08-24  Jim Meyering  <jim@meyering.net>
11045
11046         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
11047         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
11048
11049 2005-08-24  Jim Meyering  <jim@meyering.net>
11050
11051         * modules/fcntl-safer: New module.
11052         * modules/fts (Depends-on): Add fcntl-safer.
11053         * MODULES.html.sh (File descriptor based Input/Output):
11054         Add fcntl-safer.
11055
11056 2005-08-24  Bruno Haible  <bruno@clisp.org>
11057
11058         Support for unit test modules.
11059         * modules/README: Mention tests modules.
11060         * modules/TEMPLATE-TESTS: New file.
11061         * gnulib-tool: New options --extract-tests-module, --with-tests and
11062         --tests-base (unused for the moment).
11063         (testsbase, inctests): New variables.
11064         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
11065         (func_verify_module): Exclude TEMPLATE-TESTS.
11066         (func_verify_nontests_module, func_verify_tests_module): New functions.
11067         (func_get_dependencies): Add implicit dependency for tests modules.
11068         (func_get_tests_module): New function.
11069         (func_modules_transitive_closure): When --with-tests was specified,
11070         include the unit tests as well, unless explicitly avoided.
11071         (func_emit_lib_Makefile_am): Ignore the tests modules here.
11072         (func_emit_tests_Makefile_am): New function.
11073         (func_create_testdir): When --with-tests was specified, emit a
11074         tests/ directory.
11075         * MODULES.html.sh (Future developments): Update.
11076
11077 2005-08-24  Bruno Haible  <bruno@clisp.org>
11078
11079         * modules/tls-tests: New file.
11080         * tests/test-tls.c: New file, from GNU gettext.
11081
11082 2005-08-24  Bruno Haible  <bruno@clisp.org>
11083
11084         * modules/lock-tests: New file.
11085         * tests/test-lock.c: New file, from GNU gettext.
11086
11087 2005-08-24  Bruno Haible  <bruno@clisp.org>
11088
11089         * lib/lock.h: Add multiple inclusion guard.
11090         * lib/tls.h: Add multiple inclusion guard.
11091
11092 2005-08-24  Bruno Haible  <bruno@clisp.org>
11093
11094         * gnulib-tool: Add support for the --aux-dir option to
11095         --create-testdir, --create-megatestdir, --test, --megatest.
11096         (func_create_testdir, func_create_megatestdir): Optionally emit a
11097         AC_CONFIG_AUX_DIR directive.
11098         (create-testdir, create-megatestdir, test, megatest): Provide a
11099         default value for $auxdir.
11100
11101 2005-08-24  Bruno Haible  <bruno@clisp.org>
11102
11103         * gnulib-tool (import): Use compound statement instead of subshell
11104         where possible.
11105
11106 2005-08-24  Bruno Haible  <bruno@clisp.org>
11107
11108         * gnulib-tool (import): Change --aux-dir default to "build-aux".
11109
11110 2005-08-24  Bruno Haible  <bruno@clisp.org>
11111
11112         * gnulib-tool (func_version): Update.
11113
11114 2005-08-24  Bruno Haible  <bruno@clisp.org>
11115
11116         * gnulib-tool (func_import, func_create_testdir,
11117         func_create_megatestdir): Quote all autoconf macro arguments.
11118
11119 2005-08-24  Bruno Haible  <bruno@clisp.org>
11120
11121         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
11122         option --force, because --force causes the aclocal.m4 of each
11123         subdirectory to be newer than the corresponding config.h.in.
11124
11125 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11126
11127         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
11128         All contents moved to gl_REGEX.
11129         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
11130         assume that it does.
11131
11132 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11133
11134         * lib/regex.h (REG_NOSYS)
11135         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
11136         Define, since POSIX requires it as of 2001.
11137         (_REG_ENOSYS)
11138         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
11139         New private symbol, used to keep the enum signed in all cases.
11140         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
11141         Youngman in
11142         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
11143
11144         * lib/regex_internal.c (re_string_skip_chars, register_state):
11145         (calc_state_hash):
11146         Remove forward decls; no longer needed now that we use prototypes.
11147         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
11148         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
11149         (clean_state_log_if_needed): Likewise.
11150
11151 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11152
11153         * config/srclist.txt: Add glibc bugs 1231-1233.
11154
11155 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11156
11157         Fix problems reported by Sam Steingold in
11158         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
11159         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
11160         assumed that reg_errcode_t is a signed type, which is not
11161         necessarily true if _XOPEN_SOURCE is not defined.
11162         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
11163         since some compilers warn about it otherwise.
11164
11165 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11166
11167         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
11168         (init_word_char, create_initial_state, duplicate_node_closure):
11169         (fetch_token, peek_token_bracket, build_range_exp):
11170         (build_collating_symbol): Remove forward decls; no longer needed
11171         now that we use prototypes.
11172
11173         * lib/regcomp.c:
11174         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
11175         (re_compile_fastmap_iter, regcomp, regerror, regfree):
11176         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
11177         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
11178         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
11179         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
11180         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
11181         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
11182         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
11183         (build_range_exp, build_collating_symbol, parse_bracket_exp):
11184         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
11185         (build_charclass, build_charclass_op, fetch_number, create_tree):
11186         (create_token_tree, mark_opt_subexp, duplicate_tree):
11187         Use prototypes rather than old-style definitions.
11188
11189         * lib/regex_internal.c:
11190         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
11191         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
11192         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11193         (re_string_reconstruct, re_string_peek_byte_case):
11194         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
11195         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11196         (re_node_set_init_copy, re_node_set_add_intersect):
11197         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11198         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11199         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11200         (re_acquire_state, re_acquire_state_context, register_state):
11201         (create_ci_newstate, create_cd_newstate, free_state):
11202         Likewise.
11203         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
11204         re_search_2):
11205         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
11206         (re_search_internal, prune_impossible_nodes):
11207         (acquire_init_state_context, check_matching, static):
11208         (check_halt_node_context, check_halt_state_context, proceed_next_node):
11209         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
11210         (update_regs, sift_states_backward, build_sifted_states):
11211         (clean_state_log_if_needed, merge_state_array):
11212         (update_cur_sifted_state, add_epsilon_src_nodes):
11213         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
11214         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
11215         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
11216         (find_recover_state, check_subexp_matching_top, transit_state_mb):
11217         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
11218         (check_arrival, check_arrival_add_next_nodes):
11219         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11220         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11221         (check_node_accept_bytes, check_node_accept, extend_buffers):
11222         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
11223         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
11224         (sift_ctx_init):
11225         Likewise.
11226
11227         * lib/regex_internal.h:
11228         (re_string_allocate, re_string_construct, re_string_reconstruct):
11229         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
11230         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
11231         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
11232         (re_string_context_at, re_string_peek_byte_case):
11233         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
11234         is defined, since we now use prototypes always.
11235
11236         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
11237         C89 or better.  All uses removed.
11238
11239 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11240
11241         * config/srclist.txt: Add glibc bugs 1220-1227.
11242
11243 2005-08-20  Jim Meyering  <jim@meyering.net>
11244
11245         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
11246         of unused local, dfa.
11247
11248 2005-08-20  Bruno Haible  <bruno@clisp.org>
11249
11250         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
11251
11252 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11253
11254         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
11255         (re_node_set_insert_last, re_dfa_add_node):
11256         Rename local variables to avoid GCC shadowing warnings.
11257
11258 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11259
11260         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
11261         [defined lint]: Suppress bogus uninitialized-variable warnings.
11262
11263         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
11264         and let the caller return REG_ESPACE if out of space.  This
11265         removes an uninitialied-variable warning with GCC 4.0.1, and also
11266         avoids taking the address of a local variable.  All callers
11267         changed.
11268
11269 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11270
11271         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
11272         $LIBCSRC/posix/regexec.c.
11273         Add glibc bug 1217 for regcomp.c.
11274
11275 2005-08-19  Jim Meyering  <jim@meyering.net>
11276
11277         * lib/regexec.c (proceed_next_node): Redo local variables to
11278         avoid GCC shadowing warnings.
11279
11280 2005-08-18  Bruno Haible  <bruno@clisp.org>
11281
11282         * lib/strstr.c (strstr): Fix return value in multibyte case.
11283         * lib/strcasestr.c (strcasestr): Likewise.
11284
11285 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11286
11287         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
11288
11289 2005-08-17  Jim Meyering  <jim@meyering.net>
11290
11291         Make the %s format (seconds since the epoch) work for a negative
11292         number and when used with a zero-padded field width, e.g. %015s.
11293
11294         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
11295         label so that it precedes the code to set `digits'.  Otherwise,
11296         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
11297         print `00-22'.  Now, it prints `-0022', as it should.
11298
11299 2005-08-17  Bruno Haible  <bruno@clisp.org>
11300
11301         * modules/strstr (Files): Add m4/mbrtowc.m4.
11302         (Depends-on): Add mbuiter.
11303
11304 2005-08-17  Bruno Haible  <bruno@clisp.org>
11305
11306         * modules/strcasestr: New file.
11307         * MODULES.html.sh (String handling, based on ANSI C 89): Add
11308         strcasestr.
11309
11310 2005-08-17  Bruno Haible  <bruno@clisp.org>
11311
11312         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
11313
11314 2005-08-17  Bruno Haible  <bruno@clisp.org>
11315
11316         * modules/mbuiter: New file.
11317         * MODULES.html.sh (Extended multibyte and wide character utilities):
11318         Add mbuiter.
11319
11320 2005-08-17  Bruno Haible  <bruno@clisp.org>
11321
11322         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
11323         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
11324
11325 2005-08-17  Bruno Haible  <bruno@clisp.org>
11326
11327         * m4/strcasestr.m4: New file.
11328
11329 2005-08-17  Bruno Haible  <bruno@clisp.org>
11330
11331         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
11332         * lib/strstr.c: Completely rewritten, with multibyte locale support.
11333
11334 2005-08-17  Bruno Haible  <bruno@clisp.org>
11335
11336         * lib/strcasestr.h: New file.
11337         * lib/strcasestr.c: New file.
11338
11339 2005-08-17  Bruno Haible  <bruno@clisp.org>
11340
11341         * lib/strcasecmp.c: Use mbuiter.h.
11342
11343 2005-08-17  Bruno Haible  <bruno@clisp.org>
11344
11345         * lib/mbuiter.h: New file.
11346
11347 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11348
11349         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
11350         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
11351         and gl_GETOPT are both invoked via different paths (as happens
11352         with GNU tar CVS because it uses both argp and getopt), the former
11353         wins.
11354
11355 2005-08-16  Bruno Haible  <bruno@clisp.org>
11356
11357         * modules/tls: New file.
11358         * MODULES.html.sh (Multithreading): Add tls.
11359
11360 2005-08-16  Bruno Haible  <bruno@clisp.org>
11361
11362         * modules/strnlen1: New file.
11363         * MODULES.html.sh (String handling): Add strnlen1.
11364
11365 2005-08-16  Bruno Haible  <bruno@clisp.org>
11366
11367         * modules/strcase (Files): Add m4/mbrtowc.m4.
11368         (Depends-on): Add strnlen1, mbchar.
11369
11370 2005-08-16  Bruno Haible  <bruno@clisp.org>
11371
11372         * modules/mbiter: New file.
11373         * MODULES.html.sh (Extended multibyte and wide character utilities):
11374         Add mbiter.
11375
11376 2005-08-16  Bruno Haible  <bruno@clisp.org>
11377
11378         * modules/mbfile: New file.
11379         * MODULES.html.sh (Extended multibyte and wide character utilities):
11380         Add mbfile.
11381
11382 2005-08-16  Bruno Haible  <bruno@clisp.org>
11383
11384         * modules/mbchar: New file.
11385         * MODULES.html.sh (Extended multibyte and wide character utilities):
11386         New section.
11387
11388 2005-08-16  Bruno Haible  <bruno@clisp.org>
11389
11390         * m4/tls.m4: New file, from GNU gettext.
11391
11392 2005-08-16  Bruno Haible  <bruno@clisp.org>
11393
11394         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
11395         always.
11396         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
11397
11398 2005-08-16  Bruno Haible  <bruno@clisp.org>
11399
11400         * m4/mbiter.m4: New file.
11401
11402 2005-08-16  Bruno Haible  <bruno@clisp.org>
11403
11404         * m4/mbfile.m4: New file.
11405
11406 2005-08-16  Bruno Haible  <bruno@clisp.org>
11407
11408         * m4/mbchar.m4: New file.
11409
11410 2005-08-16  Bruno Haible  <bruno@clisp.org>
11411
11412         * lib/tls.h: New file, from GNU gettext.
11413         * lib/tls.c: New file, from GNU gettext.
11414
11415 2005-08-16  Bruno Haible  <bruno@clisp.org>
11416
11417         * lib/strnlen1.h: New file.
11418         * lib/strnlen1.c: New file.
11419
11420 2005-08-16  Bruno Haible  <bruno@clisp.org>
11421
11422         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
11423         (mbi_init): Update.
11424         (mbi_avail, mbi_advance): Let the iteration end before the terminating
11425         NUL byte, not after it.
11426
11427 2005-08-16  Bruno Haible  <bruno@clisp.org>
11428
11429         * lib/strcase.h (strcasecmp): Add note in comments.
11430         * lib/strncasecmp.c: Use code from strcasecmp.c.
11431         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
11432         (strcasecmp): Work correctly in multibyte locales.
11433
11434 2005-08-16  Bruno Haible  <bruno@clisp.org>
11435
11436         * lib/mbiter.h: New file.
11437
11438 2005-08-16  Bruno Haible  <bruno@clisp.org>
11439
11440         * lib/mbfile.h: New file.
11441
11442 2005-08-16  Bruno Haible  <bruno@clisp.org>
11443
11444         * lib/mbchar.h: New file.
11445         * lib/mbchar.c: New file.
11446
11447 2005-08-16  Bruno Haible  <bruno@clisp.org>
11448
11449         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
11450         the valid ones. Makes the comparison operations transitive:
11451         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
11452         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
11453
11454 2005-08-15  Simon Josefsson  <jas@extundo.com>
11455
11456         * modules/ssize_t (License): Change to 'unlimited'.
11457
11458         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
11459
11460 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11461
11462         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
11463         Add comments for each pending glibc patch.
11464
11465 2005-08-15  Bruno Haible  <bruno@clisp.org>
11466
11467         * lib/regex.h (__restrict_arr): Don't define to __restrict if
11468         __cplusplus is defined.
11469
11470 2005-08-14  Jim Meyering  <jim@meyering.net>
11471
11472         Sync from coreutils.
11473
11474         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
11475         Use the hash-table-based cycle-detection code not just when
11476         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
11477         Reported by James Youngman in
11478         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
11479         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
11480         FTS_TIGHT_CYCLE_CHECK.
11481         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
11482         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
11483         once again.
11484         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
11485         * lib/fts.c (fd_safer): Remove decl.
11486         Include fcntl--.h rather than unistd-safer.h
11487         (fts_safe_changedir): Don't call fd_safer; no longer needed
11488         now that we include fcntl--.h.
11489
11490 2005-08-12  Simon Josefsson  <jas@extundo.com>
11491
11492         * modules/getndelim2: Use ssize_t module.
11493         * modules/getnline: Likewise.
11494         * modules/safe-read: Likewise.
11495         * modules/xreadlink: Likewise.
11496
11497         * modules/ssize_t: New file.
11498
11499 2005-08-12  Simon Josefsson  <jas@extundo.com>
11500
11501         * m4/readline.m4: Look for termcap, curses or ncurses if required.
11502
11503 2005-08-12  Simon Josefsson  <jas@extundo.com>
11504
11505         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11506         ssize_t.
11507
11508 2005-08-12  Simon Josefsson  <jas@extundo.com>
11509
11510         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
11511         readline, getdelim and check_version.
11512         (Support for systems lacking ISO C 99: Sizes of integer types):
11513         Add size_max.
11514
11515 2005-08-12  Bruno Haible  <bruno@clisp.org>
11516
11517         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
11518
11519 2005-08-11  Simon Josefsson  <jas@extundo.com>
11520
11521         * modules/readline: New file.
11522
11523         * modules/strnlen (Files): Add strnlen.h.
11524
11525 2005-08-11  Simon Josefsson  <jas@extundo.com>
11526
11527         * m4/readline.m4: New file.
11528
11529 2005-08-11  Simon Josefsson  <jas@extundo.com>
11530
11531         * lib/readline.h, readline.c: New file.
11532
11533 2005-08-11  Simon Josefsson  <jas@extundo.com>
11534
11535         * doc/gnulib.texi (Initial import, Finishing touches): Mention
11536         gl_AVOID.
11537
11538 2005-08-11  Bruno Haible  <bruno@clisp.org>
11539
11540         * lib/strnlen.h (strnlen): Change parameter name to match comment.
11541
11542 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
11543
11544         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
11545
11546 2005-08-10  Simon Josefsson  <jas@extundo.com>
11547
11548         * tests/test-iconvme.c: New file.
11549
11550 2005-08-10  Simon Josefsson  <jas@extundo.com>
11551
11552         * m4/strnlen.m4: New file.
11553
11554         * m4/strndup.m4: Don't check for strnlen declaration, done in
11555         strnlen.m4.
11556
11557 2005-08-10  Simon Josefsson  <jas@extundo.com>
11558
11559         * lib/strndup.c: Use strnlen.h.
11560
11561         * lib/strnlen.h: New file.
11562
11563 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11564
11565         * README: Typos.
11566
11567 2005-08-02  Simon Josefsson  <jas@extundo.com>
11568
11569         * modules/readline: New file.
11570
11571 2005-08-02  Simon Josefsson  <jas@extundo.com>
11572
11573         * modules/getdelim: New file.
11574
11575         * modules/getline: Rewrite, don't use getndelim2.
11576
11577 2005-08-02  Simon Josefsson  <jas@extundo.com>
11578
11579         * m4/getline.m4: Separate out getdelim stuff into separate module.
11580
11581         * m4/getdelim.m4: New file.
11582
11583 2005-08-02  Simon Josefsson  <jas@extundo.com>
11584
11585         * lib/getline.h, getline.c: Rewrite.
11586
11587         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
11588
11589 2005-07-31  Bruno Haible  <bruno@clisp.org>
11590
11591         * lib/lock.h (gl_lock_initializer): New macro.
11592         (gl_lock_define_initialized): Use it.
11593         (gl_rwlock_initializer): New macro.
11594         (gl_rwlock_define_initialized): Use it.
11595         (gl_recursive_lock_initializer): New macro.
11596         (gl_recursive_lock_define_initialized): Use it.
11597
11598 2005-07-30  Karl Berry  <karl@gnu.org>
11599
11600         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
11601         Report from Ben Pfaff, regarding getopt.
11602
11603 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
11604
11605         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
11606         normal way.
11607         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
11608         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
11609         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
11610         (gl_GETOPT): Use the new macros.  Most of the implementation
11611         is moved to the new macros.  This is for programs like Emacs
11612         that don't want all the functionality of gl_GETOPT.
11613
11614 2005-07-26  Bruno Haible  <bruno@clisp.org>
11615
11616         * m4/lock.m4: Update from GNU gettext.
11617
11618 2005-07-26  Bruno Haible  <bruno@clisp.org>
11619
11620         * lib/lock.h: Update from GNU gettext.
11621         * lib/lock.c: Update from GNU gettext.
11622
11623 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
11624
11625         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
11626         obsolescent AC_TRY_RUN.  Include the default includes files, for
11627         'exit'.
11628
11629 2005-07-24  Bruno Haible  <bruno@clisp.org>
11630
11631         * modules/visibility: New file.
11632         * MODULES.html.sh (Misc): Add visibility.
11633
11634 2005-07-24  Bruno Haible  <bruno@clisp.org>
11635
11636         * m4/visibility.m4: New file.
11637
11638 2005-07-24  Bruno Haible  <bruno@clisp.org>
11639
11640         * doc/visibility.texi: New file.
11641
11642 2005-07-22  Bruno Haible  <bruno@clisp.org>
11643
11644         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
11645         $(ALLOCA_H), redundant through BUILT_SOURCES.
11646         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
11647         redundant through BUILT_SOURCES.
11648         * modules/byteswap (Makefile.am): Remove explicit dependency on
11649         $(BYTESWAP_H), redundant through BUILT_SOURCES.
11650         * modules/fnmatch (Makefile.am): Remove explicit dependency on
11651         $(FNMATCH_H), redundant through BUILT_SOURCES.
11652         * modules/getopt (Makefile.am): Remove explicit dependency on
11653         $(GETOPT_H), redundant through BUILT_SOURCES.
11654         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
11655         redundant through BUILT_SOURCES.
11656         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
11657         redundant through BUILT_SOURCES.
11658         * modules/stdbool (Makefile.am): Remove explicit dependency on
11659         $(STDBOOL_H), redundant through BUILT_SOURCES.
11660         * modules/stdint (Makefile.am): Remove explicit dependency on
11661         $(STDINT_H), redundant through BUILT_SOURCES.
11662         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
11663         Remove explicit dependency on $(SYSEXITS_H).
11664         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
11665
11666 2005-07-18  Simon Josefsson  <jas@extundo.com>
11667
11668         * lib/check-version.c (check_version): Accept identical versions too.
11669
11670 2005-07-18  Bruno Haible  <bruno@clisp.org>
11671
11672         * modules/lock: New file.
11673         * MODULES.html.sh (Multithreading): New section.
11674
11675 2005-07-18  Bruno Haible  <bruno@clisp.org>
11676
11677         * m4/lock.m4: New file, from GNU gettext.
11678
11679 2005-07-18  Bruno Haible  <bruno@clisp.org>
11680
11681         * lib/lock.h: New file, from GNU gettext.
11682         * lib/lock.c: New file, from GNU gettext.
11683
11684 2005-07-18  Bruno Haible  <bruno@clisp.org>
11685
11686         * lib/lock.h (gl_once_t): New type.
11687         (gl_once_define, gl_once): New macros.
11688         * lib/lock.c (fresh_once): New variable.
11689         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
11690         functions.
11691
11692 2005-07-16  Simon Josefsson  <jas@extundo.com>
11693
11694         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
11695         workaround, suggested by Bruno.
11696
11697 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11698
11699         * modules/xalloc (Depends-on): Add xalloc-die.
11700         * modules/xvasprintf (Depends-on): Add xalloc-die.
11701
11702 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11703
11704         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
11705         with a minor change.
11706
11707 2005-07-15  Bruno Haible  <bruno@clisp.org>
11708
11709         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
11710         When using lib/poll.c, define poll as rpl_poll.
11711
11712 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
11713
11714         * modules/argp (Depends-on): Remove unlocked-io.
11715
11716 2005-07-14  Derek Price  <derek@ximbiot.com>
11717
11718         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
11719         for glob symlink bug.
11720
11721 2005-07-14  Bruno Haible  <bruno@clisp.org>
11722
11723         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
11724         Instead, test for *_unlocked function declarations directly.
11725
11726 2005-07-11  Simon Josefsson  <jas@extundo.com>
11727
11728         * modules/size_max: New file.
11729
11730         * modules/xsize: Depend on size_max module for size_max.m4.
11731
11732 2005-07-11  Simon Josefsson  <jas@extundo.com>
11733
11734         * lib/size_max.h: New file.
11735
11736 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
11737
11738         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
11739         copyright symbol and the year.
11740         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
11741         (version_etc_va): Use parameterized copyright notice.
11742         Reword to conform to the current GNU coding standards.
11743
11744 2005-07-11  Karl Berry  <karl@gnu.org>
11745
11746         * doc/gnulib.texi (Quoting): new node.
11747         (Initial import): more info, from Patrice.
11748
11749 2005-07-11  Bruno Haible  <bruno@clisp.org>
11750
11751         * gnulib-tool (func_usage): Document option --avoid.
11752         (Command line options): Handle --avoid.
11753         (func_acceptable): New function.
11754         (func_modules_transitive_closure): Use it.
11755
11756 2005-07-11  Bruno Haible  <bruno@clisp.org>
11757
11758         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
11759         Reported by Jim Meyering.
11760
11761 2005-07-10  Bruno Haible  <bruno@clisp.org>
11762
11763         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
11764         Needed when size_t is smaller than 'unsigned int'.
11765         Reported by Paul Eggert.
11766
11767 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11768
11769         * modules/argp (Depends-on): Add unlocked-io
11770
11771 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11772
11773         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
11774         block of defines.
11775
11776 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11777
11778         * config/srclist.txt: Comment out regcomp.c, since we have a porting
11779         fix now.
11780
11781 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
11782         and Paul Eggert  <eggert@cs.ucla.edu>
11783
11784         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
11785         in wint_t, not wchar_t.  Remove now-unnecessary cast.
11786
11787 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11788
11789         * modules/regex (Files): Add lib/regex_internal.c,
11790         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
11791         (Depends-on): Add extensions.
11792         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
11793
11794 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11795
11796         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
11797         pathconf.
11798         * m4/same.m4 (gl_SAME): Likewise.
11799         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
11800
11801         * m4/regex.m4: Adjust to new libc regex implementation.
11802         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
11803         all the .c and .h parts of (the new) regex.
11804         Quote the m4 stuff better.
11805         Check for RE_ICASE bug of old gnulib.
11806         Check for REG_STARTEND of recent libc.
11807         Rename local variables from jm_* to gl_*.
11808         Quote operand of "test -f".
11809         Say "recent enough" version of libc, not "version 2".
11810         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
11811         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
11812         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
11813         Remove check for btowc, isascii.
11814         Require AM_LANGINFO_CODESET.
11815
11816 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11817
11818         * lib/regex.c, regex.h: Sync from libc.
11819         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
11820         * lib/regexec.c:
11821         New files, synced from libc, except that regex_internal.h
11822         currently has a small porting fix.
11823
11824 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11825
11826         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
11827         regex_internal.c, regexec.c.
11828         Add regex_internal.h too, but as a comment, since the libc version
11829         is currently broken in gnulib mode.
11830
11831 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11832
11833         Support programs like Emacs that use gnulib but not gettext.
11834         * MODULES.html.sh (Internationalization functions): Add gettext-h.
11835         * modules/gettext-h: New file.
11836         * modules/gettext (Files): Remove lib/gettext.h.
11837         (Depends-on): Add gettext-h.
11838         (Makefile.am): Remove lib_SOURCES.
11839         * modules/argmatch, modules/c-stack, modules/closeout:
11840         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
11841         * modules/execute, modules/file-type, modules/getaddrinfo:
11842         * modules/getopt, modules/human, modules/javacomp:
11843         * modules/javaexec, modules/mkdir-p, modules/obstack:
11844         * modules/openat, modules/pagealign_alloc, modules/pipe:
11845         * modules/quotearg, modules/regex, modules/rpmatch:
11846         * modules/unicodeio, modules/userspec, modules/version-etc:
11847         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
11848         * modules/xsetenv:
11849         Depend on gettext-h, not gettext.
11850
11851 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11852
11853         * gnulib-tool (func_import): Add support for 'public domain' license.
11854         * modules/alloca, modules/atexit, modules/memmove:
11855         Now public domain, not GPL.
11856         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
11857         * modules/realloc, modules/strerror, modules/strtod:
11858         Now LGPL, not GPL.
11859
11860 2005-07-05  Bruno Haible  <bruno@clisp.org>
11861
11862         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
11863         autoconf CVS. Needed for mingw.
11864
11865 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11866
11867         Remove the dependency of the strftime module on the tzset module.
11868         * modules/strftime (Depends-on): Remove dependency on tzset.
11869
11870 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11871
11872         Remove the dependency of the strftime module on the tzset module.
11873         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
11874         gl_FUNC_TZSET_CLOBBER.
11875
11876 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11877
11878         Remove the dependency of the strftime module on the tzset module.
11879         * lib/strftime.c (my_strftime)
11880         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
11881         Copy the input structure, to work around some of the bug with
11882         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
11883         Solaris releases, you should also use the tzset module, but we won't
11884         require it as a dependency any more since we don't want LGPLed code
11885         to depend on GPLed code.
11886
11887 2005-07-02  Jim Meyering  <jim@meyering.net>
11888
11889         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
11890         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
11891         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
11892         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
11893
11894 2005-07-02  Jim Meyering  <jim@meyering.net>
11895
11896         * lib/backupfile.c (backup_args): Change a `0' to NULL.
11897
11898 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11899
11900         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
11901         declares only 'struct timespec;' (!).
11902
11903 2005-07-01  Jim Meyering  <jim@meyering.net>
11904
11905         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
11906         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
11907         * lib/save-cwd.c, tempname.c:
11908         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
11909         and don't include <sys/file.h>).
11910
11911 2005-06-29  Jim Meyering  <jim@meyering.net>
11912
11913         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
11914         type name.  Use the variable name instead.
11915         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
11916         Likewise.
11917
11918 2005-06-28  Simon Josefsson  <jas@extundo.com>
11919
11920         * modules/check-version (Files): Add check-version.m4.
11921
11922 2005-06-28  Simon Josefsson  <jas@extundo.com>
11923
11924         * m4/check-version.m4: New file, suggested by Jim Meyering
11925         <jim@meyering.net>.
11926
11927 2005-06-28  Simon Josefsson  <jas@extundo.com>
11928
11929         * lib/check-version.h, lib/check-version.c: New files.
11930
11931 2005-06-28  Simon Josefsson  <jas@extundo.com>
11932
11933         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
11934         collision with global variable.  Better indentation.  Don't
11935         increment buffer pointer beyond buffer end.  Based on comments
11936         from Paul Eggert <eggert@cs.ucla.edu>.
11937
11938         * lib/base64.h: Indent.
11939
11940 2005-06-28  Simon Josefsson  <jas@extundo.com>
11941
11942         * doc/gnulib.texi (Library version handling): New section.
11943
11944 2005-06-28  Jim Meyering  <jim@meyering.net>
11945
11946         * check-module (find_included_lib_files): Hard-code another
11947         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
11948         but modules/fts-lgpl (correctly) does not list those files.
11949
11950         * modules/canonicalize (Files): Add lib/pathmax.h.
11951
11952 2005-06-25  Simon Josefsson  <jas@extundo.com>
11953
11954         * modules/check-version: New file.
11955
11956 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
11957
11958         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
11959         initializer of struct addrinfo, as an indication that we don't
11960         care how many members the structure has.
11961
11962 2005-06-24  Derek Price  <derek@ximbiot.com>
11963         and Bruno Haible  <bruno@clisp.org>
11964
11965         Remove stat module & update lstat.
11966         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
11967         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
11968         * m4/stat.m4: Remove this file.
11969
11970 2005-06-24  Derek Price  <derek@ximbiot.com>
11971         and Bruno Haible  <bruno@clisp.org>
11972
11973         Remove stat module & update lstat.
11974         * lib/stat.c: Remove this file...
11975         (slash_aware_lstat): ...moving this content and its support...
11976         * lib/lstat.c (rpl_lstat): ...into here.
11977         * lib/lstat.h: New file.
11978
11979 2005-06-24  Derek Price  <derek@ximbiot.com>
11980         and Bruno Haible  <bruno@clisp.org>
11981
11982         Remove stat module & update lstat.
11983         * config/srclist.txt (libc sources): Remove stat.
11984
11985 2005-06-24  Derek Price  <derek@ximbiot.com>
11986         and Bruno Haible  <bruno@clisp.org>
11987
11988         Remove stat module & update lstat.
11989         * MODULES.html.sh (stat): Remove.
11990         * MODULES.html: Regenerated.
11991         * modules/lstat (Description): Correct function name.
11992         (Files): Add "lstat.h".
11993         (Depends-on): Remove stat, add xalloc, stat-macros.
11994         * modules/stat: Remove this file.
11995         (Include): Add "lstat.h", remove <sys/stat.h>.
11996
11997 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
11998
11999         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
12000         (ranged_convert): Don't save conversion in a temporary struct.
12001         This causes a warning with GCC 4.0.0, and anyway in the typical
12002         case it's not worth the extra 100 bytes or so of code.
12003         (ranged_convert, __mktime_internal): When calling a function via a
12004         pointer P, use P () rather than (*P) (), as we now assume C89 or
12005         better.
12006
12007 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12008
12009         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
12010         "who -r" failed to give output.  Problem reported by Tim Waugh.
12011
12012         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
12013         (xcalloc): Use it to avoid needless tests.
12014         Problem reported by Jim Meyering.
12015
12016 2005-06-20  Derek Price  <derek@ximbiot.com>
12017
12018         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
12019         unnecessary for Autoconfs > 2.59c.
12020
12021 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12022
12023         * lib/argp.h (__option_is_short): Check upper limit of
12024         __key. Isprint() requires its argument to have the value
12025         of an unsigned char or EOF.
12026
12027 2005-06-16  Jim Meyering  <jim@meyering.net>
12028
12029         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
12030         when either N or S is zero.
12031
12032 2005-06-16  Derek Price  <derek@ximbiot.com>
12033
12034         * m4/bison.m4: Declare YACC & YFLAGS precious.
12035
12036 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
12037
12038         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
12039         multibyte string or pattern, fall back on unibyte matching.
12040         Problem reported by James Youngman.
12041
12042 2005-06-08  Bruno Haible  <bruno@clisp.org>
12043
12044         * modules/csharpcomp: New file.
12045         * MODULES.html.sh (C#): Add csharpcomp.
12046
12047 2005-06-08  Bruno Haible  <bruno@clisp.org>
12048
12049         * m4/csharpcomp.m4: New file, from GNU gettext.
12050
12051 2005-06-08  Bruno Haible  <bruno@clisp.org>
12052
12053         * lib/csharpcomp.h: New file, from GNU gettext.
12054         * lib/csharpcomp.c: New file, from GNU gettext.
12055         * lib/csharpcomp.sh.in: New file, from GNU gettext.
12056
12057 2005-06-08  Bruno Haible  <bruno@clisp.org>
12058
12059         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
12060         warning on mingw.
12061
12062 2005-06-07  Derek Price  <derek@ximbiot.com>
12063
12064         Sync from CVS.
12065         * lib/glob_.h: Indent nested #ifdef.
12066
12067 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12068
12069         Sync from coreutils.
12070         Use "file name" when talking about file names, instead of "filename"
12071         or "path", as per the GNU coding standards.
12072         * lib/mkdir-p.c: Renamed from makepath.c.
12073         (make_dir_parents): Renamed from make_path.  All callers changed.
12074         * lib/mkdir-p.h: Likewise.  All includers changed.
12075         * lib/filenamecat.c: Renamed from path-concat.c.
12076         (file_name_concat): Renamed from path_concat.  All callers changed.
12077         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
12078         * lib/filenamecat.h: Likewise.  All includers changed.
12079         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
12080         in comments or local variable names.
12081         * lib/basename.c: Likewise.
12082         * lib/canonicalize.c, canonicalize.h: Likewise.
12083         * lib/dirname.c, dirname.h: Likewise.
12084         * lib/euidaccess.c: Likewise.
12085         * lib/exclude.c: Likewise
12086         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
12087         * lib/fsusage.c, fsuage.h: Likewise.
12088         * lib/fts.c, fts_.h: Likewise.
12089         * lib/getcwd.c: Likewise.
12090         * lib/getloadavg.c: Likewise.
12091         * lib/mkstemp.c: Likewise.
12092         * lib/mountlist.c, mountlist.h: Likewise.
12093         * lib/openat.c, openat.h: Likewise.
12094         * lib/readlink-stub.c: Likewise.
12095         * lib/readutmp.c, readutmp.h: Likewise.
12096         * lib/rename.c: Likewise.
12097         * lib/rmdir.c: Likewise.
12098         * lib/same.c: Likewise.
12099         * lib/savedir.c: Likewise.
12100         * lib/stripslash.c: Likewise.
12101         * lib/tempname.c: Likewise.
12102         * lib/xreadlink.c: Likewise.
12103         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
12104         All uses changed.
12105         * lib/exclude.h: Likewise.
12106
12107         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
12108         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12109         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
12110         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12111         * lib/pathmax.h: Include <limits.h> unconditionally, since other
12112         files have been getting away with it for years (MORE/BSD 4.3
12113         is extinct now).
12114         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
12115         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12116
12117         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
12118         Define to 256, not 255, as per modern POSIX.
12119
12120 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12121
12122         Sync from coreutils.
12123         Use "file name" when talking about file names, instead of "filename"
12124         or "path", as per the GNU coding standards.
12125         * MODULES.html.sh: mkdir-p renamed from makepath.
12126         filenamecat renamed from path-concat.
12127         * modules/filenamecat: Renamed from modules/path-concat.
12128         (Files): filenamecat.h and filenamecat.c renamed from
12129         path-concat.h and path-concat.c.
12130         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
12131         (Include): filenamecat.h, not path-concat.h.
12132         * modules/mkdir-p: Renamed from modules/makepath.
12133         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
12134         makepath.c.
12135         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
12136         (Include): mkdir-p.h, not makepath.h.
12137
12138 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12139
12140         Sync from coreutils.
12141         * m4/mkdir-p.m4: Renamed from makepath.m4.
12142         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
12143         Rename files from makepath.c to mkdir-p.c, and from
12144         makepath.h to mkdir-p.h.
12145         * m4/filenamecat.m4: Renamed from path-concat.m4.
12146         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
12147         Rename files from path-concat.c to filenamecat.c,
12148         and from path-concat.h to filenamecat.h.
12149         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
12150         "file name" in local variables or comments.
12151         * m4/rename.m4: Likewise.
12152
12153 2005-06-01  Bruno Haible  <bruno@clisp.org>
12154
12155         * modules/csharpexec: New file.
12156         * MODULES.html.sh (C#): New section.
12157
12158 2005-06-01  Bruno Haible  <bruno@clisp.org>
12159
12160         * m4/csharp.m4: New file, from GNU gettext.
12161         * m4/csharpexec.m4: New file, from GNU gettext.
12162
12163 2005-06-01  Bruno Haible  <bruno@clisp.org>
12164
12165         * lib/csharpexec.h: New file, from GNU gettext.
12166         * lib/csharpexec.c: New file, from GNU gettext.
12167         * lib/csharpexec.sh.in: New file, from GNU gettext.
12168
12169 2005-05-31  Derek Price  <derek@ximbiot.com>
12170             Paul Eggert  <eggert@cs.ucla.edu>
12171
12172         Sync from cvs.
12173         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12174
12175 2005-05-31  Derek Price  <derek@ximbiot.com>
12176             Paul Eggert  <eggert@cs.ucla.edu>
12177
12178         Sync from cvs.
12179         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12180
12181 2005-05-29  Derek Price  <derek@ximbiot.com>
12182
12183         * config/srclist.txt (glob_.h, glob.c): Add these files.
12184
12185 2005-05-29  Derek Price  <derek@ximbiot.com>
12186
12187         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
12188         * modules/glob: New file.
12189         * modules/getlogin_r: Add link to POSIX spec in description.
12190
12191 2005-05-29  Derek Price  <derek@ximbiot.com>
12192             Paul Eggert  <eggert@cs.ucla.edu>
12193
12194         * m4/glob.m4: New file.
12195
12196 2005-05-29  Derek Price  <derek@ximbiot.com>
12197             Paul Eggert  <eggert@cs.ucla.edu>
12198
12199         * lib/glob_.h, lib/glob.c: New files.
12200
12201 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12202
12203         * modules/fts (Files): Remove m4/inttypes-pri.m4.
12204         * modules/fts-lgpl (Depends-on): Remove gettext.
12205
12206 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12207
12208         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
12209         and don't require gt_INTTYPES_PRI.
12210
12211 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12212
12213         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
12214
12215         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
12216         the configuration hassle isn't worth it.
12217         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
12218         (LONGEST_MODIFIER, PRIuMAX): Remove.
12219
12220 2005-05-27  Bruno Haible  <bruno@clisp.org>
12221
12222         * lib/getlogin_r.h: Remove second include of <stddef.h>.
12223
12224 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
12225
12226         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
12227         _POSIX_PTHREAD_SEMANTICS for Solaris.
12228
12229 2005-05-25  Derek Price  <derek@ximbiot.com>
12230
12231         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
12232
12233 2005-05-25  Derek Price  <derek@ximbiot.com>
12234             Paul Eggert  <eggert@cs.ucla.edu>
12235
12236         * modules/getlogin_r, m4/getlogin_r.m4: New files.
12237         * lib/getlogin_r.c, getlogin_r.h: New files.
12238
12239 2005-05-25  Bruno Haible  <bruno@clisp.org>
12240             Derek Price  <derek@ximbiot.com>
12241
12242         * lib/getlogin_r.h: Simplify API documentation.
12243
12244 2005-05-23  Derek Price  <derek@ximbiot.com>
12245
12246         * modules/minmax (Files): Add m4/minmax.m4.
12247         (configure.ac): Add gl_MINMAX.
12248
12249 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
12250
12251         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
12252         so that unistd-safer.h (GPL'ed code) need not be included.
12253
12254 2005-05-22  Bruno Haible  <bruno@clisp.org>
12255
12256         * m4/minmax.m4: New file.
12257         Based on a patch by Derek Price <derek@ximbiot.com>.
12258
12259 2005-05-22  Bruno Haible  <bruno@clisp.org>
12260
12261         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
12262         (INT64_MIN): Fix definition.
12263         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
12264
12265         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
12266         NEED_SIGNED_INT_TYPES.
12267
12268         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
12269         HAVE_SYSTEM_INTTYPES.
12270
12271 2005-05-22  Bruno Haible  <bruno@clisp.org>
12272
12273         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
12274         Also include <sys/param.h> if it defines MIN, MAX.
12275         Based on a patch by Derek Price <derek@ximbiot.com>.
12276
12277 2005-05-21  Jim Meyering  <jim@meyering.net>
12278
12279         * modules/fts (Files): Add m4/inttypes-pri.m4.
12280         (Depends-on): Add lstat and remove gettext.  Alphabetize.
12281
12282 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12283
12284         New fts module.
12285         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
12286         (setup_dir, free_dir): New functions.
12287         (enter_dir, leave_dir): Define trivial
12288         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
12289         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
12290         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
12291         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
12292         Move to fts-cycle.c.
12293         (fts_open): Use setup_dir.
12294         (fts_close): Use free_dir.
12295         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
12296         This adds a label and some gotos, but the alternatives were messier.
12297         Check for memory allocation failure when entering a dir.
12298         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
12299         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
12300         (FTS): New member fts_cycle, that is a union that contains the
12301         old active_dir_ht and cycle_state.  All uses changed to mention
12302         fts_cycle.ht and fts_cycle.state.
12303         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
12304         fts.c, with the following changes:
12305         (setup_dir, free_dir): New functions.
12306         (enter_dir): Now returns bool.  Return true if successful, false
12307         if memory exhausted.  All callers changed.
12308         Do not bother partly cleaning up on
12309         memory allocation failure; that is free_dir's job.
12310         However, free ad if hash_insert fails, to avoid memory leak.
12311         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
12312         fts->fts_options to see which union member to use.
12313
12314 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12315
12316         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
12317         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
12318
12319 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12320
12321         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
12322
12323 2005-05-20  Jim Meyering  <jim@meyering.net>
12324
12325         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
12326         Now a macro, to pacify GCC.
12327
12328 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12329
12330         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
12331         of -1.
12332
12333 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12334
12335         * lib/chown.c (rpl_chown): Return -1 on failure.
12336
12337 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12338
12339         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
12340         Don't check for stddef.h.
12341         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
12342         don't use its results.
12343         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
12344         since we include them unconditionally.  Don't require
12345         AM_STDBOOL_H, since stdbool is a prerequisite.
12346         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
12347         since we assume C89 or better.
12348         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
12349         as we don't use their results.
12350         Don't check for fchdir, memmove, memset, strrchr, as we use
12351         them unconditionally.
12352         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
12353         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
12354
12355 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12356
12357         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
12358         Include <stddef.h> unconditionally, since we assume C89 now.
12359         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
12360         * lib/fts.c: Include fts_.h first, to check interface.
12361         Do not include intprops.h; no longer needed.
12362         Include cycle-check.h and hash.h, since fts_.h no longer does.
12363         Remove unnecessary casts of closedir to void.
12364         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
12365         decide whether to decrement nlinks.
12366         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
12367         (FTS): Use struct hash_table * instead of Hash_table, so that
12368         we no longer need to include hash.h here.
12369
12370 2005-05-18  Jim Meyering  <jim@meyering.net>
12371
12372         * modules/dirfd (License): Change to LGPL.  Most of the code
12373         is already in the public domain.
12374
12375 2005-05-18  Jim Meyering  <jim@meyering.net>
12376
12377         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
12378         Reported by Yoann Vandoorselaere.
12379
12380 2005-05-17  Jim Meyering  <jim@meyering.net>
12381
12382         * m4/fts.m4: New file, from coreutils.
12383
12384 2005-05-17  Jim Meyering  <jim@meyering.net>
12385
12386         * lib/fts.c, lib/fts_.h: New files, from coreutils.
12387
12388 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12389
12390         Sync from coreutils.
12391         * m4/unlinkdir.m4: New file.
12392
12393 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12394
12395         Sync from coreutils.
12396         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
12397         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
12398         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
12399         White space changes only.
12400         * lib/makepath.c (make_path): Port to hosts where leading "//" is
12401         special.
12402         * lib/yesno.c: Include getline.h, not ctype.h.
12403         (yesno): Don't remove leading white space; POSIX doesn't allow it.
12404         Use getline to remove arbitrary restriction on response length.
12405
12406 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12407
12408         * config/srclist-update: Spell out "Street" in FSF postal
12409         mail address; this is the style the FSF seems to prefer.
12410
12411         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
12412         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
12413         this updates FSF postal mail address.
12414
12415         Sync from coreutils.
12416         * modules/unlinkdir: New file.
12417         * modules/yesno (Depends-on): Add getline.
12418         * MODULES.html.sh (File system functions): Add unlinkdir.
12419
12420 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12421
12422         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
12423         lib/strsep.h:
12424         Change the initial comment to refer to GPL, not LGPL.
12425         gnulib-tool will change it to LGPL as needed.
12426
12427         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
12428         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
12429         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
12430         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
12431         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
12432         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
12433         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
12434         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
12435         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
12436         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
12437         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
12438         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
12439         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
12440         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
12441         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
12442         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
12443         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
12444         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
12445         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
12446         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
12447         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
12448         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
12449         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
12450         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
12451         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
12452         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
12453         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
12454         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
12455         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
12456         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
12457         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
12458         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
12459         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
12460         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
12461         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
12462         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
12463         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
12464         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
12465         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
12466         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
12467         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
12468         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
12469         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
12470         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
12471         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
12472         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
12473         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
12474         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
12475         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
12476         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
12477         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12478         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
12479         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
12480         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
12481         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
12482         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
12483         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
12484         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
12485         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
12486         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
12487         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
12488         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
12489         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
12490         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
12491         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
12492         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
12493         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
12494         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
12495         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
12496         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
12497         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
12498         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
12499         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
12500         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
12501         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
12502         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
12503         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
12504         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
12505         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
12506         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
12507         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
12508         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
12509         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
12510         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
12511         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
12512         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
12513         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
12514         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
12515         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
12516         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
12517         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
12518         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
12519         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
12520         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
12521         lib/yesno.c, lib/yesno.h:
12522         Update FSF postal mail address.
12523
12524 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12525
12526         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
12527         tests/test-memmem.c, tests/test-stpncpy.c:
12528         Update FSF postal mail address.
12529
12530 2005-05-13  Bruno Haible  <bruno@clisp.org>
12531
12532         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
12533         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
12534         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
12535         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
12536         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
12537         Add support for 64-bit integers in the MSVC compiler.
12538
12539 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12540
12541         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
12542
12543 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
12544
12545         * gnulib-tool (func_import): Sort and uniquify recommended includes.
12546
12547 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
12548
12549         * doc/getdate.texi (General date syntax): Don't say that date
12550         date --iso-8601=ns generates acceptable dates; it doesn't yet.
12551         Problem reported by Nic Ferrier.
12552
12553 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12554
12555         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
12556         specified in ai_socktype. Fix invalid ai_protocol
12557         check. ai_protocol is usually set to 0 or depending on
12558         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
12559         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
12560         ai_socktype / ai_protocol in the returned addrinfo structure.
12561
12562 2005-05-10  Simon Josefsson  <jas@extundo.com>
12563
12564         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
12565         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12566
12567 2005-05-10  Karl Berry  <karl@gnu.org>
12568
12569         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
12570         (from http://www.gnu.org/licenses).
12571         * doc/COPYING.LIB: also rename to COPYING.LESSER.
12572         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
12573         fdl.texi suffices.
12574
12575 2005-05-10  Karl Berry  <karl@gnu.org>
12576
12577         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
12578         (COPYING.DOC): remove.
12579
12580         * config/srclist-update: new FSF address.
12581
12582 2005-05-10  Derek Price  <derek@ximbiot.com>
12583
12584         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
12585         possible.
12586
12587 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12588             Bruno Haible  <bruno@clisp.org>
12589
12590         * modules/inet_ntop: New file.
12591         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12592         inet_ntop.
12593
12594 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12595             Bruno Haible  <bruno@clisp.org>
12596
12597         * m4/inet_ntop.m4: New file.
12598
12599 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12600             Bruno Haible  <bruno@clisp.org>
12601
12602         * lib/inet_ntop.h: New file.
12603         * lib/inet_ntop.c: New file, from glibc with modifications.
12604
12605 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
12606
12607         * modules/time_r (License): Change to LGPL.
12608         * modules/extensions (License): Change to LGPL.  Actually,
12609         the license is more permissive than that, but currently gnulib-tool
12610         doesn't know how to handle more-permissive licenses.
12611
12612         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
12613         Problem reported by Dave Love.
12614
12615 2005-05-08  Jim Meyering  <jim@meyering.net>
12616
12617         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
12618         blank.
12619
12620 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12621
12622         * modules/argmatch (Depends-on): Add stdbool.
12623         * modules/backupfile (Depends-on): Likewise.
12624         * modules/chdir-long (Depends-on): Likewise.
12625         * modules/closeout (Depends-on): Likewise.
12626         * modules/cycle-check (Depends-on): Likewise.
12627         * modules/dirname (Depends-on): Likewise.
12628         * modules/fnmatch (Depends-on): Likewise.
12629         * modules/fsusage (Depends-on): Likewise.
12630         * modules/fwriteerror (Depends-on): Likewise.
12631         * modules/getcwd (Depends-on): Likewise.
12632         * modules/getloadavg (Depends-on): Likewise.
12633         * modules/hard-locale (Depends-on): Likewise.
12634         * modules/makepath (Depends-on): Likewise.
12635         * modules/mountlist (Depends-on): Likewise.
12636         * modules/nanosleep (Depends-on): Likewise.
12637         * modules/posixtm (Depends-on): Likewise.
12638         * modules/quotearg (Depends-on): Likewise.
12639         * modules/readtokens (Depends-on): Likewise.
12640         * modules/readtokens0 (Depends-on): Likewise.
12641         * modules/readutmp (Depends-on): Likewise.
12642         * modules/save-cwd (Depends-on): Likewise.
12643         * modules/strftime (Depends-on): Likewise.
12644         * modules/userspec (Depends-on): Likewise.
12645         * modules/utimecmp (Depends-on): Likewise.
12646         * modules/xgetcwd (Depends-on): Likewise.
12647         * modules/xnanosleep (Depends-on): Likewise.
12648         * modules/xstrtod (Depends-on): Likewise.
12649         * modules/yesno (Depends-on): Likewise.
12650
12651 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
12652
12653         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
12654         needless checks.
12655
12656 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12657
12658         Merge from coreutils.  Among other things,
12659         add bulletproofing for cases where stdin, stdout, or stderr are closed.
12660         * lib/fd-safer.c: New file.
12661         * lib/fcntl-safer.h, open-safer.c: Remove.
12662         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
12663         * lib/dup-safer.c: Include unistd-safer.h first.
12664         Don't include errno.h.
12665         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
12666         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
12667         * lib/file-type.c: Rely on file-type.h change.
12668         * lib/getloadavg.c: Include unistd-safer.h.
12669         (getloadavg): Use safer open.
12670         * lib/getusershell.c: Include "stdio-safer.h".
12671         (getusershell): Use safer fopen.
12672         * lib/long-options.c (long_options): Use NULL rather than 0.
12673         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
12674         'free'.
12675         * lib/modechange.c: Likewise.
12676         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
12677         (MODE_DONE): New constant.
12678         (struct mode_change): Remove 'next' member.
12679         (make_node_op_equals): New function; like the old one of the
12680         same name, except it allocates an array.
12681         (mode_compile, mode_create_from_ref): Use it.
12682         (mode_compile): Allocate result as an array, not a linked list.
12683         Parse octal string ourself, so that we catch mistakes like "+0".
12684         (mode_adjust): Arg is an array, not a linked list.
12685         * lib/modechange.c: Include stat-macros.h, xalloc.h.
12686         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
12687         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
12688         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
12689         Remove.  This is now stat-macros.h's job.
12690         (talloc): Remove.  All callers replaced by xalloc, so that
12691         our invokers don't have to worry about reporting memory failures.
12692         (make_node_op_equals): Remove.
12693         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12694         New constants.
12695         (struct mode_change): Moved here from modechange.h.
12696         (mode_append_entry): Remove.
12697         (mode_compile): Remove MASKED_OPS arg, since it encouraged
12698         apps to have incorrect behavior.  Use simpler algorithm for head
12699         and tail.  Don't futz with umask; that's now the job of mode_adjust.
12700         Detect more invalid usages rather than having somewhat-random behavior.
12701         Don't insert an "a=" action, as that leads to incorrect behavior.
12702         (mode_compile, mode_create_from_ref): Return NULL on error instead
12703         of an enum, since now there's only one way to have an error.  All
12704         callers changed.
12705         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
12706         at the correct time.  Simplify calculation of "+u" and its ilk.
12707         Don't mishandle "+X".
12708         (mode_free): Remove "register" and localize decls.
12709         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12710         (struct mode_change): Move to modechange.c; callers don't
12711         need to see this stuff.
12712         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
12713         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
12714         (mode_change, mode_adjust): Reflect the new signatures noted above.
12715         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
12716         that might redefine system include files.
12717         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
12718         (my_usleep): Use NULL rather than (void *) 0.
12719         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
12720         Use siginterrupt to specify that system calls should be interrupted.
12721         (rpl_nanosleep): Move initialization of suspended closer to call of
12722         my_usleep.
12723         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
12724         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
12725         (desirable_utmp_entry): New function.
12726         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
12727         using x2nrealloc, to simplify logic.
12728         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
12729         size calculation.  Do not assume utmp file is a regular file.
12730         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
12731         (READ_UTMP_CHECK_PIDS): New constant.
12732         * lib/save-cwd.c: Include unistd-safer.h.
12733         (save_cwd): Use fd_safer.
12734         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
12735         [!_LIBC] Include "stat-macros.h" instead.
12736         * lib/unistd-safer.h (fd_safer): New decl.
12737
12738 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12739
12740         * modules/getloadavg (Depends-on): Add unistd-safer.
12741         * modules/getusershell (Depends-on): Add stdio-safer.
12742         * modules/lstat (Depends-on): Remove xalloc.
12743         * modules/mkstemp (Depends-on): Add stat-macros.
12744         * modules/modechange (Depends-on): Remove xstrtol.
12745         Add stat-macros, xalloc.
12746         * modules/save-cwd (Depends-on): Add unistd-safer.
12747         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
12748         * modules/unistd-safer (Files): Add lib/fd-safer.c
12749         (Makefile.am): Remove lib_SOURCES.
12750
12751         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
12752         Remove fcntl-safer; unistd-safer supersedes it.
12753
12754 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12755
12756         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
12757         AC_HEADER_STAT.
12758         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
12759         (gl_PREREQ_CHOWN): Remove.
12760         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
12761         it.  Don't require AC_HEADER_STAT.
12762         (gl_PREREQ_LSTAT): Remove.
12763         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
12764         Don't require AC_HEADER_STAT.
12765         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
12766         (gl_PREREQ_RMDIR): Remove.
12767         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
12768         mention stat-macros.h or AC_HEADER_STAT, since we'll make
12769         the stat-macros module a prerequisite.
12770         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
12771         * m4/filemode.m4 (gl_FILEMODE): Likewise.
12772         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
12773         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
12774         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
12775         variable names.
12776         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
12777         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
12778         variable prefixes.
12779         * m4/fcntl-safer.m4: Remove.
12780         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
12781         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
12782         Invoke gl_PREREQ_FD_SAFER.
12783         (gl_PREREQ_FD_SAFER): New macro.
12784         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
12785         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
12786         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
12787         Remove duplicate call to AC_LIBOBJ(readutmp).
12788         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
12789
12790         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
12791         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
12792
12793 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12794
12795         * MODULES.html.sh (Misc): Add byteswap.
12796
12797 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12798
12799         * modules/getcwd (Depends-on): Add extensions.
12800         * modules/openat (Depends-on): Likewise.
12801
12802 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12803
12804         * modules/byteswap: New file.
12805
12806 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12807
12808         * m4/byteswap.m4: New file.
12809
12810 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12811
12812         * lib/byteswap_.h: New file.
12813
12814 2005-04-25  Karl Berry  <karl@gnu.org>
12815
12816         * m4/gettext.m4: Update from GNU gettext 0.14.4.
12817
12818 2005-04-25  Albert Chin  <china@thewrittenword.com>
12819
12820         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
12821         Toolkit C bug.
12822
12823 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
12824
12825         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
12826         (func_ln_if_changed) Remove forcibly for no error message
12827         in case file does not exist.
12828
12829 2005-04-19  Simon Josefsson  <jas@extundo.com>
12830
12831         * gnulib-tool (Options): Make --symlink mean --symbolic.
12832
12833 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
12834
12835         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
12836
12837 2005-04-16  Simon Josefsson  <jas@extundo.com>
12838
12839         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
12840
12841 2005-04-15  Simon Josefsson  <jas@extundo.com>
12842
12843         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
12844
12845 2005-04-15  Simon Josefsson  <jas@extundo.com>
12846
12847         * gnulib-tool: Rename --symlink to --symbolic.
12848
12849 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
12850
12851         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
12852         symbolic links to files instead of copying/moving.  Add --aux-dir,
12853         specifying directory relative --dir where auxiliary build tools
12854         are placed.
12855
12856 2005-04-14  Bruno Haible  <bruno@clisp.org>
12857
12858         * modules/allocsa (License): Change to LGPL.
12859         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
12860
12861 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12862
12863         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
12864         that "UTC +1 second" continues to work.  Problem reported
12865         by Dmitry V. Levin.
12866         (relunit_snumber): New rule.
12867         (relunit): Use it.
12868
12869 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
12870
12871         * lib/getdate.y (universal_time_zone_table): New constant.
12872         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
12873         universal_time_zone_table.
12874         (lookup_zone): Prefer universal_time_zone_table to
12875         local_time_zone_table, so that "GMT" time stamps are allowed in
12876         London during the summer.  Problem reported by Ian Abbott.
12877
12878 2005-04-12  Jim Meyering  <jim@meyering.net>
12879
12880         * lib/human.c (humblock): Set *options even when returning due to
12881         xstrtoumax conversion failure.  Thanks to a used-uninitialized
12882         warning from gcc-4.
12883
12884 2005-04-09  Jim Meyering  <jim@meyering.net>
12885
12886         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
12887         -Wuninitialized: initialize tm0.tm_year.
12888
12889 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
12890
12891         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
12892         count, since there's no maximum.  All uses changed.
12893         Add member dsts_seen.
12894         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
12895         not being INT_MAX.
12896         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
12897         Use pc_rels_seen to decide whther a date is absolute.
12898
12899         * lib/getdate.y (number): Don't overwrite year.
12900         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
12901         check.
12902
12903 2005-04-02  Simon Josefsson  <jas@extundo.com>
12904
12905         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
12906         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
12907
12908 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
12909
12910         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
12911         where no absolute path name can be longer than PATH_MAX.
12912
12913 2005-03-27  Jim Meyering  <jim@meyering.net>
12914
12915         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
12916
12917 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
12918
12919         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
12920         "one's complement" -> "ones' complement" in comment, as per Knuth.
12921         "value of type" -> "type or expression" in comment.
12922         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
12923
12924 2005-03-26  Jim Meyering  <jim@meyering.net>
12925
12926         Comment nits.
12927         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
12928         Correct typos: s/or/of/.
12929
12930 2005-03-26  Jim Meyering  <jim@meyering.net>
12931
12932         * modules/check-include-files: Move to ../ and rename to...
12933         * check-module: ...this.
12934
12935 2005-03-25  Jim Meyering  <jim@meyering.net>
12936
12937         * modules/xvasprintf (Files): Add xalloc.h.
12938
12939 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
12940
12941         * modules/gettext (Files): config/config.rpath ->
12942         build-aux/config.rpath
12943         * modules/iconv (Files): Likewise.
12944         Problem reported by Oskar Liljeblad.
12945
12946 2005-03-23  Jim Meyering  <jim@meyering.net>
12947
12948         * modules/check-include-files: New script to check for
12949         missing dependencies, multiple includes, etc.
12950
12951         * modules/c-strtold (Depends-on): Add xalloc.
12952         * modules/c-strtod (Depends-on): Add xalloc.
12953         * modules/hash (Depends-on): Add xalloc.
12954         (Files): Remove lib/xalloc.h.
12955
12956         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
12957         * modules/userspec (Files): Add lib/inttostr.h.
12958
12959 2005-03-23  Jim Meyering  <jim@meyering.net>
12960
12961         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
12962
12963 2005-03-22  Jim Meyering  <jim@meyering.net>
12964
12965         * modules/stat-macros: New module.
12966         * modules/canonicalize, modules/euidaccess, modules/file-type,
12967         * modules/filemode, modules/lchown, modules/makepath,
12968         * modules/rmdir, modules/stat: Depend on new stat-macros module
12969         rather than listing lib/stat-macros.h manually.
12970         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
12971
12972 2005-03-22  Jim Meyering  <jim@meyering.net>
12973
12974         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
12975
12976 2005-03-22  Bruno Haible  <bruno@clisp.org>
12977
12978         * config/srclist.txt: Replace target directory 'config' with
12979         'build-aux'.
12980         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
12981         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
12982         ../build-aux/.
12983
12984 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
12985
12986         * modules/chdir-long (Depends-on): Add mempcpy.
12987
12988         * modules/acl, modules/backupfile, modules/c-strtod,
12989         modules/c-strtold, modules/canon-host, modules/canonicalize,
12990         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
12991         modules/exclude, modules/exitfail, modules/file-type,
12992         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
12993         modules/getdate, modules/getline, modules/getpagesize,
12994         modules/getpass, modules/getugroups, modules/group-member,
12995         modules/hard-locale, modules/hash, modules/human, modules/idcache,
12996         modules/inttostr, modules/long-options, modules/makepath,
12997         modules/md5, modules/memcasecmp, modules/memcoll,
12998         modules/modechange, modules/mountlist, modules/path-concat,
12999         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
13000         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
13001         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
13002         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
13003         modules/strftime, modules/strndup, modules/strverscmp,
13004         modules/timespec, modules/unlocked-io, modules/userspec,
13005         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
13006         modules/yesno:
13007         Remove lib_SOURCES line from Makefile.am section, as this is now
13008         done automatically by the corresponding Autoconf macro.
13009
13010 2005-03-21  Jim Meyering  <jim@meyering.net>
13011
13012         Changes imported from coreutils.
13013
13014         * lib/cycle-check.c: Don't include xalloc.h.
13015
13016         * lib/path-concat.c: Don't include assert.h.
13017         (path_concat): Remove assertion that would have triggered
13018         for ABASE starting with more than one slash.
13019         Reported by Andreas Schwab.
13020
13021         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
13022         properly when ABASE is an absolute file name.
13023         Correct the description of this function.
13024         Include <assert.h>.
13025         Add an assertion and a test driver.
13026         This fixes a bug introduced on 2004-07-02.
13027         Andreas Schwab reported the resulting failure of cp --parents:
13028         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
13029
13030 2005-03-21  Jim Meyering  <jim@meyering.net>
13031
13032         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
13033         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
13034
13035 2005-03-21  Jim Meyering  <jim@meyering.net>
13036         and  Paul Eggert  <eggert@cs.ucla.edu>
13037
13038         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
13039         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
13040         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
13041         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
13042         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
13043         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
13044         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
13045         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
13046         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
13047         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
13048         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
13049         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
13050         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
13051         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
13052         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
13053         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
13054         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
13055         for these modules.
13056
13057 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
13058
13059         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
13060         (which shouldn't happen), generate nothing instead of returning 0
13061         immediately, so that nstrftime (NULL, ...) doesn't return 0.
13062
13063 2005-03-16  Bruno Haible  <bruno@clisp.org>
13064
13065         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
13066         HAVE_LONGLONG_64BIT.
13067
13068 2005-03-16  Bruno Haible  <bruno@clisp.org>
13069
13070         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
13071         HAVE_LONGLONG_64BIT.
13072
13073 2005-03-16  Bruno Haible  <bruno@clisp.org>
13074
13075         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
13076         HAVE_LONGLONG_64BIT.
13077
13078 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13079
13080         * lib/strftime.c (my_strftime): Prepend space to format so that we can
13081         reliably distinguish strftime failure from empty output on POSIX
13082         hosts.
13083
13084 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13085
13086         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
13087         (iconv_string): Don't guess a size-zero buffer, as that might cause
13088         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
13089         result would be 'too large', where 'too large' is (heuristically)
13090         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
13091         overflow concerns.  This will prevent some unwanted malloc failures
13092         when the inputs are very large.
13093
13094 2005-03-15  Karl Berry  <karl@gnu.org>
13095
13096         * config/srclist.txt (config.rpath): from gettext.
13097         * config/config.rpath: update.
13098
13099 2005-03-15  Bruno Haible  <bruno@clisp.org>
13100
13101         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
13102         to 'negate'.
13103
13104         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
13105         variable.
13106
13107         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
13108         results.
13109
13110 2005-03-14  Simon Josefsson  <jas@extundo.com>
13111
13112         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
13113         <fx@gnu.org>.
13114
13115 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
13116
13117         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
13118         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
13119         intprops.h.
13120         * lib/strtol.c: Likewise.
13121
13122 2005-03-14  Jim Meyering  <jim@meyering.net>
13123
13124         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
13125         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
13126         to be nonzero so that we (and caller) can detect the difference
13127         between a valid zero-length expansion and an error return, even
13128         when the underlying strftime fails before writing anything into
13129         that location.
13130
13131 2005-03-14  Bruno Haible  <bruno@clisp.org>
13132
13133         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
13134         Update from GNU gettext 0.14.3.
13135
13136 2005-03-10  Jim Meyering  <jim@meyering.net>
13137
13138         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
13139
13140 2005-03-10  Jim Meyering  <jim@meyering.net>
13141
13142         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
13143         so that this module works on systems without fchdir.
13144
13145 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
13146
13147         Factor int-properties macros into a single file, except for
13148         glibc-related files.
13149         * lib/intprops.h: New file.
13150         * lib/getloadavg.c: Include it instead of limits.h.
13151         (INT_STRLEN_BOUND): Remove.
13152         * lib/human.c: Include intprops.h.
13153         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
13154         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
13155         302/1000.
13156         * lib/inttostr.h: Include intprops.h instead of limits.h.
13157         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
13158         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
13159         for consistency with intprops.h.
13160         (time_t_is_integer, twos_complement_arithmetic): Use them.
13161         * lib/sig2str.h: Include <signal.h>, intprops.h.
13162         (INT_STRLEN_BOUND): Remove.
13163         * lib/strftime.c (TYPE_SIGNED): Remove.
13164         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
13165         * lib/strtol.c: Adjust comments to match intprops.h.
13166         * lib/userspec.c: Include intprops.h.
13167         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
13168         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
13169         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
13170         instead of rolling our own expressions.
13171         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
13172
13173         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
13174         instead of int.
13175         (my_strftime): Do not mishandle years close to INT_MAX, by doing
13176         the right thing even if adding 1900 would overflow.  Similarly
13177         for tm_mon + 1 and tm_yday + 1.
13178         Make %Y always equivalent to %C%y, and similarly for %G and %g.
13179         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
13180         (DO_SIGNED_NUMBER): New macro.
13181         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
13182
13183 2005-03-07  Bruno Haible  <bruno@clisp.org>
13184
13185         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
13186
13187 2005-03-07  Bruno Haible  <bruno@clisp.org>
13188
13189         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
13190
13191 2005-03-04  Derek R. Price  <derek@ximbiot.com>
13192
13193         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
13194         (func_import): Only replace files via --import when they have actually
13195         changed.
13196
13197 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13198
13199         * m4/mmap-anon.m4: New file.
13200         * m4/pagealign_alloc.m4: New file.
13201
13202 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13203             Bruno Haible  <bruno@clisp.org>
13204
13205         * modules/pagealign_alloc: New file.
13206         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
13207
13208 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13209             Bruno Haible  <bruno@clisp.org>
13210
13211         * lib/pagealign_alloc.h: New file.
13212         * lib/pagealign_alloc.c: New file.
13213
13214 2005-03-03  Bruno Haible  <bruno@clisp.org>
13215
13216         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
13217         Use an all-permissive copyright notice, recommended by RMS.
13218
13219 2005-03-02  Bruno Haible  <bruno@clisp.org>
13220
13221         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
13222         of AIX, the replacement has to be done only after <string.h> is
13223         included, therefore not in config.h. stpncpy.h does the replacement,
13224         and stpncpy.c uses it.
13225
13226 2005-03-02  Bruno Haible  <bruno@clisp.org>
13227
13228         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
13229         stpncpy.c uses it.
13230
13231 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13232
13233         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
13234         The workaround isn't strictly needed for POSIX conformance, and
13235         it's too much of a pain to configure and maintain.  We'll ask
13236         people to fix their kernels instead.
13237         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
13238         (NANOSLEEP_BUG_WORKAROUND): Remove.
13239         (xnanosleep): Remove the workaround.
13240
13241 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13242
13243         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
13244         Reported by Derek Price.
13245         (Include): Add "timespec.h".
13246
13247         * modules/xnanosleep (Depends-on): Remove gethrxtime.
13248
13249 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13250
13251         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
13252         to detect nanosleep bug.
13253
13254 2005-03-01  Bruno Haible  <bruno@clisp.org>
13255
13256         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
13257
13258 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13259
13260         * modules/gethrxtime: New file.
13261         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
13262         (Depends-on): Add gethrxtime.
13263         (configure.ac): Add gl_XNANOSLEEP.
13264         (Makefile.am): Remove lib_SOURCES line.
13265
13266 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13267
13268         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
13269         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
13270
13271 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13272
13273         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
13274         * lib/timespec.h (gettime): Return void, since it always
13275         succeeds now.  All uses changed.
13276         * lib/gettime.c (gettime) Likewise.
13277         [HAVE_NANOTIME]: Prefer nanotime.
13278         Assume gettimeofday succeeds, as POSIX requires.
13279         Assime time () succeeds, since other code already does.
13280         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
13281         (timespec_subtract): Remove.
13282         (NANOSLEEP_BUG_WORKAROUND): New constant.
13283         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
13284         things considerably.  Use it only on GNU/Linux hosts, since the
13285         workaround shouldn't be needed elsewhere.
13286
13287 2005-02-24  Bruno Haible  <bruno@clisp.org>
13288
13289         * modules/gettext (Files): Add m4/glibc2.m4.
13290
13291 2005-02-24  Bruno Haible  <bruno@clisp.org>
13292
13293         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
13294         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
13295         * m4/progtest.m4:
13296         Update from GNU gettext 0.14.2.
13297         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
13298
13299 2005-02-24  Bruno Haible  <bruno@clisp.org>
13300
13301         * lib/localcharset.c: Update from GNU gettext 0.14.2.
13302         * lib/config.charset: Update from GNU gettext 0.14.2.
13303
13304 2005-02-24  Bruno Haible  <bruno@clisp.org>
13305
13306         * lib/gettext.h: Update from GNU gettext 0.14.2.
13307
13308 2005-02-23  Simon Josefsson  <jas@extundo.com>
13309
13310         * m4/iconvme.m4: New file.
13311
13312 2005-02-23  Jim Meyering  <jim@meyering.net>
13313
13314         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
13315         change.
13316         Thanks to Bruno Haible for catching it.
13317
13318 2005-02-22  Simon Josefsson  <jas@extundo.com>
13319
13320         * modules/iconvme: New file.
13321
13322         * MODULES.html.sh: Add iconvme.
13323
13324 2005-02-22  Simon Josefsson  <jas@extundo.com>
13325
13326         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
13327
13328 2005-02-22  Simon Josefsson  <jas@extundo.com>
13329
13330         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
13331
13332 2005-02-22  Jim Meyering  <jim@meyering.net>
13333
13334         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
13335         s/ifndef/ifdef/.
13336
13337 2005-02-20  Neil Conway  <neilc@samurai.com>
13338
13339         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
13340         returned by OSX/Darwin if the specified buffer is not large
13341         enough for the hostname.
13342
13343 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13344
13345         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
13346         pass it to _help, otherwise the latter coredumps trying to
13347         dereference state.root_argp.
13348
13349 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13350
13351         * modules/chdir-long (Depends-on): Add memrchr.
13352         * modules/memrchr (Files): Add lib/memrchr.h.
13353         (Include): "memrchr.h".
13354
13355 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13356
13357         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
13358
13359 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13360
13361         * lib/memrchr.h: New file.
13362         * lib/chdir-long.c: Include it.
13363         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
13364         Don't bother including stddef.h.
13365
13366 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
13367
13368         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
13369         inclusion.
13370         Include <sys/types.h>, for dev_t.
13371         (ME_DUMMY, ME_REMOTE): Move from here....
13372         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
13373         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
13374         Dmitry V. Levin.
13375         Include mountlist.h first, to test the interface.
13376
13377 2005-01-29  Bruno Haible  <bruno@clisp.org>
13378
13379         * lib/progname.c (program_name): Initialize.
13380         Needed when linking statically on MacOS X.
13381
13382 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13383
13384         Sync from coreutils.
13385         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
13386         (Depends-on): Add c-strtod.
13387         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
13388
13389 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13390
13391         Sync from coreutils.
13392         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
13393
13394         Remove files that are specific to coreutils.
13395         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
13396
13397 2005-01-28  Bruno Haible  <bruno@clisp.org>
13398
13399         * modules/javacomp: New file.
13400         * MODULES.html.sh (Java): Add javacomp.
13401
13402 2005-01-28  Bruno Haible  <bruno@clisp.org>
13403
13404         * m4/javacomp.m4: New file, from GNU gettext.
13405
13406 2005-01-28  Bruno Haible  <bruno@clisp.org>
13407
13408         * lib/javacomp.sh.in: New file, from GNU gettext.
13409         * lib/javacomp.h: New file, from GNU gettext.
13410         * lib/javacomp.c: New file, from GNU gettext.
13411
13412 2005-01-26  Simon Josefsson  <jas@extundo.com>
13413
13414         * lib/gai_strerror.c: Use GPL in header.
13415
13416 2005-01-26  Bruno Haible  <bruno@clisp.org>
13417
13418         * modules/javaexec: New file.
13419         * MODULES.html.sh (Java): Add javaexec.
13420
13421 2005-01-26  Bruno Haible  <bruno@clisp.org>
13422
13423         * m4/javaexec.m4: New file, from GNU gettext.
13424
13425 2005-01-26  Bruno Haible  <bruno@clisp.org>
13426
13427         * lib/javaexec.sh.in: New file, from GNU gettext.
13428         * lib/javaexec.h: New file, from GNU gettext.
13429         * lib/javaexec.c: New file, from GNU gettext.
13430
13431 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13432
13433         * modules/lchown (Depends-on): Remove lchown.h
13434
13435 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13436
13437         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
13438         must be defined if the header file was not found, in order
13439         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
13440
13441 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13442
13443         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
13444         initializers for struct pentry_state.
13445         (__argp_error): Check return value of __asprintf
13446         (__argp_failure): Translate error message
13447
13448         * lib/argp-parse.c: Removed braces around the expansion of N_()
13449
13450 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13451
13452         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
13453         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
13454         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
13455         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
13456         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
13457         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
13458         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
13459         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
13460         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
13461         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
13462         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
13463         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
13464         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
13465         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
13466         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
13467         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
13468         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
13469         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
13470         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
13471         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
13472         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
13473         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
13474         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
13475         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
13476         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
13477         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
13478         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
13479         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
13480         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
13481         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
13482         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
13483         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
13484         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
13485         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
13486         xstrtol.m4, xstrtoumax.m4, yesno.m4:
13487         Use an all-permissive copyright notice, recommended by RMS.
13488
13489 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
13490
13491         * modules/chdir-long (Depends-on): Remove mempcpy.
13492
13493 2005-01-21  Jim Meyering  <jim@meyering.net>
13494
13495         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
13496         same value as for Solaris 9.
13497
13498         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
13499         component length.  This included changing the parameter to be
13500         of type `char *' rather than `char const *'.
13501         * lib/chdir-long.h (chdir_long): Update prototype.
13502
13503         * lib/openat.c (fdopendir, fstatat): New functions.
13504         * lib/openat.h: Include headers required for use of DIR and struct
13505         stat.
13506         [AT_SYMLINK_NOFOLLOW]: Define.
13507         (fdopendir, fstatat): Add prototypes.
13508
13509 2005-01-21  Bruno Haible  <bruno@clisp.org>
13510
13511         * modules/classpath: New file.
13512         * MODULES.html.sh (Java): Add classpath.
13513
13514 2005-01-21  Bruno Haible  <bruno@clisp.org>
13515
13516         * lib/classpath.h: New file, from GNU gettext.
13517         * lib/classpath.c: New file, from GNU gettext.
13518
13519 2005-01-20  Simon Josefsson  <jas@extundo.com>
13520
13521         * modules/version-etc-fsf: New file.
13522
13523 2005-01-20  Simon Josefsson  <jas@extundo.com>
13524
13525         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
13526         * lib/version-etc.c: Remove version_etc_copyright.
13527         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
13528         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
13529
13530 2005-01-20  Simon Josefsson  <jas@extundo.com>
13531
13532         * lib/base64.h (isbase64): Add.
13533
13534         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
13535         using a unsigned prototype, don't inline.
13536         (base64_decode): Use it.
13537
13538 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13539
13540         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
13541         it.
13542
13543 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13544
13545         * lib/save-cwd.c (save_cwd): Remove code to support the case
13546         where fchdir is missing or flaky.
13547
13548 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13549
13550         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
13551
13552 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
13553
13554         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
13555         AC_LIBSOURCES now does this.
13556         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
13557         with new ullong_max module.
13558
13559 2005-01-19  Bruno Haible  <bruno@clisp.org>
13560
13561         * modules/sh-quote: New file.
13562         * MODULES.html.sh (Executing programs): Add sh-quote.
13563
13564 2005-01-19  Bruno Haible  <bruno@clisp.org>
13565
13566         * lib/sh-quote.h: New file, from GNU gettext.
13567         * lib/sh-quote.c: New file, from GNU gettext.
13568
13569 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13570
13571         Merge from coreutils.
13572         * m4/ullong_max.m4: New file.
13573         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
13574         (gl_MACROS): Assume localeconv exists.
13575
13576 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13577
13578         Merge changes from coreutils, as described below in several
13579         changelogs dated today.
13580
13581         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
13582         (O_DIRECTORY): Remove; not needed here, since "." must be
13583         a directory.  All uses removed.
13584         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
13585         universal on Suns, and we also need to test for IRIX.
13586         Revamp code to use 'if' rather than '#if'.
13587         Avoid unnecessary comparison of cwd->desc to 0.
13588
13589         * lib/utimens.c (futimens): Robustify the previous patch, by checking
13590         for known valid error numbers rather than observed invalid ones.
13591
13592 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13593
13594         * modules/ullong_max: New file.
13595
13596         * modules/chdir-long, modules/openat: New files.
13597         * modules/save-cwd (Depends-on): Depend on chdir-long.
13598         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
13599
13600 2005-01-18  Jim Meyering  <jim@meyering.net>
13601
13602         Merge from coreutils.
13603         * m4/chdir-long.m4, m4/openat.m4: New files.
13604         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
13605         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
13606         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
13607         is sane and DOES follow symlinks.  Besides, testing 20 different
13608         systems found no broken chown implementations.
13609         Prompted by a change in rsync's copy of this macro.
13610         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
13611
13612         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
13613
13614         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
13615         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
13616         NULL-means-set-to-current-time semantics.
13617         Remove temporary file immediately, rather than waiting
13618         for configure's at-exit trap code to do it.
13619
13620 2005-01-18  Jim Meyering  <jim@meyering.net>
13621
13622         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13623
13624         * lib/utimens.c (futimens): Account for the fact that futimes
13625         can also fail with errno == ENOSYS or errno == ENOENT.
13626         Patch from Dmitry V. Levin.
13627
13628         Change the name of the robust chdir function from chdir to chdir_long.
13629         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
13630         (restore_cwd): Use chdir_long, not chdir.
13631         * lib/chdir-long.c: Renamed from chdir.c.
13632         * lib/chdir-long.h: Renamed from chdir.h.
13633         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
13634         Hurd.
13635
13636 2005-01-18  Bruno Haible  <bruno@clisp.org>
13637
13638         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
13639         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
13640         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
13641         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
13642         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
13643         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
13644         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
13645         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
13646         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
13647         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
13648         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
13649         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
13650         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
13651         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
13652         Use an all-permissive copyright notice, recommended by RMS.
13653
13654 2005-01-18  Bob Proulx  <bob@proulx.com>
13655
13656         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
13657         simplify offsetof() macro construct to avoid compile failure with
13658         native HP-UX 11.0 ANSI C compiler.
13659
13660 2005-01-17  Bruno Haible  <bruno@clisp.org>
13661
13662         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
13663         redundant because stpncpy.m4 takes care of it.
13664
13665 2005-01-17  Bruno Haible  <bruno@clisp.org>
13666
13667         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
13668
13669 2005-01-17  Bruno Haible  <bruno@clisp.org>
13670
13671         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
13672         used.
13673
13674 2005-01-17  Bruno Haible  <bruno@clisp.org>
13675
13676         * lib/fwriteerror.h (fwriteerror): Change specification to include
13677         fclose.
13678         * lib/fwriteerror.c: Include <stdbool.h>.
13679         (fwriteerror): At the end, close the file stream. Record whether
13680         stdout was already closed.
13681
13682 2005-01-17  Bruno Haible  <bruno@clisp.org>
13683
13684         * lib/execute.c (environ): Declare if needed.
13685         * lib/pipe.c (environ): Likewise.
13686         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
13687
13688 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13689
13690         * modules/argp: Depend on vsnprintf
13691
13692 2005-01-10  Jim Meyering  <jim@meyering.net>
13693
13694         * modules/closeout (Depends-on): Add atexit.
13695
13696 2005-01-06  Bruno Haible  <bruno@clisp.org>
13697
13698         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
13699
13700 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13701
13702         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
13703         definitions to be after all include files, to avoid collisions.
13704         Problem reported by Bob Proulx.
13705
13706 2005-01-04  Jim Meyering  <jim@meyering.net>
13707
13708         Changes imported from coreutils.
13709         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
13710         as the mkstemp template, use a temporary directory and an
13711         8.3-friendly template to avoid trouble on systems like DJGPP.
13712         Reported by Juan M. Guerrero via Stepan Kasal.
13713         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
13714         close. Remove the temporary directory right away, rather than waiting
13715         for configure's at-exit trap code to do it.
13716         Suggestion from Stepan Kasal.
13717
13718 2005-01-01  Simon Josefsson  <jas@extundo.com>
13719
13720         * gnulib-tool: Print #include directives when --import'ing.
13721
13722 2004-12-28  Simon Josefsson  <jas@extundo.com>
13723
13724         * tests/test-base64.c: Include required header files.  Remove
13725         unused variables.
13726
13727 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13728
13729         * modules/error (Depends-on): Remove gettext.
13730
13731 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13732
13733         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
13734         not needed.  This removes a dependency on the gettext module.
13735         [defined _LIBC]: Do not include <libintl.h>; not needed.
13736
13737 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13738
13739         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
13740         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
13741
13742 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13743
13744         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
13745         HAVE_DECL_STRTOLD.
13746
13747 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13748
13749         * modules/getdate (Depends-on): Remove alloca-opt.
13750
13751 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13752
13753         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
13754
13755 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13756
13757         * lib/argp-parse.c: Include <stddef.h>.
13758         (alignof, alignto): New macros.
13759         (parser_init): Don't assume that void * is aligned sufficiently
13760         for struct option.
13761
13762         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
13763         need to extend the stack.
13764         (YYINITDEPTH): New macro, so that the initial stack isn't overly
13765         large.
13766
13767 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13768
13769         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
13770
13771 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13772
13773         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
13774         (2004-10-24) change.  Apparently this was a false alarm.
13775
13776         * modules/getdate: Depend on alloca-opt, not alloca.
13777
13778 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13779
13780         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
13781         Remove now-obsolete comment about AIX.
13782         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
13783         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
13784         (YYMAXDEPTH): New macro.
13785
13786 2004-12-18  Simon Josefsson  <jas@extundo.com>
13787
13788         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
13789
13790 2004-12-18  Bruno Haible  <bruno@clisp.org>
13791
13792         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
13793
13794 2004-12-18  Bruno Haible  <bruno@clisp.org>
13795
13796         * lib/fatal-signal.c (fatal_signals): Make non-const.
13797         (init_fatal_signals): New function.
13798         (uninstall_handlers, install_handlers): Ignore signals that were set to
13799         SIG_IGN.
13800         (at_fatal_signal): Call init_fatal_signals.
13801         (init_fatal_signal_set): Likewise. Ignore signals that were set to
13802         SIG_IGN.
13803         Reported by Paul Eggert.
13804
13805 2004-12-18  Bruno Haible  <bruno@clisp.org>
13806
13807         * doc/alloca.texi: New file.
13808         * doc/alloca-opt.texi: New file.
13809
13810 2004-12-17  Jim Meyering  <jim@meyering.net>
13811
13812         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
13813         Otherwise, install-sh could exit with improper exit status when
13814         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
13815
13816 2004-12-16  Simon Josefsson  <jas@extundo.com>
13817
13818         * tests/test-base64.c: Add license.
13819
13820 2004-12-15  Stepan Kasal  <address@hidden>
13821
13822         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
13823
13824 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
13825
13826         * modules/getcwd (Files): Add m4/d-ino.m4.
13827         Suggested by Mark D. Baushke.
13828
13829 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13830
13831         * lib/getdate.y (textint): New member "negative".
13832         (time_zone_hhmm): New function.
13833         Expect 14 shift-reduce conflicts, not 13.
13834         (o_colon_minutes): New rule.
13835         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
13836         (yylex): Set the "negative" member of signed numbers.
13837
13838 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13839
13840         * doc/getdate.texi (Time of day items, Time zone items):
13841         Describe new formats +00:00, UTC+00:00.
13842
13843 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13844
13845         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
13846         spurious "-l"s.  Problem reported by Stepan Kasal.
13847
13848 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
13849
13850         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
13851         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
13852
13853 2004-12-04  Simon Josefsson  <jas@extundo.com>
13854
13855         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
13856         Vandoorselaere <yoann@prelude-ids.org>.
13857
13858 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13859
13860         Changes imported from coreutils.
13861         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
13862         exist.
13863         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
13864
13865 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13866
13867         Changes imported from coreutils.
13868         * lib/hard-locale.c: Assume <locale.h> exists.
13869         Include "strdup.h".
13870         (GLIBC_VERSION): New macro.
13871         (hard_locale): Assume setlocale exists.
13872         Rewrite to avoid #ifdef.
13873         Use strdup rather than malloc + strcpy.
13874         * lib/human.c: Assume <locale.h> exists.
13875         (human_readable): Assume localeconv exists.
13876
13877 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13878
13879         * modules/hard-locale (Depends-on): Add strdup.
13880
13881 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
13882
13883         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
13884         convert T2, not T.  (Imported from libc.)
13885
13886 2004-11-30  Simon Josefsson  <jas@extundo.com>
13887
13888         * modules/restrict (License): Change to LGPL.
13889
13890 2004-11-30  Simon Josefsson  <jas@extundo.com>
13891
13892         * m4/restrict.m4: Add copyright and copying conditions.
13893
13894 2004-11-30  Simon Josefsson  <jas@extundo.com>
13895
13896         * m4/base64.m4: New file.
13897
13898 2004-11-30  Simon Josefsson  <jas@extundo.com>
13899
13900         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
13901         base64.
13902
13903         * tests/test-base64.c: New file.
13904
13905         * modules/base64: New file.
13906
13907 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13908
13909         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
13910         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
13911
13912         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
13913
13914 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13915
13916         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
13917         (__getcwd.c): Don't restore errno; glibc doesn't.
13918         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
13919         first, falling back to our code only if its results look suspicious.
13920         Ensure that the resulting buffer is only as large as necessary.
13921
13922         * lib/readutmp.c: Include readutmp.h first.
13923         Include <errno.h>, since readutmp.h no longer does that.
13924         * lib/readutmp.h: Don't include <errno.h>,
13925         <sys/param.h>, <time.h>; not needed to establish interface.
13926         (errno): Remove decl.
13927         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
13928         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
13929         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
13930
13931 2004-11-28  Simon Josefsson  <jas@extundo.com>
13932
13933         * lib/base64.h, base64.c: New file.
13934
13935 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
13936
13937         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
13938
13939 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
13940
13941         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
13942         (Depends-on): Remove pathmax, same.  Add mempcpy.
13943         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
13944         (Makefile.am): Append getcwd.h to lib_SOURCES.
13945         (Include): Add getcwd.h.
13946         (Maintainer): Change from Jim Meyering to "all, glibc",
13947         since getdate now uses intended-for-glibc code.
13948         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
13949         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
13950
13951 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13952
13953         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
13954         HP's ANSI C compiler.
13955         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
13956         Declaring int functions causes warnings on some modern systems and
13957         shouldn't be needed to compile on ancient ones.
13958         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
13959         defined.
13960
13961         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
13962         with the following changes.
13963         (__set_errno): Parenthesize properly.
13964         Include <stdbool.h>.
13965         (MIN, MAX, MATCHING_INO): New macros.
13966         (__getcwd): Define with prototype, not K&R form.
13967         Use heuristics to allocate default buffer on stack if possible.
13968         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
13969         behavior, and to avoid the PATH_MAX limit when computing
13970         ../../../../...
13971         Use MATCHING_INO to compare inode number to file.
13972         Check for arithmetic overflow in size calculations.
13973         Fix bug in reallocation of dot array that caused getcwd to fail
13974         on directories nested deeper than 75.
13975         Be more careful about saving errno on error.
13976         Do not use realloc; use only free+malloc, as this is a bit
13977         more flexible and avoids a needless copy operation.
13978         Do not inspect st_dev and st_ino for symbolic links; POSIX
13979         doesn't specify the latter.
13980         Check for closedir errors.
13981         Avoid needless casts.
13982         Use "#ifdef weak_alias" around weak_alias, to be like other
13983         glibc code.
13984         The following changes to getcwd.c have effect only when used in
13985         gnulib; they have no effect inside glibc proper.
13986         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
13987         as alloca isn't used.
13988         (alloca, __alloca): Likewise.
13989         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
13990         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
13991         unconditionally, as gnulib assumes C89 or better.
13992         Do not include <sys/param.h>.
13993         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
13994         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
13995         better.
13996         (NULL) [!defined NULL]: Remove; we assume C89 or better.
13997         Include <dirent.h> in a way that is compatible with modern Autoconf.
13998         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
13999         New macros, if not already defined.
14000         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
14001         Use "_LIBC", not "defined _LIBC", for consistency.
14002         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
14003         a mempcpy module.
14004         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
14005         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
14006         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
14007         credit only to Jim Meyering and adjust the copyright dates.
14008         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
14009         <stdlib.h>, <unistd.h>, "pathmax.h".
14010         Instead, include "xgetcwd.h" (first) and "getcwd.h".
14011         (INITIAL_BUFFER_SIZE): Remove.
14012         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
14013
14014 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
14015
14016         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
14017         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
14018         Use the _ONCE methods, for efficiency.
14019         Check for fcntl.h.  In test program, include <errno.h>
14020         and <fcntl.h> if available.  Remove old K&R cruft from
14021         test program.  Check for common errors in GNU/Linux,
14022         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
14023         don't do AC_LIBOBJ, as that's getcwd.m4's job.
14024         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
14025         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
14026         name accordingly.
14027         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
14028         accommodate new getcwd.c.
14029         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
14030         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
14031         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
14032         that's all we need now.
14033
14034 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14035
14036         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
14037         argp-parse.c depends on getopt internals, that means we should
14038         always use our getopt, to be on the safe side.
14039         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
14040         order not to spoil the result of an eventual previous invocation
14041         of gl_GETOPT_SUBSTITUTE.
14042
14043 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14044
14045         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
14046         redefinition warnings. To avoid them, include the defines
14047         in `#if !defined __need_getopt ... #endif'. The only place
14048         where __getopt_argv_const is used is in definitions
14049         of getopt_long and getopt_long_only below, which are as well
14050         protected by `#ifndef __need_getopt'.
14051         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
14052         __need_getopt after including <stdio.h> and <unistd.h> These
14053         headers might have defined it.
14054
14055 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
14056
14057         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
14058
14059 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
14060
14061         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
14062         (futimens): New function, which uses futimes if available.
14063         (futimens, utimens): Support timespec==NULL, with same semantics
14064         as utime and utimens.
14065         * lib/utimens.h (futimens): New decl.
14066
14067 2004-11-23  Jim Meyering  <jim@meyering.net>
14068
14069         * lib/getopt_.h: Remove trailing blanks.
14070
14071 2004-11-23  Jim Meyering  <jim@meyering.net>
14072
14073         * lib/__fpending.c: Add comment.
14074
14075 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
14076
14077         * modules/canonicalize (Depends-on): Add xreadlink.
14078         Problem reported by James Youngman.
14079
14080 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
14081
14082         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
14083         New macros.
14084         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
14085         optopt): Use them instead of invoking ## directly; otherwise, the
14086         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
14087
14088 2004-11-19  Bruno Haible  <bruno@clisp.org>
14089
14090         * lib/strtok_r.c: Move comments from here...
14091         * lib/strtok_r.h: ... to here.
14092
14093 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14094
14095         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
14096         implementations that mishandle size_t overflow.
14097
14098 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14099
14100         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
14101         might fail.  Problem reported by Yoann Vandoorselaere.
14102         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
14103         implementations that mishandle size_t overflow.
14104
14105 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14106
14107         * modules/canon-host (Depends-on): Add strdup.
14108
14109 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14110
14111         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
14112
14113 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14114
14115         * lib/canon-host.c: Include "strdup.h".
14116         (canon_host): Use getaddrinfo if available, so that IPv6 works.
14117         Use strdup instead of malloc/strcpy to duplicate strings.
14118
14119         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
14120         (human_space_before_unit): New constant.
14121         * lib/human.c (human_readable): Support it.
14122
14123         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
14124         (xgetcwd): Set errno correctly when failing.
14125         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
14126         the failure is actually due to a PATH_MAX problem.
14127
14128         Further getopt changes to make it more likely that glibc will
14129         buy the changes back.
14130         * lib/getopt.c (POSIXLY_CORRECT): New constant.
14131         (getopt): Use it, so to preserve glibc semantic
14132         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
14133         when compiling for libc.
14134         * lib/getopt_.h (__getopt_argv_const): Bring it back.
14135         (getopt_long, getopt_long_only): Use it.
14136
14137         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14138         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
14139         (getopt): Argv is now char * const *, as per standard.
14140         (_getopt_internal_r, _getopt_internal): Argv is now char **,
14141         not char *__getopt_argv_const *.
14142         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14143         _getopt_long_only_r): Likewise.
14144         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
14145         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14146         _getopt_long_r, _getopt_long_only_r): Likewise.
14147         * lib/getopt_.h (__getopt_argv_const): Remove.
14148         (getopt): Argv is now char * const *, as per standard.
14149
14150         * lib/getdate.y (tORDINAL): New token.
14151         (day, relunit): Allow it for relative times.
14152         (relative_time_table): Use tORDINAL for ordinals.
14153
14154 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14155
14156         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
14157         Document that "second" isn't allowed as an ordinal number.
14158
14159 2004-11-16  Jim Meyering  <jim@meyering.net>
14160
14161         * modules/closeout (Depends-on): Add fpending.
14162
14163 2004-11-15  Jim Meyering  <jim@meyering.net>
14164
14165         * lib/closeout.c: Include "__fpending.h" once again.
14166         Include <stdbool.h>.
14167         (close_stdout): Don't fail just because stdout was closed initially,
14168         since some programs don't write to stdout in the normal course of
14169         operation (other than --version and --help), and we don't want this
14170         function to make e.g. `touch file >&-' fail.
14171         But do fail if it was closed and someone has tried to write to it.
14172         E.g., `printf foo >&-' must fail.
14173
14174 2004-11-13  Jim Meyering  <jim@meyering.net>
14175
14176         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
14177
14178 2004-11-12  Simon Josefsson  <jas@extundo.com>
14179
14180         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
14181         small doc fix is still pending.
14182
14183 2004-11-11  Simon Josefsson  <jas@extundo.com>
14184
14185         * modules/strtok_r: New file.
14186
14187         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14188         strtok_r.
14189
14190 2004-11-11  Simon Josefsson  <jas@extundo.com>
14191
14192         * m4/strtok_r.m4: New file.
14193
14194         * m4/getopt.m4: Replace opterr.
14195
14196 2004-11-11  Simon Josefsson  <jas@extundo.com>
14197
14198         * lib/strtok_r.h, strtok_r.c: New file.
14199
14200 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14201
14202         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
14203         of replacing opterr, getopt, etc.  This should handle the
14204         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
14205
14206 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14207
14208         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
14209         we can stop lying to compilers about the constness of argv when we
14210         are compiled outside glibc.
14211         (getopt, getopt_long, getopt_long_only): Use it.
14212         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14213         _getopt_internal, getopt): Likewise.
14214         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14215         _getopt_long_only_r): Likewise.
14216         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14217         _getopt_long_r, _getopt_long_only_r): Likewise.
14218
14219         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
14220         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
14221         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
14222         the other external symbols.
14223         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
14224         declaration, since the above renaming now works around collisions.
14225
14226 2004-11-11  Jim Meyering  <jim@meyering.net>
14227
14228         * lib/linebreak.c: Remove trailing blanks.
14229         * lib/alloca_.h: Likewise.
14230         * lib/acosl.c: Likewise.
14231         * lib/euidaccess.c: Likewise.
14232         * lib/allocsa.h: Likewise.
14233
14234 2004-11-10  Simon Josefsson  <jas@extundo.com>
14235
14236         * m4/getaddrinfo.m4: New file.
14237
14238 2004-11-10  Simon Josefsson  <jas@extundo.com>
14239
14240         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
14241
14242 2004-11-10  Simon Josefsson  <jas@extundo.com>
14243
14244         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14245         getaddrinfo.
14246
14247         * modules/getaddrinfo: New file.
14248
14249 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14250
14251         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
14252
14253 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14254
14255         * lib/mktime.c (SHR): New macro, which is a portable
14256         substitute for >> that should work even on Crays.
14257         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
14258         Problem reported by Mark D. Baushke in
14259         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
14260         * lib/getdate.y (SHR): Likewise.
14261         (tm_diff): Use it.
14262         * lib/strftime.c (SHR): Likewise.
14263         (tm_diff): Use it.
14264         * lib/quotearg.c (struct quoting_options): Use unsigned int for
14265         quote_these_too, so that right shifts are well defined.  All uses
14266         changed.
14267
14268 2004-11-10  Jim Meyering  <jim@meyering.net>
14269
14270         Ensure that no close failure goes unreported.
14271         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
14272         return early when it seems there's nothing to flush.
14273         Don't include __fpending.h.
14274
14275 2004-11-10  Jim Meyering  <jim@meyering.net>
14276
14277         * modules/closeout (Depends-on): Remove fpending.
14278
14279 2004-11-10  Jim Meyering  <jim@meyering.net>
14280
14281         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
14282
14283 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14284
14285         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
14286         gl_FUNC_STRFTIME.
14287         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
14288         and AC_REQUIRE when possible, to avoid duplicate checks.
14289         Check for <wchar.h>.
14290
14291 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14292
14293         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
14294
14295 2004-11-09  Bruno Haible  <bruno@clisp.org>
14296
14297         * m4/sockpfaf.m4: New file.
14298
14299 2004-11-05  Bruno Haible  <bruno@clisp.org>
14300
14301         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
14302         Reported by Mark D. Baushke <mdb@cvshome.org>.
14303
14304 2004-11-04  Bruno Haible  <bruno@clisp.org>
14305
14306         2004-09-11  Bruno Haible  <bruno@clisp.org>
14307                 * allocsa.valgrind: New file.
14308         2004-02-06  Bruno Haible  <bruno@clisp.org>
14309                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
14310                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
14311                 Reported by Christopher Seip <chris.seip@hp.com>.
14312
14313 2004-11-04  Bruno Haible  <bruno@clisp.org>
14314
14315         * modules/allocsa (Files): Add lib/allocsa.valgrind.
14316         (Makefile.am): Distribute it.
14317
14318 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
14319
14320         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
14321         with errno == ERANGE if the buffer is too small.
14322         Problem reported by Mark D. Baushke.
14323
14324 2004-11-03  Albert Chin  <china@thewrittenword.com>
14325             Paul Eggert  <eggert@cs.ucla.edu>
14326
14327         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
14328         equivalent, substitute $ac_type for equivalent type rather than
14329         blindly using uint32_t *always* which won't work if uint32_t is not
14330         available.  Define _UINT32_T to work around typedef of uint32_t if
14331         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
14332         2.5.1.
14333
14334 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14335
14336         * m4/jm-macros.m4: Sync from coreutils.
14337         (gl_MACROS): Check for mbrlen, for pathchk.
14338         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
14339
14340 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14341
14342         * lib/xreadlink.c (MAXSIZE): New macro.
14343         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
14344         size does not exceed MAXSIZE.  Avoid cast.
14345         As suggested by Mark D. Baushke in
14346         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
14347         if readlink fails with buffer size just under MAXSIZE, try again
14348         with MAXSIZE.
14349
14350 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14351
14352         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
14353
14354 2004-11-02  Derek R. Price  <derek@ximbiot.com>
14355         and  Paul Eggert  <eggert@cs.ucla.edu>
14356
14357         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
14358         (get_date): Overparenthesize to avoid GCC warning.
14359
14360 2004-11-02  Bruno Haible  <bruno@clisp.org>
14361
14362         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
14363         returns void.
14364
14365 2004-11-02  Bruno Haible  <bruno@clisp.org>
14366
14367         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
14368         function returns void.
14369
14370 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14371
14372         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
14373         fflush_unlocked, flockfile, funlockfile, funlockfile,
14374         fputs_unlocked, putc_unlocked.
14375
14376 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14377
14378         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14379         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
14380         already declared.
14381
14382 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14383
14384         * modules/getdate (Files): Add doc/getdate.texi.
14385         (Depends-on): Add setenv, xalloc.
14386
14387 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14388
14389         * lib/getdate.y: Add support for TZ="foo" within a date string.
14390         Fix some bugs near time_t boundaries.  Reject dates with
14391         out-of-range components, e.g., "Sept 31".
14392         Include <stdlib.h>, "setenv.h", "xalloc.h".
14393         (ISDIGIT_LOCALE): Remove; unused.
14394         Note that the TZ and time functions used here are not reentrant.
14395         (mktime_ok, get_tz): New functions.
14396         (TZBUFSIZE): New constant.
14397         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
14398         This requires that we sometimes generate our own TZ="XXX..." setting.
14399
14400 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14401
14402         * doc/getdate.texi: New file, from coreutils with modifications for
14403         the new TZ parsing.
14404
14405 2004-10-27  Derek R. Price  <derek@ximbiot.com>
14406
14407         * lib/mktime.c (not_equal_tm): Remove redundant check.
14408
14409 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14410
14411         * modules/regex (lib_SOURCES): Add regex.c.
14412         Reported by James Youngman in
14413         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
14414
14415 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14416
14417         * lib/getdate.y: Use Bison 1.875 features, and some minor
14418         code cleanups.  This change does not affect semantics.
14419         Don't include <stdlib.h>; no longer needed.
14420         Don't include unlocked-io.h; only the "#if TEST" code uses
14421         stdio, and performance isn't crucial there.
14422         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
14423         Bison 1.875 features as described below.
14424         All uses of "PC." replaced by "pc->".
14425         (YYSTYPE): Add a forward declaration.
14426         (yylex, yyerror): Use full prototypes in forward decls.
14427         Use "%pure-parser" rather than obsolescent "%pure_parser".
14428         Use %parse-param and %lex-param instead of obsolescent
14429         YYPARSE_PARAM and YYLEX_PARAM.
14430         (meridian_table, month_and_day_table, time_units_table,
14431         relative_time_table, time_zone_table, military_table,
14432         lookup_zone, lookup_word, get_date):
14433         Use NULL instead of 0 where appropriate.
14434         (to_hour): Avoid abort (), to avoid a dependency on
14435         stdlib.h.
14436         (yyerror, yylex): Now accepts parser_control * arg.
14437         (main) [TEST]: Use '\0' rather than 0 for char.
14438
14439 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14440
14441         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
14442
14443 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14444
14445         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
14446         It's now the caller's responsibility to handle the case where
14447         !HAVE_GETPAGESIZE && !defined getpagesize.
14448
14449         * lib/mktime.c (leapyear): Arg is long int, not int.
14450
14451 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
14452
14453         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
14454
14455 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
14456
14457         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
14458         missing.  Problem reported by James Youngman.
14459
14460 2004-10-16  Simon Josefsson  <jas@extundo.com>
14461
14462         * gnulib-tool: Fix comments.  Fix parse problem.
14463         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
14464
14465 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
14466
14467         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
14468         implementation of getopt_long.  Problem reported by Alexander Taler in:
14469         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
14470
14471 2004-10-15  Bruno Haible  <bruno@clisp.org>
14472
14473         * gnulib-tool: Untabify. Initialize supplied_libname.
14474         (func_usage): More homogenous output.
14475         (func_modules_transitive_closure, func_modules_to_filelist,
14476         func_emit_lib_Makefile_am): New functions.
14477         (func_import): New function, extracted from big case statement. Use
14478         func_get_license, func_modules_transitive_closure,
14479         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
14480         opt_lgpl. Don't use test -a, as it's not portable.
14481         (func_create_testdir): Use func_modules_transitive_closure,
14482         func_modules_to_filelist, func_emit_lib_Makefile_am.
14483
14484 2004-10-15  Bruno Haible  <bruno@clisp.org>
14485
14486         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
14487
14488 2004-10-15  Bruno Haible  <bruno@clisp.org>
14489
14490         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
14491         the portions belonging to each module.
14492         Suggested by Derek Robert Price <derek@ximbiot.com>.
14493
14494 2004-10-12  Simon Josefsson  <jas@extundo.com>
14495
14496         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14497         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
14498         to real functions.
14499
14500 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14501
14502         * modules/vsnprintf: New file.
14503
14504 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14505
14506         * m4/vsnprintf.m4: New file.
14507
14508 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14509
14510         * lib/vsnprintf.h: New file.
14511         * lib/vsnprintf.c: New file.
14512
14513 2004-10-11  Bruno Haible  <bruno@clisp.org>
14514
14515         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
14516         vsnprintf.
14517
14518 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14519
14520         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
14521
14522 2004-10-07  Bruno Haible  <bruno@clisp.org>
14523
14524         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
14525         fits into the provided buffer.
14526
14527 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14528
14529         * lib/diacrit.c, diacrit.h: Add GPL notice.
14530
14531         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
14532         notice.
14533         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
14534         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
14535         This avoids a potential constant-folding bug.
14536
14537 2004-10-05  Bruno Haible  <bruno@clisp.org>
14538
14539         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
14540         for the declaration of strsep.
14541
14542 2004-10-05  Bruno Haible  <bruno@clisp.org>
14543
14544         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
14545
14546 2004-10-04  Simon Josefsson  <jas@extundo.com>
14547
14548         * modules/memmem: New file.
14549         * tests/test-memmem.c: New file.
14550         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
14551
14552 2004-10-04  Simon Josefsson  <jas@extundo.com>
14553
14554         * m4/memmem.m4: New file.
14555
14556 2004-10-04  Simon Josefsson  <jas@extundo.com>
14557
14558         * lib/memmem.h: New file.
14559         * lib/memmem.c: New file, taken from glibc.
14560
14561 2004-10-04  Simon Josefsson  <jas@extundo.com>
14562
14563         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
14564         '#ifdef USE_UNLOCKED_IO'.
14565
14566 2004-10-04  Simon Josefsson  <jas@extundo.com>
14567
14568         * config/srclist.txt: Add memmem from glibc.
14569
14570 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14571
14572         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
14573
14574         * modules/argmatch, modules/argp, modules/closeout, modules/error,
14575         modules/exclude, modules/getdate, modules/getline,
14576         modules/getndelim2, modules/getpass, modules/getpass-gnu,
14577         modules/getusershell, modules/linebuffer, modules/md5,
14578         modules/mountlist, modules/posixtm, modules/readtokens,
14579         modules/readutmp, modules/regex, modules/sha1,
14580         modules/version-etc, modules/yesno:
14581         Remove dependency on unlocked-io.
14582
14583 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14584
14585         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
14586
14587         * m4/unlocked-io.m4: Add copyright notice.
14588         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
14589
14590 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14591
14592         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
14593         * lib/xmalloc.c (xmemdup): Likewise.
14594         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
14595         XFREE): Remove these long-obsolescent macros.
14596         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
14597         * lib/xstrdup.c: Remove.
14598
14599         * lib/regex.c (re_comp): Cast gettext return value to char *,
14600         Problem reported by Martin Neitzel via Mark D. Baushke.
14601
14602 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14603
14604         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
14605         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
14606         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
14607         regex.c, sha1.c, version-etc.c, yesno.c:
14608         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
14609         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
14610         the includer's responsibility.
14611
14612         Sync from coreutils.
14613
14614         * lib/modechange.c (mode_compile): Don't decrement a pointer that
14615         points to the start of a string, as the C Standard says the
14616         resulting behavior is undefined.
14617
14618         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
14619         simple -> simple_backups, numbered_existing ->
14620         numbered_existing_backups, numbered -> numbered_backups
14621         to avoid shadowing problems.  All uses changed.
14622         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
14623         * lib/backupfile.c (check_extension, numbered_backup):
14624         Rename locals to avoid shadowing 'basename'.
14625         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
14626         once.
14627
14628         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
14629         * lib/.cvsignore: Add getopt.h.
14630
14631 2004-10-04  Bruno Haible  <bruno@clisp.org>
14632
14633         * modules/README: New file.
14634         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
14635         not a module.
14636
14637 2004-10-02  Jim Meyering  <jim@meyering.net>
14638
14639         * lib/dirfd.h, getpagesize.h: Add copyright notice.
14640
14641 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14642
14643         * modules/strsep: New file.
14644
14645 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14646
14647         * m4/strsep.m4: New file.
14648
14649 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14650
14651         * lib/strsep.h: New file.
14652         * lib/strsep.c: New file.
14653
14654 2004-10-01  Simon Josefsson  <jas@extundo.com>
14655
14656         * lib/snprintf.c (snprintf): Handle size==0.
14657
14658 2004-10-01  Simon Josefsson  <jas@extundo.com>
14659             Bruno Haible  <bruno@clisp.org>
14660
14661         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
14662         (snprintf): Declare 'args'.
14663
14664 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
14665
14666         * lib/snprintf.c: Remove comments as to why each header is needed.
14667
14668 2004-10-01  Bruno Haible  <bruno@clisp.org>
14669
14670         * MODULES.html.sh: Add strsep.
14671
14672 2004-09-30  Simon Josefsson  <jas@extundo.com>
14673
14674         * modules/snprintf: New file.
14675
14676 2004-09-30  Simon Josefsson  <jas@extundo.com>
14677
14678         * m4/snprintf.m4: New file.
14679
14680 2004-09-30  Simon Josefsson  <jas@extundo.com>
14681
14682         * lib/snprintf.h, lib/snprintf.c: New files.
14683
14684 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14685
14686         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
14687         (hol_entry_help): Never translate an empty string.
14688         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
14689         * lib/argp.h (OPTION_NO_TRANS): New option.
14690
14691 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14692
14693         * modules/argp (Maintainer): Replace Simon Josefsson
14694         by Sergey Poznyakoff.
14695
14696 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14697
14698         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
14699         changes merged back into glibc.
14700
14701 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14702
14703         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
14704
14705 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14706
14707         * lib/xvasprintf.c: Include xalloc.h.
14708         (xvasprintf): Use xalloc_die, not xmalloc_die.
14709
14710 2004-09-29  Bruno Haible  <bruno@clisp.org>
14711
14712         * modules/alloca-opt: New file, derived from modules/alloca.
14713         * modules/allocsa: Depend on alloca-opt instead of alloca.
14714         * modules/setenv: Likewise.
14715         * modules/vasnprintf: Likewise.
14716         * MODULES.html.sh: Add alloca-opt.
14717
14718 2004-09-28  Simon Josefsson  <jas@extundo.com>
14719
14720         * gnulib-tool: New parameter --lgpl, to asseert that modules are
14721         LGPL, and to replace license template from GPL to LGPL.
14722
14723 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14724
14725         * modules/dummy: Change license to LGPL.
14726
14727 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14728
14729         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
14730
14731 2004-09-24  Simon Josefsson  <jas@extundo.com>
14732
14733         * modules/minmax (License): Change from GPL to LGPL.
14734
14735 2004-09-23  Simon Josefsson  <jas@extundo.com>
14736
14737         * gnulib-tool (--import): Typo.
14738
14739 2004-09-23  Simon Josefsson  <jas@extundo.com>
14740
14741         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
14742
14743 2004-09-22  Bruno Haible  <bruno@clisp.org>
14744
14745         * modules/*: Add 'License' field.
14746         * gnulib-tool: Accept --extract-license option.
14747         (func_get_license): New function.
14748
14749 2004-09-21  Bruno Haible  <bruno@clisp.org>
14750
14751         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
14752         Reported by Simon Josefsson.
14753
14754 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14755
14756         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
14757         gl_AC_TYPE_LONG_LONG.
14758
14759 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14760
14761         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
14762
14763 2004-09-18  Simon Josefsson  <jas@extundo.com>
14764         and  Paul Eggert  <eggert@cs.ucla.edu>
14765
14766         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
14767         calls with autoreconf.  Define GL_LIB.
14768
14769 2004-09-14  Karl Berry  <karl@gnu.org>
14770
14771         * config/srclist.txt: unsync setenv.c, sigh.
14772
14773 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14774
14775         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
14776         Problem reported by Bruno Haible in:
14777         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
14778
14779 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14780
14781         * config/srclist.txt: Comment out argp-pvh.c.
14782
14783 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
14784
14785         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
14786         in case some system header has #define'd it.  Problem reported by
14787         Soeren D. Schulze in
14788         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
14789
14790 2004-09-09  Karl Berry  <karl@gnu.org>
14791
14792         * regex.[ch]: delete from the root.  These were supposed to be
14793                 synced with emacs cvs, but this has not happened for about
14794                 a year, and anyway nothing else uses emacs regex.[ch].
14795                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
14796                 lib/regex[.ch] is untouched.
14797
14798 2004-09-09  Bruno Haible  <bruno@clisp.org>
14799
14800         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
14801
14802 2004-09-09  Bruno Haible  <bruno@clisp.org>
14803
14804         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
14805         modifications.
14806         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
14807
14808 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14809
14810         * modules/xvasprintf: New file.
14811         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
14812
14813 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14814
14815         * lib/xvasprintf.h: New file.
14816         * lib/xvasprintf.c: New file.
14817         * lib/xasprintf.c: New file.
14818
14819 2004-09-08  Bruno Haible  <bruno@clisp.org>
14820
14821         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
14822
14823 2004-09-08  Bruno Haible  <bruno@clisp.org>
14824
14825         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
14826         length is > INT_MAX.
14827         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
14828         more.
14829
14830 2004-09-08  Bruno Haible  <bruno@clisp.org>
14831
14832         * lib/stdint_.h: New file, taken from GNU clisp.
14833
14834 2004-09-08  Bruno Haible  <bruno@clisp.org>
14835             Oskar Liljeblad  <oskar@osk.mine.nu>
14836
14837         * modules/stdint: New file.
14838         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
14839
14840 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14841
14842         Import from coreutils.
14843         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
14844         strings on unbounded length.  alloca's performance benefits aren't
14845         that important here.
14846         (V_STRDUP): Remove.
14847         (parse_with_separator): New function, with most of the internals
14848         of the old parse_user_spec.  Allow user to omit both user and group,
14849         for compatibility with FreeBSD.
14850         Clone only the user name, not the entire spec.
14851         Do not set *uid, *gid unless entirely successful.
14852         Avoid memory leak in some failing cases.
14853         Fix regression for USER.GROUP reported by Dmitry V. Levin in
14854         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
14855         (parse_user_spec): Rewrite to use parse_with_separator.
14856
14857 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14858
14859         * modules/userspec: Don't depend on alloca.
14860
14861 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14862
14863         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
14864
14865 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
14866
14867         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
14868         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
14869         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
14870
14871 2004-08-16  Simon Josefsson  <jas@extundo.com>
14872
14873         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
14874         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
14875         Add --dry-run for --import.
14876         Let user provided command line parameters override configure.ac
14877         settings.
14878
14879 2004-08-12  Simon Josefsson  <jas@extundo.com>
14880
14881         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
14882         as discussed with Paul Eggert in threads rooted at
14883         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
14884         and
14885         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
14886         Before, the test was empty, and relied on ELIDE_CODE in source
14887         code.)
14888         (gl_PREREQ_GETOPT): New macro.
14889         (gl_GETOPT): Use them.
14890
14891 2004-08-12  Simon Josefsson  <jas@extundo.com>
14892
14893         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
14894         * lib/getopt_.h: Renamed from getopt.h.
14895
14896 2004-08-12  Simon Josefsson  <jas@extundo.com>
14897
14898         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
14899         Change default library name from libfoo to libgnu.
14900         Now, if you have a configure.ac that says:
14901                 gl_SOURCE_BASE(gl)
14902                 gl_M4_BASE(gl/m4)
14903                 gl_MODULES(error getopt etcetera)
14904                 gl_INIT
14905         you can import all you need by running:
14906                 ../gnulib/gnulib-tool --import
14907
14908         * modules/getopt (Files): Rename getopt.h to getopt_.h.
14909         (Makefile.am): Rewrite, use logic from argz.
14910         (Include): Use <getopt.h> instead of "getopt.h".
14911
14912 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14913
14914         * modules/argp (Files): Add m4/unlocked-io.m4.
14915         (Depends-on): Add extensions.
14916
14917 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14918
14919         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
14920         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
14921         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
14922         Check for program_invocation_name, program_invocation_short_name,
14923         flockfile, funlockfile, features.h, _getopt_long_only_r.
14924
14925 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14926
14927         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
14928         its complicated substitute.
14929         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
14930         and program_invocation_name.
14931         (__argp_basename) [!_LIBC]: Remove; the only use was
14932         replaced by its body.
14933         (__argp_short_program_name): Change condition from
14934         !defined __argp_short_program_name to
14935         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
14936         to match argp-namefrob.h.
14937         (__argp_failure): Don't assume strerror_r returns char *.
14938         * lib/argp-parse.c (N_): Define unconditionally.
14939         (argp_default_options): Fill out initializers with 0 to avoid
14940         gcc warnings.
14941
14942 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14943
14944         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
14945         getopt1.c.
14946
14947 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14948
14949         Merge from coreutils.
14950
14951         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
14952
14953         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
14954         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
14955
14956 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14957
14958         Merge from coreutils.
14959
14960         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
14961         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
14962         for Reliant Unix 5.43.
14963
14964         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
14965         (union fooround): Use uintmax_t, not long int.
14966         The rest is a merge from libc:
14967         [defined _LIBC]: Include <shlib-compat.h>.
14968         (_obstack) [defined _LIBC]: Remove after 2.3.4.
14969
14970         * lib/settime.c (settime): Recode to avoid warning with
14971         Sun Forte C 6U2.
14972
14973         * lib/strverscmp.c: Convert to UTF-8.
14974
14975 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14976
14977         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14978         m4/uintmax_t.m4.
14979
14980 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14981
14982         * modules/xalloc-die: New file.
14983         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
14984
14985         * modules/md5 (Files): Add m4/uint32_t.m4.
14986         * modules/sha1: Renamed from modules/sha.
14987         (Files):
14988         Rename lib/sha.h to lib/sha1.h.
14989         Rename lib/sha.c to lib/sha1.c.
14990         Rename m4/sha.m4 to m4/sha1.m4.
14991         (lib_SOURCES): Likewise.
14992         (configure.ac): Rename gl_SHA to gl_SHA1.
14993         (Include): sha.h -> sha1.h.
14994
14995 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14996
14997         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
14998         * m4/sha1.m4: Renamed from sha.m4.
14999         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
15000
15001 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15002
15003         * lib/obstack.h (obstack_empty_p):
15004         Don't assume that chunk->contents is suitably aligned.
15005         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
15006         Likewise. Problem reported by Benno in
15007         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
15008
15009         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
15010         readable.  This could be improved further but it'd take some work.
15011
15012 2004-08-08  Simon Josefsson  <jas@extundo.com>
15013
15014         * modules/xgethostname (Depends-on): Remove exit and error (not
15015         used).
15016
15017         * modules/getpass-gnu: Add getpass.h.
15018         (Depends-on): Add stdbool.
15019         * modules/getpass: Add getpass.h.
15020
15021 2004-08-08  Simon Josefsson  <jas@extundo.com>
15022
15023         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
15024         Check getpass declaration.
15025
15026 2004-08-08  Simon Josefsson  <jas@extundo.com>
15027
15028         * lib/xgethostname.c: Don't include error.h (not used).
15029
15030         * lib/getpass.h: Add.
15031         * lib/getpass.c: Include getpass.h first.
15032
15033 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
15034
15035         * lib/xalloc-die.c: New file.
15036         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
15037         All uses removed.
15038         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
15039         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
15040         xalloc-die.c.
15041         (_, N_, xalloc_die): Move to xalloc-die.c.
15042         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
15043         so that we needn't mess with xalloc_msg_memory_exhausted.
15044
15045         * lib/sha1.h: Renamed from sha.h.
15046         (SHA1_H): Renamed from _SHA_H.
15047         (sha1_ctx): Renamed from sha_ctx.
15048         (sha1_init_ctx): Renamed from sha_init_ctx.
15049         (sha1_process_block): Renamed from sha_process_block.
15050         (sha1_process_bytes): Renamed from sha_process_bytes.
15051         (sha1_finish_ctx): Renamed from sha_finish_ctx.
15052         (sha1_read_ctx): Renamed from sha_read_ctx.
15053         (sha1_stream): Renamed from sha_stream.
15054         (sha1_buffer): Renamed from sha_buffer.
15055         * lib/sha1.c: Likewise; renamed from sha.c.
15056         Do not include <sys/types.h>.
15057         Include <stddef.h> rather than <stdlib.h>.
15058
15059 2004-08-08  Bruno Haible  <bruno@clisp.org>
15060
15061         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
15062         FILESYSTEM_PREFIX_LEN.
15063         * lib/progreloc.c: Likewise.
15064         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
15065
15066 2004-08-06  Simon Josefsson  <jas@extundo.com>
15067
15068         * modules/progname (Depends-on): Don't depend on stdbool.
15069
15070 2004-08-06  Simon Josefsson  <jas@extundo.com>
15071
15072         * modules/getsubopt: New file.
15073         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15074         getsubopt.
15075
15076 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15077
15078         More merge from coreutils.
15079
15080         * m4/utimens.m4, m4/utimecmp.m4: New files.
15081         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
15082         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
15083         prereq.m4, sha.m4: Import changes from coreutils.
15084
15085 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15086
15087         More merge from coreutils.
15088         * modules/raise, modules/readtokens0, modules/utimens:
15089         * modules/utimecmp, module/xnanosleep: New files.
15090         * modules/strftime: Add lib/strftime.h.
15091         Change include from <time.h> to "strftime.h".
15092         * modules/yesno: Add lib/yesno.h.
15093         * modules/backupfile: Remove lib/addext.c.
15094         * modules/euidaccess: Add stat-macros.h.
15095         * modules/canonicalize, modules/euidaccess,
15096         modules/filemode, modules/lchown, modules/makepath,
15097         modules/rmdir, modules/stat: Likewise.
15098
15099 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15100
15101         Merge from tar.
15102         * lib/argp-help.c (make_hol, hol_append): Don't assume that
15103         SIZE_MAX is a valid preprocessor constant.
15104         (__argp_basename): Change from "#ifndef _LIBC"
15105         to "#ifndef __argp_short_program_name", so that
15106         we don't compile these functions for tar.
15107
15108         More merges from coreutils.
15109         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
15110         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
15111         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
15112         * lib/addext.c: Remove; no longer needed.
15113         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
15114         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
15115         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
15116         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
15117         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
15118         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
15119         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
15120         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
15121         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
15122         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15123         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
15124         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
15125         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
15126         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
15127         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
15128         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
15129         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
15130         Import changes from coreutils.
15131
15132 2004-08-05  Simon Josefsson  <jas@extundo.com>
15133
15134         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
15135
15136 2004-08-05  Simon Josefsson  <jas@extundo.com>
15137
15138         * m4/getsubopt.m4: New file.
15139
15140 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15141
15142         Merge from coreutils.
15143
15144         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
15145         * m4/getcwd-path-max.m4: New files.
15146
15147         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
15148         FILESYSTEM_PREFIX_LEN ->
15149         FILE_SYSTEM_PREFIX_LEN.
15150         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
15151         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
15152         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
15153         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
15154
15155         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
15156         prerequisite modules now handle the DOS stuff.
15157         Don't check for unistd.h.
15158
15159 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15160
15161         Merge from coreutils.
15162
15163         * lib/.gdb-history: Remove; this doesn't belong here.
15164
15165         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
15166         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
15167         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
15168         * lib/getcwd.c: New files.
15169
15170         * lib/dirname.h: Include <stdbool.h>.
15171         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
15172         for consistency with POSIX terminology.  All uses changed.
15173         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
15174         (strip_trailing_slashes): Use bool for booleans.
15175         * lib/stripslash.c (strip_trailing_slashes): Likewise.
15176
15177         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
15178         sometimes returns a positive errno value even when it succeeds.
15179         (print_errno_message) [!LIBC]: Fall back on strerror if
15180         __strerror_r fails.
15181
15182         * lib/path-concat.c (mempcpy): Don't define if a system header defines
15183         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
15184         (longest_relative_suffix): New function.
15185         (path_concat): Use it.  Assume first argument is not NULL.
15186         Port to DOS.  Omit redundant separators.
15187         Report an error instead of returning NULL.
15188         Use mempcpy instead of memcpy.
15189         (xpath_concat): Remove: not declared or used.
15190
15191         * lib/same.h: Include <stdbool.h>
15192         (same_name): Return bool, not int.
15193         * lib/same.c (same_name): Likewise.
15194         (errno): Don't declare; we assume C89 or better now.
15195
15196         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
15197         if not already defined.
15198
15199         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
15200         * lib/dup-safer.c (errno): Likewise.
15201
15202 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15203
15204         Merge from coreutils.
15205         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
15206         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
15207         * modules/path-concat: Don't depend on strdup.
15208
15209 2004-08-03  Simon Josefsson  <jas@extundo.com>
15210
15211         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
15212         * lib/progname.h: Don't include stdbool.h.
15213
15214 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15215
15216         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
15217         * MODULES.html.sh (func_all_modules): Remove fatal.
15218
15219 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15220
15221         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
15222
15223 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15224
15225         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
15226         working.
15227
15228 2004-08-02  Simon Josefsson  <jas@extundo.com>
15229
15230         * lib/getsubopt.h: New file, with comments from Bruno Haible.
15231         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
15232         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
15233
15234 2004-08-01  Simon Josefsson  <jas@extundo.com>
15235
15236         * lib/xgetdomainname.c: Include stdlib.h, for free().
15237
15238 2004-07-19  Bruno Haible  <bruno@clisp.org>
15239
15240         * MODULES.html.sh (func_all_modules): Add dummy.
15241
15242 2004-07-16  Simon Josefsson  <jas@extundo.com>
15243
15244         * modules/dummy: New file.
15245
15246 2004-07-16  Simon Josefsson  <jas@extundo.com>
15247
15248         * lib/dummy.c: New file.
15249
15250 2004-07-16  Bruno Haible  <bruno@clisp.org>
15251
15252         * lib/backupfile.h: Add extern "C" for C++.
15253         * lib/closeout.h: Likewise.
15254         * lib/copy-file.h: Likewise.
15255         * lib/findprog.h: Likewise.
15256         * lib/full-write.h: Likewise.
15257         * lib/pathname.h: Likewise.
15258         * lib/progname.h: Likewise.
15259         * lib/stpcpy.h: Likewise.
15260         * lib/stpncpy.h: Likewise.
15261         * lib/strcase.h: Likewise.
15262         * lib/strstr.h: Likewise.
15263         * lib/xalloc.h: Likewise.
15264
15265         * lib/mbswidth.h: Add extern "C" for C++.
15266         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
15267
15268 2004-07-13  Robert Millan  <robertmh@gnu.org>
15269
15270         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
15271
15272 2004-07-09  Simon Josefsson  <jas@extundo.com>
15273
15274         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
15275         failed without this.)
15276
15277 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15278
15279         * modules/chown (Files): Add lib/fchown-stub.c, since
15280         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
15281
15282 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15283
15284         * lib/fchown-stub.c: New file.
15285
15286 2004-06-24  Jim Meyering  <jim@meyering.net>
15287
15288         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
15289
15290 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15291
15292         * modules/argz: Omit "#include".
15293
15294         * MODULES.html.sh (func_all_modules): Add calloc, to match
15295         2004-06-01 addition of calloc module.
15296
15297 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15298
15299         * m4/argz.m4: New file, which is autoupdated from libtool.
15300
15301 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15302
15303         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
15304         libtool.
15305
15306 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15307
15308         * config/srclist-update: Don't insist on "USA." before the
15309         close-comment, as libtool omits the period and puts the */ on a
15310         separate line.
15311         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
15312         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
15313
15314 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
15315
15316         * modules/argz: New file.
15317         * MODULES.html.sh (func_all_modules): Add argz.
15318
15319 2004-06-12  Jim Meyering  <jim@meyering.net>
15320         and  Paul Eggert  <eggert@cs.ucla.edu>
15321
15322         * modules/hash (Files): Add lib/xalloc.h.
15323         * modules/pipe (Depends-on): Add wait-process.
15324         * modules/stat (Depends-on): Add xalloc.
15325         * modules/userspec (Files): Add lib/userspec.h.
15326         * modules/xstrto
15327
15328         Upgrade from gettext-0.13.
15329         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
15330         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
15331         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
15332
15333 2004-06-10  Jim Meyering  <jim@meyering.net>
15334
15335         * lib/calloc.c: New file.
15336
15337 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
15338
15339         * lib/getdate.y (yylex): Allow space between sign and number.
15340         Problem reported by Dan Jacobson.
15341
15342 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15343
15344         Merge from coreutils CVS.
15345
15346         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
15347         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
15348         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
15349         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
15350         xstrtol.m4: Fix copyright date and/or serial number.
15351
15352         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
15353         See if we need an fchown replacement.
15354         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
15355         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
15356         and use the replacement function if we detect either defect.
15357
15358         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
15359         gl_UTIMECMP.
15360
15361 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15362         and  Jim Meyering  <jim@meyering.net>
15363
15364         Merge from coreutils CVS.
15365
15366         * lib/stat-macros.h: New file, with contents from file-type.h
15367         and coreutils' system.h.
15368         * lib/file-type.c: Include "stat-macros.h".
15369         * lib/file-type.h (file_type): Move all macro definitions to new file,
15370         stat-macros.h.
15371
15372         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
15373         Wrap old code with this conditional.
15374         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
15375         function that does not dereference symlinks.
15376         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
15377
15378         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
15379         dependency problems.
15380         (xreadlink): Accept new arg SIZE, for efficiency.
15381         All decls and uses changed.
15382         * lib/xreadlink.h: Include <stddef.h>, for size_t.
15383
15384         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
15385         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
15386
15387         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
15388         sysexits.h.
15389
15390 2004-06-01  Jim Meyering  <jim@meyering.net>
15391
15392         * m4/calloc.m4: New file.
15393
15394 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
15395
15396         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
15397         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
15398         Also, fix a typo in a diagnostic.
15399
15400 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15401
15402         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
15403         or AC_FUNC_REALLOC.
15404
15405 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15406
15407         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
15408         macros to be defined.
15409         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
15410         the allocator returns NULL because the requested size is zero.
15411
15412 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15413
15414         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
15415         var.  Add comment explaining why libc still defines it.  This
15416         merges the following patch from glibc:
15417         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
15418
15419 2004-05-20  Andreas Schwab  <schwab@suse.de>
15420
15421         * m4/free.m4: Replace free if it not known to work, not the other
15422         way round.
15423
15424 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
15425
15426         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
15427         present in glibc since revision 1.1 of this file.
15428         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
15429         obstack_alignment_mask, obstack_alloc, obstack_base,
15430         obstack_blank, obstack_blank_fast, obstack_chunk_size,
15431         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
15432         obstack_grow0, obstack_init, obstack_int_grow,
15433         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
15434         obstack_next_free, obstack_object_size, obstack_ptr_grow,
15435         obstack_ptr_grow_fast, obstack_room): Remove declarations of
15436         nonexistent functions.
15437
15438 2004-05-18  Karl Berry  <karl@gnu.org>
15439
15440         * config/srclist.txt: break link for vasnprintf.c.
15441
15442 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15443
15444         Port obstack to the AS/400, where pointers are 16 bytes wide and
15445         you cannot cast an integer to a valid pointer.  This patch is
15446         currently waiting to be integrated into glibc; see
15447         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
15448
15449         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
15450         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
15451         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
15452         (struct obstack): temp member is now a union of a pointer and
15453         an integer, instead of an integer.  All integer uses changed.
15454         This does not affect the physical layout of struct obstack,
15455         except on hosts (like the AS/400) where the size or alignment of
15456         void * is greater than that of ptrdiff_t.
15457         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
15458         __STDC__)]: Store temporary in pointer member of union, not
15459         integer member.
15460         * lib/obstack.c: Include <stddef.h>, for offsetof.
15461         (struct fooalign): Remove; it doesn't need a name.
15462         (union fooround): Change double to long double, and add void *.
15463         (DEFAULT_ALIGNMENT): Use offsetof to compute.
15464         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
15465         not a macro.  Hence the values are always int; so remove all
15466         casts-to-int in uses.
15467
15468 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15469
15470         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
15471         we can get this patch merged into glibc.
15472
15473 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15474             Paul Eggert  <eggert@cs.ucla.edu>
15475
15476         * m4/argp: Depend on alloca.
15477
15478 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15479             Paul Eggert  <eggert@cs.ucla.edu>
15480
15481         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
15482         freecoding.
15483
15484 2004-05-17  Bruno Haible  <bruno@clisp.org>
15485
15486         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
15487         precision that consists of a '.' followed by an empty digit string.
15488         Patch by Tor Lillqvist <tml@iki.fi>.
15489
15490 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15491
15492         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
15493         for backward compatibility with older code.  We need our own
15494         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
15495         it under some other name, and our alloca.h will define it.
15496
15497 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15498             Derek Price  <derek@ximbiot.com>
15499
15500         * lib/alloca.c: Include <alloca.h>, to get our interface.
15501         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
15502         include <alloca.h> first.  Use C89 prototype for alloca; this
15503         requires including <stddef.h> for size_t.  Use extern "C" if C++.
15504         Use #elif for simplicity, since we can assume C89 now.
15505         Don't try to source the system alloca.h since it will not be found
15506         and to prevent recursively including its replacement.
15507         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
15508         * lib/regex.c: Likewise.
15509
15510 2004-05-16  Derek Price  <derek@ximbiot.com>
15511             Paul Eggert  <eggert@cs.ucla.edu>
15512
15513         getline cleanup.  This changes the getndelim2 API: both order of
15514         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
15515         no delimiter).
15516
15517         * lib/getline.c: Don't include stddef.h or stdio.h, since our
15518         interface does that.
15519         (getline): Always use getdelim, so that we don't have two
15520         copies of this code.
15521         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
15522         if available.
15523         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
15524         (GETNDELIM2_MAXIMUM): New macro.
15525         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
15526         instead of the old practice of delim2==0.  All callers changed.
15527         Return -1 on overflow, instead of returning junk.
15528         Do not set *linesize unless allocation succeeds.
15529         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
15530         that we include sys/types.h.
15531         * lib/getnline.h: Likewise.
15532         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
15533         (getndelim2): Reorder arguments.
15534         * lib/getnline.c (getnline, getndelim):
15535         Don't discard the NMAX argument.
15536         (getnline): Invoke getndelim, to avoid code duplication.
15537         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
15538         of (size_t) -1 by callers of the getnline family.
15539
15540 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15541
15542         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
15543         Check for gettimeofday.
15544         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
15545         Check for settimeofday, stime.
15546
15547 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15548
15549         * lib/nanosleep.c (suspended): Change its type from int to
15550         sig_atomic_t volatile.
15551         (first_call): Make it private to rpl_nanosleep, and have it
15552         be zero initially as that's a bit faster.
15553         (my_usleep): Round up fractional times instead of truncating them,
15554         as this is the usual meaning for 'sleep'.
15555
15556         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
15557         doesn't work.
15558         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
15559         (ENOSYS): Define if not defined.
15560         (settime): Fall back on stime if it exists and settimeofday fails.
15561         But don't bother with fallbacks if a method fails with errno == EPERM.
15562
15563 2004-05-11  Jim Meyering  <jim@meyering.net>
15564
15565         Prior to this change, the save_cwd caller required read access to the
15566         current directory on most systems (ones with the fchdir function).
15567
15568         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
15569         fails, try write-only, and finally, resort to using xgetcwd.
15570
15571 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15572
15573         * lib/obstack.c, obstack.h: Import changes from libc.
15574
15575 2004-04-28  Bruno Haible  <bruno@clisp.org>
15576
15577         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
15578         also implicitly appends .exe to executables.
15579         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
15580         accepts Windows pathnames.
15581         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15582         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15583         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15584         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15585         Reported by Derek Robert Price <derek@ximbiot.com>.
15586
15587 2004-04-21  Karl Berry  <karl@gnu.org>
15588
15589         * config/srclist.txt (localcharset.c): break sync.
15590
15591 2004-04-20  Paul Eggert  <eggert@twinsun.com>
15592
15593         * m4/host-os.m4: Add a copyright notice.
15594
15595 2004-04-20  Jim Meyering  <jim@meyering.net>
15596
15597         Change UTILS_ to gl_ in AC_DEFINE'd names.
15598         Change utils_- and jm_-prefixed variables, too.
15599         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
15600         UTILS_FUNC_MKDIR_TRAILING_SLASH.
15601         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
15602
15603         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
15604         Don't emit trailing blanks.
15605         Also rename jm_-prefixed variables to have gl_ prefix.
15606
15607         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
15608         Also rename jm_-prefixed variables to have gl_ prefix.
15609
15610         * m4/jm-macros.m4: Reflect the renamings.
15611         * m4/prereq.m4: Likewise.
15612
15613 2004-04-20  Jim Meyering  <jim@meyering.net>
15614
15615         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
15616         memory.
15617
15618 2004-04-20  Jim Meyering  <jim@meyering.net>
15619             Bruno Haible  <bruno@clisp.org>
15620
15621         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
15622         memory when realloc fails.
15623
15624 2004-04-19  Jim Meyering  <jim@meyering.net>
15625
15626         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
15627         now that readutmp.c may call `free (0)'.
15628
15629 2004-04-19  Bruno Haible  <bruno@clisp.org>
15630
15631         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
15632         * m4/inttypes_h.m4: Likewise.
15633         * m4/stdint_h.m4: Likewise.
15634         * m4/intmax_t.m4: Likewise.
15635         * m4/uintmax_t.m4: Likewise.
15636
15637 2004-04-18  Jim Meyering  <jim@meyering.net>
15638
15639         * m4/prereq.m4: Don't forbid jm_ prefix.
15640
15641         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
15642         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
15643         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
15644         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
15645         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
15646         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
15647         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
15648         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
15649         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
15650         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
15651         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
15652         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
15653         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
15654         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
15655         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
15656         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
15657         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
15658         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
15659         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
15660
15661 2004-04-18  Jim Meyering  <jim@meyering.net>
15662
15663         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
15664         failure, don't leak memory and do call END_UTMP_ENT.
15665
15666 2004-04-16  Jim Meyering  <jim@meyering.net>
15667
15668         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
15669         coreutils' stat program.
15670         (gl_PREREQ): Don't require jm_PREREQ_STAT.
15671
15672 2004-04-11  Paul Eggert  <eggert@twinsun.com>
15673
15674         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
15675         C89.
15676         (CHAR_BIT): Remove, since we assume C89.
15677         Include <stdint.h> if available, as per current Autoconf CVS advice.
15678
15679 2004-03-31  Jim Meyering  <jim@meyering.net>
15680
15681         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
15682         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
15683         * m4/xalloc.m4: Likewise.
15684
15685 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15686
15687         Merge from coreutils.
15688
15689         * m4/inttostr.m4: New file.
15690         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
15691         Require AM_STDBOOL_H and gl_TIMESPEC instead.
15692         Require gl_CLOCK_TIME.
15693         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
15694
15695 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15696
15697         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
15698         not bool, to be more consistent with Unix conventions.
15699         Suggested by Bruno Haible.
15700
15701         Merge from coreutils.
15702
15703         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
15704         * lib/umaxtostr.c: New files.
15705
15706         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
15707         the usual <time.h> dance.
15708         (get_date): Change signature to support fractional time stamps.
15709         All callers changed.
15710         * lib/getdate.y: Include "getdate.h" first, as we can now
15711         assume C89 and don't need to worry about 'const'.
15712         Similarly, include "unlocked-io.h" near start, not in middle.
15713         Include <limits.h>.
15714         (textint.value): Use long int rather than int.
15715         (textint.digits): Use size_t rather than int.
15716         (BILLION, LOG10_BILLION): New constants.
15717         (parser_control): New member rel_ns.  Members day_ordinal,
15718         time_zone, month, day, hour, minutes, rel_year, rel_month,
15719         rel_day, rel_hour, rel_minutes, rel_seconds
15720         are now long int, not int.  Member seconds is now struct timespec,
15721         not int.  New member timespec_seen.  Members dates_seen, days_seen,
15722         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
15723         not int.
15724         (%union.intval): Now long int, not int.
15725         New member timespec.
15726         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
15727         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
15728         (spec): Now is a timespec or an item list.
15729         (timespec, items): New nonterminals.
15730         (time, rel, relunit, number, get_date):
15731         Add support for fractional seconds.
15732         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
15733         (gmtime, localtime, mktime): Remove decls; not needed with C89.
15734         (to_hour): First arg is now long int, not int.
15735         (to_year): Returns long int, not int.
15736         Don't treat year -70 like 70.
15737         (tm_diff): Returns long int, not int.
15738         (lookup_word): Use bool instead of int when appropriate.
15739         (yylex): Use size_t for count, not int.
15740         Detect overflow when parsing large integer constants.
15741         Add support for fractions.
15742         (get_date): Make pointers 'const' if possible.
15743         Use more-portable code to detect integer overflow.
15744         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
15745         Don't use ctime; it's not reliable if the year has >4 digits.
15746
15747         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
15748         This is for compatibility with BSD.
15749
15750         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
15751         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
15752         From coreutils' system.h.
15753
15754         * lib/userspec.c: Don't include "posixver.h".
15755         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
15756         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
15757         compatible extension.  Simplify code by removing a boolean int
15758         that was always nonzero if a string was nonnull.
15759
15760 2004-03-30  Jim Meyering  <jim@meyering.net>
15761
15762         Merge from coreutils.
15763
15764         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
15765         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
15766         on some systems one must include <grp.h> before it.
15767         Reported by Christian Krackowizer.
15768
15769 2004-03-30  Jim Meyering  <jim@meyering.net>
15770
15771         Merge from coreutils.
15772
15773         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
15774
15775         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
15776         an empty input stream.
15777
15778         * lib/readtokens.c: Include <stdbool.h>.
15779         (readtoken): Use `size_t' rather than int/long.
15780         All callers adjusted.
15781         Use `bool' rather than `int' where appropriate.
15782         Use memset rather than an explicit loop.
15783         Use x2nrealloc rather than xrealloc.
15784         Allow the use of `\0' as a delimiter.
15785         (readtokens): Likewise.
15786         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
15787
15788 2004-03-30  Jim Meyering  <jim@meyering.net>
15789
15790         * m4/realloc.m4: Remove file, since now it does no more than
15791         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
15792         the `configure.ac' section of module/realloc.
15793         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
15794
15795 2004-03-30  Bruno Haible  <bruno@clisp.org>
15796
15797         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
15798         nonnull.
15799
15800 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15801
15802         Merge changes to getloadavg.c from coreutils and Emacs.
15803
15804         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
15805         Define to an expression, not to the empty string.
15806         Include cloexec.h and xalloc.h.
15807         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
15808         Use set_cloexec_flag rather than rolling our own.
15809         * lib/cloexec.c, lib/cloexec.h: New files.
15810
15811 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15812
15813         * m4/cloexec.m4: New file.
15814
15815 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15816
15817         * lib/getopt.h: Sync with libc CVS.
15818
15819 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15820             Bruno Haible  <bruno@clisp.org>
15821
15822         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
15823         mbswidth.
15824
15825 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15826             Bruno Haible  <bruno@clisp.org>
15827
15828         * lib/mbswidth.h: Include <wchar.h> only if
15829         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
15830         <wchar.h>.
15831         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
15832
15833 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15834
15835         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
15836         Sync with libc CVS.
15837         * lib/getopt_int.h: New file, also synced from libc.
15838
15839 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15840
15841         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
15842         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
15843         Bring back getopt.c, getopt.h, getopt1.c.
15844
15845 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15846
15847         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
15848         All uses changed.  Check for sa_sigaction member; this fixes
15849         a bug first reported by Jason Andrade in
15850         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15851
15852 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15853
15854         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
15855         '#if' expressions.  Unlike the code it replaces, it does not
15856         depend on (defined _SC_PAGESIZE).  However, it does depend on
15857         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
15858         first reported by Jason Andrade in
15859         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15860
15861 2004-02-25  Simon Josefsson  <jas@extundo.com>
15862
15863         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
15864
15865 2004-02-25  Simon Josefsson  <jas@extundo.com>
15866
15867         * lib/strdup.h: New file.
15868         * lib/strdup.c: Include it.
15869         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
15870         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
15871
15872 2004-02-23  Karl Berry  <karl@gnu.org>
15873
15874         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
15875         (from fencepost.gnu.org:/gd/gnuorg).
15876
15877 2004-02-23  Karl Berry  <karl@gnu.org>
15878
15879         * config/srclistvars.sh (GNUORG) [karl]: redefine.
15880         * config/srclist.txt: add maintain/standards documents.
15881
15882 2004-02-18  Bruno Haible  <bruno@clisp.org>
15883
15884         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
15885         Reported by Derek Robert Price <derek@ximbiot.com>.
15886
15887 2004-02-16  Karl Berry  <karl@gnu.org>
15888
15889         * config/mkinstalldirs, install-sh: update from automake.
15890
15891 2004-02-06  Karl Berry  <karl@gnu.org>
15892
15893         * m4/po.m4: update from gettext 0.14.1.
15894
15895 2004-02-06  Karl Berry  <karl@gnu.org>
15896
15897         * lib/config.charset: update from gettext 0.14.1.
15898
15899 2004-02-05  Paul Eggert  <eggert@twinsun.com>
15900
15901         Add comments and code, prompted by suggestions from Bruno Haible
15902         for sh-quote.
15903         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
15904         describing the enum quoting_style values.
15905         * lib/quotearg.c (quotearg_alloc): New function.
15906         (quotearg_buffer_restyled): Treat lone { and } as special.
15907         Treat = as special.  Work around bug with older shells
15908         that "see" a '\' that is really the 2nd byte of a multibyte char.
15909         Quote empty string with shell_quoting_style.
15910
15911 2004-02-03  Bruno Haible  <bruno@clisp.org>
15912
15913         * m4/pipe.m4: New file, from GNU gettext.
15914
15915 2004-02-03  Bruno Haible  <bruno@clisp.org>
15916
15917         * lib/pipe.h: New file, from GNU gettext.
15918         * lib/pipe.c: New file, from GNU gettext.
15919
15920 2004-01-27  Bruno Haible  <bruno@clisp.org>
15921
15922         * m4/execute.m4: New file, from GNU gettext.
15923
15924 2004-01-27  Bruno Haible  <bruno@clisp.org>
15925
15926         * lib/execute.h: New file, from GNU gettext.
15927         * lib/execute.c: New file, from GNU gettext.
15928         * lib/w32spawn.h: New file, from GNU gettext.
15929
15930 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15931
15932         Merge from diffutils.
15933
15934         * lib/file-type.c (file_type): Add typed memory objects.
15935         * lib/file-type.h (S_TYPEISTMO): New macro.
15936
15937         * lib/c-stack.h (c_stack_action): Remove argv argument.
15938         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
15939         (die): Don't calculate message unless segv_action returns.
15940         (get_stack_location, min_address_from_argv, max_address_from_argv,
15941         volatile stack_base, volatile_stack_size): Remove.
15942         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
15943         that every segmentation violation is a stack overflow.  (Ouch!)
15944         See Debian bug 136249 (still outstanding) for more info about why
15945         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
15946
15947 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15948
15949         Exit-status fix from coreutils.
15950
15951         Use exit_failure consistently in place of EXIT_FAILURE,
15952         so that program exit statuses are consistent on failure.
15953
15954         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
15955         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
15956         * lib/argmatch.h: Comment fix to match the above.
15957         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
15958         Now a macro referring to exit_failure, instead of a separate
15959         variable.  Include "exitfail.h" to get it.
15960         * lib/xstrtol.h: Include "exitfail.h".
15961         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
15962
15963         * lib/long-options.c (parse_long_options): Use prototype
15964         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
15965         for clarity.
15966
15967 2004-01-21  Jim Meyering  <jim@meyering.net>
15968
15969         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
15970         so as not to conflict with a different-sized __mktime_internal
15971         function in GNU libc.
15972         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
15973         Problem building statically-linked `ls' reported by Michael Brunnbauer.
15974
15975 2004-01-20  Karl Berry  <karl@gnu.org>
15976
15977         * config/config.guess: update from config.
15978
15979         * config/srclistvars.sh: GNUWWWLICENSES for karl.
15980
15981 2004-01-20  Bruno Haible  <bruno@clisp.org>
15982
15983         Safer stack allocation.
15984         * lib/setenv.c: Include allocsa.h.
15985         (alloca): Remove fallback definition.
15986         (freea): Remove macro.
15987         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
15988         instead of freea.
15989
15990 2004-01-20  Bruno Haible  <bruno@clisp.org>
15991
15992         * m4/eealloc.m4: New file, from GNU gettext.
15993
15994 2004-01-20  Bruno Haible  <bruno@clisp.org>
15995
15996         * m4/allocsa.m4: New file, from GNU gettext.
15997
15998 2004-01-20  Bruno Haible  <bruno@clisp.org>
15999
16000         * lib/xallocsa.h: New file, from GNU gettext.
16001         * lib/xallocsa.c: New file, from GNU gettext.
16002
16003 2004-01-20  Bruno Haible  <bruno@clisp.org>
16004
16005         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
16006
16007 2004-01-20  Bruno Haible  <bruno@clisp.org>
16008
16009         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
16010         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
16011         specially.
16012
16013 2004-01-20  Bruno Haible  <bruno@clisp.org>
16014
16015         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
16016         patch.
16017
16018 2004-01-20  Bruno Haible  <bruno@clisp.org>
16019
16020         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
16021
16022 2004-01-20  Bruno Haible  <bruno@clisp.org>
16023
16024         * lib/eealloc.h: New file.
16025
16026 2004-01-20  Bruno Haible  <bruno@clisp.org>
16027
16028         * lib/binary-io.h: Avoid warnings on Cygwin.
16029
16030 2004-01-20  Bruno Haible  <bruno@clisp.org>
16031
16032         * lib/allocsa.h: New file, from GNU gettext.
16033         * lib/allocsa.c: New file, from GNU gettext.
16034
16035 2004-01-18  Karl Berry  <karl@gnu.org>
16036
16037         * doc/gpl.texi, doc/lgpl.texi: new files.
16038
16039 2004-01-18  Karl Berry  <karl@gnu.org>
16040
16041         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
16042         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
16043
16044 2004-01-15  Paul Eggert  <eggert@twinsun.com>
16045
16046         Merge from coreutils.
16047
16048         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
16049         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
16050         (gl_DEFAULT_POSIX2_VERSION): Move
16051         the documentation from 'configure' into 'config.hin',
16052         so that 'configure --help' isn't burdened by it and
16053         we don't have to worry about its formatting there.
16054         Reword the documentation so that it's more succinct
16055         and can be run together into a single paragraph.
16056         * m4/same.m4 (gl_SAME): Check for pathconf.
16057
16058 2004-01-15  Paul Eggert  <eggert@twinsun.com>
16059
16060         Merge from coreutils.
16061
16062         * lib/posixver.c: Include posixver.h.
16063
16064         * lib/same.c: Include <stdbool.h>, <limits.h>.
16065         (_POSIX_NAME_MAX): Define if not defined.
16066         (MIN): New macro.
16067         (same_name): If file names are silently truncated, report
16068         that the file names are the same if they are the same after
16069         the silent truncation.
16070
16071         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
16072         conversion function.
16073         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
16074         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
16075         longer needed.
16076
16077 2004-01-15  Jim Meyering  <jim@meyering.net>
16078
16079         Merge from coreutils.
16080
16081         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
16082         if no library is required.
16083         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
16084         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
16085         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
16086         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
16087         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
16088         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
16089         value, $ac_cv_search_crypt, if it's "none required".
16090         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
16091         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
16092         not gl_FUNC_GETLOADAVG.
16093         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
16094         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
16095
16096 2004-01-15  Jim Meyering  <jim@meyering.net>
16097
16098         Merge from coreutils.
16099
16100         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
16101         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
16102         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
16103
16104         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
16105         optional configure-time default.
16106
16107         * lib/version-etc.c (version_etc_copyright): Update copyright date.
16108
16109         * lib/xreadlink.c (xreadlink): Correct outdated comment.
16110
16111 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
16112
16113         Merge from coreutils.
16114
16115         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
16116         value, $ac_cv_search_nanosleep, if it's "none required".
16117
16118 2004-01-14  Paul Eggert  <eggert@twinsun.com>
16119
16120         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
16121         with like-named macro in fnmatch.c.
16122         (EXT): Use an internal constant instead.
16123
16124         Merge fnmatch patches from glibc.
16125         * lib/fnmatch.c (mbsinit): Remove define.
16126         Add libc_hidden_ver (__fnmatch, fnmatch).
16127         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
16128         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
16129
16130 2004-01-14  Karl Berry  <karl@gnu.org>
16131
16132         * config/install-sh: update from automake.
16133
16134 2004-01-13  Karl Berry  <karl@gnu.org>
16135
16136         * config/install-sh: update from automake.
16137
16138 2004-01-09  Karl Berry  <karl@gnu.org>
16139
16140         * config/install-sh: update from automake.
16141
16142 2004-01-05  Karl Berry  <karl@gnu.org>
16143
16144         * config/config.{sub,guess}: update from config.
16145
16146 2003-12-31  Karl Berry  <karl@gnu.org>
16147
16148         * config/depcomp: update from automake.
16149
16150 2003-12-14  Karl Berry  <karl@gnu.org>
16151
16152         * lib/config.charset: update from gettext-runtime.
16153
16154 2003-12-03  Paul Eggert  <eggert@twinsun.com>
16155
16156         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
16157         Bug reported by Alfred M. Szmidt.
16158
16159 2003-12-03  Bruno Haible  <bruno@clisp.org>
16160
16161         * m4/gettext.m4: Upgrade from gettext-0.13.
16162         * m4/po.m4: Upgrade from gettext-0.13.
16163         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
16164         * m4/intmax.m4: New file, from gettext-0.13.
16165         * m4/printf-posix.m4: New file, from gettext-0.13.
16166
16167 2003-11-29  Karl Berry  <karl@gnu.org>
16168
16169         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
16170
16171 2003-11-25  Paul Eggert  <eggert@twinsun.com>
16172             Bruno Haible  <bruno@clisp.org>
16173
16174         * lib/printf-parse.h: Don't include sys/types.h.
16175         (ARG_NONE): New macro.
16176         (char_directive): Change type of *arg_index fields to size_t.
16177         * lib/printf-parse.c: Don't include sys/types.h.
16178         (SSIZE_MAX): Remove macro.
16179         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
16180         Remove unnecessary overflow check.
16181         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
16182         fields.
16183
16184 2003-11-25  Bruno Haible  <bruno@clisp.org>
16185
16186         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
16187
16188 2003-11-25  Bruno Haible  <bruno@clisp.org>
16189
16190         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
16191         gt_TYPE_SSIZE_T.
16192
16193 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16194
16195         * modules/alloca: Remove dependency on xalloc.
16196
16197 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16198
16199         * lib/alloca.c: Remove dependency on xalloc module.
16200         (xalloc_die): Remove.
16201         (memory_full) [!defined emacs]: New macro.
16202         [!defined emacs]: Don't include xalloc.h.
16203         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
16204         address arithmetic overflows.  Change datatypes a bit to avoid
16205         unnecessary casts.
16206
16207 2003-11-22  Jim Meyering  <jim@meyering.net>
16208
16209         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
16210         s/size/size_t/.
16211
16212 2003-11-21  Karl Berry  <karl@gnu.org>
16213
16214         * config/config.{sub,guess}: update from config.
16215
16216 2003-11-18  Karl Berry  <karl@gnu.org>
16217
16218         * config/config.{sub,guess}: update from config.
16219
16220         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
16221
16222 2003-11-17  Paul Eggert  <eggert@twinsun.com>
16223
16224         * README: Mention that S+T cannot overflow if S is the size of
16225         an existing object and T is sufficiently small.
16226
16227 2003-11-17  Jim Meyering  <jim@meyering.net>
16228
16229         On systems without utime and without a utimes function capable of
16230         dealing with a NULL struct utimbuf* argument, this utime replacement
16231         could -- in unusual circumstances -- leak a file descriptor.
16232         * lib/utime.c: Include <unistd.h> and <errno.h>.
16233         (utime_null): Be sure to close `fd' and to preserve errno.
16234         Reported by Geoff Collyer via Arnold Robbins.
16235
16236 2003-11-17  Bruno Haible  <bruno@clisp.org>
16237
16238         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
16239         (Depends-on): Add xsize.
16240
16241 2003-11-17  Bruno Haible  <bruno@clisp.org>
16242
16243         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
16244
16245 2003-11-17  Bruno Haible  <bruno@clisp.org>
16246
16247         * lib/vasnprintf.c (alloca): Remove fallback definition.
16248         (freea): Remove definition.
16249         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
16250         Reported by Paul Eggert.
16251
16252 2003-11-16  Paul Eggert  <eggert@twinsun.com>
16253             Bruno Haible  <bruno@clisp.org>
16254
16255         Protect against address arithmetic overflow.
16256         * lib/printf-args.h: Include stddef.h.
16257         (arguments): Change type of field 'count' to size_t.
16258         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
16259         'unsigned int' where appropriate.
16260         * lib/printf-parse.h: Include sys/types.h.
16261         (char_directive): Change type of *arg_index fields to ssize_t.
16262         (char_directives): Change type of fields 'count', max_*_length to
16263         size_t.
16264         * lib/printf-parse.c: Include sys/types.h and xsize.h.
16265         (SSIZE_MAX): Define fallback value.
16266         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
16267         instead of 'int' where appropriate. Check a_allocated, d_allocated
16268         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
16269         * lib/vasnprintf.c: Include xsize.h.
16270         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
16271         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
16272         overflow. Avoid wraparound when converting a width or precision from
16273         decimal to binary.
16274
16275 2003-11-16  Bruno Haible  <bruno@clisp.org>
16276
16277         Update from GNU gettext.
16278         * lib/printf-parse.c: Generalize to it can be compiled for wide
16279         strings.
16280         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
16281         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
16282         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
16283         SNPRINTF): New macros.
16284         Don't include <alloca.h> if the file is used inside libintl.
16285         (local_wcslen): New function, for Solaris 2.5.1.
16286         (VASNPRINTF): Use it instead of wcslen.
16287
16288 2003-11-16  Bruno Haible  <bruno@clisp.org>
16289
16290         * lib/xsize.h (xmax): New function.
16291         (xsum, xsum3, xsum4): Declare as "pure" functions.
16292
16293 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16294
16295         * modules/xalloc (Files): Undo latest change, since xalloc.h
16296         no longer needs SIZE_MAX or PTRDIFF_MAX.
16297
16298 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16299
16300         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
16301         gl_PTRDIFF_MAX.
16302
16303 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16304
16305         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
16306         "return", to pacify some unknown compiler.  Problem reported
16307         by Joerg Schilling.
16308
16309 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16310
16311         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
16312         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
16313         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
16314         heuristic is just as accurate as far as we know, and it removes a
16315         dependency on size_max.m4 and ptrdiff_max.m4.
16316
16317 2003-11-11  Bruno Haible  <bruno@clisp.org>
16318
16319         * modules/xsize (Files): Add m4/size_max.m4.
16320         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
16321
16322 2003-11-11  Bruno Haible  <bruno@clisp.org>
16323
16324         * m4/size_max.m4: New file.
16325         * m4/ptrdiff_max.m4: New file.
16326         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
16327         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
16328         (gl_XALLOC): Invoke it.
16329
16330 2003-11-11  Bruno Haible  <bruno@clisp.org>
16331
16332         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
16333         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
16334         defined.
16335
16336 2003-11-10  Paul Eggert  <eggert@twinsun.com>
16337
16338         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
16339         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
16340         rejected some allocations of exactly SIZE_MAX - 2 bytes.
16341         From Bruno Haible.
16342         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
16343         not (size_t) -1, since it's defined here.
16344
16345 2003-11-09  Karl Berry  <karl@gnu.org>
16346
16347         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
16348
16349 2003-11-06  Paul Eggert  <eggert@twinsun.com>
16350
16351         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
16352         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
16353         Reject sizes of exactly SIZE_MAX bytes.
16354         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
16355         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
16356
16357 2003-11-05  Bruno Haible  <bruno@clisp.org>
16358
16359         * lib/xsize.h: Include limits.h, to avoid a possible collision with
16360         SIZE_MAX defined in <limits.h> on Solaris.
16361
16362 2003-11-04  Jim Meyering  <jim@meyering.net>
16363
16364         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
16365         variable names, rather than @VAR@.
16366         * modules/poll: Likewise.
16367
16368 2003-11-04  Bruno Haible  <bruno@clisp.org>
16369
16370         * modules/xsize: New file.
16371         * modules/linebreak: Depend on xsize.
16372         * MODULES.html.sh (func_all_modules): Add xsize.
16373
16374 2003-11-04  Bruno Haible  <bruno@clisp.org>
16375
16376         * m4/xsize.m4: New file.
16377
16378 2003-11-04  Bruno Haible  <bruno@clisp.org>
16379
16380         * lib/xsize.h: New file.
16381         * lib/linebreak.c: Include xsize.h.
16382         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
16383         argument for overflow.
16384         Suggested by Paul Eggert.
16385
16386 2003-11-03  Karl Berry  <karl@gnu.org>
16387
16388         * config/config.{guess,sub}: update from config.
16389
16390 2003-11-03  Jim Meyering  <jim@meyering.net>
16391
16392         * modules/userspec (lib_SOURCES): Add userspec.h.
16393         (Include): Add "userspec.h".
16394         Improve description.
16395
16396 2003-11-03  Jim Meyering  <jim@meyering.net>
16397
16398         * lib/userspec.c: Include "userspec.h".
16399         * lib/userspec.h: New file.
16400
16401 2003-11-03  Bruno Haible  <bruno@clisp.org>
16402
16403         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
16404
16405 2003-11-03  Bruno Haible  <bruno@clisp.org>
16406
16407         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
16408         available, to avoid (extremely rare) race condition.
16409         Suggested by Paul Eggert.
16410
16411 2003-11-02  Karl Berry  <karl@gnu.org>
16412
16413         * config/srclist.txt (vasprintf.c): sync broken, sigh.
16414
16415 2003-10-31  Paul Eggert  <eggert@twinsun.com>
16416
16417         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
16418         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
16419         (read_filesystem_list): Set and use me_type_malloced.
16420         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
16421         whatever the type happens to be), for brevity and consistency.
16422         Check for size calculation overflow on Alphas running OSF/1.
16423
16424 2003-10-31  Jim Meyering  <jim@meyering.net>
16425
16426         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
16427
16428         * lib/linebuffer.c: Include <string.h> for declaration of memset.
16429
16430 2003-10-30  Paul Eggert  <eggert@twinsun.com>
16431             Bruno Haible  <bruno@clisp.org>
16432
16433         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
16434         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
16435
16436 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16437
16438         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
16439         netbsd*-gnu*.  Suggested by Robert Millan.
16440
16441 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16442
16443         * modules/group-member: Depend on stdbool.
16444
16445 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16446
16447         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
16448
16449 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16450
16451         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
16452         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
16453         after the 'gnu' in these cases.  This fixes some bugs in the
16454         previous change, and is based on suggestions by Robert Millan.
16455
16456 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16457
16458         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
16459         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
16460         no longer needed.
16461         * lib/quotearg.c (quotearg_n_options): Use it.
16462         * lib/group-member.c: Include <stdbool.h>.
16463         (free_group_info): Arg is now const *; don't free arg.
16464         (get_group_info): Now returns bool and accepts struct group_info *,
16465         rather than returning a malloc'ed struct group_info *.
16466         All uses changed.  Check for overflow in internal size calculation.
16467
16468         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
16469         rather than xmalloc/xrealloc.
16470         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
16471         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
16472         conformance bug: the old code used a pointer after freeing the
16473         storage that it addressed.
16474         * lib/hash.c (hash_initialize): Simplify the code by using
16475         xalloc_oversized rather than doing it by hand.
16476         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
16477         the buffer preserved.  Use free and xmalloc instead.
16478         * lib/quotearg.c (quotearg_n_options): Likewise.
16479         Use a simpler test for size overflow.  Don't use xalloc_oversized
16480         because unsigned int might be wider than size_t (!); this suggests
16481         that we should switch from unsigned int to size_t for slot numbers.
16482
16483 2003-10-28  Paul Eggert  <eggert@twinsun.com>
16484
16485         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
16486         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
16487         NetBSD kernels.  Requested by Richard Stallman.
16488
16489 2003-10-27  Paul Eggert  <eggert@twinsun.com>
16490
16491         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
16492         to allocate the returned structure.  Do not allocate a subarray,
16493         as x2nrealloc will do that.
16494         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
16495         instead of xnrealloc.
16496         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
16497
16498 2003-10-27  Bruno Haible  <bruno@clisp.org>
16499
16500         * lib/stdbool_.h: Better support for BeOS.
16501
16502 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16503
16504         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
16505         now uses inline.
16506
16507 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16508
16509         * lib/xalloc.h (xalloc_oversized): New static inline function, for
16510         callers that want to do their own size-overflow checking.  Include
16511         <stdbool.h>, since xalloc_oversized returns bool.
16512         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
16513         to use xalloc_oversized.
16514
16515         Add two functions x2realloc, x2nrealloc, for programs that grow
16516         arrays dynamically by doubling their sizes.
16517         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
16518         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
16519         New functions.
16520
16521         Port to C99 semantics for 'inline' of external functions.
16522         Bug reported by Bruno Haible.
16523         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
16524         with the old contents of xnmalloc.
16525         (xnmalloc, xmalloc): Use it.
16526         (xnrealloc_inline): New static inline function,
16527         with the old contents of xnrealloc.
16528         (xnrealloc, xrealloc): Use it.
16529
16530         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
16531         that.
16532
16533 2003-10-26  Karl Berry  <karl@gnu.org>
16534
16535         * config/srclist.txt (COPYING.DOC): no longer available from
16536         /gd/gnuorg; don't know where the ultimate source is.
16537
16538 2003-10-25  Paul Eggert  <eggert@twinsun.com>
16539
16540         Fix several address-calculation bugs in the hash modules,
16541         plus some minor code cleanup.
16542
16543         * lib/hash.h: Include <stdbool.h>, for bool.
16544         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
16545         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
16546         hash_get_n_entries, hash_get_max_bucket_length,
16547         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
16548         hash_rehash): Use size_t rather than unsigned.
16549         * lib/hash.c (struct hash_table, hash_get_n_buckets,
16550         hash_get_n_buckets_used, hash_get_n_entries,
16551         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
16552         hash_get_entries, hash_do_for_each, hash_string, is_prime,
16553         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
16554         Likewise.
16555         (SIZE_MAX): Define if not defined.
16556         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
16557         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
16558         hash_print):
16559         Use const * when possible.
16560         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
16561         (check_tuning): Fix bug: if tuning parameters were very close to
16562         0 or 1, rounding errors could have caused subscript violations.
16563         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
16564         (hash_initialize): Add 'fail:' label
16565         to free table and return NULL, and use it to simplify code.
16566         Use calloc rather than clearing the storage ourself.
16567         (hash_initialize, hash_rehash): Check for arithmetic overflow in
16568         buffer size calculations.
16569         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
16570         Include <stddef.h>, for size_t.
16571         * lib/hash-pjw.c (hash_pjw): Likewise.
16572         Switch to method described by Bruno Haible.
16573         Include <limits.h>, for CHAR_BIT.
16574         (SIZE_BITS): New macro.
16575
16576 2003-10-23  Paul Eggert  <eggert@twinsun.com>
16577
16578         * m4/getline.m4 (AM_FUNC_GETLINE):
16579         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
16580         hosts.  Problem reported by Derek Robert Price in
16581         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
16582         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
16583         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
16584
16585 2003-10-21  Paul Eggert  <eggert@twinsun.com>
16586
16587         * lib/getndelim2.c (getndelim2): When size calculation overflows,
16588         ceiling the allocation at NMAX bytes rather than silently
16589         discarding input bytes before NMAX is reached.  This makes
16590         a difference only if NMAX exceeds SIZE_MAX / 2.
16591
16592         * lib/obstack.c: Merge from glibc.
16593         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
16594         Add libc_hidden_def (_obstack_newchunk).
16595         (_obstack_free) [! defined _LIBC]: Remove.
16596         [defined _LIBC]: Make a strong alias from obstack_free, rather than
16597         a clone of the function body.
16598         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
16599         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
16600
16601         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
16602         glibc.
16603         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
16604         arg to memcpy.
16605
16606         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
16607         (obstack_ptr_grow_fast, obstack_int_grow_fast):
16608         Don't use lvalue casts, as GCC plans to remove support for them
16609         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
16610         was also present in the non-GCC version, indicating that this
16611         code had always been buggy and had never been widely used.
16612         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
16613         Use the fast variant of each macro, rather than copying the
16614         definiens of the fast variant; that way, we'll be more likely to
16615         catch future bugs in the fast variants.
16616
16617 2003-10-20  Bruno Haible  <bruno@clisp.org>
16618
16619         * modules/wait-process: New file.
16620         * MODULES.html.sh (func_all_modules): Add wait-process.
16621
16622 2003-10-20  Bruno Haible  <bruno@clisp.org>
16623
16624         * m4/wait-process.m4: New file.
16625
16626 2003-10-20  Bruno Haible  <bruno@clisp.org>
16627
16628         * lib/wait-process.h: New file, from GNU gettext.
16629         * lib/wait-process.c: New file, from GNU gettext.
16630
16631 2003-10-19  Jim Meyering  <jim@meyering.net>
16632
16633         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
16634         HPUX 10.20.
16635
16636 2003-10-18  Karl Berry  <karl@gnu.org>
16637
16638         * config/config.guess: update from config.
16639
16640 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16641
16642         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
16643         (getgroups): First arg is int, not size_t.
16644         Don't let 'free' mangle errno.
16645
16646 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16647
16648         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
16649
16650 2003-10-16  Karl Berry  <karl@gnu.org>
16651
16652         * config/config.{guess,sub}: update from config.
16653
16654 2003-10-16  Jim Meyering  <jim@meyering.net>
16655
16656         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
16657         memcpy.
16658
16659 2003-10-15  Paul Eggert  <eggert@twinsun.com>
16660
16661         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
16662         (SIZE_MAX): Remove.
16663         (new_exclude, add_exclude_file): Initial size no longer needs to
16664         be a power of 2.
16665         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
16666         our own address arithmetic overflow checking.
16667
16668         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
16669         (fnmatch): Do not alloca more than 2000 wide characters;
16670         instead, use malloc for large buffers.
16671         Check for address arithmetic overflow, and return -1
16672         with errno set to ENOMEM in that case.
16673         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
16674         (NEW_PATTERN): Do not alloca more than 8000 bytes;
16675         instead, return -1.  Check for address arithmetic overflow.
16676
16677 2003-10-14  Paul Eggert  <eggert@twinsun.com>
16678
16679         Handle invalid suffixes and overflow independently, so that
16680         callers can treat them independently as needed.  Fix some bugs in
16681         suffix handling, e.g., "100k@" was not diagnosed as an invalid
16682         suffix for a human-readable blocksize.  The major caller-visible
16683         change is the addition of a new
16684         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
16685         that both overflow and suffix chars were found.
16686
16687         * lib/human.c (humblock): Don't check separately for invalid suffix
16688         char; that is xstrtoumax's job (now that its bug is fixed).
16689         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
16690         INTMAX_MAX]: New macros.
16691         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
16692         TYPE_MAXIMUM): New macros.
16693         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
16694         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
16695         if overflow occurs, as it's what __strtol does and it's more useful
16696         in practice.
16697         (__xstrtol): If __strtol reports some error other than ERANGE,
16698         reflect it to the caller as LONGINT_INVALID.  If it reports
16699         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
16700         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
16701         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
16702         value.
16703         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
16704         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
16705         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
16706         [defined UINTMAX_MAX]: New macros.
16707
16708 2003-10-14  Bruno Haible  <bruno@clisp.org>
16709
16710         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
16711
16712 2003-10-14  Bruno Haible  <bruno@clisp.org>
16713
16714         * m4/sig_atomic_t: New file, from GNU gettext.
16715         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
16716
16717 2003-10-14  Bruno Haible  <bruno@clisp.org>
16718
16719         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
16720         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
16721         Also use volatile where needed.
16722
16723 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16724
16725         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
16726         Change maintainer from Bruno Haible to 'all'.
16727
16728 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16729
16730         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
16731
16732 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16733
16734         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
16735         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
16736         and define in terms of the other primitives.
16737         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
16738         (SIZE_MAX): Define if not already defined.
16739         (array_size_overflow): New function.
16740         (xalloc_die): Abort instead of exiting if 'error' returns.
16741         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
16742         (xmalloc, xrealloc): Use them.
16743         (xcalloc): Check for address arithmetic overflow.
16744         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
16745         a bit faster than strcpy.
16746
16747 2003-10-10  Simon Josefsson  <jas@extundo.com>
16748
16749         * modules/argp (Depends-on): Add restrict and strcase.
16750
16751 2003-10-10  Simon Josefsson  <jas@extundo.com>
16752
16753         * m4/argp.m4: Add AC_C_INLINE.
16754
16755 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16756
16757         Merge getpass from libc, plus a few fixes.
16758
16759         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
16760         Include <stdbool.h>.
16761         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
16762         __fsetlocking to empty.
16763         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
16764         do include <bits/libc-lock.h>.
16765         Do not include <fcntl.h>; not needed.
16766         [_LIBC]: Include <wchar.h>.
16767         (NOTCANCEL_MODE): New macro.
16768         (flockfile, funlockfile) [_LIBC]: New macros.
16769         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
16770         [!_LIBC]: New macros.
16771         (call_fclose): New function.
16772         (getpass): Use it.  Save tty stream separately; this simplifies the
16773         code and makes it more reliable if stdin happens to equal stdout.
16774         Invoke __fsetlocking on tty.
16775         Handle thread cancellation if needed.
16776         Namespace cleanup (use __tcgetattr, __getline).
16777         Use bool for Booleans.
16778         [USE_IN_LIBIO]: Handle wide streams.
16779         [!_LIBC]: Unconditionally do the fseek, since we don't know what
16780         stream might go where.
16781
16782         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
16783         doesn't have to include <stdio.h> before us.
16784         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
16785         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
16786         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
16787         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
16788         if not declared, so that we can use getpass.c code from libc without
16789         rewriting it.
16790         (flockfile, ftrylockfile, funlockfile): New macros.
16791
16792 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16793
16794         * modules/getpass: Depend on stdbool.
16795
16796 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16797
16798         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
16799
16800 2003-10-07  Karl Berry  <karl@gnu.org>
16801
16802         * config/config.{guess,sub}: update from config.
16803
16804 2003-10-06  Jim Meyering  <jim@meyering.net>
16805             Bruno Haible  <bruno@clisp.org>
16806
16807         This lets translators provide better translations for the
16808         "Written by ..." part of --version output.
16809         * lib/version-etc.h: Include stdarg.h.
16810         (version_etc_copyright): Declare as readonly.
16811         (version_etc): Make this function variadic with a NULL-terminated list
16812         of author name strings.
16813         (version_etc_va): New declaration.
16814         * lib/version-etc.c: Include stdarg.h, stdlib.h.
16815         (version_etc_copyright): Declare as readonly.
16816         (version_etc_va): New function. Provide a different translatable string
16817         for each possible number of authors < 10. Abbreviate when there are 10
16818         authors or more.
16819         (version_etc): Make this function variadic. Call version_etc_va.
16820         Suggestion from Gary V. Vaughan.
16821
16822         * lib/long-options.h (parse_long_options): Change prototype: the
16823         authors string is moved to the end and becomes variadic.
16824         * lib/long-options.c: Include stdarg.h.
16825         (parse_long_options): Make this function variadic, too.
16826         Call version_etc_va, not version_etc.
16827
16828 2003-10-06  Bruno Haible  <bruno@clisp.org>
16829
16830         * modules/version-etc-2: Remove file.
16831         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
16832
16833 2003-10-06  Bruno Haible  <bruno@clisp.org>
16834
16835         * modules/fatal-signal: New file.
16836         * MODULES.html.sh (func_all_modules): Add fatal-signal.
16837
16838 2003-10-06  Bruno Haible  <bruno@clisp.org>
16839
16840         * m4/fatal-signal.m4: New file.
16841         * m4/signalblocking.m4: New file, from GNU gettext.
16842
16843 2003-10-06  Bruno Haible  <bruno@clisp.org>
16844
16845         * lib/version-etc-2.h: Remove file.
16846         * lib/version-etc-2.c: Remove file.
16847
16848 2003-10-06  Bruno Haible  <bruno@clisp.org>
16849
16850         * lib/fatal-signal.h: New file, from GNU gettext.
16851         * lib/fatal-signal.c: New file, from GNU gettext.
16852
16853 2003-10-05  Paul Eggert  <eggert@twinsun.com>
16854
16855         * README: Rework advice for preventing empty .o files.
16856         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
16857         not <sys/types.h>.
16858
16859 2003-10-04  Karl Berry  <karl@gnu.org>
16860
16861         * lib/argp*: update from libc.
16862
16863 2003-10-04  Karl Berry  <karl@gnu.org>
16864
16865         * config/config.{guess,sub}: update from config.
16866
16867 2003-10-02  Bruno Haible  <bruno@clisp.org>
16868
16869         * modules/lchown (Include): Add lchown.h.
16870         * modules/time_r (Include): Use "..." syntax.
16871         * modules/xgetdomainname (Include): Add xgetdomainname.h.
16872
16873 2003-10-01  Simon Josefsson  <jas@extundo.com>
16874
16875         * MODULES.html.sh (func_all_modules): Move gethostname from section
16876         'based on' to section 'lacking' POSIX:2001.
16877
16878 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
16879
16880         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
16881         to output mode on the same stream.
16882
16883 2003-09-29  Paul Eggert  <eggert@twinsun.com>
16884
16885         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
16886         Fix arg typo in previous patch.
16887
16888 2003-09-28  Jim Meyering  <jim@meyering.net>
16889
16890         * lib/error.c: Correct cpp indentation.
16891
16892 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16893
16894         * modules/free: New file.
16895
16896 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16897
16898         * m4/free.m4: New file.
16899
16900 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16901
16902         * lib/minmax.h (MIN, MAX)
16903         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
16904         Omit the special code that used __typeof__, since we worry that
16905         it could be more trouble than it's worth.  See:
16906         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
16907         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
16908
16909         * lib/free.c: New file.
16910
16911 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
16912
16913         Trivial fixes to Makefile.am parts of module listings.
16914         * modules/strstr: Append strstr.h to lib_SOURCES.
16915         * modules/strcase: Likewise, for strcase.h.
16916
16917 2003-09-27  Karl Berry  <karl@gnu.org>
16918
16919         * config/mkinstalldirs: update from automake.
16920
16921 2003-09-26  Paul Eggert  <eggert@twinsun.com>
16922
16923         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
16924         (error_tail): Do not loop, reallocating temporary buffer, since
16925         the output cannot contain more wide characters than the input
16926         contains bytes, the size must be big enough already.  This avoids
16927         one potential size overflow calculation.  Check for size overflow
16928         when calculating temporary buffer size.  Free temporary buffer
16929         when done, if it was allocated with malloc; this plugs a memory
16930         leak.  Remove casts from void * to pointers, that are no longer
16931         needed now that we're assuming C89 or better.
16932
16933         Merge error changes from glibc.
16934
16935         * lib/error.c, error.h: Update copyright notice header to match glibc.
16936         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
16937         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
16938         Disable cancellation while printing error.
16939         * lib/error.h: Prepend __ to parameter names.
16940
16941 2003-09-26  Jim Meyering  <jim@meyering.net>
16942
16943         * lib/error.c (error_tail): Move some declarations
16944         into inner scope where the local variables are used.
16945
16946 2003-09-26  Bruno Haible  <bruno@clisp.org>
16947
16948         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
16949         stpncpy().
16950         Don't define stpncpy through config.h; it's now done through stpncpy.h.
16951
16952 2003-09-26  Bruno Haible  <bruno@clisp.org>
16953
16954         * lib/stpncpy.h (gnu_stpncpy): New declaration.
16955         (stpncpy): Define as alias for gnu_stpncpy.
16956         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
16957
16958 2003-09-25  Simon Josefsson  <jas@extundo.com>
16959
16960         * lib/xgetdomainname.h: New file.
16961         * lib/xgetdomainname.c: New file.
16962
16963 2003-09-25  Simon Josefsson  <jas@extundo.com>
16964             Bruno Haible  <bruno@clisp.org>
16965
16966         * modules/getdomainname: New file.
16967         * modules/xgetdomainname: New file.
16968         * MODULES.html.sh (func_all_modules): Add getdomainname,
16969         xgetdomainname.
16970
16971 2003-09-25  Simon Josefsson  <jas@extundo.com>
16972             Bruno Haible  <bruno@clisp.org>
16973
16974         * m4/getdomainname.m4: New file.
16975
16976 2003-09-25  Simon Josefsson  <jas@extundo.com>
16977             Bruno Haible  <bruno@clisp.org>
16978
16979         * lib/getdomainname.h: New file.
16980         * lib/getdomainname.c: New file.
16981
16982 2003-09-25  Karl Berry  <karl@gnu.org>
16983
16984         * lib/argp-fmtstream.c, argp-help.c: update from libc.
16985
16986 2003-09-25  Karl Berry  <karl@gnu.org>
16987
16988         * config/install-sh: update from automake.
16989
16990 2003-09-25  Bruno Haible  <bruno@clisp.org>
16991
16992         * modules/version-etc-2: New file, from modules/version-etc with
16993         modifications.
16994         * MODULES.html.sh (func_all_modules): Add version-etc-2.
16995
16996 2003-09-25  Bruno Haible  <bruno@clisp.org>
16997
16998         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
16999         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
17000
17001 2003-09-24  Simon Josefsson  <jas@extundo.com>
17002
17003         * modules/xgethostname: Add xgethostname.h.
17004
17005 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17006
17007         * lib/linebuffer.c (freebuffer): Don't free the argument, just
17008         the buffer associated with the argument.  Bug reported by
17009         Simon Josefsson.
17010
17011 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17012
17013         * README: Document assumptions that 'int' is at least 32 bits
17014         wide, that integer arithmetic is 2's complement without overflow,
17015         that there are no holes in integer values, that adding sizes of
17016         two nonoverlapping objects can't overflow, and that all-bits-zero
17017         yields scalar zero.  Fix spelling and capitalization typos.
17018
17019 2003-09-19  Karl Berry  <karl@gnu.org>
17020
17021         * lib/argp.h: update from libc.
17022
17023 2003-09-17  Paul Eggert  <eggert@twinsun.com>
17024
17025         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
17026         to avoid spurious warnings like "AC_RUN_IFELSE was called before
17027         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
17028
17029 2003-09-17  Paul Eggert  <eggert@twinsun.com>
17030
17031         * gnulib-tool: Use "test -h", not "test -L", for portability
17032         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
17033         (tags_regexp): Remove, since \| doesn't conform to POSIX.
17034         (sed_extract_prog): Issue s commands one-by-one, rather than
17035         using \| in one s command.
17036
17037 2003-09-16  Paul Eggert  <eggert@twinsun.com>
17038
17039         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
17040         input error, instead of returning NULL the next time we are called
17041         (and therefore losing track of errno).
17042
17043 2003-09-16  Bruno Haible  <bruno@clisp.org>
17044
17045         * gnulib-tool (func_create_testdir): Warn about duplicated
17046         dependencies.
17047
17048 2003-09-15  Paul Eggert  <eggert@twinsun.com>
17049
17050         * modules/argmatch, modules/fatal, modules/obstack,
17051         modules/xalloc, modules/xgethostname: Sort dependencies by
17052         importance, not alphabetically.
17053
17054 2003-09-15  Paul Eggert  <eggert@twinsun.com>
17055
17056         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
17057         fails, so that the caller gets the proper errno.
17058
17059         * lib/readutmp.c (read_utmp): Likewise.
17060         Check for fstat error.  Close stream and free storage
17061         when failing.
17062
17063 2003-09-14  Karl Berry  <karl@gnu.org>
17064
17065         * config/srclist.txt (strdup.c): disable for c89 changes.
17066
17067 2003-09-14  Jim Meyering  <jim@meyering.net>
17068
17069         * lib/getloadavg.c: Correct cpp indentation.
17070         * lib/strdup.c: Likewise.
17071         * lib/vasnprintf.c: Likewise.
17072
17073 2003-09-14  Bruno Haible  <bruno@clisp.org>
17074
17075         * modules/fwriteerror: New file.
17076         * MODULES.html.sh (func_all_modules): Add fwriteerror.
17077
17078 2003-09-14  Bruno Haible  <bruno@clisp.org>
17079
17080         * lib/fwriteerror.h: New file.
17081         * lib/fwriteerror.c: New file.
17082
17083 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17084
17085         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
17086         modules/xgethostname, modules/xalloc: Depend on exit.
17087
17088 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17089
17090         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
17091
17092         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
17093         and AC_MINIX, too, so that their extensions are available.
17094
17095         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
17096         This macro has been superseded by gl_BACKUPFILE.
17097
17098         More patches to assume C89 or better.
17099
17100         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
17101
17102         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
17103         unconditionally.
17104         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
17105         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
17106         Include <string.h>, <stdlib.h> unconditionally.
17107         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
17108         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
17109         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
17110         headers or for string.h.
17111         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
17112         or strtoul.
17113
17114         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
17115         headers.
17116         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
17117         * m4/userspec.m4 (gl_USERSPEC): Likewise.
17118         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
17119         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
17120         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
17121         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
17122         memcpy, memset.
17123         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
17124         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
17125         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
17126         strtol.
17127         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
17128         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
17129         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
17130         strtoul.
17131
17132 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17133
17134         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
17135         * lib/obstack.c [!defined _LIBC]: Likewise.
17136         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
17137         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
17138         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
17139
17140         More changes to assume C89 or better.
17141
17142         * lib/error.c (error_tail): Assume vprintf.
17143
17144         * lib/argmatch.c (getenv): Remove decl.
17145         * lib/progreloc.c (get_full_program_name): Define via prototype.
17146         * lib/setenv.c (clearenv): Likewise.
17147         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
17148         needed.
17149         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
17150         (malloc, memcpy): Remove decls.
17151         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
17152         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
17153         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17154         (memcpy): Remove macro.
17155         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
17156         (__P): Remove.  All uses removed.
17157         (PTR): Remove.  All uses changed to void *.
17158         (CHAR_BIT, NULL): Remove.
17159         (spaces, zeros, memset_space, memset_zero)
17160         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
17161         Remove.
17162         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
17163         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
17164         Define with prototype.
17165         Remove now-unnecessary prototype decl.
17166         (extra_args_spec): Assume ANSI C.  All uses changed.
17167         (extra_args_spec_iso): Remove.
17168         (my_strftime, emacs_strftimeu): Define via prototype.
17169         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
17170         unconditionally.
17171         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
17172         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
17173         (strtoul, strtol): Remove decls.
17174         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
17175         LONG_MAX): Remove.
17176         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17177         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
17178         (LOCALE_PARAM_PROTO): New macro.
17179         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
17180         (INTERNAL (strtol), strtol): Define with a prototype.
17181         (PARAMS): Remove.  All uses removed.
17182         * lib/tempname.c: Include <string.h> unconditionally.
17183         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
17184         * lib/xgethostname.c (main): Define with a prototype.
17185         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
17186         Include <stdlib.h> unconditionally.
17187         (calloc, malloc, realloc, free): Remove decls.
17188         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
17189         Include <stdlib.h> unconditionally.  Sort include file names.
17190         (strtod): Remove.
17191         (xstrtod): Define with a prototype.
17192         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
17193         (strtol, strtoul): Remove decls.
17194
17195 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17196
17197         More patches to assume C89 or better.
17198         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
17199         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
17200         string.h, memchr, STDC_HEADERS.
17201
17202 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17203
17204         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
17205         Include <stdlib.h>, <string.h> unconditionally.
17206         Remove now-unnecessary cast to char *.
17207         * lib/strnlen.c: Include <string.h> unconditionally.
17208         * lib/yesno.c (yesno): Define with a prototype.
17209
17210 2003-09-11  Bruno Haible  <bruno@clisp.org>
17211
17212         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
17213
17214 2003-09-10  Jim Meyering  <jim@meyering.net>
17215
17216         * lib/error.c: Correct indentation of cpp directives.
17217
17218 2003-09-10  Bruno Haible  <bruno@clisp.org>
17219
17220         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
17221         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
17222         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
17223         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
17224         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
17225         <stdlib.h> and <string.h> checks.
17226         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
17227         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
17228
17229 2003-09-10  Bruno Haible  <bruno@clisp.org>
17230
17231         * lib/strcspn.c: Include <string.h> unconditionally.
17232         * lib/strpbrk.c: Include <string.h> unconditionally.
17233         * lib/strstr.c: Include <string.h> unconditionally.
17234         * lib/unicodeio.c: Include <string.h> unconditionally.
17235         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
17236         * lib/unsetenv.c: Likewise.
17237         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
17238         * lib/yesno.c: Include <stdlib.h> unconditionally.
17239         (rpmatch): Add prototype.
17240
17241 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17242
17243         More patches to assume C89 or better.
17244         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
17245         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
17246         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
17247         or for string.h.
17248         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
17249         stdlib.h.
17250         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
17251         C headers.
17252         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
17253         string.h.
17254         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
17255         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
17256         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
17257         or for string.h.
17258         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
17259         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
17260         C headers.
17261         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
17262         memcpy.
17263         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
17264         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
17265         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
17266         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
17267         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
17268         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
17269         string.h, free.
17270         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
17271         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
17272         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
17273         C headers, or for string.h.
17274         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
17275         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
17276         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
17277         headers, memory.h, stdlib.h, string.h, strings.h.
17278         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
17279         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
17280         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
17281         strchr.
17282         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
17283         headers, memory.h, string.h.
17284         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
17285         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
17286         free.
17287         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
17288         headers.
17289         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
17290         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
17291         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
17292         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
17293         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
17294
17295 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17296
17297         More K&R removal.
17298
17299         * lib/acosl.c (main): Use a prototype.
17300         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
17301         tanl.c: Likewise.
17302
17303         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
17304
17305         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
17306         (getopt, etopt_long, getopt_long_only, _getopt_internal)
17307         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
17308         with a prototype.
17309         * lib/getopt.c (const): Remove macro.
17310         Include <string.h> unconditionally.
17311         (my_index): Remove; all uses changed to strchr.
17312         (strlen): Remove decl.
17313         (exchange): Remove forward decl; no longer needed.
17314         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
17315         Define with prototype.
17316         * lib/getopt1.c (const): Remove macro.
17317         (getopt_long, getopt_long_only, main): Define with prototype.
17318
17319         * lib/getugroups.c: Include <string.h> unconditionally.
17320
17321         * lib/getusershell.c: Include <stdlib.h> unconditionally.
17322         (getusershell, setusershell, endusershell, readname, main):
17323         Define with prototypes.
17324
17325         * lib/group-member.c: Include group-member.h first.
17326         Include <stdlib.h> unconditionally.
17327
17328         * lib/hard-locale.c: Include hard-locale.h first.
17329         Include <stdlib.h>, <string.h> unconditionally.
17330
17331         * lib/hash.c (free, malloc): Remove decls.
17332         Include <stdlib.h> unconditionally.
17333
17334         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
17335         (getenv): Do not declare.
17336
17337         * lib/idcache.c: Include <string.h> unconditionally.
17338
17339         * lib/long-options.c: Include long-options.h first, to test interface.
17340         Include <stdlib.h> unconditionally.
17341
17342         * lib/makepath.c: Include makepath.h first, to test interface.
17343         Include <stdlib.h> and <string.h> unconditionally.
17344
17345         * lib/linebuffer.c: Include <stdlib.h>.
17346         (free): Remove decl.
17347
17348         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
17349         stddef.h. rpl_malloc returns void *, not char *.
17350         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
17351         prototype.
17352
17353         * lib/md5.h: Include <limits.h> unconditionally.
17354         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
17355         (__P): Remove; all uses removed.
17356         * lib/md5.c: Include "md5.h" first.
17357         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
17358         md5_buffer, md5_process_bytes, md5_process_block):
17359         Define with prototypes.
17360         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
17361         * lib/sha.c: Include "sha.h" first.
17362         Include <stdlib.h>, <string.h> unconditionally.
17363
17364         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
17365         * lib/memcmp.c (__ptr_t): Likewise.
17366         * lib/memrchr.c (__ptr_t): Likewise.
17367         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
17368         Include <string.h> unconditionally.
17369         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
17370         * lib/memchr.c: Include <stdlib.h> unconditionally.
17371         * lib/memchr.c (LONG_MAX): Remove.
17372         * lib/memrchr.c (LONG_MAX): Likewise.
17373         * lib/memchr.c (__memchr): Define via a prototype.
17374         * lib/memrchr.c (__memrchr): Likewise.
17375         * lib/memcmp.c (__P): Remove, and remove all uses.
17376         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
17377         Remove forward decls; no longer needed.
17378         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
17379         Use types required by C89 in prototype.
17380
17381         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
17382         * lib/savedir.c: Likewise.
17383         * lib/mkdir.c (free): Remove decl.
17384         * lib/rmdir.c (rmdir): Define with a prototype.
17385         * lib/savedir.c: Include savedir.h first, to test interface.
17386
17387         * lib/mktime.c (STDC_HEADERS): Remove.
17388         Include <stdlib.h>, <string.h> unconditionally.
17389
17390         * lib/modechange.c: Include <stdlib.h> unconditionally.
17391         (malloc): Remove decl.
17392
17393         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
17394         (free): Remove decl.
17395
17396         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
17397         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
17398         (This type really should be intptr_t, but that's a C99ism.)
17399         (_obstack_memcpy): Remove: all uses changed to memcpy.
17400         Include <string.h> unconditionally.
17401         (struct obstack): Assume __STDC__ for types of members
17402         chunkfun, freefun, extra_arg.
17403         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
17404         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
17405         obstack_begin, obstack_specify_allocation,
17406         obstack_specify_allocation_with_arg, obstack_chunkfun,
17407         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
17408         Remove unprototyped decls and the macros that use them.
17409         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
17410         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
17411         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
17412         (defined __STDC__ && __STDC__)]:
17413         Remove nonprototyped code.
17414         Include <stdlib.h> unconditionally.
17415         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
17416         _obstack_allocated_p, _obstack_free, obstack_free,
17417         _obstack_memory_used, print_and_abort):
17418         Define using prototypes.
17419         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
17420         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
17421         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
17422         obstack_next_free, obstack_object_size, obstack_room) [0]:
17423         Remove unused, unprototyped code.
17424
17425         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
17426
17427         * lib/physmem.c (physmem_total, physmem_available, main): Define
17428         with prototypes.
17429
17430         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
17431         (main): Define with a prototype.
17432
17433         * lib/posixver.c (getenv): Remove decl.
17434
17435         * lib/putenv.c (malloc): Returns void *, not char *.
17436         Include <string.h> unconditionally.
17437         (strchr, memcpy, NULL): Do not define.
17438
17439         * lib/readtokens.c: Include readtokens.h first, to test interface.
17440         Include <stdlib.h>, <string.h> unconditionally.
17441         (init_tokenbuffer): Define with a prototype.
17442
17443         * lib/regex.c (PARAMS): Remove.  All uses removed.
17444         All uses of _RE_ARGS removed, too.
17445         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17446         unconditionally.
17447         (bzero): Assume memset exists.
17448         (memcmp, memcpy, NULL): Remove.
17449         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
17450         char, or assignments to local vars of type signed char.
17451         (init_syntax_once, PREFIX(extract_number_and_incr),
17452         PREFIX(print_partial_compiled_pattern),
17453         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
17454         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
17455         PREFIX(regex_grow_registers), PREFIX(regex_compile),
17456         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
17457         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
17458         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
17459         wcs_compile_range, byte_compile_range, truncate_wchar,
17460         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
17461         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
17462         count_mbs_length, wcs_re_match_2_internal,
17463         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
17464         PREFIX(alt_match_null_string_p),
17465         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
17466         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
17467         regfree, PREFIX(extract_number)): Define with prototype.  Remove
17468         now-unnecessary declaration, if any.
17469         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
17470         regcomp, regexec):
17471         Remove now-unnecessary casts among pointer types.
17472         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
17473
17474         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
17475         (free): Remove decl.
17476
17477         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
17478
17479         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
17480         (free): Remove decl.
17481
17482         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
17483         * lib/xgetcwd.c: Likewise.
17484
17485         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
17486         (free): Remove decl.
17487
17488         * lib/strchrnul.c (strchrnul): Define with a prototype.
17489         Fix bug: c_in was not converted to char before searching.
17490
17491         The following changes are not K&R related:
17492
17493         * lib/group-member.h: Include <sys/types.h>, so that this file is
17494         self-contained.
17495         * lib/makepath.h: Likewise.
17496
17497         * lib/getusershell.c (readname, default_index, line_size, readname):
17498         Use size_t, not int, for sizes.
17499         (readname): If the size overflows, report an error instead of
17500         looping forever.
17501
17502 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17503
17504         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
17505         libc.
17506
17507 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17508
17509         * README: New section: portability guidelines.
17510
17511 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17512
17513         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
17514         C89 spec.
17515
17516 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17517
17518         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
17519
17520 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17521
17522         Assume C89 or better; remove K&R cruft.
17523         A few of these changes were first proposed by Derek Robert Price
17524         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
17525
17526         * lib/addext.c: Include <string.h> unconditionally.
17527         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
17528         Don't declare getenv or malloc.
17529
17530         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
17531         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
17532         (NULL): Remove.
17533         (find_stack_direction, alloca): Use prototypes.
17534
17535         * lib/atexit.c (atexit): Define using a prototype.
17536
17537         * lib/basename.c, dirname.c, stripslash.c:
17538         Include <string.h> unconditionally.
17539
17540         * lib/bcopy.c: Include <stddef.h>.
17541         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
17542
17543         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
17544
17545         * lib/error.h (error, error_at_line, error_print_progname)
17546         [! (defined (__STDC__) && __STDC__)]: Remove decls.
17547         * lib/error.c: Include error.h first, to check interface.
17548         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17549         (VA_START): Remove; all uses changeed to va_start.
17550         (exit, strerror): Remove decls.
17551         (error_print_progname): Prototype uncondionally.
17552         Don't include <errno.h>; no longer needed.
17553         (private_strerror): Remove.
17554         (error_tail): Always define.
17555         (error, error_at_line): Assume C89 or better; always use prototypes.
17556         * lib/fatal.c: Include "fatal.h" first, to test interface.
17557         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17558         (VA_START): Remove; all uses changed to va_start.
17559         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
17560         this case.
17561         (exit): Remove decl.
17562         (fatal): Prototype unconditionally.  Assume va_start works.
17563         Abort at end, to pacify gcc.
17564
17565         * lib/euidaccess.c (main): Define with a prototype.
17566
17567         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
17568
17569         * lib/exitfail.c: Include <stdlib.h> unconditionally.
17570
17571         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
17572         prototypes.
17573         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
17574         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
17575         (getenv): Remove decl.
17576         (fnmatch): Define using a prototype.
17577         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
17578         (FCT): Define using a prototype.
17579
17580         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
17581
17582         * lib/gethostname.c: Include <stddef.h>.
17583         (gethostname): Define with prototype.  Length is size_t, not int.
17584
17585 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17586
17587         Assume C89 or better; remove K&R cruft.
17588         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
17589         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
17590         string.h, getenv, malloc.
17591         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
17592         headers.
17593         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
17594         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
17595         do not check for strerror.
17596         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
17597         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
17598         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
17599         do not check for doprnt or vprintf.
17600         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
17601         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
17602
17603 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17604
17605         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
17606         getversion.c should have been removed then, but was accidentally
17607         preserved.
17608
17609         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
17610         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
17611
17612 2003-09-08  Karl Berry  <karl@gnu.org>
17613
17614         * config/config.sub, config.guess, srclistvars.sh: update from savannah
17615                 config, forget about prep.
17616
17617         * config/depcomp, missing: update from automake.
17618
17619 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17620
17621         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
17622         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17623
17624 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17625
17626         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
17627         copy_tm_result.  Bug reported by Simon Josefsson in
17628         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17629
17630 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17631
17632         * m4/time_r.m4: New file.
17633         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
17634         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
17635         is. Check for timegm declaration.
17636         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
17637         Do not check for gmtime_r.
17638         Replace mktime if __mktime_internal does not exist and if mktime
17639         hasn't been replaced already.
17640
17641 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17642
17643         * lib/time_r.c, lib/time_r.h: New files.
17644
17645         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
17646         __localtime_r.
17647         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
17648         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
17649
17650         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
17651         __gmtime_r.
17652         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
17653         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
17654         Include <time_r.h>.
17655
17656         * lib/timegm.c: Switch to glibc implementation, with the following
17657         changes:
17658         [defined HAVE_CONFIG_H]: Include <config.h>.
17659         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
17660         (__mktime_internal) [!defined _LIBC]: New decl.
17661         (__gmtime_r) [!defined _LIBC]: New macro and function.
17662         (timegm): Use a prototype, since gnulib assumes C89.
17663         Do not bother declaring tmp to be const, as it's not really usefu.
17664         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
17665         (timegm): Declare only if HAVE_DECL_TIMEGM.
17666
17667 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17668
17669         * MODULES.html.sh (func_all_modules): Add time_r.
17670         * modules/time_r: New file.
17671         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
17672         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
17673
17674 2003-09-03  Paul Eggert  <eggert@twinsun.com>
17675
17676         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
17677         Bug reported by Lute Kamstra in
17678         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
17679
17680         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
17681         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
17682         course with correspondingly smaller numbers for tomorrow and
17683         yesterday.  From Tadayoshi Funaba.  Originally installed into
17684         sh-utils on 1999-08-07, but the patch got lost (I guess during the
17685         coreutils merge?).
17686
17687 2003-08-31  Simon Josefsson  <jas@extundo.com>
17688
17689         * modules/timegm: New file.
17690         * MODULES.html.sh (func_all_modules): Add timegm.
17691
17692 2003-08-31  Simon Josefsson  <jas@extundo.com>
17693
17694         * m4/timegm.m4: New file.
17695
17696 2003-08-31  Simon Josefsson  <jas@extundo.com>
17697
17698         * lib/timegm.h: New file.
17699         * lib/timegm.c: New file.  Based on
17700         wget-1.8.2/src/http.c:mktime_from_utc.
17701
17702 2003-08-31  Karl Berry  <karl@gnu.org>
17703
17704         * lib/argp.h: update from libc.
17705
17706 2003-08-28  Bruno Haible  <bruno@clisp.org>
17707
17708         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
17709         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
17710         followed by '#define fnmatch fnmatch_posix' gives an error.
17711
17712 2003-08-28  Bruno Haible  <bruno@clisp.org>
17713
17714         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
17715         warning on QNX, which defines O_BINARY to 000000.
17716
17717 2003-08-27  Jim Meyering  <jim@meyering.net>
17718
17719         * m4/mkstemp.m4: Require that the system mkstemp be able to create
17720         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
17721         would fail after 32.  Reported by Danny Levinson.  Details here:
17722         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
17723
17724 2003-08-24  Bruno Haible  <bruno@clisp.org>
17725
17726         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
17727         MSVC7 <stdio.h> is included later.
17728
17729 2003-08-22  Simon Josefsson  <jas@extundo.com>
17730
17731         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
17732
17733 2003-08-20  Karl Berry  <karl@gnu.org>
17734
17735         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
17736
17737 2003-08-20  Bruno Haible  <bruno@clisp.org>
17738
17739         * modules/progname: New file.
17740         * MODULES.html.sh (func_all_modules): Add progname.
17741
17742 2003-08-20  Bruno Haible  <bruno@clisp.org>
17743
17744         * lib/progname.h: New file, from GNU gettext.
17745         * lib/progname.c: New file, from GNU gettext.
17746         * lib/progreloc.c: New file, from GNU gettext.
17747
17748 2003-08-19  Jim Meyering  <jim@meyering.net>
17749
17750         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
17751         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
17752
17753 2003-08-19  Bruno Haible  <bruno@clisp.org>
17754
17755         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
17756         more.
17757
17758 2003-08-19  Bruno Haible  <bruno@clisp.org>
17759
17760         * lib/xstrdup.c: Assume <string.h> exists.
17761
17762 2003-08-18  Paul Eggert  <eggert@twinsun.com>
17763
17764         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
17765         in makefile rules.
17766
17767 2003-08-18  Jim Meyering  <jim@meyering.net>
17768
17769         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
17770         * m4/lib-ld.m4: Likewise.
17771
17772 2003-08-18  Jim Meyering  <jim@meyering.net>
17773
17774         * lib/setenv.h: Indent nested cpp directive.
17775         * lib/vasnprintf.c: Remove trailing blanks.
17776
17777 2003-08-17  Simon Josefsson  <jas@extundo.com>
17778
17779         * modules/xstrndup: New file.
17780         * MODULES.html.sh (func_all_modules): Add xstrndup.
17781
17782 2003-08-17  Simon Josefsson  <jas@extundo.com>
17783
17784         * modules/argp: Fix autoconf macro name. Add more dependencies.
17785
17786 2003-08-17  Simon Josefsson  <jas@extundo.com>
17787
17788         * m4/xstrndup.m4: New file.
17789
17790 2003-08-17  Simon Josefsson  <jas@extundo.com>
17791
17792         * m4/argp.m4: New file.
17793
17794 2003-08-17  Simon Josefsson  <jas@extundo.com>
17795             Bruno Haible  <bruno@clisp.org>
17796
17797         * lib/xstrndup.h: New file.
17798         * lib/xstrndup.c: New file.
17799
17800 2003-08-17  Bruno Haible  <bruno@clisp.org>
17801
17802         * modules/strndup (Files, Include): Add lib/strndup.h.
17803
17804 2003-08-17  Bruno Haible  <bruno@clisp.org>
17805
17806         * modules/euidaccess (Files): Add lib/euidaccess.h.
17807
17808 2003-08-17  Bruno Haible  <bruno@clisp.org>
17809
17810         * lib/strndup.h: New file.
17811
17812 2003-08-17  Bruno Haible  <bruno@clisp.org>
17813
17814         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
17815         like AC_GNU_SOURCE.
17816         * modules/extensions (configure.ac): Comment out the invocation of
17817         gl_USE_SYSTEM_EXTENSIONS.
17818
17819 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17820
17821         Merges from coreutils, etc.
17822         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
17823         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
17824         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
17825         fixing a typo.
17826         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
17827         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
17828
17829 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17830
17831         Document merge from coreutils.
17832         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
17833         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
17834         * modules/utime: Add m4/utimes-null.m4.
17835
17836 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17837
17838         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
17839         space, undoing this 2003-08-12 change:
17840         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17841
17842 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17843
17844         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
17845         strtoul.c from libc, undoing this 2003-08-12 change:
17846         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17847
17848 2003-08-16  Jim Meyering  <jim@meyering.net>
17849
17850         Merges from coreutils.
17851         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
17852         prefix.  Adjust cache variables similarly.  Create 500 rather than
17853         just 300 files, to exercise bug on Darwin6.5, too.
17854         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
17855         $missing_dir.
17856         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
17857         AM_SYS_POSIX_TERMIOS.
17858         Reported by mkc@mathdogs.com.
17859         Also change use of $am_cv_sys_posix_termios
17860         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
17861         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
17862         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
17863         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
17864         in /proc/mounts until it finds one with matching device number.  This
17865         is unnecessary when the FILE argument *is* a mount point.  No stat call
17866         is necessary in that case.  So, disable the statvfs-testing code on
17867         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
17868         as RedHat bug# 84846.
17869         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17870         to 1MB, so as not to render systems with no stack size limit (e.g.,
17871         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17872         Include <unistd.h>.  On some systems,
17873         it is required for the definition of _SC_PAGESIZE.
17874
17875 2003-08-16  Jim Meyering  <jim@meyering.net>
17876
17877         Merge from coreutils.
17878         * lib/xstrtoimax.c: #else #if -> #elif.
17879         * lib/xstrtoumax.c: Likewise.
17880
17881 2003-08-16  Jim Meyering  <jim@meyering.net>
17882
17883         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
17884         * m4/utimes.m4: Removed.
17885         * m4/utimes-null.m4: Renamed from utimes.m4.
17886
17887         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17888         to 1MB, so as not to render systems with no stack size limit (e.g.,
17889         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17890         Include <unistd.h>.  On some systems,
17891         it is required for the definition of _SC_PAGESIZE.
17892
17893 2003-08-16  Jim Meyering  <jim@meyering.net>
17894         and Paul Eggert  <eggert@cs.ucla.edu>
17895
17896         Merges from coreutils, etc.
17897
17898         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
17899         using the latest version from cvs.  This avoids problems with #line
17900         directives using a vendor (Sun) compiler.
17901         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
17902         Don't set GETGROUPS_LIB here; now it's
17903         done via getgroups.m4's wrapper function.
17904         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
17905         rather than just in sh-util/configure.in, so that the
17906         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
17907         same.
17908         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
17909         AC_FUNC_GETLOADAVG where to find getloadavg.c.
17910         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
17911         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
17912         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
17913         Remove code that is now done by the newly-required macros.
17914         Append $(EXEEXT) to DF_PROG.
17915         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
17916         Do not invoke or require the following here,
17917         since prereq.m4 or some gnulib .m4 now does this for us:
17918         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
17919         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
17920         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
17921         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
17922         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
17923         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
17924         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
17925         AC_FUNC_OBSTACK.
17926         Do not replace the following functions, as this is now the job
17927         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
17928         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
17929         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
17930         atexit getpass, strdup, getpagesize.
17931         Replace 'raise'.
17932         Do not check for the following functions, as this is now the job
17933         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
17934         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
17935         setregid.
17936         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
17937         Check for sys/sysctl.h.
17938         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
17939         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
17940         of checking for ssize_t ourselves.
17941
17942         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
17943         Require every macro that gnulib/modules/* suggests for us.
17944         (jm_PREREQ_ADDEXT): New macro.
17945         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
17946         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
17947
17948         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
17949         (gl_PHYSMEM): Use it.
17950         Also check for `table' function.
17951         Check for new headers and functions.
17952         Add check for sys/sysmp.h.
17953         With suggestions from Kaveh Ghazi.
17954         Ignore headers that are present but cannot be compiled.  This
17955         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
17956         C 5.4.
17957
17958 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17959
17960         Document merge from coreutils.
17961         * modules/userspec: Depend on posixver.
17962         * modules/strftime: Depend on tzset.
17963
17964 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17965
17966         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
17967         rather than tab, after '#' in shell-script copyright notices.
17968         Suggested by Bruno Haible.
17969
17970 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17971
17972         * config/srclist-update: Use three spaces, rather than tab, after '#'
17973         in shell-script copyright notices.  Suggested by Bruno Haible.
17974         Remove unnecessary parenthesization in regular expression.
17975
17976 2003-08-15  Jim Meyering  <jim@meyering.net>
17977
17978         Merge from coreutils.
17979         * lib/xgethostname.c: Include <stdlib.h>.
17980         (xghostname): Don't exit for anything other than memory-related
17981         failure; just return NULL.
17982         * lib/userspec.c: Include "posixver.h".
17983         (parse_user_spec): Accept `.' as a separator only
17984         in pre-POSIX-200112 mode.
17985         * lib/strtoimax.c: Use #elif rather than #else #if.
17986         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
17987         Remove function, now that we can rely on a working tzset function.
17988         [!_LIBC]: Ensure that the required autoconf test has been run.
17989         [!defined _NL_CURRENT && HAVE_STRFTIME]:
17990         Use underlying_strftime for %r.
17991         * lib/sha.c: Merge in some clean-up and optimization changes from
17992         glibc.
17993         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
17994         Ensure that it is a multiple of 64.
17995         Rearrange loop exit tests so as to avoid performing an
17996         additional fread after encountering an error or EOF.
17997         * lib/realloc.c: Update copyright date.
17998
17999 2003-08-15  Jim Meyering  <jim@meyering.net>
18000         and Paul Eggert  <eggert@twinsun.com>
18001
18002         Merge from coreutils.
18003         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
18004         member but strut utmpx does not.  Needed for AIX 4.3.3.
18005         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
18006
18007 2003-08-15  Jim Meyering  <jim@meyering.net>
18008         and Paul Eggert  <eggert@cs.ucla.edu>
18009
18010         Merges from coreutils, etc.
18011         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
18012         Require gl_FUNC_TZSET_CLOBBER.
18013         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
18014         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
18015         members.
18016
18017 2003-08-14  Paul Eggert  <eggert@twinsun.com>
18018
18019         Help the merge from coreutils.
18020         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
18021         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
18022         * m4/tzset.m4: Use it too.
18023
18024 2003-08-14  Paul Eggert  <eggert@twinsun.com>
18025
18026         * modules/tzset: New file.
18027
18028 2003-08-14  Jim Meyering  <jim@meyering.net>
18029
18030         Merges from coreutils.
18031         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
18032         variable names, rather than @FNMATCH_H@.
18033         * modules/alloca: Likewise for $(ALLOCA_H).
18034
18035         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
18036         the three copies of the literal target, `fnmatch.h'.
18037         * modules/alloca (alloca.h): Likewise.
18038
18039 2003-08-14  Jim Meyering  <jim@meyering.net>
18040
18041         Merge from coreutils.
18042         * m4/tzset.m4: New file.
18043         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
18044         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
18045         otherwise, AIX 5.1 systems would end up using the latter.
18046         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
18047         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
18048         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
18049         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
18050
18051 2003-08-14  Jim Meyering  <jim@meyering.net>
18052
18053         Merge from coreutils.
18054         * lib/obstack.h: Whitespace changes.
18055         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
18056         and xcalloc return values.
18057         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
18058         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
18059         hang on OSF/1 5.1 for DIR on both local and remote file systems.
18060         Reported by (and fix confirmed by) Nelson H. F. Beebe.
18061         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
18062         error from mntctl.
18063         Use mntctl's return value to drive the entry-processing loop, since
18064         we can't rely on the value of the vmt_length member in the last
18065         entry.  On some systems doing so could result in exhausting
18066         virtual memory.  Based in part on a patch from Mike Jetzer.
18067
18068 2003-08-14  Jim Meyering  <jim@meyering.net>
18069         and Paul Eggert  <eggert@twinsun.com>
18070
18071         Merges from coreutils, plus other fixes.
18072         * lib/physmem.c: Merge in portability changes from gcc/libiberty
18073         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
18074         for credits and details.  Thanks to Kaveh Ghazi for helping
18075         to keep these files in sync.
18076         (ARRAY_SIZE): Define it.
18077         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
18078         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
18079         (memcasecmp): Don't assume size_t fits in unsigned int.
18080         Remove casts and duplicate code.
18081         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
18082         (memcpy): Remove definition.
18083         Merge in some clean-up and optimization changes from glibc.
18084         [BLOCKSIZE]: Move definition to top of file.
18085         Ensure that it is a multiple of 64.
18086         Rearrange loop exit tests so as to avoid performing an
18087         additional fread after encountering an error or EOF.
18088         * lib/md5.h (md5_uintptr): Define.
18089         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
18090         return to the initial working directory.  Preserve errno
18091         for caller.
18092         * lib/idcache.c: Include "xalloc.h".
18093         (xmalloc, xrealloc): Remove decls.
18094         (getuser): Remove casts no longer required in C89.
18095         * lib/human.c: Include stdio.h, for sprintf.
18096         * lib/group-member.c: Include "xalloc.h".
18097         (xmalloc, xrealloc): Remove decls.
18098         (get_group_info): Remove casts no longer required in C89.
18099         * lib/getusershell.c (readname): Remove casts no longer required in
18100         C89.
18101         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
18102         * lib/getline.c: Whitespace fix, from coreutils.
18103
18104 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18105
18106         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
18107         Check for isascii.
18108
18109         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18110         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18111         Undo previous (whitespace-only) change.
18112
18113 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18114
18115         * lib/exclude.c: Include <ctype.h>
18116         (IN_CTYPE_DOMAIN): New macro.
18117         (is_space): New fn.
18118         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
18119         and empty lines.
18120
18121         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18122         Undo previous (whitespace-only) change.
18123
18124 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18125
18126         * config/srclist-update: Change update back to the old behavior,
18127         leaving whitespace alone.  Use one 'sed' command rather than a
18128         pipeline.
18129         (fixlicense): Now a variable, not a function.
18130         (remove_trailing_blanks): Remove.
18131         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
18132         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18133         Undo previous (whitespace-only) change.
18134
18135 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18136
18137         Merge from coreutils.
18138         * modules/euidaccess: Add lib_SOURCES, include for new
18139         file euidaccess.h
18140
18141 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18142
18143         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18144         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18145         Normalize leading white space and remove trailing white space.
18146
18147         Merge from coreutils
18148         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
18149
18150         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
18151         0.12.1.  These files are now being upgraded automatically by
18152         ../config/srclist-update.
18153
18154 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18155
18156         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18157         Normalize leading white space and remove trailing white space.
18158         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
18159         notice, as per ../config/srclist-update.
18160
18161         Merge from coreutils.
18162         * lib/euidaccess.h: New file.
18163         * lib/euidaccess.c: Include it.
18164         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
18165         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
18166         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
18167
18168 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18169
18170         * config/srclist-update: Add copyright notice.
18171         (remove_id_lines, remove_trailing_blanks): New constants.
18172         (fixfile): Use them to normalize spacing a bit in copied files.
18173         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18174         Normalize leading white space and remove trailing white space.
18175
18176         * config/texinfo.tex: Sync with texinfo.
18177
18178         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
18179         strtoul.c from libc, to merge coreutils whitespace changes.
18180
18181         * config/srclist.txt: Get the following m4 files from gettext:
18182         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
18183         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
18184         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
18185         wint_t.m4.
18186
18187 2003-08-12  Karl Berry  <karl@gnu.org>
18188
18189         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
18190         been made.
18191
18192 2003-08-11  Paul Eggert  <eggert@twinsun.com>
18193
18194         * modules/gnu-source, m4/gnu-source.m4:
18195         Remove; we're assuming Autoconf 2.54 or later now.
18196         Suggested by Bruno Haible.
18197         * MODULES.html.sh (func_all_modules): Remove gnu-source.
18198
18199 2003-08-11  Bruno Haible  <bruno@clisp.org>
18200
18201         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
18202
18203 2003-08-11  Bruno Haible  <bruno@clisp.org>
18204
18205         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
18206         (vasnprintf): Use it instead of wcslen.
18207
18208 2003-08-11  Bruno Haible  <bruno@clisp.org>
18209
18210         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
18211         value to ensure that _Bool promotes to int. Use #define for _Bool when
18212         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
18213
18214 2003-08-10  Karl Berry  <karl@gnu.org>
18215
18216         * lib/regex.h: update from libc (whitespace fix).
18217
18218 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18219
18220         Merge some files from coreutils.  These changes were
18221         originally made by Jim Meyering.
18222         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
18223         many older Unixes require this.
18224         * lib/alloca.c (alloca): Remove cast to argument of free;
18225         no longer needed in C89.
18226         * lib/alloca_.h, regex.h: Fix white space to match
18227         what GNU indent does.
18228
18229 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18230
18231         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
18232         apparently Emacs's Unicode mode got confused before my 2003-08-05
18233         checkin.
18234
18235 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18236
18237         * m4/extensions.m4: New file.
18238         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
18239         Require gl_USE_SYSTEM_EXTENSIONS.
18240         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
18241         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
18242
18243 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18244
18245         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
18246         * modules/extensions, modules/gnu-source: New files.
18247         * modules/timespec, modules/unlocked-io: Depend on extensions.
18248
18249 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18250
18251         * modules/restrict: New file.
18252         * MODULES.html.sh (func_all_modules): Add restrict.
18253         * modules/regex: Depend on restrict.
18254
18255 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18256
18257         * m4/restrict.m4: New file.
18258         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
18259
18260 2003-08-07  Bruno Haible  <bruno@clisp.org>
18261
18262         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
18263         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
18264
18265 2003-08-07  Bruno Haible  <bruno@clisp.org>
18266
18267         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
18268         makes the module 'getndelim2' compatible with the module 'getline'.
18269
18270 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18271
18272         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
18273         byte with "\201" to avoid glitches when editing that source file
18274         with multi-gnome-terminal.
18275
18276 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18277
18278         * lib/bumpalloc.h: Remove.
18279
18280 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18281
18282         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
18283         * modules/bumpalloc: Remove.
18284
18285 2003-08-04  Paul Eggert  <eggert@twinsun.com>
18286
18287         * lib/getloadavg.c: Change copyright notice and spacing to conform to
18288         GNU coding style.
18289
18290         Merge from coreutils.
18291         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
18292         1. From glibc.
18293         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
18294         from Karl Berry, implemented by Jim Meyering.
18295         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
18296         from Dmitry V. Levin.
18297         Remove anachronistic cast of xrealloc.
18298         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
18299         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
18300         type. Otherwise, it wouldn't compile with at least /bin/cc on
18301         ymp-cray-unicos9.0.2.X.
18302         Combine two mostly-identical uses of alloca into one.
18303         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
18304
18305 2003-08-04  Dave Love  <d.love@dl.ac.uk>
18306
18307         [From Emacs.]
18308
18309         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
18310         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
18311         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
18312         obsolete NLIST_NAME_UNION.
18313         [__GNU__]: Undef BSD and FSCALE.
18314         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
18315
18316 2003-08-03  Paul Eggert  <eggert@twinsun.com>
18317
18318         * lib/stdbool_.h (_Bool): Make it signed char, instead of
18319         an enum type, so that it's guaranteed to promote to int.  See:
18320         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
18321
18322 2003-08-03  Karl Berry  <karl@gnu.org>
18323
18324         * config/depcomp: update from automake.
18325
18326 2003-07-31  Paul Eggert  <eggert@twinsun.com>
18327
18328         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
18329         (strerror): Don't assume that a printable int fits in 14 bytes.
18330
18331 2003-07-31  Bruno Haible  <bruno@clisp.org>
18332
18333         * modules/getpass-gnu: New file.
18334         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
18335
18336 2003-07-31  Bruno Haible  <bruno@clisp.org>
18337
18338         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
18339
18340 2003-07-24  Karl Berry  <karl@gnu.org>
18341
18342         * config/missing: update from automake.
18343
18344 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
18345             Bruno Haible  <bruno@clisp.org>
18346
18347         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
18348         * lib/getline.c (getline, getdelim): Likewise.
18349         Remove _GNU_SOURCE define; now it's defined in config.h through
18350         m4/getline.m4.
18351
18352 2003-07-23  Karl Berry  <karl@gnu.org>
18353
18354         * config/config.sub: update from prep.
18355
18356 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18357
18358         * modules/xalloc (Depends-on): Add exitfail.
18359         * modules/xmemcoll: Likewise.
18360
18361 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18362
18363         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
18364         over-parenthesization in macros.
18365
18366         Sync with coreutils.
18367
18368         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
18369         required by C99.
18370
18371         Use `exit_failure' for xalloc and xmemcoll instead of their own
18372         private exit-failure variables.
18373         * lib/xalloc.h (xalloc_exit_failure): Remove.
18374         * lib/xmalloc.c: Likewise.  Include exitfail.h.
18375         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
18376         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
18377         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
18378         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
18379
18380 2003-07-20  Jim Meyering  <jim@meyering.net>
18381
18382         * modules/closeout (Depends-on): Add exitfail.
18383         Suggestion from Bruno Haible.
18384
18385 2003-07-19  Karl Berry  <karl@gnu.org>
18386
18387         * config/config.sub: update from prep.
18388
18389 2003-07-18  Paul Eggert  <eggert@twinsun.com>
18390
18391         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
18392         Remove.
18393         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
18394         to test that it can stand by itself.  Include "exitfail.h".
18395         Clients should set exit_failure instead.
18396         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
18397
18398 2003-07-18  Bruno Haible  <bruno@clisp.org>
18399
18400         * modules/getndelim2: New file.
18401         * modules/getline: Share files with module getndelim2.
18402         * modules/getnline: Depend on getndelim2 instead of sharing files with
18403         it. Add getnline.c to lib_SOURCES.
18404         * MODULES.html.sh (func_all_modules): Add getndelim2.
18405
18406 2003-07-18  Bruno Haible  <bruno@clisp.org>
18407
18408         * m4/getndelim2.m4: New file.
18409         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
18410         invoke gl_PREREQ_GETNDELIM2.
18411         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
18412         gl_PREREQ_GETNDELIM2.
18413         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
18414         gl_GETNDELIM2.
18415
18416 2003-07-18  Bruno Haible  <bruno@clisp.org>
18417
18418         * lib/getndelim2.h: New file.
18419         * lib/getndelim2.c: Make into a module of its own. Include config.h,
18420         getndelim2.h.
18421         (getndelim2): Make non-static. Change return type to ssize_t.
18422         * lib/getline.h: Change argument names.
18423         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
18424         * lib/getnline.c: Include getndelim2.h.
18425
18426 2003-07-18  Andreas Schwab  <schwab@suse.de>
18427
18428         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
18429
18430 2003-07-17  Karl Berry  <karl@gnu.org>
18431
18432         * config/config.sub: update from prep.
18433
18434 2003-07-17  Bruno Haible  <bruno@clisp.org>
18435
18436         * modules/getnline: New file.
18437         * modules/getline: Add lib/getndelim2.c to source file list.
18438         * MODULES.html.sh (func_all_modules): Add getnline.
18439
18440 2003-07-17  Bruno Haible  <bruno@clisp.org>
18441
18442         * m4/getnline.m4: New file.
18443
18444 2003-07-17  Bruno Haible  <bruno@clisp.org>
18445
18446         * m4/Makefile.am.in: Remove file.
18447         * m4/Makefile.am: Remove file.
18448         * m4/Makefile.in: Remove file.
18449
18450 2003-07-17  Bruno Haible  <bruno@clisp.org>
18451
18452         * lib/getnline.h: New file.
18453         * lib/getnline.c: New file.
18454         * lib/getndelim2.c: New file, extracted from getline.c.
18455         (getndelim2): Renamed from getdelim2, with added nmax argument.
18456         * lib/getline.c: Include getndelim2.c.
18457         (getdelim2): Moved out to getndelim2.c.
18458         (getline, getdelim): Update.
18459
18460 2003-07-17  Bruno Haible  <bruno@clisp.org>
18461
18462         * lib/Makefile.am: Remove file.
18463         * lib/Makefile.in: Remove file.
18464
18465 2003-07-17  Bruno Haible  <bruno@clisp.org>
18466
18467         * configure.in: Remove file.
18468         * Makefile.in: Remove file.
18469
18470 2003-07-17  Bruno Haible  <bruno@clisp.org>
18471
18472         * MODULES.html.sh: Put the </BODY> right before </HTML>.
18473
18474 2003-07-16  Karl Berry  <karl@gnu.org>
18475
18476         * config/srclist-update: was running fixlicense twice, which caused
18477                 texinfo.tex to be nullified for some reason.  Simplify,
18478                 $gplsrc is no longer needed as far as I can see?
18479
18480 2003-07-16  Jim Meyering  <jim@meyering.net>
18481
18482         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
18483
18484 2003-07-15  Paul Eggert  <eggert@twinsun.com>
18485
18486         * config/srclist.txt: Get the following files from gettext-runtime/intl
18487         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
18488         ref-del.sin.  From Bruno Haible.
18489         * config/srclist-update (fixfile): Change grep pattern again, since the
18490         previous fix didn't work (there was another trailing $).  Use
18491         '[$]' to escape the $s.
18492
18493 2003-07-15  Karl Berry  <karl@gnu.org>
18494
18495         * lib/vasnprintf.c: update from gettext.
18496
18497 2003-07-15  Karl Berry  <karl@gnu.org>
18498
18499         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
18500         gets expanded when surrounded by '$'.
18501
18502 2003-07-15  Jim Meyering  <jim@meyering.net>
18503
18504         * modules/save-cwd: Don't depend on error.  From Derek Price.
18505
18506 2003-07-15  Jim Meyering  <jim@meyering.net>
18507
18508         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
18509
18510 2003-07-14  Simon Josefsson  <jas@extundo.com>
18511
18512         * modules/mempcpy: New file.
18513         * MODULES.html.sh (func_all_modules): Add mempcpy.
18514
18515 2003-07-14  Simon Josefsson  <jas@extundo.com>
18516
18517         * m4/mempcpy.m4: New file.
18518
18519 2003-07-14  Simon Josefsson  <jas@extundo.com>
18520
18521         * lib/mempcpy.h: New file.
18522         * lib/mempcpy.c: New file.
18523
18524 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18525
18526         * modules/getdate, modules/posixtm: Depend on mktime.
18527
18528 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18529
18530         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
18531         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
18532         unicodeio.c, unicodeio.h, unlocked-io.h:
18533         Switch from LGPL to GPL.
18534
18535 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18536
18537         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
18538         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
18539         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
18540         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
18541         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
18542         updated automatically by ../config/srclist-update.  This changes
18543         their license from LPGL to GPL.
18544
18545 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18546
18547         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
18548         assumed to refer to the root of the most recent stable gettext version.
18549         * config/srclistvars.sh: Add defaults for eggert.
18550         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
18551         Match "This program" as well as "The program".  This is needed
18552         for gettext.
18553
18554 2003-07-14  Jim Meyering  <jim@meyering.net>
18555
18556         Don't emit diagnostics.  Let callers do that.
18557         * lib/save-cwd.c: Don't include "error.h".
18558         (save_cwd): Don't call error.  Ensure that errno is valid
18559         when returning nonzero.
18560
18561         * lib/save-cwd.h (restore_cwd): Update prototype.
18562         * lib/save-cwd.c (restore_cwd): Remove two parameters.
18563         Simplify.  Don't call error upon failure.  Let callers do that.
18564         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
18565         when auditing is enabled.  But don't bother updating the #if.
18566
18567 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
18568
18569         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
18570         it breaks C++ compilation.
18571         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
18572
18573 2003-07-10  Simon Josefsson  <jas@extundo.com>
18574
18575         * modules/strchrnul (Makefile.am): Add strchrnul.h.
18576
18577 2003-07-10  Jim Meyering  <jim@meyering.net>
18578
18579         * m4/clock_time.m4: Remove trailing blank.
18580         * m4/intmax_t.m4: Likewise.
18581
18582 2003-07-10  Jim Meyering  <jim@meyering.net>
18583
18584         * lib/vasnprintf.c: Remove trailing blanks.
18585         Make cpp indentation consistent.
18586
18587 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18588
18589         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
18590         posixver.c, strftime.c, strnlen.c, strverscmp.c:
18591         Switch from LGPL to GPL.
18592
18593 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18594
18595         * config/srclist.txt: Sort sublists.  Add
18596         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
18597         that differ from gnulib for one reason or another; we'd like this list
18598         to be smaller but for now let's document what we have.
18599
18600 2003-07-08  Paul Eggert  <eggert@twinsun.com>
18601
18602         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
18603         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
18604         and sweeter "eval x=$x".
18605         * config/srclist.txt: Get lib/argp* from glibc.
18606
18607 2003-07-07  Paul Eggert  <eggert@twinsun.com>
18608
18609         * lib/mktime.c: Fix some boundary cases and remove need for floating
18610         point.
18611
18612         Issue a compile-time diagnostic if time_t is floating point, or if
18613         two's complement arithmetic is not in effect, or if arithmetic
18614         right shift does not propagate the sign.  These assumptions were
18615         all in the original code but they weren't checked.
18616
18617         (TIME_T_MIDPOINT, verify): New macros.
18618         (__isleap): Remove; it has integer overflow problems.
18619         (leapyear): New function, without those problems.
18620         (ydhms_tm_diff): Remove; splitting into two parts.
18621         (ydhms_diff): New function, containing the arithmetic part of
18622         the old ydhms_tm_diff function.  Issue a compile-time
18623         diagnostic if we are not using C99 integer division.
18624         Avoid casts when possible.
18625         (guess_time_tm): New function, containing the checking part of
18626         the old ydhms_tm_diff function.  Return the new value, rather than
18627         the difference between it and the old.  Accept a new argument T
18628         so that *T specifies the old value.  Check for overflow in the result.
18629
18630         (__mktime_internal): Use a time_t offset, not a long int offset.
18631         This undoes the 2003-06-04 change, which is no longer needed now
18632         that we have better overflow checking.
18633         (localtime_offset): Likewise.
18634
18635         (__mktime_internal): Avoid harmful overflow on hosts where time_t
18636         and long are 64-bit but int is only 32-bit.
18637         (ydhms_diff): Use long int to store year1 and yday1.
18638         Issue a compile-time diagnostic if long int is not wide enough.
18639
18640         (__mktime_internal): Use long int to store adjusted year and yday.
18641         Use plain C rather than preprocessor commands, if that doesn't
18642         affect efficiency.
18643         Check for overflow (and try to repair) after each probe
18644         rather than checking only at the very end.  This avoids some bugs
18645         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
18646         does not equal GMT offset at maximum time).
18647         Use integer to check for overflow rather than floating point; this
18648         is more portable to non-IEEE hosts, and is a tad faster.
18649         When we detect that we are oscillating between two values,
18650         don't check whether tm_isdst has the requested value, since
18651         we already know the answer.  When tm_isdst has the wrong value,
18652         use a different heuristic to find the right one, based on the
18653         extreme values actually observed in practice in tz2003a,
18654         rather than the (overly optimistic) "previous 3 calendar quarters".
18655
18656         (not_equal_tm, print_tm, check_result): Use "const T" rather than
18657         "T const" to accommodate glibc style.
18658         (check_result): Use less-confusing report format.  "long" -> "long int.
18659         (main): Likewise.
18660         Don't loop if the iteration overflows time_t.
18661         Allow a negative step in the iteration.
18662
18663 2003-07-06  Karl Berry  <karl@gnu.org>
18664
18665         * config/depcomp: update from automake.
18666         * config/config.sub: update from prep.
18667
18668 2003-07-03  Karl Berry  <karl@gnu.org>
18669
18670         * config/config.guess: update from prep.
18671
18672 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18673
18674         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
18675         xreadlink.c now includes it unconditionally.
18676
18677 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18678
18679         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
18680         having it depend on HAVE_SYS_TYPES_H.
18681
18682 2003-07-01  Bruno Haible  <bruno@clisp.org>
18683
18684         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
18685         <sys/types.h> should be sufficient.
18686         Reported by Paul Eggert.
18687
18688 2003-06-26  Karl Berry  <karl@gnu.org>
18689
18690         * config/depcomp: update from automake.
18691
18692 2003-06-26  Bruno Haible  <bruno@clisp.org>
18693
18694         * modules/human: Depend on module stdbool.
18695
18696 2003-06-25  Bruno Haible  <bruno@clisp.org>
18697
18698         * modules/readlink: New file.
18699         * modules/xreadlink: Depend on it.
18700         * MODULES.html.sh (func_all_modules): Add readlink.
18701
18702 2003-06-25  Bruno Haible  <bruno@clisp.org>
18703
18704         * m4/readlink.m4: New file.
18705
18706 2003-06-25  Bruno Haible  <bruno@clisp.org>
18707
18708         * lib/readlink.c: New file.
18709
18710 2003-06-22  Karl Berry  <karl@gnu.org>
18711
18712         * config/srclist.txt: update mkinstalldirs from automake.
18713         * config/mkinstalldirs: update.
18714
18715 2003-06-22  Bruno Haible  <bruno@clisp.org>
18716
18717         Portability to mingw32.
18718         * m4/ssize_t.m4: New file, from GNU gettext.
18719         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
18720         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
18721
18722 2003-06-22  Bruno Haible  <bruno@clisp.org>
18723
18724         * modules/safe-read: Add m4/ssize_t.m4.
18725         * modules/xreadlink: Add m4/ssize_t.m4.
18726
18727 2003-06-20  Bruno Haible  <bruno@clisp.org>
18728
18729         Assume C89, so PARAMS isn't needed.
18730         * lib/unicodeio.h (PARAMS): Remove.
18731         * lib/unicodeio.c: Don't use PARAMS.
18732
18733 2003-06-18  Karl Berry  <karl@gnu.org>
18734
18735         * config/config.{guess,sub}: update from prep.
18736
18737 2003-06-18  Jim Meyering  <jim@meyering.net>
18738
18739         Merge changes from coreutils.
18740         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
18741         Remove explicit declarations of xmalloc and realloc.
18742         Include xalloc.h.
18743         (read_utmp): Remove anachronistic cast of xmalloc.
18744
18745 2003-06-17  Paul Eggert  <eggert@twinsun.com>
18746
18747         Assume C89, so PARAMS isn't needed.
18748         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
18749         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
18750         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
18751         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
18752         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
18753         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
18754         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
18755         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
18756         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
18757         lib/xstrtod.h, lib/xstrtol.h: Likewise.
18758         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
18759         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
18760         no longer needed. Anyway, config.h should always be included before any
18761         other file.
18762
18763 2003-06-11  Simon Josefsson  <jas@extundo.com>
18764
18765         * modules/sysexits: New file.
18766         * MODULES.html.sh (func_all_modules): Add sysexits.
18767
18768 2003-06-11  Simon Josefsson  <jas@extundo.com>
18769
18770         * lib/sysexit_.h: New file.
18771
18772 2003-06-11  Derek Price  <derek@ximbiot.com>
18773
18774         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
18775         necessary.
18776
18777 2003-06-11  Bruno Haible  <bruno@clisp.org>
18778
18779         * m4/sysexits.m4: New file.
18780
18781 2003-06-10  Simon Josefsson  <jas@extundo.com>
18782
18783         * lib/argp.h: New file, from glibc.
18784         * lib/argp-ba.c: New file, from glibc.
18785         * lib/argp-eexst.c: New file, from glibc.
18786         * lib/argp-fmtstream.c: New file, from glibc.
18787         * lib/argp-fmtstream.h: New file, from glibc.
18788         * lib/argp-fs-xinl.c: New file, from glibc.
18789         * lib/argp-help.c: New file, from glibc.
18790         * lib/argp-namefrob.h: New file, from glibc.
18791         * lib/argp-parse.c: New file, from glibc.
18792         * lib/argp-pv.c: New file, from glibc.
18793         * lib/argp-pvh.c: New file, from glibc.
18794         * lib/argp-xinl.c: New file, from glibc.
18795
18796 2003-06-10  Simon Josefsson  <jas@extundo.com>
18797
18798         * modules/strchrnul: New file.
18799
18800 2003-06-10  Simon Josefsson  <jas@extundo.com>
18801
18802         * modules/argp: New file.
18803
18804 2003-06-10  Simon Josefsson  <jas@extundo.com>
18805
18806         * m4/strchrnul.m4: New file.
18807
18808 2003-06-10  Simon Josefsson  <jas@extundo.com>
18809
18810         * lib/strchrnul.h: New file.
18811         * lib/strchrnul.c: New file.
18812
18813 2003-06-10  Bruno Haible  <bruno@clisp.org>
18814
18815         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
18816
18817 2003-06-07  Karl Berry  <karl@gnu.org>
18818
18819         * config/config.{guess,sub}: update from prep.
18820
18821 2003-06-07  Jim Meyering  <jim@meyering.net>
18822
18823         * modules/strtod: Use $(...) notation, not @...@ for
18824         AC_REPLACE'd variables.
18825         * modules/localcharset: Likewise.
18826
18827 2003-06-07  Jim Meyering  <jim@meyering.net>
18828
18829         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
18830         in place of my name in the copyright comment.
18831         Remove definition and uses of __P.
18832
18833         From coreutils.
18834         * lib/stat.c: Don't declare xmalloc explicitly.
18835         Instead, include "xalloc.h".
18836         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
18837         xrealloc, and xcalloc return values.
18838         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
18839         Improve comment.
18840         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
18841
18842 2003-06-07  Bruno Haible  <bruno@clisp.org>
18843
18844         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
18845         avoid AC_CONFIG_LINKS.
18846         * modules/fnmatch (Makefile.am): Use explicit creation rule for
18847         fnmatch.h, to avoid AC_CONFIG_LINKS.
18848         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
18849
18850 2003-06-07  Bruno Haible  <bruno@clisp.org>
18851
18852         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
18853         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
18854         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18855         directory.
18856         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
18857         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18858         directory.
18859
18860 2003-06-06  Jim Meyering  <jim@meyering.net>
18861
18862         Merge from coreutils.
18863         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
18864         Consolidate declarations and initializations of *_base* locals.
18865
18866         Merge from coreutils.
18867         This avoids a core dump on systems without GNU putenv,
18868         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
18869         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
18870         (unsetenv): New static function, from GNU libc.
18871         (rpl_putenv): Use it.
18872
18873         * lib/modechange.c: Remove trailing blanks.
18874
18875         Merge from coreutils.
18876         * lib/fsusage.c: Remove declaration of statfs.
18877         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
18878
18879         * lib/posixtm.c: Include <stdbool.h> unconditionally.
18880
18881 2003-06-06  Jim Meyering  <jim@meyering.net>
18882
18883         * lib/stdbool_.h: Renamed from stdbool.h.in.
18884
18885 2003-06-06  Jim Meyering  <jim@meyering.net>
18886             Bruno Haible  <bruno@clisp.org>
18887
18888         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
18889         Adjust Makefile.am snippet not to redirect directly to target.
18890         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
18891
18892 2003-06-05  Paul Eggert  <eggert@twinsun.com>
18893
18894         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
18895         mismatch, look in future quarters as well as past.  This fixes a
18896         bug when processing fall-backwards gaps immediately after a long
18897         period of daylight-saving time.
18898
18899         * lib/mktime.c: Assume freestanding C89 or better.
18900         (HAVE_LIMITS_H): Remove.  Assume it's 1.
18901         (__P): Remove; not used.
18902         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
18903         (mktime, not_equal_tm, print_tm, check_result,
18904         main): Use prototypes.  Use const * where appropriate.
18905         (main): Fix typo in testing code that uncovered by above changes.
18906         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
18907
18908 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18909
18910         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
18911         locale.h, localeconv.  This merges changes from coreutils.
18912
18913         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
18914         It can be removed after the next Autoconf is released.
18915         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
18916         needed.
18917
18918 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18919
18920         * lib/mktime.c: Fix Debian bug 177940
18921         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
18922         (localtime_offset): Now long int, not time_t, because we want it
18923         to be guaranteed to be signed.  All uses changed.
18924         (__mktime_internal): If overflow would occur when adding offset,
18925         don't add it.
18926
18927         Merge 'human' changes from coreutils.  Rewrite to support
18928         locale-specific notations like thousands separators.
18929         * lib/human.c: Simplify authorship notice.
18930         Include human.h immediately after config.h.
18931         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
18932         <limits.h>: Do not include, since human.h does.
18933         (SIZE_MAX, UINTMAX_MAX): New macros.
18934         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
18935         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
18936         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
18937         (power_letter): Renamed from suffixes.
18938         (generate_suffix_backwards): Remove.
18939         (adjust_value): Now takes int style (because of human.h changes)
18940         and long double value (for greater precision on some platforms).
18941         (group_number): New function.
18942         (human_readable): Use it.  Use integer options, not enum.
18943         Put the options before the sizes in the arg list.
18944         Support all the new options.
18945         The old human_readable function has been removed;
18946         use inttostr.h instead.
18947         (human_readable, default_block_size, humblock):
18948         Use uintmax_t, not int, for block sizes.
18949         (human_readable_inexact, block_size_types): Remove.
18950         (block_size_opts): New constant.
18951         (human_options): Renamed from human_block_size, with new signature
18952         that allows block sizes up to UINTMAX_MAX.  All callers changed.
18953         * lib/human.h: Add copyright and authorship notice.
18954         Include <limits.h> and <stdbool.h> unconditionally.
18955         (PARAMS): Remove.  All uses removed.
18956         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
18957         (enum human_inexact_style): Remove tag; now a nameless enum.
18958         (human_floor, human_ceiling, human_round_to_even): Now have
18959         values 2, 0, 1 rather than -1, 1, 0.
18960         (human_group_digits, human_suppress_point_zero, human_autoscale,
18961         human_base_1024, human_SI, human_B): New constants.
18962         (human_readable_inexact, human_block_size): Remove.
18963         (human_readable): Size args are now uintmax_t, not int.
18964         (human_options): New decl.
18965
18966         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
18967         unnecessary now that we assume C89 or better.  This change
18968         imported from coreutils.
18969
18970         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
18971         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
18972         in the 2003-05-30 sync from glibc.
18973
18974         .h files should stand alone, but we shouldn't include <sys/types.h>
18975         if we can get away with just <stddef.h>.
18976
18977         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
18978         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
18979         rather than <sys/types.h>, as we merely need size_t.
18980         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
18981         to get size_t.
18982         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
18983         Include <stdio.h>, to get FILE.
18984         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
18985         memcasecmp.h has included <stddef.h> and all we need is size_t.
18986         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
18987         our interface, instead of including <sys/types.h>
18988
18989 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18990
18991         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
18992         now, as glibc mktime is buggy on non-glibc systems.
18993
18994 2003-06-03  Karl Berry  <karl@gnu.org>
18995
18996         * config/config.sub: update from prep.
18997
18998 2003-06-02  Paul Eggert  <eggert@twinsun.com>
18999
19000         [from coreutils]
19001         Fix some minor time-related bugs with POSIX time arguments.
19002         Some valid time stamps were being rejected (notably -1, and
19003         time stamps before 1900 on 64-bit hosts).  And some invalid
19004         time stamps were being accepted, e.g. September 31.
19005
19006         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
19007         that we can return (time_t) -1 successfully.
19008         * lib/posixtm.c: Likewise.
19009         [HAVE_STDBOOL_H]: Include <stdbool.h>.
19010         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
19011         (t): Remove static var.
19012         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
19013         of static var.  All uses changed.
19014         (year): Do not reject years before 1900; they can occur with
19015         64-bit time_t.
19016         (posix_time_parse): Do not check for out-of-range components;
19017         that is now the caller's responsibility, since our checks were
19018         only approximations.
19019         (posixtime): Use mktime to check for out-of-range components,
19020         since it knows them exactly.
19021         If mktime returns (time_t) -1, check whether an error actually occurred
19022         by invoking localtime on -1.
19023         (main) [TEST_POSIXTIME]: Check for input data errors, and report
19024         posixtime failures better.
19025         Improve the test data (in comments only).
19026
19027 2003-06-02  Karl Berry  <karl@gnu.org>
19028
19029         * config/mkinstalldirs (version): new variable.
19030         (--version): new option.
19031         (usage): improve message.
19032
19033 2003-05-30  Karl Berry  <karl@gnu.org>
19034
19035         * lib/mktime.c: update from libc.
19036
19037 2003-05-30  Bruno Haible  <bruno@clisp.org>
19038
19039         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
19040         * config/config.rpath: Upgrade to gettext-0.12.1.
19041
19042 2003-05-30  Bruno Haible  <bruno@clisp.org>
19043
19044         * m4/gettext.m4: Upgrade to gettext-0.12.1.
19045         * m4/nls.m4: New file, from gettext-0.12.1.
19046         * m4/po.m4: New file, from gettext-0.12.1.
19047         * m4/progtest.m4: Upgrade to gettext-0.12.1.
19048
19049 2003-05-30  Bruno Haible  <bruno@clisp.org>
19050
19051         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
19052         * lib/localcharset.h: Likewise.
19053         * lib/localcharset.c: Likewise.
19054
19055 2003-05-29  Karl Berry  <karl@gnu.org>
19056
19057         * config/config.rpath: update from gettext.
19058
19059 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19060
19061         Assume the headers required for C89 freestanding compilers.
19062         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
19063         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
19064         * m4/human.m4 (gl_HUMAN): Likewise.
19065         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
19066         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
19067         * m4/userspec.m4 (gl_USERSPEC): Likewise.
19068         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
19069         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
19070         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
19071
19072 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19073
19074         Assume the headers required for C89 freestanding compilers.
19075         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
19076         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
19077         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
19078         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
19079         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
19080         define, since <limits.h> is guaranteed to do that.
19081         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
19082         * lib/exclude.c: Include <stdbool.h> unconditionally.
19083         * lib/tempname.c: Include <stddef.h> unconditionally.
19084         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
19085         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
19086         <stddef.h> does that.
19087         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
19088         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
19089         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
19090         needed.
19091         * lib/xstrtol.c: Likewise.
19092         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
19093         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
19094
19095         * lib/addext.c (addext): Use assignment rather than cast, to avoid
19096         warnings on some platforms.
19097
19098         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19099         arbitrarily.
19100
19101 2003-05-26  Jim Meyering  <jim@meyering.net>
19102
19103         Merge in a change from coreutils:
19104         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
19105         that is guaranteed to be `no'.  Use `no_such_member' to indicate
19106         that condition, rather than `-1' which is slightly misleading.
19107         Change the name of the cache variable to have the gl_ prefix.
19108         Prompted by a patch from Richard Dawe for DJGPP.
19109
19110 2003-05-24  Karl Berry  <karl@gnu.org>
19111
19112         * config/config.guess: update from prep.
19113
19114 2003-05-22  Karl Berry  <karl@gnu.org>
19115
19116         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
19117
19118 2003-05-20  Karl Berry  <karl@gnu.org>
19119
19120         * config/config.guess: update from prep.
19121
19122 2003-05-18  Karl Berry  <karl@gnu.org>
19123
19124         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
19125         might actually be set by the user.
19126
19127         * config/depcomp, install-sh, mdate-sh: update from automake.
19128
19129 2003-05-17  Bruno Haible  <bruno@clisp.org>
19130
19131         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
19132         invalid expansion for AC_EGREP_CPP.
19133         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
19134         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
19135         Suggested by Akim Demaille <akim@epita.fr> in
19136         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
19137
19138 2003-05-12  Jim Meyering  <jim@meyering.net>
19139
19140         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
19141         the space-padded-by-default conversion specifiers, %e, %k, %l.
19142
19143 2003-05-12  Bruno Haible  <bruno@clisp.org>
19144
19145         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
19146         the string is longer than 4 KB.
19147
19148 2003-05-11  Karl Berry  <karl@gnu.org>
19149
19150         * config/config.{guess,sub}: update from prep.
19151
19152 2003-05-09  Bruno Haible  <bruno@clisp.org>
19153
19154         * modules/error: Add m4/strerror_r.m4 to file list.
19155
19156 2003-05-03  Bruno Haible  <bruno@clisp.org>
19157
19158         Upgrade to Unicode-4.0.
19159         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
19160         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
19161         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
19162         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
19163         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
19164         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
19165         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
19166         Change width of U+E0100..U+E01EF from 1 to 0.
19167
19168 2003-04-25  Jim Meyering  <jim@meyering.net>
19169
19170         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
19171         of type size_t, not int.
19172
19173 2003-04-25  Bruno Haible  <bruno@clisp.org>
19174
19175         * lib/copy-file.c: Include <stddef.h>, for size_t.
19176
19177 2003-04-21  Paul Eggert  <eggert@twinsun.com>
19178
19179         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
19180         code which expansion is under static control.  Patch imported from
19181         Akim Demaille's patch to Bison; see
19182         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
19183
19184 2003-04-14  Bruno Haible  <bruno@clisp.org>
19185
19186         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
19187
19188 2003-04-11  Jim Meyering  <jim@meyering.net>
19189
19190         Merge changes from Coreutils.
19191
19192         2003-03-22  Jim Meyering  <jim@meyering.net>
19193
19194         * lib/strftime.c (widen): Cast alloca return value to proper type.
19195
19196         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
19197
19198         From GNU libc.
19199         * lib/strftime.c (my_strftime): Handle very large width
19200         specifications for numeric values correctly.  Improve checks for
19201         overflow.
19202
19203         2003-01-19  Jim Meyering  <jim@meyering.net>
19204
19205         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
19206         definitions.
19207         (nl_get_alt_digit) [! defined my_strftime]: Define.
19208         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
19209         _nl_get_alt_digit and _nl_get_walt_digit.
19210
19211         * lib/strftime.c (my_strftime): Merge in locale-related changes from
19212         libc. These changes have no effect outside of _LIBC.
19213
19214 2003-04-10  Bruno Haible  <bruno@clisp.org>
19215
19216         * modules/findprog: New file.
19217         * MODULES.html.sh (func_all_modules): Add it.
19218
19219 2003-04-10  Bruno Haible  <bruno@clisp.org>
19220
19221         * m4/findprog.m4: New file.
19222         * m4/eaccess.m4: New file.
19223
19224 2003-04-10  Bruno Haible  <bruno@clisp.org>
19225
19226         * lib/findprog.h: New file, from GNU gettext.
19227         * lib/findprog.c: New file, from GNU gettext.
19228
19229 2003-04-05  Jim Meyering  <jim@meyering.net>
19230
19231         Merge changes from Coreutils.
19232
19233         * lib/exclude.h (PARAMS): Remove definition and uses.
19234         * lib/exclude.c: Remove uses of `PARAMS'.
19235
19236         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
19237         Add test-cases for DOS filenames. Declare program_name.
19238         (main): Set up program_name.  Patch by Rich Dawe.
19239
19240         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19241         error from mntctl.
19242         Use mntctl's return value to drive the entry-processing loop, since
19243         we can't rely on the value of the vmt_length member in the last
19244         entry.  On some systems doing so could result in exhausting
19245         virtual memory.  Based in part on a patch from Mike Jetzer.
19246
19247 2003-04-04  Bruno Haible  <bruno@clisp.org>
19248
19249         * modules/linebreak: New file.
19250         * MODULES.html.sh (func_all_modules): Add it.
19251
19252 2003-04-04  Bruno Haible  <bruno@clisp.org>
19253
19254         * m4/linebreak.m4: New file.
19255
19256 2003-04-04  Bruno Haible  <bruno@clisp.org>
19257
19258         * lib/linebreak.h: New file, from GNU gettext.
19259         * lib/linebreak.c: New file, from GNU gettext with slight
19260         modifications.
19261         * lib/lbrkprop.h: New file, from GNU gettext.
19262
19263 2003-04-03  Bruno Haible  <bruno@clisp.org>
19264
19265         * modules/utf8-ucs4: New file.
19266         * modules/utf16-ucs4: New file.
19267         * modules/ucs4-utf8: New file.
19268         * modules/ucs4-utf16: New file.
19269         * MODULES.html.sh (func_all_modules): Add them.
19270
19271 2003-04-03  Bruno Haible  <bruno@clisp.org>
19272
19273         * m4/utf-ucs4.m4: New file.
19274         * m4/ucs4-utf.m4: New file.
19275
19276 2003-04-03  Bruno Haible  <bruno@clisp.org>
19277
19278         * lib/utf8-ucs4.h: New file, from GNU gettext.
19279         * lib/utf16-ucs4.h: New file, from GNU gettext.
19280         * lib/ucs4-utf8.h: New file, from GNU gettext.
19281         * lib/ucs4-utf16.h: New file, from GNU gettext.
19282
19283 2003-04-02  Bruno Haible  <bruno@clisp.org>
19284
19285         * modules/binary-io: New file.
19286         * MODULES.html.sh (func_all_modules): Add it.
19287
19288 2003-04-02  Bruno Haible  <bruno@clisp.org>
19289
19290         * lib/binary-io.h: New file, from GNU gettext.
19291
19292 2003-04-01  Bruno Haible  <bruno@clisp.org>
19293
19294         * modules/pathname: New file.
19295         * MODULES.html.sh (func_all_modules): Add it.
19296
19297 2003-04-01  Bruno Haible  <bruno@clisp.org>
19298
19299         * lib/pathname.h: New file, from GNU gettext.
19300         * lib/concatpath.c: New file, from GNU gettext.
19301
19302 2003-03-30  Bruno Haible  <bruno@clisp.org>
19303
19304         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
19305
19306 2003-03-30  Bruno Haible  <bruno@clisp.org>
19307
19308         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
19309         function chown() doesn't exist.
19310
19311 2003-03-28  Bruno Haible  <bruno@clisp.org>
19312
19313         * modules/copy-file: New file.
19314         * MODULES.html.sh (func_all_modules): Add it.
19315
19316 2003-03-28  Bruno Haible  <bruno@clisp.org>
19317
19318         * m4/copy-file.m4: New file.
19319
19320 2003-03-28  Bruno Haible  <bruno@clisp.org>
19321
19322         * lib/copy-file.h: New file, from GNU gettext.
19323         * lib/copy-file.c: New file, from GNU gettext.
19324
19325 2003-03-18  Jim Meyering  <jim@meyering.net>
19326
19327         * lib/quote.c (quote_n): Fix typo in comment.
19328
19329 2003-03-18  Bruno Haible  <bruno@clisp.org>
19330
19331         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
19332         checking.
19333         * m4/onceonly_2_57.m4: Likewise.
19334
19335 2003-03-17  Bruno Haible  <bruno@clisp.org>
19336
19337         * m4/onceonly.m4: Require autoconf 2.54 or newer.
19338         (m4_quote): Remove macro.
19339         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
19340
19341 2003-03-14  Jim Meyering  <jim@meyering.net>
19342
19343         Merge changes from Coreutils.
19344         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
19345         to be const, in order to avoid warnings.
19346         (obstack_room): Likewise.
19347         (obstack_empty_p): Likewise.
19348
19349 2003-03-14  Bruno Haible  <bruno@clisp.org>
19350
19351         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
19352         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
19353
19354 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19355
19356         Merge changes from Bison.
19357         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
19358         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
19359         when compiling Bison 1.875's `bitset bset = obstack_alloc
19360         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
19361         * lib/hash.c: Include <stdbool.h> unconditionally.
19362
19363 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19364
19365         * m4/onceonly.m4 (m4_quote): New macro.
19366         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
19367         Quote AC_FOREACH variable-expansions properly.
19368
19369 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19370
19371         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
19372
19373 2003-03-09  Paul Eggert  <eggert@twinsun.com>
19374
19375         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
19376         Reported by Bruce Becker; see:
19377         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
19378
19379 2003-03-03  Paul Eggert  <eggert@twinsun.com>
19380             Bruno Haible  <bruno@clisp.org>
19381
19382         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
19383         Reported by John Hughes, see
19384         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
19385
19386 2003-02-20  Bruno Haible  <bruno@clisp.org>
19387
19388         * MODULES.html.sh (func_all_modules): Add poll.
19389
19390 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19391
19392         * modules/poll: New file.
19393
19394 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19395
19396         * lib/poll_.h: New file.
19397         * lib/poll.c: New file.
19398
19399 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19400
19401         * m4/poll.m4: New file.
19402
19403 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19404
19405         * modules/mathl: New file.
19406
19407 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19408
19409         * lib/mathl.h: New file.
19410         * lib/acosl.c: New file.
19411         * lib/asinl.c: New file.
19412         * lib/atanl.c: New file.
19413         * lib/ceill.c: New file.
19414         * lib/cosl.c: New file.
19415         * lib/expl.c: New file.
19416         * lib/floorl.c: New file.
19417         * lib/frexpl.c: New file.
19418         * lib/ldexpl.c: New file.
19419         * lib/logl.c: New file.
19420         * lib/sincosl.c: New file.
19421         * lib/sinl.c: New file.
19422         * lib/sqrtl.c: New file.
19423         * lib/tanl.c: New file.
19424         * lib/trigl.c: New file.
19425         * lib/trigl.h: New file.
19426
19427 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19428
19429         * m4/mathl.m4: New file.
19430
19431 2003-02-18  Bruno Haible  <bruno@clisp.org>
19432
19433         * MODULES.html.sh (func_all_modules): Add mathl.
19434
19435 2003-02-17  Bruno Haible  <bruno@clisp.org>
19436
19437         * modules/mkdtemp: New module.
19438         * MODULES.html.sh (func_all_modules): Add it.
19439
19440 2003-02-17  Bruno Haible  <bruno@clisp.org>
19441
19442         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
19443
19444 2003-02-17  Bruno Haible  <bruno@clisp.org>
19445
19446         * lib/mkdtemp.h: New file, from GNU gettext.
19447         * lib/mkdtemp.c: New file, from GNU gettext.
19448
19449 2003-02-02  Jim Meyering  <jim@meyering.net>
19450
19451         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
19452         e.g. glibc-2.2.93.
19453
19454 2003-01-31  Bruno Haible  <bruno@clisp.org>
19455
19456         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
19457         'rpl_rename'.
19458         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
19459         'rpl_strnlen'.
19460         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
19461         'rpl_strtod'.
19462         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
19463         'rpl_utime'.
19464
19465 2003-01-31  Bruno Haible  <bruno@clisp.org>
19466
19467         * lib/rename.c: #undef rename before defining rpl_rename.
19468         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
19469
19470 2003-01-30  Bruno Haible  <bruno@clisp.org>
19471
19472         * modules/vasnprintf, modules/vasprintf: New modules.
19473         * MODULES.html.sh (func_all_modules): Add them.
19474
19475 2003-01-30  Bruno Haible  <bruno@clisp.org>
19476
19477         * m4/signed.m4: New file, from GNU gettext.
19478         * m4/longdouble.m4: New file, from GNU gettext.
19479         * m4/wchar_t.m4: New file, from GNU gettext.
19480         * m4/wint_t.m4: New file, from GNU gettext.
19481         * m4/vasnprintf.m4: New file.
19482         * m4/vasprintf.m4: New file.
19483
19484 2003-01-30  Bruno Haible  <bruno@clisp.org>
19485
19486         * lib/printf-args.h: New file, from GNU gettext.
19487         * lib/printf-args.c: New file, from GNU gettext.
19488         * lib/printf-parse.h: New file, from GNU gettext.
19489         * lib/printf-parse.c: New file, from GNU gettext.
19490         * lib/vasnprintf.h: New file, from GNU gettext.
19491         * lib/vasnprintf.c: New file, from GNU gettext.
19492         * lib/asnprintf.c: New file, from GNU gettext.
19493         * lib/vasprintf.h: New file, from GNU gettext with modifications.
19494         * lib/vasprintf.c: New file, from GNU gettext.
19495         * lib/asprintf.c: New file, from GNU gettext.
19496
19497 2003-01-29  Bruno Haible  <bruno@clisp.org>
19498
19499         * modules/stpncpy: New module.
19500         * MODULES.html.sh (func_all_modules): Add it.
19501
19502 2003-01-29  Bruno Haible  <bruno@clisp.org>
19503
19504         * m4/stpncpy.m4: New file.
19505
19506 2003-01-29  Bruno Haible  <bruno@clisp.org>
19507
19508         * lib/stpncpy.h: New file, from GNU gettext with modifications.
19509         * lib/stpncpy.c: New file, from GNU gettext with modifications.
19510
19511 2003-01-28  Bruno Haible  <bruno@clisp.org>
19512
19513         * modules/c-ctype: New module.
19514         * MODULES.html.sh (func_all_modules): Add it.
19515
19516 2003-01-28  Bruno Haible  <bruno@clisp.org>
19517
19518         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
19519         Paul Eggert.
19520         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
19521         Paul Eggert.
19522
19523 2003-01-27  Bruno Haible  <bruno@clisp.org>
19524
19525         * modules/xsetenv: New module.
19526         * MODULES.html.sh (func_all_modules): Add it.
19527
19528 2003-01-27  Bruno Haible  <bruno@clisp.org>
19529
19530         * lib/xsetenv.h: New file, from GNU gettext.
19531         * lib/xsetenv.c: New file, from GNU gettext.
19532
19533 2003-01-23  Jim Meyering  <jim@meyering.net>
19534
19535         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
19536         from working on systems without dirfd (at least Irix and OSF1/Tru64).
19537
19538 2003-01-23  Bruno Haible  <bruno@clisp.org>
19539
19540         * modules/minmax: New module.
19541         * MODULES.html.sh (func_all_modules): Add it.
19542
19543 2003-01-23  Bruno Haible  <bruno@clisp.org>
19544
19545         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
19546         Eggert.
19547
19548 2003-01-22  Bruno Haible  <bruno@clisp.org>
19549
19550         * modules/exit: New module.
19551         * MODULES.html.sh (func_all_modules): Add it.
19552
19553 2003-01-22  Bruno Haible  <bruno@clisp.org>
19554
19555         * lib/exit.h: New file, from GNU gettext.
19556
19557 2003-01-19  Bruno Haible  <bruno@clisp.org>
19558
19559         * gnulib-tool: Recognize option --extract-maintainer.
19560         (func_get_maintainer): New function.
19561         * modules/*: Add Maintainer entry.
19562
19563 2003-01-16  Jim Meyering  <jim@meyering.net>
19564
19565         * m4/regex.m4: The `regex' struct is both input and output.
19566         Initialize it before each use.  Patch by Tim Waugh.
19567
19568 2003-01-16  Bruno Haible  <bruno@clisp.org>
19569
19570         * MODULES.html.sh: Add a table of contents. Add the module name as
19571         leftmost column. Add hyperlinks.
19572
19573 2003-01-15  Bruno Haible  <bruno@clisp.org>
19574
19575         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
19576
19577 2003-01-15  Bruno Haible  <bruno@clisp.org>
19578
19579         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
19580         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
19581         suffix.
19582
19583 2003-01-15  Bruno Haible  <bruno@clisp.org>
19584
19585         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
19586
19587 2003-01-15  Bruno Haible  <bruno@clisp.org>
19588
19589         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
19590         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
19591
19592 2003-01-14  Jim Meyering  <jim@meyering.net>
19593
19594         * lib/same.c (same_name): Tweak a comment.
19595
19596 2003-01-14  Bruno Haible  <bruno@clisp.org>
19597
19598         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
19599         when a string comparison is sufficient.
19600
19601 2003-01-14  Bruno Haible  <bruno@clisp.org>
19602
19603         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
19604         'unsigned int'.
19605
19606 2003-01-14  Bruno Haible  <bruno@clisp.org>
19607
19608         * lib/hash-pjw.c: Add comment about low quality of this function.
19609
19610 2003-01-13  Bruno Haible  <bruno@clisp.org>
19611
19612         * modules/stpcpy: Distribute lib/stpcpy.h.
19613         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
19614
19615 2003-01-13  Bruno Haible  <bruno@clisp.org>
19616
19617         * modules/*: Add a description.
19618         * modules/strpbrk: Fix Makefile.am snippet.
19619         * modules/strtoimax: Fix dependencies.
19620         * modules/strtoumax: Likewise.
19621
19622 2003-01-13  Bruno Haible  <bruno@clisp.org>
19623
19624         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
19625         * modules/alloca (Makefile.am): All object files depend on alloca.h.
19626         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
19627
19628 2003-01-13  Bruno Haible  <bruno@clisp.org>
19629
19630         * gnulib-tool (func_create_testdir): Store config/* files in the main
19631         directory.
19632         * config.rpath: Move to ...
19633         * config/config.rpath: ... here.
19634         * modules/gettext: Contains config/config.rpath, not config.rpath.
19635         * modules/iconv: Likewise.
19636
19637 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19638
19639         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19640         to avoid collisions with libcurses and libreadline.
19641
19642         * m4/getstr.m4: Remove.
19643         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
19644
19645 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19646
19647         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19648         to avoid collisions with libcurses and libreadline.
19649
19650         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
19651         * lib/getstr.h, getstr.c: Remove.
19652         * lib/getline.c: Include "getline.h", to check interface.
19653         Move body of old getstr.c here: this defines MIN_CHUNK and
19654         declares getdelim2, which is renamed from getstr.
19655         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
19656
19657         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
19658         All uses changed.
19659         * lib/linebuffer.h: Likewise.
19660         (readline): Remove backward-compatibility macro.
19661
19662 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19663
19664         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19665         to avoid collisions with libcurses and libreadline.
19666         * getstr: Remove.
19667         * MODULES.html.sh: Remove getstr.
19668         * modules/getline: Depend on unlocked-io, not getstr.
19669
19670 2003-01-12  Jim Meyering  <jim@meyering.net>
19671
19672         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
19673
19674 2003-01-10  Bruno Haible  <bruno@clisp.org>
19675
19676         * modules/alloca: Change Makefile.am requirements. Simplify Include
19677         requirements. Add lib/alloca_.h to file list.
19678
19679 2003-01-10  Bruno Haible  <bruno@clisp.org>
19680
19681         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
19682
19683 2003-01-10  Bruno Haible  <bruno@clisp.org>
19684
19685         * lib/alloca_.h: New file.
19686         * lib/getdate.y: Unconditionally include alloca.h.
19687         * lib/makepath.c: Likewise.
19688         * lib/setenv.c: Likewise.
19689         * lib/userspec.c: Likewise.
19690
19691 2003-01-09  Karl Berry  <karl@gnu.org>
19692
19693         * MODULES.html.sh: include `dirname $0` in PATH, to find
19694         gnulib-tool.
19695
19696 2003-01-09  Bruno Haible  <bruno@clisp.org>
19697
19698         * modules/stdbool: Change configure.ac, Makefile.am requirements.
19699         Simplify Include requirements. Add lib/stdbool.h.in to file list.
19700
19701 2003-01-09  Bruno Haible  <bruno@clisp.org>
19702
19703         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
19704
19705 2003-01-09  Bruno Haible  <bruno@clisp.org>
19706
19707         * lib/stdbool.h.in: New file.
19708
19709 2003-01-09  Bruno Haible  <bruno@clisp.org>
19710
19711         * gnulib-tool (func_all_modules): Ignore files ending in ~.
19712         * MODULES.html.sh: Likewise.
19713
19714 2003-01-08  Jim Meyering  <jim@meyering.net>
19715
19716         * lib/full-write.c: Undefine and define-away `const' after inclusion
19717         of errno.h, not before.  Suggestion from Bruno Haible.
19718
19719 2003-01-08  Bruno Haible  <bruno@clisp.org>
19720
19721         * modules/full-read: Depend on full-write.
19722
19723 2003-01-08  Bruno Haible  <bruno@clisp.org>
19724
19725         * lib/safe-read.c: Include specification header first, to ensure its
19726         selfcontainedness.
19727         * lib/full-write.c: Likewise.
19728
19729 2003-01-07  Jim Meyering  <jim@meyering.net>
19730
19731         * lib/full-write.c: Rework so that it may serve to define full_read,
19732         too.
19733         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
19734
19735 2003-01-07  Bruno Haible  <bruno@clisp.org>
19736
19737         * lib/strtoimax.c: Include <stdint.h> as an alternative to
19738         <inttypes.h>.
19739         * lib/xstrtol.h: Likewise.
19740         * lib/xstrtoimax.c: Likewise.
19741         * lib/xstrtoumax.c: Likewise.
19742         * lib/human.h: Likewise.
19743
19744         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
19745         on systems that have <inttypes.h> but not <stdint.h>.
19746
19747 2003-01-07  Bruno Haible  <bruno@clisp.org>
19748
19749         * MODULES.html.sh: Add copyright notice.
19750         (missed_files): Omit CVS directory entries.
19751         (func_module): Make it work with sed-3.02.
19752         * MODULES.txt: Remove file.
19753
19754 2003-01-06  Jim Meyering  <jim@meyering.net>
19755
19756         * lib/version-etc.c: Update year in translatable copyright string.
19757
19758 2003-01-03  Karl Berry  <karl@gnu.org>
19759
19760         * config/config.{guess,sub}: update from prep.
19761
19762 2003-01-02  Karl Berry  <karl@gnu.org>
19763
19764         * doc/COPYING.DOC: belatedly updated to 1.2.
19765
19766 2003-01-01  Karl Berry  <karl@gnu.org>
19767
19768         * gnulib-tool (func_verify_module): report module name $module in
19769         error message, not $1.
19770         * gnulib-tool (create-testdir): don't complain if destdir couldn't
19771         be created, only if it doesn't exist.
19772         * gnulib-tool (last_checkin_date): don't expand the $Date here.
19773
19774 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19775
19776         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
19777
19778 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19779
19780         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
19781         memcmp if strcoll doesn't work.
19782
19783 2002-12-31  Bruno Haible  <bruno@clisp.org>
19784
19785         * lib/utime.c (utime_null): No need to call ftruncate if the file was
19786         nonempty.
19787
19788 2002-12-31  Bruno Haible  <bruno@clisp.org>
19789
19790         * lib/memcoll.c (STRCOLL): New macro.
19791         (memcoll): Use it.
19792
19793 2002-12-31  Bruno Haible  <bruno@clisp.org>
19794
19795         * lib/localcharset.h: New file.
19796         * lib/localcharset.c: Include it.
19797         * lib/unicodeio.c: Likewise.
19798
19799 2002-12-31  Bruno Haible  <bruno@clisp.org>
19800
19801         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
19802         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
19803
19804 2002-12-31  Bruno Haible  <bruno@clisp.org>
19805
19806         * lib/getline.h: Include <stddef.h>, for size_t.
19807
19808         * lib/unicodeio.h: Include <stddef.h>, for size_t.
19809         * lib/unicodeio.c: Don't include <stddef.h>.
19810
19811 2002-12-31  Bruno Haible  <bruno@clisp.org>
19812
19813         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
19814         HAVE_TM_ZONE.
19815
19816 2002-12-24  Karl Berry  <karl@gnu.org>
19817
19818         * config/config.guess: update from prep.
19819
19820 2002-12-24  Bruno Haible  <bruno@clisp.org>
19821
19822         General infrasructure.
19823         * m4/README: Rewritten.
19824         * m4/onceonly.m4: New file.
19825         * m4/onceonly_2_57.m4: New file.
19826
19827         Module atexit.
19828         * m4/atexit.m4: New file.
19829
19830         Module strtod.
19831         * m4/strtod.m4: New file.
19832
19833         Module strtol.
19834         * m4/strtol.m4: New file.
19835
19836         Module strtoul.
19837         * m4/strtoul.m4: New file.
19838
19839         Module memchr.
19840         * m4/memchr.m4: New file.
19841
19842         Module memcmp.
19843         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
19844         (jm_FUNC_MEMCMP): Invoke it.
19845
19846         Module memcpy.
19847         * m4/memcpy.m4: New file.
19848
19849         Module memmove.
19850         * m4/memmove.m4: New file.
19851
19852         Module memset.
19853         * m4/memset.m4: New file.
19854
19855         Module strcspn.
19856         * m4/strcspn.m4: New file.
19857
19858         Module strpbrk.
19859         * m4/strpbrk.m4: New file.
19860
19861         Module strstr.
19862         * m4/strstr.m4: New file.
19863
19864         Module strerror.
19865         * m4/strerror.m4: New file.
19866
19867         Module mktime.
19868         * m4/mktime.m4: Renamed from jm-mktime.m4.
19869         (gl_PREREQ_MKTIME): New macro.
19870         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
19871
19872         Module malloc.
19873         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
19874         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
19875         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
19876
19877         Module realloc.
19878         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
19879         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
19880         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
19881
19882         Module strftime.
19883         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
19884         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
19885         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
19886         gl_TM_GMTOFF.
19887         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
19888
19889         Module xalloc.
19890         * m4/xalloc.m4: New file.
19891
19892         Module alloca.
19893         * m4/alloca.m4: New file.
19894
19895         Module putenv.
19896         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
19897         (jm_FUNC_PUTENV): Invoke it.
19898
19899         Module setenv.
19900         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
19901         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
19902         when invoked twice.
19903         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
19904         gt_FUNC_SETENV.
19905
19906         Module memrchr.
19907         * m4/memrchr.m4: New file.
19908
19909         Module stpcpy.
19910         * m4/stpcpy.m4: New file.
19911
19912         Module strcase.
19913         * m4/strcase.m4: New file.
19914
19915         Module strdup.
19916         * m4/strdup.m4: New file.
19917
19918         Module strnlen.
19919         * m4/strnlen.m4: New file.
19920
19921         Module strndup.
19922         * m4/strndup.m4: New file.
19923
19924         Module xstrtod.
19925         * m4/xstrtod.m4: New file.
19926
19927         Module xstrtol.
19928         * m4/xstrtol.m4: New file.
19929
19930         Module getdate.
19931         * m4/getdate.m4: New file.
19932
19933         Module unlocked-io.
19934         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
19935         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
19936         * m4/jm-glibc-io.m4n: Remove file.
19937
19938         Module long-options.
19939         * m4/long-options.m4: New file.
19940
19941         Module md5.
19942         * m4/md5.m4: New file.
19943
19944         Module sha.
19945         * m4/sha.m4: New file.
19946
19947         Module getstr.
19948         * m4/getstr.m4: New file.
19949
19950         Module getline.
19951         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
19952         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
19953         <sys/types.h>, for size_t. Use the function name gnu_getline, not
19954         simply getline. Infoke gl_PREREQ_GETLINE.
19955
19956         Module obstack.
19957         * m4/obstack.m4: New file.
19958
19959         Module hash.
19960         * m4/hash.m4: New file.
19961
19962         Module readtokens.
19963         * m4/readtokens.m4: New file.
19964
19965         Module strverscmp.
19966         * m4/strverscmp.m4: New file.
19967
19968         Module stdbool.
19969         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
19970         OSF/1.
19971
19972         Module strtoll.
19973         * m4/strtoll.m4: New file.
19974
19975         Module strtoull.
19976         * m4/strtoull.m4: New file.
19977
19978         Module strtoimax.
19979         * m4/strtoimax.m4: New file.
19980
19981         Module strtoumax.
19982         * m4/strtoumax.m4: New file.
19983
19984         Module xstrtoimax.
19985         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
19986         jm_AC_PREREQ_XSTRTOIMAX.
19987         Moved the strtol prerequisites to strtol.m4.
19988         Moved the strtoll prerequisites to strtoll.m4.
19989         Moved the strtoimax prerequisites to strtoimax.m4.
19990
19991         Module xstrtoumax.
19992         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
19993         jm_AC_PREREQ_XSTRTOUMAX.
19994         Moved the strtoul prerequisites to strtoul.m4.
19995         Moved the strtoull prerequisites to strtoull.m4.
19996         Moved the strtoumax prerequisites to strtoumax.m4.
19997
19998         Module chown.
19999         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
20000         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
20001
20002         Module dup2.
20003         * m4/dup2.m4: New file.
20004
20005         Module ftruncate.
20006         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
20007         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
20008
20009         Module getgroups.
20010         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
20011         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
20012
20013         Module gettimeofday.
20014         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
20015         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
20016         gl_PREREQ_GETTIMEOFDAY.
20017
20018         Module mkdir.
20019         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
20020         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
20021
20022         Module mkstemp.
20023         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
20024         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
20025         jm_AC_TYPE_UINTMAX_T.
20026         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
20027
20028         Module stat.
20029         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
20030         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
20031
20032         Module lstat.
20033         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
20034         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
20035
20036         Module timespec.
20037         * m4/timespec.m4 (gl_TIMESPEC): New macro.
20038         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
20039         * m4/st_mtim.m4: Indentation.
20040
20041         Module nanosleep.
20042         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
20043         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
20044         gl_PREREQ_NANOSLEEP.
20045
20046         Module regex.
20047         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
20048         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
20049         (gl_REGEX): New macro.
20050
20051         Module rename.
20052         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
20053         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
20054
20055         Module rmdir.
20056         * m4/rmdir.m4: New file.
20057
20058         Module utime.
20059         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
20060         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
20061         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
20062
20063         Module dirname.
20064         * m4/dirname.m4: New file.
20065
20066         Module getopt.
20067         * m4/getopt.m4: New file.
20068
20069         Module unistd-safer.
20070         * m4/unistd-safer.m4: New file.
20071
20072         Module fnmatch.
20073         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
20074         declaration.
20075         (gl_PREREQ_FNMATCH_EXTRA): New macro.
20076         (gl_FUNC_FNMATCH_POSIX): New macro.
20077         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
20078         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
20079         simply fnmatch.
20080
20081         Module exclude.
20082         * m4/exclude.m4: New file.
20083
20084         Module human.
20085         * m4/human.m4: New file.
20086
20087         Module acl.
20088         * m4/acl.m4: Nop.
20089
20090         Module backupfile.
20091         * m4/backupfile.m4: New file.
20092         * m4/d-ino.m4: Indentation.
20093
20094         Module fsusage.
20095         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
20096         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
20097         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
20098
20099         Module dirfd.
20100         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
20101         requirements.
20102
20103         Module euidaccess.
20104         * m4/euidaccess.m4: New file.
20105
20106         Module file-type.
20107         * m4/file-type.m4: New file.
20108
20109         Module fileblocks.
20110         * m4/fileblocks.m4: New file.
20111
20112         Module filemode.
20113         * m4/filemode.m4: New file.
20114
20115         Module isdir.
20116         * m4/isdir.m4: New file.
20117
20118         Module lchown.
20119         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
20120         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
20121
20122         Module makepath.
20123         * m4/makepath.m4: New file.
20124
20125         Module modechange.
20126         * m4/modechange.m4: New file.
20127
20128         Module mountlist.
20129         * m4/mountlist.m4: New file.
20130         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
20131         Indentation.
20132
20133         Module path-concat.
20134         * m4/path-concat.m4: New file.
20135
20136         Module pathmax.
20137         * m4/pathmax.m4: New file.
20138
20139         Module same.
20140         * m4/same.m4: New file.
20141
20142         Module save-cwd.
20143         * m4/save-cwd.m4: New file.
20144
20145         Module savedir.
20146         * m4/savedir.m4: New file.
20147
20148         Module xgetcwd.
20149         * m4/xgetcwd.m4: New file.
20150         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
20151
20152         Module xreadlink.
20153         * m4/xreadlink.m4: New file.
20154
20155         Module safe-read.
20156         * m4/safe-read.m4: New file.
20157
20158         Module safe-write.
20159         * m4/safe-write.m4: New file.
20160
20161         Module closeout.
20162         * m4/closeout.m4: New file.
20163
20164         Module stdio-safer.
20165         * m4/stdio-safer.m4: New file.
20166
20167         Module getpass.
20168         * m4/getpass.m4: New file.
20169
20170         Module getugroups.
20171         * m4/getugroups.m4: New file.
20172
20173         Module group-member.
20174         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
20175         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
20176
20177         Module idcache.
20178         * m4/idcache.m4: New file.
20179
20180         Module userspec.
20181         * m4/userspec.m4: New file.
20182
20183         Module gettime.
20184         * m4/clock_time.m4: New file.
20185         * m4/gettime.m4: New file.
20186
20187         Module settime.
20188         * m4/settime.m4: New file.
20189
20190         Module posixtm.
20191         * m4/posixtm.m4: New file.
20192
20193         Module gethostname.
20194         * m4/gethostname.m4: New file.
20195
20196         Module canon-host.
20197         * m4/canon-host.m4: New file.
20198
20199         Module gettext.
20200         * m4/codeset.m4: New file, from gettext-0.11.5.
20201         * m4/gettext.m4: New file, from gettext-0.11.5.
20202         * m4/glibc21.m4: New file, from gettext-0.11.5.
20203         * m4/iconv.m4: New file, from gettext-0.11.5.
20204         * m4/intdiv0.m4: New file, from gettext-0.11.5.
20205         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
20206         * m4/inttypes.m4: New file, from gettext-0.11.5.
20207         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
20208         * m4/isc-posix.m4: New file, from gettext-0.11.5.
20209         * m4/lcmessage.m4: New file, from gettext-0.11.5.
20210         * m4/lib-ld.m4: New file, from gettext-0.11.5.
20211         * m4/lib-link.m4: New file, from gettext-0.11.5.
20212         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
20213         * m4/progtest.m4: New file, from gettext-0.11.5.
20214         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
20215         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
20216         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
20217
20218         Module localcharset.
20219         * m4/localcharset.m4: New file.
20220
20221         Module hard-locale.
20222         * m4/hard-locale.m4: New file.
20223
20224         Module mbswidth.
20225         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
20226         onceonly macros.
20227         * m4/mbrtowc.m4: Add comment.
20228
20229         Module memcasecmp.
20230         * m4/memcasecmp.m4: New file.
20231
20232         Module memcoll.
20233         * m4/memcoll.m4: New file.
20234
20235         Module unicodeio.
20236         * m4/unicodeio.m4: New file.
20237
20238         Module rpmatch.
20239         * m4/rpmatch.m4: New file.
20240
20241         Module yesno.
20242         * m4/yesno.m4: New file.
20243
20244         Module exitfail.
20245         * m4/exitfail.m4: New file.
20246
20247         Module c-stack.
20248         * m4/c-stack.m4 (gl_C_STACK): New macro.
20249         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
20250
20251         Module error.
20252         * m4/error.m4 (gl_ERROR): New macro.
20253         (jm_PREREQ_ERROR): Use onceonly macros.
20254
20255         Module fatal.
20256         * m4/fatal.m4: New file.
20257
20258         Module getloadavg.
20259         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
20260         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
20261
20262         Module getpagesize.
20263         * m4/getpagesize.m4: New file.
20264
20265         Module getusershell.
20266         * m4/getusershell.m4: New file.
20267
20268         Module physmem.
20269         * m4/physmem.m4: New file.
20270
20271         Module posixver.
20272         * m4/posixver.m4: New file.
20273
20274         Module quotearg.
20275         * m4/quotearg.m4: New file.
20276
20277         Module quote.
20278         * m4/quote.m4: New file.
20279
20280         Module readutmp.
20281         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
20282
20283         Module sig2str.
20284         * m4/sig2str.m4: New file.
20285
20286         Other.
20287         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
20288         ulonglong.m4.
20289         * m4/intmax_t.m4: New file.
20290         * m4/d-type.m4: Indentation.
20291         * m4/jm-macros.m4: Update.
20292         * m4/prereq.m4 (jm_PREREQ): Update.
20293         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
20294         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
20295         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
20296         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
20297         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
20298         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
20299         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
20300         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
20301         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
20302         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
20303         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
20304         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
20305         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
20306         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
20307         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
20308         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
20309         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
20310         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
20311         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
20312
20313 2002-12-24  Bruno Haible  <bruno@clisp.org>
20314
20315         * MODULES.txt: Update according to m4/ changes.
20316
20317         Module gettext.
20318         * config.rpath: New file, from gettext-0.11.5.
20319
20320         * modules/*: New module descriptions.
20321         * gnulib-tool: New file.
20322         * MODULES.html.sh: New file.
20323
20324 2002-12-21  Karl Berry  <karl@gnu.org>
20325
20326         * doc/fdl.texi: update to version 1.2.
20327
20328 2002-12-19  Karl Berry  <karl@gnu.org>
20329
20330         * config/config.guess: update from prep.
20331
20332 2002-12-18  Bruno Haible  <bruno@clisp.org>
20333
20334         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
20335         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
20336
20337 2002-12-17  Bruno Haible  <bruno@clisp.org>
20338
20339         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
20340         stdlib.h, string.h.
20341
20342 2002-12-17  Bruno Haible  <bruno@clisp.org>
20343
20344         * lib/canon-host.c (strdup): Remove unused declaration.
20345
20346         * lib/fsusage.c: Include full_read.h.
20347         (get_fs_usage): Use full_read instead of safe_read.
20348
20349         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
20350
20351 2002-12-12  Karl Berry  <karl@gnu.org>
20352
20353         * config/config.guess: update from prep.
20354
20355 2002-12-11  Bruno Haible  <bruno@clisp.org>
20356
20357         * m4/setenv.m4: New file, from gettext-0.11.5.
20358
20359 2002-12-11  Bruno Haible  <bruno@clisp.org>
20360
20361         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
20362         not unsetenv().
20363         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
20364         modifications:
20365
20366         2002-12-11  Bruno Haible  <bruno@clisp.org>
20367
20368                 * setenv.c (alloca): Fall back to malloc.
20369                 (freea): New macro.
20370                 (setenv): Use freea() to free memory allocated with alloca().
20371
20372         2002-11-13  Bruno Haible  <bruno@clisp.org>
20373
20374                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
20375                 function declarations.
20376                 * unsetenv.c (unsetenv): Likewise.
20377
20378         2002-03-04  Bruno Haible  <bruno@clisp.org>
20379
20380                 Portability to AIX 4.3.3.
20381                 * unsetenv.c: New file, extracted from setenv.c.
20382                 * setenv.c: Move the unsetenv() function to unsetenv.c.
20383
20384         2001-12-20  Bruno Haible  <bruno@clisp.org>
20385
20386                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
20387                 use malloc instead. For SunOS 4.
20388
20389         2001-12-11  Bruno Haible  <bruno@clisp.org>
20390
20391                 * setenv.c: Declare alloca.
20392                 (compar_fn_t): New typedef.
20393                 (KNOWN_VALUE, STORE_VALUE): Use it.
20394
20395         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
20396         setenv.h.
20397
20398 2002-12-10  Paul Eggert  <eggert@twinsun.com>
20399
20400         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
20401         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
20402         Choose values that are less likely to collide with system fnmatch
20403         options.
20404         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
20405         defined (e.g., a pure POSIX system).
20406         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
20407         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
20408
20409 2002-12-06  Paul Eggert  <eggert@twinsun.com>
20410
20411         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
20412         a pain in practice to deal with generated m4 files.  This change
20413         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
20414
20415         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
20416         and jm-glibc-io.m4, as they are no longer a special case.
20417         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
20418         kludge and the auto-generation stuff.  Check only whether the
20419         functions are declared, not whether they exist, since older hosts
20420         that don't declare the functions can't use the optimization anyway.
20421
20422 2002-12-06  Jim Meyering  <jim@meyering.net>
20423
20424         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
20425
20426         Merge in changes from libc's misc/error.c, in preparation
20427         for the merge of gnulib's changes back into libc.
20428
20429         * lib/error.c (_): Define only if not already defined.
20430         Move definition to follow all #include directives.
20431         Include unlocked-io.h only if !_LIBC.
20432         [_LIBC]: Include <libio/libioP.h>.
20433         [USE_IN_LIBIO]: Include <libio/iolibio.h>
20434         (fflush): Tweak definition to use INTUSE.
20435         (putc): Define.
20436
20437 2002-12-05  Paul Eggert  <eggert@twinsun.com>
20438
20439         * lib/alloca.c [defined emacs]: Include "lisp.h".
20440         (xalloc_die) [defined emacs]: New macro.
20441         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
20442         [! defined emacs]: Include <xalloc.h>.
20443         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
20444         (pointer): Typedef to POINTER_TYPE *.
20445         (malloc): Remove decl; we now always use xmalloc.
20446         (alloca): Use old-style definition, since Emacs needs this.
20447         Check for arithmetic overflow when computing combined size.
20448
20449 2002-12-04  Paul Eggert  <eggert@twinsun.com>
20450
20451         Do not generate unlocked-io.h automatically, since it's easier to
20452         maintain it by hand.
20453
20454         * lib/unlocked-io.h: New file, from GNU diffutils,
20455         but with proper copyright notice and attribution.
20456         * lib/gen-uio: Remove.
20457         * lib/Makefile.am: Add copyright notice.
20458         (libfetish_a_SOURCES): Add unlocked-io.h.
20459         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
20460         (DISTCLEANFILES, io_functions): Remove macros.
20461         (EXTRA_DIST): Remove gen_uio.
20462         (unlocked-io.h): Remove rule.
20463
20464 2002-12-04  Jim Meyering  <jim@meyering.net>
20465
20466         Reflect the fact that stat.c and lstat.c are no longer generated.
20467         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
20468         (DISTCLEANFILES): Likewise.
20469         (EXTRA_DIST): Likewise.
20470         (all_local): Don't depend on stat.c or lstat.c.
20471         (stat.c, lstat.c): Remove rules.
20472         (EXTRA_DIST): Remove xstat.in.
20473
20474         * lib/xstat.in: Remove file.  Contents moved into stat.c.
20475         * lib/stat.c: New file.  Contents mostly from xstat.in.
20476         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
20477         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
20478
20479         * lib/safe-read.c: Rework so that it may serve to define safe_write,
20480         too.
20481         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
20482
20483 2002-12-03  Jim Meyering  <jim@meyering.net>
20484
20485         * lib/safe-read.c, safe-write.c: Change variable names and comments,
20486         but not semantics, to minimize the differences between these two files.
20487         (safe_read): Change comment to mention SAFE_READ_ERROR.
20488
20489         * lib/safe-read.c (IS_EINTR): Define.
20490         (safe_read): Use IS_EINTR in place of in-function cpp directives.
20491
20492 2002-12-02  Jim Meyering  <jim@meyering.net>
20493
20494         * lib/safe-read.c (EINTR): Define.
20495         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20496         (INT_MAX): Provide fallback.
20497         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
20498
20499         * lib/safe-read.h (SAFE_READ_ERROR): Define.
20500
20501 2002-12-02  Bruno Haible  <bruno@clisp.org>
20502
20503         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
20504         Define, taken from safe-read.c.
20505         (INT_MAX): Provide fallback.
20506         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
20507         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
20508
20509         * lib/safe-read.c (EINTR): Remove definition.
20510         (safe_read): Don't use EINTR if it is absent.
20511
20512 2002-12-01  Jim Meyering  <jim@meyering.net>
20513
20514         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
20515         zero.
20516         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
20517
20518 2002-11-27  Paul Eggert  <eggert@twinsun.com>
20519
20520         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
20521         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
20522         with `if (! (value < limit)) abort ();', for readability.
20523
20524 2002-11-26  Karl Berry  <karl@gnu.org>
20525
20526         * lib/strdup.c: copy from libc again, with jim's ok.
20527         * lib/.cppi-disable: re-add strdup.c
20528
20529 2002-11-25  Karl Berry  <karl@gnu.org>
20530
20531         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
20532         instead of "strtol.c".
20533
20534 2002-11-25  Karl Berry  <karl@gnu.org>
20535
20536         * config/install-sh: update from automake for variable quoting, $0 in
20537         error msgs, etc.
20538
20539         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
20540         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
20541         entry.
20542
20543 2002-11-25  Jim Meyering  <jim@meyering.net>
20544
20545         * lib/mktime.c: Sync from libc, now that it has the latest fix.
20546
20547 2002-11-24  Karl Berry  <karl@gnu.org>
20548
20549         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
20550         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
20551
20552 2002-11-24  Jim Meyering  <jim@meyering.net>
20553
20554         Update from coreutils:
20555
20556         * lib/mktime.c: Merge in changes from libc.
20557
20558         Avoid a link-time failure on some Linux systems.
20559         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
20560         (otherwise).
20561         (__mon_yday): Declare with the STATIC attribute.
20562         (__mktime_internal): Likewise.
20563         Based on a report from Greg Schafer.
20564
20565 2002-11-23  Jim Meyering  <jim@meyering.net>
20566
20567         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
20568         Use `unsigned', not `int', as type of index.
20569
20570         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
20571
20572         * lib/fsusage.c: Remove unneeded parentheses around operands of
20573         `defined'.
20574
20575 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20576
20577         * lib/quotearg.h: Allow multiple inclusion by surrounding with
20578         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
20579         so that we can be included first.
20580         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
20581         * lib/quotearg.c: Include quotearg.h immediately after config.h.
20582         No need to include stddef.h or sys/types.h any more.
20583         Surround local include files with "", not "<>".
20584         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
20585         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
20586         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
20587         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
20588         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
20589         (ISPRINT): Remove; no longer needed now that we assume C89.
20590
20591         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
20592         Preserve errno.
20593
20594         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
20595         quotearg_char): Use SIZE_MAX rather than
20596         (size_t) -1 when we are talking about "infinity".
20597
20598         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
20599
20600 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20601
20602         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
20603         hint that one should use `if (! x) abort ();' rather than `assert
20604         (x);', and anyway it's one less thing to worry about configuring.
20605         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
20606         hash_rehash, hash_insert): Use abort rather than assert.
20607
20608 2002-11-22  Bruno Haible  <bruno@clisp.org>
20609
20610         * lib/safe-read.h: Assume C89. Add comments.
20611         (safe_read): Change return type to size_t.
20612         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
20613         byte counts > SSIZE_MAX correctly.
20614         * lib/safe-write.h: New file.
20615         * lib/safe-write.c: New file.
20616         * lib/full-read.h: New file.
20617         * lib/full-read.c: New file.
20618         * lib/full-write.h: Assume C89. Add comments.
20619         * lib/full-write.c: Include safe-write.h.
20620         (full_write): Rewritten to use safe_write.
20621         Suggested by Jim Meyering and Paul Eggert.
20622
20623 2002-11-21  Jim Meyering  <jim@meyering.net>
20624
20625         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
20626
20627         Merge in changes from the coreutils.
20628
20629         2002-09-25  Paul Eggert  <eggert@twinsun.com>
20630         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
20631         <stdint.h>.
20632         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
20633         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
20634         int.  Work more efficiently if X is the same width as uintmax_t.
20635         Do not compare X to -1, to avoid bogus compiler warning.
20636         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
20637         Don't assume that f_frsize and f_bsize are the same type.
20638
20639         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
20640         warning on FreeBSD.
20641
20642         * lib/makepath.c (make_path): Restore umask *before* creating the final
20643         component.
20644         (make_path): Minor reformatting.
20645
20646         * lib/xmalloc.c: Adjust to work with new autoconf macros,
20647         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
20648         HAVE_MALLOC/HAVE_REALLOC.
20649
20650         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
20651         dummy ones.  At least on GNU/Linux systems, `auto' means something
20652         else.
20653         From Michael Stone.
20654
20655 2002-11-21  Bruno Haible  <bruno@clisp.org>
20656
20657         Remove case insensitive option matching.
20658         * lib/argmatch.h (argcasematch): Remove declaration.
20659         (ARGCASEMATCH): Remove macro.
20660         (__xargmatch_internal): Remove case_sensitive argument.
20661         (XARGMATCH): Update.
20662         (XARGCASEMATCH): Remove macro.
20663         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
20664         case_sensitive argument.
20665         (argcasematch): Remove function.
20666         (__xargmatch_internal): Remove case_sensitive argument.
20667         (main): Use XARGMATCH instead of XARGCASEMATCH.
20668
20669         * lib/xmalloc.c: Change compile-time error message. Add comment about
20670         required autoconf version.
20671
20672 2002-11-20  Paul Eggert  <eggert@twinsun.com>
20673
20674         Merge argmatch cleanups from Bison.  Assume C89.
20675
20676         * lib/argmatch.c: Include config.h here, not in argmatch.h.
20677         Include stdlib.h, for EXIT_FAILURE.
20678         Always include <string.h>, since we assume C89.
20679         (EXIT_FAILURE): Remove pre-C89 bug workaround.
20680         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
20681         Include <stddef.h> instead, since it's all we need for size_t.
20682         (PARAMS): Remove.  All uses removed.
20683         (ARRAY_CARDINALITY): Do not bother to #undef.
20684         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
20685         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20686         Remove unnecessary parentheses.
20687         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20688         Insert necessary parentheses.
20689         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
20690         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
20691
20692 2002-11-19  Bruno Haible  <bruno@clisp.org>
20693
20694         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
20695         * lib/mbswidth.h: Include <stddef.h>, for size_t.
20696
20697         * lib/mbswidth.h (PARAMS): Remove macro.
20698         (mbswidth, mbsnwidth): Use ANSI C function declarations.
20699         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
20700
20701         * lib/gcd.h (PARAMS): Remove macro.
20702         (gcd): Use ANSI C function declarations.
20703         * lib/gcd.c (gcd): Likewise.
20704
20705 2002-11-15  Bruno Haible  <bruno@clisp.org>
20706
20707         * lib/strcspn.c: Include <stddef.h>.
20708         (strcspn): Use ANSI C function declaration. Change return type to
20709         size_t. Use NULL.
20710         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
20711         (strpbrk): Use NULL.
20712         * lib/strpbrk.h (PARAMS): Remove macro.
20713         (strpbrk): Use ANSI C function declaration.
20714         * lib/strstr.c: Don't include <sys/types.h>.
20715         * lib/strstr.h (PARAMS): Remove macro.
20716         (strstr): Use ANSI C function declarations.
20717
20718 2002-11-14  Karl Berry  <karl@gnu.org>
20719
20720         * config/mkinstalldirs: `do' on separate line, instead of
20721         `for var; do'.
20722
20723 2002-11-06  Bruno Haible  <bruno@clisp.org>
20724
20725         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
20726         * lib/gcd.c (gcd): Likewise.
20727
20728 2002-11-05  Bruno Haible  <bruno@clisp.org>
20729
20730         * lib/gcd.h: New file, from gettext-0.11.5.
20731         * lib/gcd.c: New file, from gettext-0.11.5.
20732
20733 2002-11-05  Bruno Haible  <bruno@clisp.org>
20734
20735         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20736         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20737         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20738         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20739
20740         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
20741         <libintl.h>.
20742         * lib/makepath.c: Include gettext.h instead of <locale.h> and
20743         <libintl.h>.
20744
20745         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
20746         * lib/human.c: Include gettext.h instead of <libintl.h>.
20747         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
20748         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
20749         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
20750         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
20751         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
20752         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
20753         (textdomain): Remove definition.
20754         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
20755
20756         * lib/long-options.c: Remove include of <libintl.h> and definition of
20757         _.
20758         * lib/same.c: Remove include of <libintl.h> and definition of _.
20759
20760 2002-11-04  Owen Taylor  <otaylor@redhat.com>
20761
20762         * lib/config.charset: A few additions for Solaris.
20763
20764 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20765
20766         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
20767         * lib/localcharset.c (locale_charset): Declare as extern "C".
20768
20769 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20770
20771         * lib/config.charset: msdos in uk_UA uses CP1125.
20772
20773 2002-11-04  Bruno Haible  <bruno@clisp.org>
20774
20775         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
20776         * lib/strcase.h: New file, from GNU gettext-0.11.5.
20777         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
20778         * lib/strstr.h: New file, from GNU gettext-0.11.5.
20779         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
20780
20781 2002-11-04  Bruno Haible  <bruno@clisp.org>
20782
20783         * lib/localcharset.c (locale_charset): Don't return an empty string.
20784
20785 2002-11-04  Bruno Haible  <bruno@clisp.org>
20786
20787         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
20788         aliases.
20789
20790 2002-11-04  Bruno Haible  <bruno@clisp.org>
20791
20792         * lib/config.charset: Update for newest glibc. Add canonical names
20793         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
20794
20795 2002-11-04  Bruno Haible  <bruno@clisp.org>
20796
20797         * lib/config.charset: Add support for NetBSD.
20798
20799 2002-11-04  Bruno Haible  <bruno@clisp.org>
20800
20801         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
20802
20803 2002-11-01  Bruno Haible  <bruno@clisp.org>
20804
20805         * configure.in: Add AC_CONFIG_AUX_DIR call.
20806         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
20807         test/Makefile.
20808         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
20809
20810 2002-09-28  Karl Berry  <karl@gnu.org>
20811
20812         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
20813         installed automake until the next release, since changes have been
20814         made.
20815
20816 2002-09-25  Karl Berry  <karl@gnu.org>
20817
20818         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
20819         * lib/getopt*: copy from libc/posix.
20820         * lib/gettext.h: copy from gettext.
20821         * lib/.cppi-disable: add strdup.c, gettext.h.
20822
20823 2002-09-25  Karl Berry  <karl@gnu.org>
20824
20825         * config/srclist.txt: enable gettext.h check.
20826         * config/config.{guess,sub}: update from prep.
20827         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
20828                 from automake 1.6.3.
20829         See srclist*.
20830
20831 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
20832
20833         * regex.c (PATFETCH): Remove the translating fetch.
20834         (PATFETCH_RAW): Rename to PATFETCH.
20835         (set_image_of_range): New fun.
20836         (SET_RANGE_TABLE_WORK_AREA): Use it.
20837         (regex_compile): Don't translate the pattern chars so eagerly.
20838         Only do it when inserting an `exactn' bytecode or when handling
20839         a char-range.
20840         (mutually_exclusive_p): Avoid empty statement.
20841
20842 2002-07-06  Jim Meyering  <meyering@lucent.com>
20843
20844         * m4/README: Don't mention Makefile.am.in.
20845         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
20846
20847 2002-07-01  Jim Meyering  <meyering@lucent.com>
20848
20849         * lib/c-stack.c: Include sys/time.h.
20850         From Volker Borchert.
20851
20852 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20853
20854         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
20855
20856 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20857
20858         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
20859         New macro.  Use it uniformly instead of
20860         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
20861         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
20862         reported by Vin Shelton.
20863
20864 2002-06-22  Paul Eggert  <eggert@twinsun.com>
20865
20866         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
20867         Do not assume SA_SIGINFO behavior.
20868         Bug reported by Jim Meyering on NetBSD 1.5.2.
20869
20870 2002-06-22  Jim Meyering  <meyering@lucent.com>
20871
20872         * m4/c-stack.m4: New file, from diffutils-2.8.2.
20873         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
20874
20875         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
20876         now that configure.ac uses AC_GNU_SOURCE.
20877         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
20878         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
20879
20880         Update to latest tools.  Suggestions from Paul Eggert.
20881         * m4/stdbool.m4: New file, from diffutils-2.8.2.
20882         * m4/gnu-source.m4: Update from diffutils-2.8.2.
20883         * m4/fnmatch.m4: Likewise.
20884         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
20885         to AC_HEADER_STDBOOL
20886
20887 2002-06-22  Jim Meyering  <meyering@lucent.com>
20888
20889         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
20890         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
20891
20892 2002-06-22  Jim Meyering  <meyering@lucent.com>
20893
20894         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
20895
20896         * lib/exitfail.c, exitfail.h: Likewise.
20897         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
20898
20899         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
20900         of fnmatch.h.
20901         (EXTRA_DIST): Add fnmatch_loop.c.
20902         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
20903
20904         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
20905         * lib/fnmatch.c: Update from diffutils-2.8.2.
20906         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
20907         * lib/fnmatch.h: Remove file.
20908
20909 2002-06-21  Jim Meyering  <meyering@lucent.com>
20910
20911         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
20912         * m4/mbrtowc.m4: Likewise.
20913
20914         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
20915         * m4/mbswidth.m4: Reflect name change:
20916         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
20917         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
20918
20919         * m4/lib-link.m4: Update from gettext-0.11.2.
20920         * m4/gettext.m4: Likewise.
20921
20922         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
20923         From Alfred M. Szmidt.
20924
20925 2002-06-18  Paul Eggert  <eggert@twinsun.com>
20926
20927         * lib/file-type.h: Report an error if neither S_ISREG nor
20928         S_IFREG is defined, instead of using a test specific to glibc
20929         2.2.  This should be safe, since POSIX requires S_ISREG and
20930         Unix Version 7 had S_IFREG.  We don't need to check for
20931         <sys/types.h> since we don't use any symbols that it defines.
20932
20933 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
20934
20935         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
20936         $@-t, so that each temporary file name is unique and valid in the first
20937         8 characters, for operation under DOS.
20938
20939 2002-06-15  Paul Eggert  <eggert@twinsun.com>
20940
20941         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
20942
20943 2002-06-15  Jim Meyering  <meyering@lucent.com>
20944
20945         Work even with DJGPP 2.03, which lacks support for symlinks.
20946         From Richard Dawe.
20947         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
20948         is defined.
20949         * lib/lchown.c (S_ISLNK): Likewise.
20950
20951 2002-06-15  Jim Meyering  <meyering@lucent.com>
20952
20953         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
20954         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
20955         have been included before this file.
20956
20957 2002-06-14  Jim Meyering  <meyering@lucent.com>
20958
20959         * lib/file-type.h: Use the version from diffutils-2.8.2.
20960         * lib/file-type.c: Likewise.
20961
20962 2002-06-07  Jim Meyering  <meyering@lucent.com>
20963
20964         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
20965         They're needed at least for NetBSD 1.5.2.
20966         ($statxfs_includes): Include those same headers.
20967         ($statxfs_includes): Include sys/vfs.h if available.
20968         ($statxfs_includes): Likewise for sys/statvfs.h.
20969         Check for the following members in both structs statfs and statvfs:
20970         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
20971
20972 2002-06-01  Jim Meyering  <meyering@lucent.com>
20973
20974         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
20975         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
20976
20977 2002-05-28  Jim Meyering  <meyering@lucent.com>
20978
20979         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
20980         Reported by Volker Borchert.
20981
20982 2002-05-27  Jim Meyering  <meyering@lucent.com>
20983
20984         Fix a problem seen only on nonconforming systems whereby ls.c's
20985         use of localtime, and then of gettimeofday would cause trouble:
20986         the localtime call used to initialize rpl_gettimeofday's save
20987         mechanism would clobber ls's current local time information so
20988         that in any long listing the first file would always be listed
20989         with date 1970-01-01.  Analysis by Volker Borchert.
20990
20991         * lib/gettimeofday.c (localtime): Undefine.
20992         (rpl_localtime): New function.
20993
20994 2002-05-27  Jim Meyering  <meyering@lucent.com>
20995
20996         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
20997         localtime.
20998
20999         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
21000         use the replacement function; it wouldn't resolve at link time.
21001         Reported by Volker Borchert.
21002
21003 2002-05-22  Jim Meyering  <meyering@lucent.com>
21004
21005         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
21006         file-type.h.
21007         * lib/file-type.h: New file.
21008         * lib/file-type.c (file_type): New file/function.  Extracted from
21009         diffutils.
21010
21011 2002-04-30  Jim Meyering  <meyering@lucent.com>
21012
21013         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
21014
21015 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21016
21017         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
21018
21019 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21020
21021         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
21022         Do not check for alloca.h (no longer used) or stdbool.h (was never
21023         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
21024
21025 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21026
21027         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
21028
21029 2002-04-29  Jim Meyering  <meyering@lucent.com>
21030
21031         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
21032         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
21033         Use AC_FUNC_STRNLEN here instead.
21034
21035         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
21036         With autoconf-2.53a, it's part of AC_PROG_CC.
21037
21038 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21039
21040         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
21041         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
21042
21043 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21044
21045         * lib/sig2str.h, lib/sig2str.c: New files.
21046         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
21047
21048 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21049
21050         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
21051         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
21052         of 127, since 64 is the largest conceivable number for ancient
21053         nonstandard hosts.
21054         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
21055
21056 2002-04-28  Jim Meyering  <meyering@lucent.com>
21057
21058         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
21059
21060 2002-04-24  Jim Meyering  <meyering@lucent.com>
21061
21062         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
21063         (jm_PREREQ): Use it.
21064
21065         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
21066         mach/mach.h fcntl.h.
21067         Check for this function: setlocale.
21068
21069 2002-04-24  Jim Meyering  <meyering@lucent.com>
21070
21071         * lib/gettext.h: New file, from Gettext.
21072         * lib/Makefile.am (INCLUDES): Remove -I../intl.
21073         (libfetish_a_SOURCES): Add gettext.h.
21074
21075 2002-04-16  Jim Meyering  <meyering@lucent.com>
21076
21077         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
21078         ut_pid, ut_id, ut_exit.
21079
21080 2002-04-16  Jim Meyering  <meyering@lucent.com>
21081
21082         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
21083         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
21084         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
21085
21086 2002-04-12  Jim Meyering  <meyering@lucent.com>
21087
21088         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
21089         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
21090         existence of the getmntinfo function.  Needed for Darwin 5.3.
21091
21092         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
21093         This is necessary at least on Darwin 5.3.
21094
21095         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
21096         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
21097         strnlen.o in the library, and that makes some versions of ranlib
21098         object.
21099
21100 2002-04-12  Jim Meyering  <meyering@lucent.com>
21101
21102         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
21103
21104 2002-04-09  Jim Meyering  <meyering@lucent.com>
21105
21106         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
21107         to be more precise.  Rather than saying we're checking whether the
21108         function `works', say what we're testing.
21109         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
21110         Reported by Bruno Haible.
21111
21112 2002-03-10  Jim Meyering  <meyering@lucent.com>
21113
21114         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
21115         Suggestion from Santiago Vila.
21116
21117 2002-03-08  Jim Meyering  <meyering@lucent.com>
21118
21119         * lib/rename.c: Mention that this wrapper is needed also on
21120         mips-dec-ultrix4.4 systems.
21121
21122 2002-03-02  Jim Meyering  <meyering@lucent.com>
21123
21124         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
21125         not HAVE_CLOCK_SETTIME.
21126
21127 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21128
21129         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
21130         Check for clock_settime.
21131
21132 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21133
21134         * lib/nanosleep.h: Rename to....
21135         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
21136
21137         * lib/gettime.c: New file.
21138         * lib/settime.c: New file.
21139         * lib/stime.c: Remove.
21140
21141         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
21142         timespec.h.  Remove nanosleep.h.
21143
21144 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21145
21146         * m4/acl.m4: New file.
21147         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
21148         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
21149
21150 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21151
21152         * lib/acl.c, lib/acl.h: New files.
21153         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
21154
21155 2002-02-24  Jim Meyering  <meyering@lucent.com>
21156
21157         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
21158         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
21159         cause trouble.  Reported by Nelson Beebe.
21160
21161 2002-02-23  Paul Eggert  <eggert@twinsun.com>
21162
21163         * lib/path-concat.c (xpath_concat): Reorder code to pacify
21164         compilers that don't know that xalloc_die never returns.
21165
21166 2002-02-20  Jim Meyering  <meyering@lucent.com>
21167
21168         * lib/getdate.c: Regenerate using bison-1.33.
21169
21170 2002-02-17  Jim Meyering  <meyering@lucent.com>
21171
21172         * config/config.guess (main): Don't use `head -1'; it's no longer
21173         portable. Use `sed 1q' instead.
21174
21175 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
21176
21177         * m4/codeset.m4: Upgrade to gettext-0.11.
21178         * m4/gettext.m4: Upgrade to gettext-0.11.
21179         * m4/glibc21.m4: Upgrade to gettext-0.11.
21180         * m4/iconv.m4: Upgrade to gettext-0.11.
21181         * m4/isc-posix.m4: Upgrade to gettext-0.11.
21182         * m4/lcmessage.m4: Upgrade to gettext-0.11.
21183         * m4/lib-ld.m4: New file, from gettext-0.11.
21184         * m4/lib-link.m4: New file, from gettext-0.11.
21185         * m4/lib-prefix.m4: New file, from gettext-0.11.
21186         * m4/progtest.m4: Upgrade to gettext-0.11.
21187
21188 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21189
21190         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
21191         (jm_PREREQ): Use it.
21192
21193 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21194
21195         * lib/posixver.c, lib/posixver.h: New files.
21196         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21197
21198 2002-02-02  Paul Eggert  <eggert@twinsun.com>
21199             Bruno Haible  <bruno@clisp.org>
21200
21201         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
21202         (fwrite_success_callback): New declaration.
21203         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
21204         print_unicode_char. Call failure callback instead of error.
21205         (fwrite_success_callback): New function.
21206         (exit_failure_callback): New function.
21207         (fallback_failure_callback): New function.
21208         (print_unicode_char): Call unicode_to_mb.
21209
21210 2002-01-26  Jim Meyering  <meyering@lucent.com>
21211
21212         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
21213         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
21214
21215 2002-01-26  Jim Meyering  <meyering@lucent.com>
21216
21217         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
21218
21219 2002-01-22  Paul Eggert  <eggert@twinsun.com>
21220
21221         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
21222
21223 2002-01-22  Jim Meyering  <meyering@lucent.com>
21224
21225         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
21226         Otherwise, some versions of automake would omit the rule that makes
21227         Makefile from Makefile.in.
21228
21229 2002-01-21  Paul Eggert  <eggert@twinsun.com>
21230
21231         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
21232         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21233         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
21234         (memcoll): Set errno to zero if there is no error.
21235
21236         * lib/quotearg.c (quotearg_buffer_restyled):
21237         Fix bug with quoting buffers containing NUL when backslashing escapes.
21238         This bug was exposed by the other changes in this patch.
21239         (quotearg_n_options): New arg ARGSIZE.
21240         All callers changed.
21241         (quoting_options_from_style): New function.
21242         (quotearg_n_style): Use it.
21243         (quotearg_n_style_mem): New function.
21244
21245         * lib/quotearg.h (quotearg_n_style_mem): New function.
21246
21247 2002-01-19  Jim Meyering  <meyering@lucent.com>
21248
21249         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
21250         Remove useless quotes: DF_PROG="df".
21251         * m4/strnlen.m4: New file.
21252
21253 2002-01-16  Paul Eggert  <eggert@twinsun.com>
21254
21255         * lib/backupfile.c (ISDIGIT): Comment fix.
21256         * lib/getdate.y (ISDIGIT): Likewise.
21257         * lib/posixtm.c (ISDIGIT, year): Likewise.
21258         * lib/strverscmp.c (ISDIGIT): Likewise.
21259         * lib/userspec.c (ISDIGIT): Likewise.
21260
21261 2002-01-16  Jim Meyering  <meyering@lucent.com>
21262
21263         * lib/getdate.y: Add three semicolons, each just before a closing
21264         brace. Bison (as of version 1.31) no longer papers over that mistake.
21265
21266 2002-01-05  Jim Meyering  <meyering@lucent.com>
21267
21268         * lib/version-etc.c (version_etc_copyright): Update copyright year.
21269
21270 2001-12-19  Paul Eggert  <eggert@twinsun.com>
21271
21272         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
21273         not silently exit merely because the output buffer happens to
21274         have nothing pending.
21275
21276 2001-12-18  Paul Eggert  <eggert@twinsun.com>
21277
21278         See the big note in ../ChangeLog.
21279         * lib/human.c (suffixes): Prefer K to k for 1024.
21280         (generate_suffix_backwards): New function.
21281         (human_readable_inexact): Use it.
21282         * lib/xstrtol.c (__xstrtol): If there is no number but there
21283         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
21284         Accept 'K' as well as 'k'.
21285
21286 2001-12-15  Jim Meyering  <meyering@lucent.com>
21287
21288         * lib/regex.h (__restrict_arr): Update from libc.
21289
21290         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
21291         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
21292         (STREQ): Define.
21293
21294 2001-12-14  Jim Meyering  <meyering@lucent.com>
21295
21296         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
21297         Suggestion from Bruno Haible.
21298
21299 2001-12-10  Jim Meyering  <meyering@lucent.com>
21300
21301         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
21302         xrealloc, Instead, include "xalloc.h".
21303         (initbuffer): Don't cast xmalloc return value to char*.
21304         (readline): Reword comment.
21305         Don't cast xrealloc return value to char*
21306         Return NULL, not 0.
21307
21308 2001-12-09  Jim Meyering  <meyering@lucent.com>
21309
21310         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
21311         about `signed and unsigned type in conditional expression'.
21312         * lib/posixtm.c (posix_time_parse): Likewise.
21313
21314         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
21315
21316         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
21317         to avoid a pedantic warning.
21318
21319         * lib/getstr.c: Don't include assert.h.
21320         (getstr): Remove warning-evoking assertions.
21321         Return -1 if offset parameter is out of bounds.
21322         Change the type of a local from int to size_t.
21323
21324         * lib/strftime.c (my_strftime_localtime_r): Include this function
21325         definition in the `#if ! HAVE_TM_GMTOFF' block.
21326
21327         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
21328         Include xalloc.h instead.
21329
21330 2001-12-02  Jim Meyering  <meyering@lucent.com>
21331
21332         * lib/tempname.c: Don't declare getenv, thus reverting the change of
21333         2001-11-18.  It's no longer necessary, now that stdlib.h is always
21334         included.
21335
21336         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
21337         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
21338
21339 2001-11-30  Akim Demaille  <akim@epita.fr>
21340
21341         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
21342         before being defined.
21343
21344 2001-11-27  Paul Eggert  <eggert@twinsun.com>
21345
21346         * lib/quotearg.h (quotearg_n, quotearg_n_style):
21347         First arg is int, not unsigned.
21348         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
21349         (SIZE_MAX, UINT_MAX): New macros.
21350         (quotearg_n_options): Abort if N is negative.
21351         Avoid overflow check on hosts where size_t is 64 bits and int
21352         is 32 bits, as overflow is impossible there.
21353         Fix off-by-one typo that caused unnecessary reallocation.
21354
21355 2001-11-27  Jim Meyering  <meyering@lucent.com>
21356
21357         * lib/tempname.c: Merge with version from libc.
21358         * lib/regex.c: Likewise.
21359
21360         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
21361         systems for which STDC_HEADERS is 0, it was not included, resulting in
21362         a warning about an integer-to-pointer conversion problem with getenv.
21363         Reported by Volker Borchert.
21364
21365 2001-11-26  Jim Meyering  <meyering@lucent.com>
21366
21367         * lib/gtod.h: Remove file.
21368         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
21369         * lib/gettimeofday.c: Don't include gtod.h.
21370         (GTOD_init): Remove function.
21371         (rpl_gettimeofday): Do its job here instead, rather than aborting.
21372         Suggestion from Volker Borchert.
21373
21374 2001-11-23  Jim Meyering  <meyering@lucent.com>
21375
21376         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
21377         it.
21378         * lib/hash.c (struct hash_table): Define it here instead.
21379
21380 2001-11-22  Jim Meyering  <meyering@lucent.com>
21381
21382         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
21383
21384 2001-11-20  Jim Meyering  <meyering@lucent.com>
21385
21386         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
21387         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
21388
21389 2001-11-19  Jim Meyering  <meyering@lucent.com>
21390
21391         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
21392         directory.  Use "conftestXXXXXX" as the template.
21393         Suggestion from Paul Eggert.
21394
21395         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
21396         immediately, so the test doesn't mistakenly hit the max-open-files
21397         limit.
21398
21399 2001-11-18  Paul Eggert  <eggert@twinsun.com>
21400
21401         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
21402         (TEMPORARIES): New macro.
21403         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
21404         removes an artificial limitation (e.g. HP-UX 10.20, where
21405         TMP_MAX is 17576).
21406
21407 2001-11-18  Jim Meyering  <meyering@lucent.com>
21408
21409         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
21410
21411 2001-11-18  Jim Meyering  <meyering@lucent.com>
21412
21413         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
21414         on SunOS 4.
21415
21416         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
21417         files will be created before anything else.
21418
21419 2001-11-17  Paul Eggert  <eggert@twinsun.com>
21420
21421         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
21422         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
21423
21424 2001-11-17  Jim Meyering  <meyering@lucent.com>
21425
21426         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
21427         Prompted by a report from Bob Proulx.
21428
21429         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
21430         Instead, require UTILS_FUNC_MKSTEMP.
21431
21432 2001-11-17  Jim Meyering  <meyering@lucent.com>
21433
21434         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
21435         Now, that's done as part of AC_FUNC_STRTOD.
21436
21437 2001-11-17  Jim Meyering  <meyering@lucent.com>
21438
21439         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
21440         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
21441         rather than group writable.  Patch by Juan F. Codagnone.
21442
21443         * lib/readtokens.c: Remove explicit declarations of xmalloc and
21444         xrealloc, Instead, include "xalloc.h".
21445
21446         * lib/mountlist.c: Include unlocked-io.h after all system headers.
21447         Remove explicit declarations of xmalloc, xrealloc,
21448         and xstrdup.  Instead, include "xalloc.h".
21449
21450         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
21451         unlocked-io.h.
21452         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
21453         Likewise.
21454         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
21455
21456         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
21457         Reported by Padraig Brady.
21458
21459         * lib/mkstemp.c: #undef mkstemp.
21460         Include config.h.
21461         (rpl_mkstemp): Rename from mkstemp.
21462         Protoize.
21463
21464 2001-11-16  Jim Meyering  <meyering@lucent.com>
21465
21466         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
21467         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
21468         determine the amount of total physical memory, use pstat_getstatic.
21469         HPUX-11 doesn't define _SC_PHYS_PAGES.
21470         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
21471         If sysconf couldn't be used to determine the amount of available
21472         physical memory, use both pstat_getstatic and pstat_getdynamic.
21473         Based on a patch from Bob Proulx.
21474
21475 2001-11-10  Jim Meyering  <meyering@lucent.com>
21476
21477         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
21478         (jm_PREREQ): Use it.
21479
21480 2001-11-09  Jim Meyering  <meyering@lucent.com>
21481
21482         * m4/jm-macros.m4: Require autoconf-2.52f.
21483         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
21484         Use these AC_-prefixed names, not the AM_-prefixed ones.
21485
21486         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
21487
21488 2001-11-05  Jim Meyering  <meyering@lucent.com>
21489
21490         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
21491
21492 2001-11-04  Jim Meyering  <meyering@lucent.com>
21493
21494         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
21495         $DEFS.
21496
21497 2001-11-03  Jim Meyering  <meyering@lucent.com>
21498
21499         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
21500         of AC_DEFUN.
21501
21502         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
21503         know the name of the variable in the macro definition.
21504
21505 2001-11-03  Jim Meyering  <meyering@lucent.com>
21506
21507         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
21508         in argmatch_to_argument call.
21509
21510         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
21511         argument.
21512
21513         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
21514         e.g., a fault due to an attempt to free a NULL pointer.
21515
21516 2001-11-01  Jim Meyering  <meyering@lucent.com>
21517
21518         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
21519         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
21520
21521 2001-11-01  Jim Meyering  <meyering@lucent.com>
21522
21523         * lib/dirfd.c, lib/dirfd.h: New files.
21524         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
21525
21526         * lib/hash.c (hash_print) [TESTING]: Clean up.
21527
21528 2001-10-22  Paul Eggert  <eggert@twinsun.com>
21529
21530         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
21531         to avoid a warning if -Wall.
21532
21533 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
21534
21535         * README: New file
21536         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
21537         (per RMS's instructions, this is now the canonical source)
21538         * lgpl/, gpl/: New directories.
21539
21540 2001-10-21  Paul Eggert  <eggert@twinsun.com>
21541
21542         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
21543
21544 2001-10-21  Jim Meyering  <meyering@lucent.com>
21545
21546         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
21547         this code would end up calling gettext even in packages built
21548         with --disable-nls.
21549         * lib/getopt.c (_): Likewise.
21550         * lib/regex.c (_): Likewise.
21551
21552 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21553
21554         * m4/error.m4 (jm_PREREQ_ERROR):
21555         Do not invoke AC_CHECK_FUNCS with strerror_r, as
21556         AC_FUNC_STRERROR_R does that.
21557         Check for strerror declaration.
21558
21559         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
21560         are supposed to have them these days.
21561         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
21562         Merge changes from latest Autoconf CVS.
21563         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
21564         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
21565         POSIX decided to standardize on the int flavor of strerror_r.
21566
21567 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21568
21569         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
21570         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
21571         Use strerror_r that is only a macro, even if it is not a function.
21572         (strerror): Check for HAVE_DECL_STRERROR before declaring.
21573         (private_strerror): Use prototypes, not old-style function definition.
21574         (print_errno_message): New function.
21575         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
21576         char*-flavored one.
21577         (error_tail, error, error_at_line): Use it.
21578
21579 2001-10-11  Jim Meyering  <meyering@lucent.com>
21580
21581         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
21582         and quote_n (1, ... to avoid clobbering a buffer.
21583
21584 2001-10-05  Jim Meyering  <meyering@lucent.com>
21585
21586         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
21587         hash-pjw.h.
21588         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
21589         * lib/hash-pjw.h: New file.
21590
21591 2001-09-30  Jim Meyering  <meyering@lucent.com>
21592
21593         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
21594         `struct fsstat' has the `f_fstypename' member.
21595         Use that to define FS_TYPE, which is now used to make
21596         the getfsstat link test tighter.
21597
21598 2001-09-30  Jim Meyering  <meyering@lucent.com>
21599
21600         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
21601         Include <sys/ucred.h>, for Apple Darwin.
21602         Include sys/mount.h and sys/fs_types.h only if available.
21603         (FS_TYPE): Define.
21604         (read_filesystem_list): Use FS_TYPE.
21605
21606 2001-09-29  Paul Eggert  <eggert@twinsun.com>
21607
21608         * lib/exclude.c (excluded_filename): 0 -> false, since it's
21609         a boolean context.
21610
21611 2001-09-29  Jim Meyering  <meyering@lucent.com>
21612
21613         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21614         [one-argument getmntent function]): Include stdio.h before mntent.h.
21615         SunOS 4.1.x needs it for the declaration of `FILE'.
21616         Patch by Volker Borchert.
21617
21618         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21619         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
21620         sys/fs_types.h, and make the link-test for getfsstat guard #include
21621         directives with appropriate #if HAVE_*_H tests so that we can
21622         detect getfsstat on Apple Darwin1.3.7 systems.
21623         Reported by Nelson Beebe.
21624         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
21625
21626 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21627
21628         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21629         #defines strtoimax.  Also treat the other strto* functions
21630         like strtoimax.
21631
21632         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21633         Check for strtoul and strtoumax,
21634         as those declarations are made even in the signed case.
21635         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
21636         Likewise, for strtol and strtoimax.
21637
21638 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21639
21640         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21641         #defines strtoimax.  Also treat the other strto* functions
21642         like strtoimax.
21643
21644         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
21645         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
21646         (strtoimax, strtoumax): Do not declare if already defined as a macro.
21647
21648 2001-09-26  Jim Meyering  <meyering@lucent.com>
21649
21650         Most macros in unlocked-io.h had the wrong number of arguments.
21651         * lib/gen-uio: New script.
21652         (USE_UNLOCKED_IO): Define to 1 if not already defined.
21653         * lib/unlocked-io.hin: Remove file.
21654         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
21655         rather than trying to embed it here.
21656         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
21657         Reported by Padraig Brady.
21658
21659 2001-09-25  Volker Borchert  <bt@teknon.de>
21660
21661         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
21662         `result'.
21663
21664 2001-09-24  Jim Meyering  <meyering@lucent.com>
21665
21666         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
21667
21668 2001-09-23  Jim Meyering  <meyering@lucent.com>
21669
21670         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
21671         instead of the mere test for existence of mntent.h.  The latter
21672         would get a false-positive on AIX 3.4 systems.
21673         In the outer getmntent if-block, don't die if neither of the getmntent
21674         tests succeeds.  Instead, just fall through and continue with the
21675         remaining tests.
21676
21677 2001-09-23  Jim Meyering  <meyering@lucent.com>
21678
21679         * lib/mountlist.c: Remove useless parentheses in #if directives.
21680         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
21681         the deprecated MOUNTED symbol is no longer defined in mntent.h.
21682
21683 2001-09-22  Jim Meyering  <meyering@lucent.com>
21684
21685         * m4/gettext.m4: New file.  From gettext.
21686         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
21687         * m4/progtest.m4: Likewise
21688         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
21689         * m4/glibc21.m4: Likewise.
21690
21691         * m4/libintl.m4: Remove.  No longer used.
21692
21693 2001-09-22  Jim Meyering  <meyering@lucent.com>
21694
21695         * lib/localcharset.c: Update from latest gettext.
21696         * lib/config.charset: Likewise.
21697
21698 2001-09-20  Jim Meyering  <meyering@lucent.com>
21699
21700         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
21701         strtoimax.
21702         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
21703         strtoumax.
21704
21705 2001-09-20  Jim Meyering  <meyering@lucent.com>
21706
21707         * lib/xstrtol.c (strtoimax): Guard declaration with
21708         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
21709         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
21710         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
21711         (strtoumax): Likewise, for completeness (it wasn't necessary).
21712
21713 2001-09-17  Paul Eggert  <eggert@twinsun.com>
21714
21715         * lib/strtoimax.c (HAVE_LONG_LONG):
21716         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
21717         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
21718         to work around bug in IBM C compiler.
21719
21720 2001-09-17  Jim Meyering  <meyering@lucent.com>
21721
21722         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
21723         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
21724         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
21725         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
21726         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
21727         whenever the right hand side need not be expanded by the shell.
21728
21729 2001-09-16  Paul Eggert  <eggert@twinsun.com>
21730
21731         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
21732         library.  It's not correct, as some older glibcs are buggy.
21733         fnmatch wasn't fixed until glibc 2.2.
21734
21735         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
21736         special shell magic here.
21737
21738 2001-09-16  Jim Meyering  <meyering@lucent.com>
21739
21740         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
21741         * m4/jm-macros.m4: Require it.
21742
21743 2001-09-16  Jim Meyering  <meyering@lucent.com>
21744
21745         * lib/mkdir.c: New file.
21746
21747 2001-09-15  Jim Meyering  <meyering@lucent.com>
21748
21749         * m4/jm-macros.m4: Check for help2man.
21750
21751 2001-09-11  Jim Meyering  <meyering@lucent.com>
21752
21753         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
21754         The body, by Paul Eggert, was moved here from configure.in.
21755         * m4/jm-macros.m4: Require UTILS_HOST_OS.
21756
21757 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21758
21759         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
21760         (jm_PREREQ): Use it.
21761
21762 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21763
21764         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
21765         Use ssize_t, not int, to store result of readlink.
21766         Check for ssize_t overflow as well as size_t overflow,
21767         as POSIX says the result of readlink is implementation-defined
21768         when ssize_t overflows.
21769         Remove unnecessary cast to char*.
21770         Use free+malloc instead of realloc, as the storage doesn't need
21771         to be preserved and it's clearer and can be more efficient that way.
21772         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
21773         * lib/xreadlink.h (xreadlink): Update prototype.
21774
21775 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21776
21777         * lib/xgetcwd.c: Revert some of the previous change; intead,
21778         fix the HAVE_GETCWD_NULL code to behave more like the
21779         !HAVE_GETCWD_NULL code used to.
21780
21781         Include "xalloc.h".
21782         (xgetcwd): Do not return NULL when memory is exhausted; instead,
21783         invoke xalloc_die.
21784
21785 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21786
21787         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
21788         sys/param.h, as pathmax.h includes them.
21789
21790 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21791
21792         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
21793         (jm_PREREQ_XGETCWD): New macro.
21794
21795         * m4/getcwd.m4: New file.
21796
21797 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21798
21799         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
21800         like the HAVE_GETCWD_NULL code.
21801         Include pathmax.h if not HAVE_GETCWD.
21802         Do not include xalloc.h.
21803         (INITIAL_BUFFER_SIZE): New symbol.
21804         Do not use xmalloc / xrealloc, since the caller is responsible for
21805         handling errors.  Preserve errno around `free' during failure.
21806         Do not overrun buffer when using getwd.
21807
21808 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21809
21810         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
21811         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
21812         getcwd (NULL, 0).
21813
21814 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21815
21816         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
21817         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
21818         spotted by Jim Meyering.
21819
21820 2001-09-03  Jim Meyering  <meyering@lucent.com>
21821
21822         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
21823         failure.
21824
21825 2001-09-02  Jim Meyering  <meyering@lucent.com>
21826
21827         * lib/error.c: Update from GNU libc.
21828
21829 2001-09-01  Jim Meyering  <meyering@lucent.com>
21830
21831         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
21832         Used by df.
21833
21834 2001-09-01  Jim Meyering  <meyering@lucent.com>
21835
21836         * lib/xreadlink.c: New file.
21837         * lib/xreadlink.h: New file.
21838         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
21839         xreadlink.h.
21840
21841         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
21842         doesn't conflict with sparc Solaris 7's definition in
21843         /usr/include/sys/int_types.h.
21844
21845         * lib/exclude.c: Use `""', not `<>' to #include non-system header
21846         files.
21847         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
21848         and strncasecmp as r-values.  Unixware didn't have declarations.
21849
21850 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21851
21852         * lib/xstrtol.h: Add copyright notice.
21853         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
21854         LONGINT_INVALID_SUFFIX_CHAR.
21855
21856 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21857
21858         * lib/xstrtol.c (strtoimax): New decl.
21859
21860 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21861
21862         * lib/xgetcwd.c: Don't include pathmax.h.
21863         Include stdlib.h and unistd.h if available.
21864         Include xalloc.h.
21865         (xmalloc, xstrdup, free): Remove decls.
21866         (xgetcwd): Don't assume sizes fit in unsigned.
21867         Check for overflow when computing sizes.
21868         Simplify reallocation code.
21869
21870 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21871
21872         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
21873         a directory's st_size can have an arbitrary value, so the old
21874         usage could waste an arbitrary amount of memory.  All uses
21875         changed.
21876         * lib/savedir.h: Update prototype.
21877
21878 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21879
21880         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
21881
21882         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
21883         old strtoimax.c.
21884
21885         Also, make the following further changes to make this file's
21886         configuration more similar to that of strtol.c:
21887         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
21888         (strtoumax, uintmax_t, strtoull, strtol): Remove.
21889         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
21890         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
21891         changed to signed values.
21892
21893         And make the following changes as well:
21894         Fix copyright notice, as 1999 was missing.
21895         (verify): New macro.
21896         (strtoimax): Check sizes at compile-time, not run-time.
21897         Prefer strtol to strtoll if both work.
21898         (main): Remove; it was not that useful and was a pain to maintain.
21899
21900         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
21901
21902 2001-08-31  Jim Meyering  <meyering@lucent.com>
21903
21904         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
21905         Use an initial, malloc'd, buffer of length 128 rather than
21906         a statically allocated one of length 1024.
21907
21908 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21909
21910         Simplify code, partly by assuming autoconf 2.52 semantics.
21911
21912         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
21913
21914         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
21915         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
21916         All uses removed.
21917         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
21918         Move AC_REQUIRE to next-to-top level, to avoid confusion.
21919         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
21920         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
21921         jm_AC_HEADER_INTTYPES_H.
21922         * m4/jm-macros.m4 (jm_MACROS): Likewise.
21923
21924         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
21925
21926         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21927         Quote first arg of AC_DEFUN.
21928         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
21929         since they are needed to parse the include file even if we need
21930         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
21931         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
21932         but with opposite signedness.
21933
21934 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21935
21936         Merge 'exclude' changes from tar 1.13.22.
21937         This fixes one or two unlikely storage allocation overflow bugs,
21938         but doesn't change user-visible behavior otherwise.
21939
21940 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21941
21942         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
21943         (jm_PREREQ_EXCLUDE): New macro.
21944
21945 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21946
21947         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
21948         tm to be declared.
21949
21950 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21951
21952         * lib/hash.c: Remove '2001' from copyright notice.
21953
21954 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21955
21956         * lib/full-write.h: New file.
21957         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
21958         * lib/full-write.c: Correct credits, as cccp.c no longer
21959         exists and anyway it was so heavily changed from the old cccp
21960         code as to be unrecognizable.  Include full-write.h.
21961         (full_write) Return size_t, with short writes meaning failure.
21962         All callers changed.  This fixes a bug with large buffers
21963         on 64-bit hosts.
21964         * lib/utime.c: Include full-write.h.
21965
21966 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21967
21968         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
21969         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
21970         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
21971         Include if available.
21972         (<xalloc.h>): Include
21973         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
21974         (verify): New macro.  Use it to verify that EXCLUDE macros do not
21975         collide with FNM macros.
21976         (struct patopts): New struct.
21977         (struct exclude): Use it, as exclude patterns now come with options.
21978         (new_exclude): Support above changes.
21979         (new_exclude, add_exclude_file):
21980         Initial size must now be a power of two to simplify overflow checking.
21981         (free_exclude, fnmatch_no_wildcards): New function.
21982         (excluded_filename): No longer requires options arg, as the options
21983         are determined by add_exclude.  Now returns bool, not int.
21984         (excluded_filename, add_exclude):
21985         Add support for the fancy new exclusion options.
21986         (add_exclude, add_exclude_file): Now takes int options arg.
21987         Check for arithmetic overflow when computing sizes.
21988         (add_exclude_file): xrealloc might modify errno, so don't
21989         realloc until after errno might be used.
21990
21991         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
21992         New macros.
21993         (free_exclude): New decl.
21994         (add_exclude, add_exclude_file): Now takes int options arg.
21995         (excluded_filename): No longer requires options arg, as the options
21996         are determined by add_exclude.  Now returns bool, not int.
21997
21998 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21999
22000         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
22001
22002 2001-08-27  Jim Meyering  <meyering@lucent.com>
22003
22004         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
22005
22006         * lib/version-etc.c (N_): Remove definition.
22007         Revert most of last change.
22008         Instead, simply don't mark the `Copyright...' string for translation.
22009         Based on advice from Paul Eggert.
22010
22011         * lib/strtoxmax.c: Tweak comment.
22012
22013 2001-08-26  Jim Meyering  <meyering@lucent.com>
22014
22015         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
22016
22017         * m4/xstrtoimax.m4: New file.
22018         * m4/xstrtoumax.m4: Add comments explaining why we
22019         AC_REPLACE_FUNCS(strtol).
22020
22021 2001-08-26  Jim Meyering  <meyering@lucent.com>
22022
22023         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
22024         of copyright with `%s' so translators don't get an untranslated
22025         message in 2002.
22026         (COPYRIGHT_YEAR): Define.
22027         (version_etc): Use fprintf rather than fputs.
22028         Suggestion from Ulrich Drepper.
22029
22030         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
22031
22032         * lib/strtoll.c: New file, from GNU libc.
22033         * lib/xstrtoimax.c: New file.
22034
22035         * lib/xstrtol.h: Add xstrtoimax.
22036         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
22037         * lib/strtoimax.c: New file.  Likewise, but first define
22038         STRTOUXMAX_SIGNED.
22039
22040         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
22041         ...
22042         * lib/strtoxmax.c: ... then renamed to this.
22043
22044 2001-08-18  Paul Eggert  <eggert@twinsun.com>
22045
22046         * m4/inttypes.m4: Add AC_PREREQ(2.13).
22047         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
22048         (jm_AC_TYPE_INTMAX_T): New macro.
22049         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
22050
22051         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
22052
22053         * m4/longlong.m4: Renamed from ulonglong.m4.
22054         * m4/inttypes.m4: Renamed from inttypes_h.m4.
22055         * m4/uintmax_t.m4: Removed.
22056
22057 2001-08-13  Paul Eggert  <eggert@twinsun.com>
22058
22059         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
22060         Port to Solaris 8, where 'sed' requires a space after the 'r'
22061         command, and where sh dislikes "$/".  Clean up the spacing a bit.
22062         Redirect output to $tmp just once.
22063
22064 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
22065
22066         * lib/addext.c (<errno.h>): Include.
22067         (errno): Declare if not defined.
22068         (addext): Work correctly when pathconf returns -1 and leaves
22069         errno alone because there is no limit.  Also, work even if
22070         pathconf returns a value greater than SIZE_MAX.
22071
22072 2001-08-12  Jim Meyering  <meyering@lucent.com>
22073
22074         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
22075         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
22076         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
22077         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
22078         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
22079         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
22080         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
22081         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
22082         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
22083         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
22084         utime.m4, utimes.m4, xstrtoumax.m4:
22085         Quote the first argument in each use of AC_DEFUN.
22086
22087 2001-08-12  Jim Meyering  <meyering@lucent.com>
22088
22089         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
22090         Simply `return getcwd (NULL, 0);'.
22091         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
22092         Use 1300 as initial value for length, not PATH_MAX.
22093
22094         * lib/pathmax.h: Clean up cpp syntax.
22095
22096 2001-08-12  Jim Meyering  <meyering@lucent.com>
22097
22098         * lib/gettimeofday.c: New file.
22099         * lib/gtod.h: New file.
22100         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
22101
22102 2001-08-05  Jim Meyering  <meyering@lucent.com>
22103
22104         * m4/jm-macros.m4: Require autoconf-2.52.
22105
22106 2001-08-04  Jim Meyering  <meyering@lucent.com>
22107
22108         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
22109         stmt, to get in sync with glibc.
22110
22111 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22112
22113         The following changes are from gettext 0.10.39 as maintained by
22114         Bruno Haible.
22115
22116         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
22117         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
22118         with inverted sense.  All uses changed.
22119
22120         * lib/mbswidth.c: Don't include <limits.h>.
22121         Include <stdlib.h> and <string.h> unconditionally.
22122         (iswcntrl, mbsinit, ISCNTRL): New macros.
22123         (mbsnwidth): Use K&R style function declarations.
22124         Don't bother checking for MB_LEN_MAX == 1, since the compiler
22125         can optimize it when MB_CUR_MAX == 1.
22126         The width of control characters is zero, not 1.
22127
22128 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22129
22130         The following changes are from gettext 0.10.39 as maintained by
22131         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
22132
22133         * m4/codeset.m4: Upgrade to serial AM1.
22134         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
22135         all uses changed.  Quote first arg of AC_DEFUN.
22136         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
22137
22138         * m4/iconv.m4: Upgrade to serial AM2.
22139         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
22140         Add --with-libconv-prefix.
22141         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
22142         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
22143         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
22144         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
22145         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
22146
22147         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
22148         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
22149         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
22150         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
22151         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
22152         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
22153         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
22154         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
22155         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
22156
22157         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
22158         string.h any more.
22159
22160         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
22161         not the default value.
22162
22163         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
22164         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
22165         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
22166         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
22167         Also check for iswcntrl, used for wcwidth fallback.
22168         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
22169         to Autoconf 2.13.
22170
22171 2001-08-03  Jim Meyering  <meyering@lucent.com>
22172
22173         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
22174         as it was in the original.  Reported by Paul Eggert.
22175
22176 2001-07-16  Jim Meyering  <meyering@lucent.com>
22177
22178         * m4/gettimeofday.m4: New file.
22179         Prompted by a report from Bernhard Baehr.
22180
22181 2001-07-15  Jim Meyering  <meyering@lucent.com>
22182
22183         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
22184         stuff. Now it's in ../Makefile.cfg.
22185
22186 2001-07-15  Jim Meyering  <meyering@lucent.com>
22187
22188         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
22189         (BUILT_SOURCES): Add unlocked-io.h.
22190         (io_functions): Define.
22191         (unlocked-io.h): New rule.
22192         (DISTCLEANFILES): Add unlocked-io.h.
22193         (all-local): Depend on unlocked-io.h, to ensure it is created.
22194
22195         * lib/unlocked-io.hin: New file
22196
22197         * lib/regex.c: Update from glibc.
22198
22199 2001-07-05  Jim Meyering  <meyering@lucent.com>
22200
22201         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
22202         recommendation.
22203         (libfetish_a_SOURCES): Put all .h files here instead.
22204         Remove a thus-exposed (better checks in automake) duplicate and
22205         two unnecessary .h files.
22206
22207 2001-07-04  Jim Meyering  <meyering@lucent.com>
22208
22209         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
22210         that generates jm-glibc-io.m4 so that it doesn't trigger any make
22211         distcheck failure.
22212
22213 2001-07-02  Jim Meyering  <meyering@lucent.com>
22214
22215         The following changes were prompted by suggestions from Bruno Haible.
22216
22217         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
22218         is now generated.
22219         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
22220         definition of EXTRA_DIST.
22221         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
22222         ensure that the generated file is created/updated whenever the list
22223         of $(unlocked_functions) is changed.
22224         (jm-glibc-io.m4): New rule.
22225         (unlocked-io.h): New rule -- currently unused.
22226
22227 2001-06-24  Jim Meyering  <meyering@lucent.com>
22228
22229         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
22230         unmatched right bracket, rather than kludging it with an extra,
22231         falsely-matching quote in a comment.  Patch by Akim Demaille.
22232
22233 2001-06-11  Jim Meyering  <meyering@lucent.com>
22234
22235         * lib/regex.c: Update from GNU libc.
22236
22237 2001-05-27  Jim Meyering  <meyering@lucent.com>
22238
22239         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
22240         Check for ut_type in struct utmp.
22241
22242 2001-05-27  Jim Meyering  <meyering@lucent.com>
22243
22244         * lib/readutmp.h (UT_TYPE): Define.
22245
22246 2001-05-24  Jim Meyering  <meyering@lucent.com>
22247
22248         * lib/argmatch.c: Include "quote.h".
22249         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
22250         quote function.  Reported by Göran Uddeborg.
22251
22252 2001-05-22  Jim Meyering  <meyering@lucent.com>
22253
22254         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
22255         now that we use the package-supplied version unconditionally.
22256         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
22257
22258 2001-05-21  Jim Meyering  <meyering@lucent.com>
22259
22260         * m4/regex.m4: Change a couple backticks to single quotes to avoid
22261         shell syntax errors.
22262
22263 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22264
22265         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
22266
22267 2001-05-20  Paul Eggert  <eggert@twinsun.com>
22268
22269         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
22270         Don't bother to check library strftime, since
22271         we'll be using our own my_strftime function anyway.
22272         Define my_strftime instead of strftime.
22273
22274 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
22275
22276         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
22277         which is not yet declared.
22278
22279 2001-05-15  Jim Meyering  <meyering@lucent.com>
22280
22281         * m4/regex.m4: Use proper quoting so brackets appear in the test
22282         program.
22283         Reported by, and with help from, Bruno Haible.
22284
22285 2001-05-13  Jim Meyering  <meyering@lucent.com>
22286
22287         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
22288         undefined.
22289
22290 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22291
22292         dirname code cleanup.  base_name now behaves more compatibly
22293         with POSIX basename when given file names that have trailing
22294         slashes, and similarly for dir_name.  Add new primitives
22295         base_len and dir_len.  Put the directory-name-related decls
22296         into dirname.h.
22297
22298         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
22299         * lib/backupfile.c (base_name): Likewise.
22300         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
22301         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
22302         * lib/makepath.c (strip_trailing_slashes): Likewise.
22303         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
22304         ISSLASH): Likewise.
22305         * lib/rename.c (strip_trailing_slashes): Likewise.
22306         * lib/same.c (base_name): Likewise.
22307         * lib/stripslash.c (ISSLASH): Likewise.
22308
22309         * lib/addext.c: Include <dirname.h> after size_t is defined.
22310         * lib/backupfile.c: Likewise.
22311
22312         * lib/addext.c (addext): Use base_len to trim redundant
22313         trailing slashes instead of doing it ourselves.
22314         But do not trim the last slash if it is not redundant.
22315
22316         * lib/backupfile.c (find_backup_file_name,
22317         max_backup_version): Use base_len instead of rolling it ourselves.
22318         Handle the case of "" and (on DOS) "C:" correctly.
22319
22320         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
22321         needed. Include <string.h>, <dirname.h>.
22322         (base_name): Allow file names ending in slashes, other than names
22323         that are all slashes.  In this case, return the basename followed
22324         by the slashes.  This is more general, and can be used in places
22325         where the original base_name purposely had an assertion failure.
22326         (base_len): New function.
22327
22328         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
22329         Do not include <assert.h>; no longer needed.
22330         Include xalloc.h.
22331         (memrchr): Remove decl.
22332         (dir_name_r): Remove.
22333         (dir_len): Renamed from dirlen.  All callers changed.
22334         Rewrite in terms of base_name, for simplicity and consistency.
22335         (dir_name): Never return NULL.  All callers changed.
22336         Do not include <stdlib.h> in test program; no longer needed.
22337         return 0; is fine for test program.
22338
22339         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
22340         New macros.
22341         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
22342
22343         * lib/path-concat.c (path_concat): Use base_len to compute
22344         base length, not strlen; this means we cannot rely on memcpy
22345         to null-terminate.
22346
22347         * lib/same.c (STREQ): Remove.
22348         (same_name): Handle the case where the basename ends in trailing '/'.
22349
22350         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
22351         a slash was stripped.  Do not strip the last slash after a
22352         file system prefix.
22353
22354 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22355
22356         * lib/Makefile.am (libfetish_a_SOURCES):
22357         Add strftime.c, since we now compile it on all hosts.
22358
22359         * lib/strftime.c (my_strftime):
22360         Define to nstrftime if emacs, but only if my_strftime is not defined.
22361         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
22362         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
22363         Add one more extra argument: a nanoseconds value.
22364         All uses changed.
22365         (ns): New macro.
22366         (my_strftime function): Add %N format.
22367         (emacs_strftimeu): Renamed from emacs_strftime,
22368         with extra ut argument.
22369
22370 2001-05-09  Paul Eggert  <eggert@twinsun.com>
22371
22372         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
22373
22374 2001-04-21  Jim Meyering  <meyering@lucent.com>
22375
22376         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
22377         doesn't interfere.
22378
22379 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22380
22381         * m4/ftruncate.m4: Check for chsize.
22382         Link with ftruncate.o unconditionally if ftruncate is missing.
22383         This was required when cross-compiling to i586-mingw32msvc.
22384
22385 2001-04-08  Jim Meyering  <meyering@lucent.com>
22386
22387         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
22388         recomputed; that's necessary when the offset spans a DST transition.
22389         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
22390
22391 2001-04-02  Jim Meyering  <meyering@lucent.com>
22392
22393         * lib/regex.h, regex.c: Update from GNU libc.
22394
22395 2001-03-24  Jim Meyering  <meyering@lucent.com>
22396
22397         * m4/jm-macros.m4: Require autoconf-2.49d.
22398
22399 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
22400
22401         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
22402
22403 2001-03-19  Paul Eggert  <eggert@twinsun.com>
22404
22405         * lib/version-etc.c (version_etc_copyright): Update to 2001.
22406
22407 2001-03-17  Jim Meyering  <meyering@lucent.com>
22408
22409         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
22410         now that the version in autoconf is equivalent.
22411         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
22412
22413         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
22414         Suggestion from Akim Demaille.
22415
22416         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
22417         (jm_PREREQ_TEMPNAME): New function.
22418
22419 2001-03-16  Paul Eggert  <eggert@twinsun.com>
22420
22421         * lib/tempname.c (uint64_t): Define to uintmax_t if
22422         not defined, and if UINT64_MAX is not defined.
22423         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
22424         Reported by John David Anglin.
22425
22426 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
22427
22428         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
22429         resolve alias if codeset is empty.
22430         * lib/config.charset (BeOS): Use wildcard syntax.
22431
22432 2001-03-13  Jim Meyering  <meyering@lucent.com>
22433
22434         * lib/path-concat.c (path_concat)
22435         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
22436         concatenating e.g., `C:' and `foo'.
22437         From Bruno Haible.
22438
22439 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22440
22441         * lib/localcharset.c (locale_charset): Don't use
22442         setlocale(LC_CTYPE,NULL). Don't return NULL.
22443         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
22444
22445 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22446
22447         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
22448         support for DOS/DJGPP.
22449
22450 2001-03-01  Paul Eggert  <eggert@twinsun.com>
22451
22452         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
22453         lacks mkstemp.  Compile our own tempname.c if we compile our own
22454         mkstemp.c, as mkstemp relies on tempname.
22455
22456 2001-03-01  Jim Meyering  <meyering@lucent.com>
22457
22458         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
22459         AH_VERBATIM really does output its argument verbatim.
22460
22461 2001-02-28  Paul Eggert  <eggert@twinsun.com>
22462
22463         * lib/Makefile.am (libfetish_a_SOURCES):
22464         Add dup-safer.c, fopen-safer.c.
22465         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
22466
22467         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
22468         * lib/unistd-safer.h: New files.
22469
22470 2001-02-25  Paul Eggert  <eggert@twinsun.com>
22471
22472         The mkstemp replacement is taken from glibc 2.2.2, with some
22473         portability fixes for use outside glibc, as follows:
22474
22475         * lib/tempname.c (struct_stat64): New macro.
22476         (direxists, __gen_tempname): Use it.
22477         This avoids a portability problem with Solaris 8.
22478
22479         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
22480         (<stddef.h>, <stdint.h>, <string.h>):
22481         Include only if STDC_HEADERS || _LIBC.
22482         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
22483         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
22484         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
22485         (__set_errno): Define this macro if <errno.h> doesn't.
22486         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
22487         Define these macros if <stdio.h> doesn't.
22488         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
22489         Define these macros if <sys/stat.h>
22490         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
22491         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
22492         __xstat64): Define if not _LIBC.
22493         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
22494         (__gen_tempname): Invoke gettimeofday only if
22495         HAVE_GETTIMEOFDAY || _LIBC;
22496         otherwise, fall back on plain "time".
22497         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
22498
22499         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
22500
22501         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
22502
22503 2001-02-18  Paul Eggert  <eggert@twinsun.com>
22504
22505         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
22506
22507 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22508
22509         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
22510         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
22511         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
22512         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22513
22514 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22515
22516         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
22517         Remove workaround macros for hosts that have mbrtowc but not
22518         mbstate_t, as we now insist on proper declarations for both
22519         before using mbrtowc.
22520
22521 2001-02-17  Jim Meyering  <meyering@lucent.com>
22522
22523         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
22524         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
22525         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
22526         UnixWare 7.1.1.
22527
22528         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
22529         rather than AC_CACHE_VAL.
22530
22531 2001-02-17  Jim Meyering  <meyering@lucent.com>
22532
22533         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
22534         around included file name.
22535
22536         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
22537
22538         * lib/strftime.c: Update from GNU libc (the only changes were to
22539         comments).
22540
22541 2001-02-17  Jim Meyering  <meyering@lucent.com>
22542
22543         * lib/regex.c: Update from libc.
22544
22545 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
22546
22547         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
22548         clash.
22549
22550 2001-02-16  Paul Eggert  <eggert@twinsun.com>
22551
22552         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
22553         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
22554         Reported by Mark Hounschell via Paul Eggert.
22555
22556 2001-02-07  Jim Meyering  <meyering@lucent.com>
22557
22558         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
22559
22560 2001-02-05  Jim Meyering  <meyering@lucent.com>
22561
22562         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
22563         it includes the patch required for `large file' support with at least
22564         HP-UX's 10.20 /bin/cc.
22565
22566 2001-02-03  Jim Meyering  <meyering@lucent.com>
22567
22568         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
22569         AS_IF, now that it works once again (mysteriously).
22570         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22571
22572 2001-01-30  Jim Meyering  <meyering@lucent.com>
22573
22574         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
22575         * m4/chown.m4: Rename conftestchown to conftest.chown.
22576         * m4/rename.m4: s/conftestdir/conftest.d1/ and
22577         s/conftestdir2/conftest.d2/.
22578         * m4/utimes.m4: s/conftestdata/conftest.data/
22579         Inspired by Pavel Roskin's change in autoconf.
22580
22581 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
22582
22583         * lib/config.charset: Update for FreeBSD 4.2.
22584
22585 2001-01-27  Jim Meyering  <meyering@lucent.com>
22586
22587         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
22588         a use of AS_IF.
22589         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22590
22591 2001-01-26  Jim Meyering  <meyering@lucent.com>
22592
22593         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
22594         quotearg.c includes it.
22595
22596 2001-01-26  Jim Meyering  <meyering@lucent.com>
22597
22598         * lib/quotearg.c: Include stddef.h.
22599         * lib/quote.c: Include stddef.h.
22600         Reported by Axel Kittenberger.
22601
22602         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
22603         line in double quotes so that it evokes a better diagnostic.
22604         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
22605         Reported by Axel Kittenberger.
22606
22607 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
22608
22609         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
22610         as if it was a `charset'.
22611
22612 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22613
22614         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
22615         has const.
22616
22617 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22618
22619         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
22620         to avoid a warning.  Add back 'const' to inptr.
22621
22622 2001-01-20  Jim Meyering  <meyering@lucent.com>
22623
22624         Be sure that headers are checked before used in code compiled
22625         for the type checks.
22626         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
22627         In place of that, invoke jm_CHECK_ALL_TYPES.
22628         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
22629         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
22630         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
22631         The check for ssize_t was mistakenly run before the test for unistd.h.
22632
22633         The configure-time check for stdbool.h was missing.
22634         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
22635         (jm_PREREQ_HASH): New function.
22636
22637 2001-01-17  Jim Meyering  <meyering@lucent.com>
22638
22639         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
22640         for autoconf-2.49c.
22641         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
22642
22643 2001-01-16  Jim Meyering  <meyering@lucent.com>
22644
22645         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
22646         From Bruno Haible.
22647
22648 2001-01-14  Jim Meyering  <meyering@lucent.com>
22649
22650         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
22651         foo and bar.  Create conftestdir/ in the script, not in the C code.
22652         Remove directories in the script, not in the C code.
22653         Remove conftestdir{,2} before trying to create the directory.
22654         Make the entire configure script fail if the mkdir fails.
22655
22656 2001-01-14  Jim Meyering  <meyering@lucent.com>
22657
22658         * lib/rename.c: New file.  From Volker Borchert.
22659         Include stdlib.h, string.h or strings.h, and xalloc.h.
22660         Use strip_trailing_slashes rather than open-coding it.
22661
22662 2001-01-03  Paul Eggert  <eggert@twinsun.com>
22663
22664         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
22665
22666 2001-01-03  Jim Meyering  <meyering@lucent.com>
22667
22668         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
22669         of local `inptr' to avoid warning with some system declarations of
22670         iconv.
22671
22672 2001-01-02  Volker Borchert  <bt@teknon.de>
22673
22674         * m4/rename.m4: New file.
22675         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
22676
22677 2001-01-01  Jim Meyering  <meyering@lucent.com>
22678
22679         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
22680         even on systems with utmpx.h.  It's necessary for the declaration of
22681         utmp's ut_user member.  Reported by Andreas Jaeger.
22682
22683         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
22684         available. They are required for the declarations of getgrgid and
22685         getpwuid resp.
22686         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
22687         Reported by Andreas Jaeger.
22688
22689 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
22690
22691         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
22692         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
22693         so `make install' also works in VPATH builds.
22694
22695 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
22696
22697         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
22698         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
22699         can be used in subdirectories.
22700
22701 2000-12-29  Paul Eggert  <eggert@twinsun.com>
22702
22703         * lib/modechange.c: Do not assume that mode_t uses the
22704         traditional octal encoding.  E.g. "chmod 1 FOO" should set
22705         the other-execute bit of FOO even if S_IXOTH != 1.
22706
22707         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
22708         WOTH, XOTH, ALLM): New macros.
22709         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
22710          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
22711         Use them.
22712         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
22713         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
22714         (mode_compile):
22715         No need to use uintmax_t; unsigned long is long enough.
22716         Don't bother to get suffix since we don't use it.
22717
22718 2000-12-26  Jim Meyering  <meyering@lucent.com>
22719
22720         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
22721         better with autoheader.
22722
22723 2000-12-24  Jim Meyering  <meyering@lucent.com>
22724
22725         * lib/hash.c (is_prime): Return explicit boolean values.
22726         (hash_get_first): Return NULL to appease Irix5.6's 89.
22727         Reported by Nelson Beebe.
22728
22729 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
22730
22731         * lib/localcharset.c (locale_charset): Add support for Win32.
22732
22733 2000-12-18  Paul Eggert  <eggert@twinsun.com>
22734
22735         * lib/physmem.h, lib/physmem.c: New files.
22736
22737         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
22738         (noinst_HEADERS): Add physmem.h.
22739
22740         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
22741         't' for compatibility with Solaris 8 sort.
22742
22743 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
22744
22745         * lib/config.charset: Add support for BeOS.
22746
22747 2000-12-17  Jim Meyering  <meyering@lucent.com>
22748
22749         * m4/dos.m4 (jm_AC_DOS): New file and macro.
22750         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
22751
22752 2000-12-16  Jim Meyering  <meyering@lucent.com>
22753
22754         This bug had a serious impact on chown: `chown N:M FILE' (for integer
22755         N and M) would have treated it like `chown N:N FILE'.
22756
22757         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
22758
22759 2000-12-16  Jim Meyering  <meyering@lucent.com>
22760
22761         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
22762         SHELLS_FILE to a file name that's useful on djgpp systems.
22763         Include stdlib.h.
22764         (ADDITIONAL_DEFAULT_SHELLS): Define.
22765         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
22766         Based mostly on a patch from Prashant TR.
22767
22768 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
22769
22770         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
22771         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
22772         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
22773
22774 2000-12-08  Andreas Schwab  <schwab@suse.de>
22775
22776         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
22777         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
22778
22779 2000-12-07  Jim Meyering  <meyering@lucent.com>
22780
22781         * lib/stripslash.c (ISSLASH): Define.
22782         (strip_trailing_slashes): Use ISSLASH rather than comparing against
22783         `/'.
22784         From Prashant TR.
22785
22786         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
22787         (dir_name_r): Declare this function as static.
22788         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
22789         manifest itself on a name containing a mix of slashes and
22790         backslashes.
22791         Make this function work with names starting with a DOS-style
22792         drive letter and colon prefix.
22793         (dir_name): Append `.' if necessary.
22794         Based mostly on patches from Prashant TR and Eli Zaretskii.
22795
22796         * lib/dirname.h (dir_name_r): Remove prototype.
22797
22798 2000-12-06  Paul Eggert  <eggert@twinsun.com>
22799
22800         * m4/off_t-format.m4: Remove this file.
22801         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
22802
22803 2000-12-06  Jim Meyering  <meyering@lucent.com>
22804
22805         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
22806         replacement strtoull, we may well need the replacement strtoul, too.
22807         Check for declarations of strtoul and strtoull.
22808         Check for strtol.  Mainly as a cue to cause automake to include
22809         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
22810         Check for limits.h -- strtol.c needs it.
22811
22812 2000-12-05  Jim Meyering  <meyering@lucent.com>
22813
22814         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
22815
22816 2000-12-04  Jim Meyering  <meyering@lucent.com>
22817
22818         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
22819         Also include memory.h, stdlib.h, unistd.h if appropriate.
22820         Reported by Andreas Jaeger (conflicting declaration of malloc).
22821
22822 2000-12-02  Jim Meyering  <meyering@lucent.com>
22823
22824         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
22825         * m4/jm-macros.m4 (jm_MACROS): require it.
22826
22827 2000-12-02  Jim Meyering  <meyering@lucent.com>
22828
22829         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
22830
22831 2000-12-01  Paul Eggert  <eggert@twinsun.com>
22832
22833         * lib/memrchr.c: Include <config.h> before any system include file.
22834
22835 2000-11-30  Jim Meyering  <meyering@lucent.com>
22836
22837         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
22838
22839 2000-11-30  Jim Meyering  <meyering@lucent.com>
22840
22841         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
22842
22843 2000-11-29  Paul Eggert  <eggert@twinsun.com>
22844
22845         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
22846
22847 2000-11-26  Jim Meyering  <meyering@lucent.com>
22848
22849         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
22850
22851 2000-11-22  Paul Eggert  <eggert@twinsun.com>
22852
22853         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
22854         size of (size_t) -1; it's not portable.
22855
22856 2000-11-17  Jim Meyering  <meyering@lucent.com>
22857
22858         * lib/strstr.c: Update from GNU libc.
22859
22860 2000-11-17  Akim Demaille  <akim@epita.fr>
22861
22862         * lib/obstack.h: Formatting changes.
22863         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
22864         prevent type checking.
22865         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
22866         cast the value to (void *): assigning a `foo *' to a `void *'
22867         variable is valid.
22868         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
22869
22870 2000-11-16  Jim Meyering  <meyering@lucent.com>
22871
22872         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
22873
22874 2000-11-11  Jim Meyering  <meyering@lucent.com>
22875
22876         * lib/error.c: Add a couple #includes, merging from GNU libc version.
22877
22878 2000-11-10  Jim Meyering  <meyering@lucent.com>
22879
22880         * lib/obstack.h: Update from GNU libc.
22881         * lib/obstack.c: Likewise.
22882
22883 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
22884
22885         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
22886
22887 2000-11-06  Paul Eggert  <eggert@twinsun.com>
22888
22889         * lib/getusershell.c (setusershell): Use rewind rather than
22890         fseek/fseeko, to avoid configuration hassles with fseeko.
22891         Don't bother opening SHELLS_FILE if shellstream is NULL;
22892         it's not necessary.
22893
22894 2000-11-05  Jim Meyering  <meyering@lucent.com>
22895
22896         * lib/makepath.h (make_dir): Declare.
22897         * lib/makepath.c (make_dir): Remove `static' attribute.
22898         Tweak a comment.
22899
22900 2000-11-04  Jim Meyering  <meyering@lucent.com>
22901
22902         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
22903
22904 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
22905
22906         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
22907         last one in a bucket, advance to the next bucket.
22908
22909 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
22910
22911         * lib/fnmatch.c: Do not comment out all the code if we are using
22912         the GNU C library, because in some cases we are replacing buggy
22913         code in the GNU C library itself.
22914
22915 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
22916
22917         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
22918         (regex_compile): Catch bogus \(\1\).
22919
22920 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22921
22922         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
22923         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
22924         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
22925
22926 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22927
22928         * lib/error.h, getline.h, modechange.h:
22929         Remove "2000" from Copyright line, as the file hasn't been
22930         changed this year other than in the copyright notice.
22931
22932         * lib/xalloc.h: Add "2000" to Copyright line, as this file
22933         was changed this year.
22934
22935 2000-10-29  Jim Meyering  <meyering@lucent.com>
22936
22937         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
22938         renaming.
22939         * m4/ls-mntd-fs.m4: Likewise
22940
22941 2000-10-29  Jim Meyering  <meyering@lucent.com>
22942
22943         * lib/xstat.in: Fix grammar in comment.
22944
22945 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
22946
22947         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
22948         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
22949         doesn't define __restrict_arr.
22950
22951 2000-10-28  Jim Meyering  <meyering@lucent.com>
22952
22953         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
22954         (jm_PREREQ_MEMCHR): New function.
22955
22956 2000-10-28  Jim Meyering  <meyering@lucent.com>
22957
22958         * lib/memchr.c: Update from libc.
22959         Adjust for portability:
22960         [HAVE_STDLIB_H]: Include stdlib.h.
22961         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
22962         Undef __memchr, too.
22963         [!weak_alias]: Define __memchr to memchr.
22964
22965         * lib/regex.c: Update from libc.
22966         * lib/regex.h: Likewise.
22967         * lib/getopt1.c: Likewise.
22968         * lib/memcmp.c: Likewise.
22969
22970         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
22971         Avoid using fseek, when possible -- it's broken by design.
22972         Patch by Ulrich Drepper.
22973
22974 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
22975
22976         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
22977         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
22978         Giving in to popular pressure to shut up the compiler with casts.
22979
22980 2000-10-26  Jim Meyering  <meyering@lucent.com>
22981
22982         * lib/strftime.c: Update from libc.
22983
22984 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
22985
22986         * regex.c: More `unsigned char' -> `re_char' changes.
22987         Also change several `int' into `re_wchar_t'.
22988         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
22989         (PUSH_FAILURE_POINTER): Don't cast any more.
22990         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
22991         We want GCC to complain, since this piece of code makes
22992         re_match non-reentrant, which *should* be fixed.
22993         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
22994         (EXTEND_BUFFER): Use RETALLOC.
22995         (SET_LIST_BIT): Don't cast.
22996         (re_wchar_t): New type.
22997         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
22998         that those two functions will always properly return.
22999         (IMMEDIATE_QUIT_CHECK): Cast to void.
23000         (analyse_first): Use recursion rather than an explicit stack.
23001         (re_compile_fastmap): Can't fail anymore.
23002         (re_search_2): Don't check re_compile_fastmap for failure.
23003         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
23004         Now also sets the new value (passed in a new argument).
23005         (re_match_2_internal): Use it.
23006         Also, use a new var `reg' of type size_t when looping through regs
23007         rather than reuse the inappropriate `mcnt'.
23008
23009 2000-10-25  Jim Meyering  <meyering@lucent.com>
23010
23011         * lib/obstack.c: Update from libc.
23012
23013 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
23014
23015         * regex.c (regex_compile): Change the way of handling a range from
23016         a char less than 256 to a char not less than 256.
23017
23018 2000-10-24  Andrew Innes  <andrewi@gnu.org>
23019
23020         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
23021         NT-Emacs only.
23022         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
23023         so that re_search functions only quit when callers expect them to.
23024
23025 2000-10-23  Jim Meyering  <meyering@lucent.com>
23026
23027         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
23028         wrong.  That set_locale call must not have any side effects.
23029         From Paul Eggert.
23030
23031 2000-10-22  Jim Meyering  <meyering@lucent.com>
23032
23033         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
23034         [CYCLIC]: Remove now-unused definition.
23035
23036         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
23037         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
23038         Suggestion from Ulrich Drepper.
23039
23040 2000-10-21  Jim Meyering  <meyering@lucent.com>
23041
23042         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
23043         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
23044         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
23045
23046 2000-10-21  Jim Meyering  <meyering@lucent.com>
23047
23048         * lib/dirname.c (memrchr): Declare if necessary.
23049         (dir_name): Remove the restriction that there be no
23050         trailing slashes.  Now, this code skips past them, effectively
23051         ignoring them.
23052         [TEST_DIRNAME] (main): New unit tests.
23053
23054         * lib/memrchr.c: New file from GNU libc.
23055         Undef __memrchr, too.
23056         [!weak_alias]: Define __memrchr to memrchr.
23057         Guard weak_alias use with `#ifdef weak_alias'.
23058
23059 2000-10-21  Jim Meyering  <meyering@lucent.com>
23060
23061         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
23062         (dir_name): Use dir_name_r.
23063         * lib/dirname.h (dir_name_r): Declare it.
23064
23065 2000-10-17  Jim Meyering  <meyering@lucent.com>
23066
23067         * lib/quote.h (PARAMS): Define and use.
23068         Reported by Akim Demaille.
23069
23070         * lib/getopt.c: Update from libc.
23071
23072 2000-10-16  Jim Meyering  <meyering@lucent.com>
23073
23074         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
23075         setlocale.
23076         From Jan Fedak.
23077
23078 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
23079
23080         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
23081
23082 2000-09-25  Jim Meyering  <meyering@lucent.com>
23083
23084         * lib/md5.h (rol): Define (from GnuPG).
23085
23086         * lib/sha.c: Give credit (GnuPG) where due.
23087         (M): Use rol rather than open-coding it.
23088         Add a FIXME comment.
23089
23090 2000-09-21  Jim Meyering  <meyering@lucent.com>
23091
23092         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
23093         Reported by Michael Stone.
23094
23095 2000-09-20  Jim Meyering  <meyering@lucent.com>
23096
23097         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
23098         (noinst_HEADERS): Add sha.h.
23099         Based on code from Scott G. Miller and from GnuPG.
23100
23101 2000-09-18  Jim Meyering  <meyering@lucent.com>
23102
23103         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
23104         LIBS. Otherwise, everyone ends up linking with -lelf for some
23105         configurations.
23106         Reported by Mike Stone.
23107
23108 2000-09-15  Jim Meyering  <meyering@lucent.com>
23109
23110         * lib/regex.c: Update from libc.
23111
23112 2000-09-10  Jim Meyering  <meyering@lucent.com>
23113
23114         * lib/getopt.c (_getopt_internal): Update from glibc.
23115
23116 2000-09-09  Jim Meyering  <meyering@lucent.com>
23117
23118         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
23119         think it should be used as a general replacement for isascii.
23120         * lib/fnmatch.c: Likewise.
23121         * lib/mbswidth.c: Likewise
23122         * lib/regex.c: Likewise.
23123
23124         Don't use atoi.
23125         * lib/userspec.c: Include sys/param.h and limits.h.
23126         Include xstrtol.h.
23127         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23128         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
23129         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
23130         UID, GID.  Check range.
23131
23132 2000-09-06  Jim Meyering  <meyering@lucent.com>
23133
23134         * lib/getopt.c (_getopt_internal): Update from glibc.
23135
23136 2000-08-30  Jim Meyering  <meyering@lucent.com>
23137
23138         * lib/strftime.c: Merge in changes from GNU libc.
23139
23140 2000-08-26  Jim Meyering  <meyering@lucent.com>
23141
23142         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
23143         * m4/fpending.m4: New file.
23144
23145 2000-08-26  Jim Meyering  <meyering@lucent.com>
23146
23147         * lib/closeout.c: Include "__fpending.h".
23148         (close_stdout_status): Return right away if there's nothing to flush.
23149
23150         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
23151         * lib/__fpending.c: New file.
23152         * lib/__fpending.h: New file.
23153
23154 2000-08-20  Jim Meyering  <meyering@lucent.com>
23155
23156         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
23157         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
23158         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
23159
23160 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
23161
23162         Improve fileutils installation on systems where running
23163         programs (like install) can't be unlinked.
23164         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
23165         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
23166
23167 2000-08-07  Paul Eggert  <eggert@twinsun.com>
23168
23169         Standardize on "memory exhausted" instead of "Memory exhausted"
23170         or "virtual memory exhausted".
23171         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
23172         "virtual memory exhausted".
23173         * lib/same.c (same_name): Invoke xalloc_die instead of printing
23174         our own message.
23175         * lib/userspec.c (parse_user_spec): Likewise.
23176         * lib/bumpalloc.h: comment fix
23177         * lib/same.c, userspec.c: Include xalloc.h.
23178
23179         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
23180         not char *const and pointing to a constant array.
23181         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
23182         (xrealloc): Comment fix.
23183
23184         * lib/userspec.c (parse_user_spec):
23185         Don't translate a message until just before returning,
23186         to avoid unnecessary translation.
23187
23188 2000-08-07  Jim Meyering  <meyering@lucent.com>
23189
23190         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
23191         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
23192         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
23193         getgroups.c, gethostname.c, getopt.h, group-member.c,
23194         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
23195         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
23196         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
23197         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
23198         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
23199         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
23200         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
23201         yesno.c: Back out Copyright date changes for each file with no change
23202         this year.  This eases coordination with other programs using the same
23203         source code modules.  From Paul Eggert.
23204
23205 2000-08-06  Paul Eggert  <eggert@twinsun.com>
23206
23207         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
23208         not char, for compatibility with glibc 2.1.3 strftime.c.
23209
23210 2000-08-03  Greg McGary  <greg@mcgary.org>
23211
23212         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
23213         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
23214         (EXTEND_BUFFER): Use them.
23215
23216 2000-08-01  Jim Meyering  <meyering@lucent.com>
23217
23218         * lib/dirname.c (ISSLASH): Define.
23219         (BACKSLASH_IS_PATH_SEPARATOR): Define.
23220         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
23221         both `\' and `/' may be use as path separators.
23222         Based on a patch from Prashant TR.
23223
23224 2000-07-31  Paul Eggert  <eggert@twinsun.com>
23225
23226         * lib/quotearg.c (quotearg_n_options): Don't make the initial
23227         slot vector a constant, since it might get modified.
23228
23229 2000-07-31  Jim Meyering  <meyering@lucent.com>
23230
23231         * lib/xmalloc.c: Use `virtual memory exhausted', not
23232         `Memory exhausted'.
23233         * lib/obstack.c (print_and_abort): Likewise.
23234
23235 2000-07-30  Paul Eggert  <eggert@twinsun.com>
23236
23237         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
23238         buffer, so that the caller can always quote one small
23239         component of a "memory exhausted" message in slot 0.
23240         From a suggestion by Jim Meyering.
23241
23242 2000-07-30  Jim Meyering  <meyering@lucent.com>
23243
23244         * lib/makepath.c (make_path): Quote the other instance, too.
23245
23246         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
23247         (STATIC_BUF_SIZE): Define.
23248         (quotearg_n_options): Use only statically allocated storage when
23249         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
23250         than STATIC_BUF_SIZE.
23251
23252 2000-07-29  Jim Meyering  <meyering@lucent.com>
23253
23254         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
23255         * lib/dirname.c (dir_name): Likewise.
23256
23257         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
23258         `/'.
23259
23260         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
23261         (dir_name): Assert that there are no trailing slashes.
23262
23263 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
23264
23265         * lib/mbswidth.h (mbswidth): Add a flags argument.
23266         (mbswidth): New declaration.
23267         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
23268         * lib/mbswidth.c (mbswidth): Add a flags argument.
23269         (mbsnwidth): New function.
23270
23271 2000-07-24  Jim Meyering  <meyering@lucent.com>
23272
23273         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
23274
23275 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23276
23277         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
23278
23279 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23280
23281         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
23282         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
23283         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
23284         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
23285         invoke multibyte primitives.
23286
23287 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23288
23289         * lib/quotearg.c:
23290         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
23291         so that mbstate_t is always defined.
23292
23293         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
23294         be 1 in at least one GCC installation, and this configuration
23295         error is likely to be common.  Ignoring MB_LEN_MAX hurts
23296         performance on hosts that have mbrtowc but have only unibyte
23297         locales, but I assume these hosts are rare.
23298
23299 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23300
23301         * lib/mbswidth.c (_XOPEN_SOURCE):
23302         Don't define; this causes problems on Solaris 7.
23303         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
23304
23305 2000-07-23  Jim Meyering  <meyering@lucent.com>
23306
23307         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
23308         too: getgrgid, getpwuid, getuid.
23309
23310 2000-07-23  Jim Meyering  <meyering@lucent.com>
23311
23312         * lib/basename.c (base_name): Add an assertion.
23313
23314 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
23315
23316         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
23317         shadow its mbsinit function.
23318
23319 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23320
23321         * lib/mbswidth.h: New file.
23322         * lib/mbswidth.c: New file.
23323         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
23324         (noinst_HEADERS): Add mbswidth.h.
23325
23326 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23327
23328         * lib/config.charset: Add support for FreeBSD. Improve support for
23329         HP-UX and IRIX 6.
23330
23331 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
23332
23333         * m4/mbswidth.m4: New file.
23334         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
23335
23336 2000-07-15  Jim Meyering  <meyering@lucent.com>
23337
23338         * lib/makepath.c: Include quote.h.
23339         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
23340         corresponding argument in a `quote (...)' call.
23341         Give better diagnostics.
23342
23343         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
23344         (noinst_HEADERS): Add quote.h.
23345
23346         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
23347         from tar's src/misc.c.
23348         * lib/quote.h: New file.  Prototypes for same.
23349
23350 2000-07-14  Paul Eggert  <eggert@twinsun.com>
23351
23352         From a suggestion by Bruno Haible.
23353         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
23354         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
23355         to decide whether to define the BeOS workaround macro;
23356         this adjusts to the change to AC_MBSTATE_T.
23357
23358 2000-07-14  Jim Meyering  <meyering@lucent.com>
23359
23360         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
23361         jm_AC_TYPE_UINTMAX_T.
23362
23363 2000-07-13  Paul Eggert  <eggert@twinsun.com>
23364
23365         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
23366
23367         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
23368         quotearg_buffer_restyled): Add support for
23369         clocale_quoting_style.  Undo previous change to
23370         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
23371         and "{RIGHT QUOTATION MARK}" msgids.
23372
23373 2000-07-10  Paul Eggert  <eggert@twinsun.com>
23374
23375         From a suggestion by Bruno Haible.
23376         * m4/mbstate_t.m4 (AC_MBSTATE_T):
23377         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
23378         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
23379         and mbstate_t, to a single-part test that simply defines mbstate_t.
23380         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
23381         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
23382
23383 2000-07-10  Jim Meyering  <meyering@lucent.com>
23384
23385         * m4/strerror_r.m4: Mirror the correction made in autoconf.
23386
23387         * m4/gnu-source.m4: Output to confdefs.h directly.
23388         Suggestion from Akim Demaille.
23389
23390 2000-07-09  Paul Eggert  <eggert@twinsun.com>
23391
23392         The old behavior of quoting `like this' doesn't look good with
23393         newer, ISO-style fonts.  See:
23394         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
23395
23396         Instead, quote "like this" by default.  Let the translator
23397         tailor the locale-specific quoting behavior by providing
23398         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
23399
23400         * lib/quotearg.c (N_): New macro.
23401         (gettext_default): New function.
23402         (quotearg_buffer_restyled): Use
23403         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
23404         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
23405
23406 2000-07-09  Jim Meyering  <meyering@lucent.com>
23407
23408         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
23409         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
23410
23411         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
23412         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
23413
23414 2000-07-09  Jim Meyering  <meyering@lucent.com>
23415
23416         * lib/Most files: Update copyright dates to include 2000.
23417
23418 2000-07-08  Jim Meyering  <meyering@lucent.com>
23419
23420         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
23421         if not defined.
23422         (xgethostname): Remove now-unnecessary #ifdef.
23423         Move declaration of `err' into loop where it's used.
23424
23425 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23426         and Bruno Haible  <haible@clisp.cons.org>
23427
23428         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
23429         only if the test for an object-type mbstate_t fails.  This
23430         prevents us from mistakenly reporting that mbstate_t is a
23431         system object type after we "#define mbstate_t int" to work
23432         around its lack.
23433
23434 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23435         and Bruno Haible  <haible@clisp.cons.org>
23436
23437         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
23438
23439 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23440
23441         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
23442         to strerror_r.
23443         Include <ctype.h> for use of isalpha.
23444
23445 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23446
23447         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
23448         by allocating a larger buffer. Test the gethostname return value for
23449         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
23450         returns an error and ENAMETOOLONG isn't defined.
23451
23452 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23453
23454         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
23455         dimension.
23456
23457 2000-07-04  Jim Meyering  <meyering@lucent.com>
23458
23459         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
23460         of the deprecated AC_CHECKING.
23461
23462 2000-07-04  Jim Meyering  <meyering@lucent.com>
23463
23464         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
23465         Reported by Bruno Haible.
23466
23467 2000-07-04  Jim Meyering  <meyering@lucent.com>
23468
23469         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
23470         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
23471         lacks mbrtowc.
23472
23473 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23474
23475         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
23476         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
23477
23478 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23479         and Bruno Haible  <haible@clisp.cons.org>
23480
23481         * lib/quotearg.c (mbrtowc):
23482         Assign to *pwc, and return 1 only if result is nonzero.
23483         (iswprint): Use ISPRINT when substituting our own mbrtowc.
23484
23485 2000-07-03  Jim Meyering  <meyering@lucent.com>
23486
23487         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
23488
23489 2000-07-03  Jim Meyering  <meyering@lucent.com>
23490
23491         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
23492         This is necessary to get a definition of e.g., UTMP_FILE on
23493         HP-UX 10.20.
23494         From Bob Proulx.
23495
23496 2000-07-02  Jim Meyering  <meyering@lucent.com>
23497
23498         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
23499
23500         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
23501         AC_LIBOBJ(function_name).
23502         * m4/chown.m4: Likewise.
23503         * m4/fnmatch.m4: Likewise.
23504         * m4/ftruncate.m4: Likewise.
23505         * m4/getgroups.m4: Likewise.
23506         * m4/getline.m4: Likewise.
23507         * m4/group-member.m4: Likewise.
23508         * m4/jm-macros.m4: Likewise.
23509         * m4/lstat.m4: Likewise.
23510         * m4/malloc.m4: Likewise.
23511         * m4/memcmp.m4: Likewise.
23512         * m4/nanosleep.m4: Likewise.
23513         * m4/putenv.m4: Likewise.
23514         * m4/realloc.m4: Likewise.
23515         * m4/regex.m4: Likewise.
23516         * m4/stat.m4: Likewise.
23517         * m4/strftime.m4: Likewise.
23518
23519 2000-07-02  Jim Meyering  <meyering@lucent.com>
23520
23521         * lib/quotearg.c (mbstate_t): Don't define here.
23522
23523 2000-07-02  Jim Meyering  <meyering@lucent.com>
23524
23525         * lib/nanosleep.c (SIGCONT): Define if not already defined.
23526
23527 2000-07-01  Jim Meyering  <meyering@lucent.com>
23528
23529         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
23530
23531 2000-07-01  Jim Meyering  <meyering@lucent.com>
23532
23533         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
23534         problem.
23535
23536 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23537
23538         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
23539         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
23540
23541 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23542
23543         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
23544         per change in ../m4/ls-mntd-fs.m4.
23545         (read_filesystem_list): Ignore symbolic links.
23546
23547 2000-06-29  Jim Meyering  <meyering@lucent.com>
23548
23549         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
23550         for declaration of strcmp.
23551
23552         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
23553
23554         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
23555         Avoid warning by casting result to `char *' to remove `const'.
23556
23557 2000-06-28  Jim Meyering  <meyering@lucent.com>
23558
23559         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
23560         included by quotearg.c, for which we perform this test.  From
23561         Bruno Haible.
23562
23563 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23564
23565         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
23566         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
23567         <utmpx.h> exists, put readutmp.o into LIBOBJS.
23568
23569 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23570
23571         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
23572
23573 2000-06-26  Paul Eggert  <eggert@twinsun.com>
23574
23575         savedir now sets errno on failure and invokes xmalloc to get memory.
23576         Fix a couple of other minor bugs while we're at it.
23577
23578         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
23579         (NAMLEN): Remove macro.
23580         (malloc, realloc): Remove decls.
23581         (stpcpy): Likewise.
23582         ("xalloc.h"): Include.
23583         (NAME_SIZE_DEFAULT): New macro.
23584         (savedir): Use xmalloc / xrealloc to allocate memory.
23585         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
23586         Skip "" directory entries.
23587         Use strlen to calculate directory entry length, since the old method
23588         is rarely used these days and isn't worth supporting.
23589         Don't use a pointer after freeing it.
23590         Check for integer overflow when calculating allocation size.
23591         Use memcpy to copy entries, instead of stpcpy.
23592         Set errno properly when returning NULL.
23593         Check for readdir error.
23594
23595 2000-06-26  Jim Meyering  <meyering@lucent.com>
23596
23597         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
23598
23599 2000-06-25  Jim Meyering  <meyering@lucent.com>
23600
23601         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
23602         Linux header bug when _XOPEN_SOURCE is defined to 500.
23603
23604 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23605
23606         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
23607         deficiency.
23608
23609 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23610
23611         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
23612         Include xalloc.h.
23613         Don't include <stdlib.h>.  Don't declare malloc, realloc.
23614
23615 2000-06-24  Jim Meyering  <meyering@lucent.com>
23616
23617         * m4/strerror_r.m4: Revive this file -- to try out an experimental
23618         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
23619         for which strerror does return char*, but which lacks a conveniently
23620         accessible declaration of the function.  If the compile-test says
23621         strerror_r doesn't work, then resort to a `run'-test that works on
23622         BeOS and segfaults on DEC Unix.
23623
23624 2000-06-24  Jim Meyering  <meyering@lucent.com>
23625
23626         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
23627
23628 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23629
23630         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
23631         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
23632
23633 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23634
23635         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
23636         (mbrtowc, mbstate_t): Define substitutes if
23637         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
23638         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
23639         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
23640
23641 2000-06-23  Jim Meyering  <meyering@lucent.com>
23642
23643         * m4/afs.m4: Add missing AC_MSG_RESULT.
23644         Reported by Bruno Haible.
23645
23646         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
23647         Suggestion from Bruno Haible.
23648
23649 2000-06-23  Jim Meyering  <meyering@lucent.com>
23650
23651         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
23652
23653 2000-06-21  Jim Meyering  <meyering@lucent.com>
23654
23655         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
23656
23657 2000-06-21  Jim Meyering  <meyering@lucent.com>
23658
23659         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
23660         (noinst_HEADERS): Add getstr.h.
23661
23662         * lib/getline.c (getstr): Move into a separate file.
23663         * lib/getstr.c (getstr): New file, extracted from getline.c, with
23664         the following changes: new parameter, delim2; both delim[12]
23665         parameters have type `int', not `char'.  The latter would lose
23666         with 8-bit delimiters.
23667         * lib/getstr.h: New file.
23668
23669 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23670
23671         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
23672         than 1024, return a memory chunk of least possible size, instead
23673         of size PATH_MAX + 2. In the loop, increment the size proportionally.
23674         Use free/xmalloc instead of xrealloc to avoid copying for very long
23675         paths.
23676
23677 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23678
23679         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
23680         the empty string.
23681
23682 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23683
23684         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
23685         address, not strdup.  Include <stdlib.h> and don't declare free().
23686
23687 2000-06-19  Jim Meyering  <meyering@lucent.com>
23688
23689         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
23690
23691 2000-06-18  Jim Meyering  <meyering@lucent.com>
23692
23693         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
23694
23695         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
23696         `checking whether...' message to be consistent with that of the
23697         lstat test.
23698
23699 2000-06-18  Jim Meyering  <meyering@lucent.com>
23700
23701         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
23702         Besides, these days every porting target provides a mkdir function.
23703
23704         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
23705         needed. (this snippet comes from src/system.h).
23706
23707 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
23708
23709         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
23710
23711 2000-06-15  Paul Eggert  <eggert@twinsun.com>
23712
23713         * lib/human.c (adjust_value): New function.
23714         (human_readable_inexact): Apply rounding style even when
23715         printing approximate values.
23716
23717 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23718
23719         * lib/human.c (human_readable_inexact): Allow an input block
23720         size that is not a multiple of the output block size, and vice versa.
23721         Reported by Piergiorgio Sartor.
23722
23723 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23724
23725         * lib/getdate.y (get_date): Apply relative times after time
23726         zone indicator, not before.  Reported by Todd A. Jacobs.
23727
23728 2000-06-13  Jim Meyering  <meyering@lucent.com>
23729
23730         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
23731
23732         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
23733
23734 2000-06-12  Paul Eggert  <eggert@twinsun.com>
23735
23736         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
23737
23738 2000-06-12  Jim Meyering  <meyering@lucent.com>
23739
23740         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
23741         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
23742         optional argument.
23743         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
23744         the optional argument, `lib'.
23745
23746 2000-06-08  Jim Meyering  <meyering@lucent.com>
23747
23748         * m4/largefile.m4: Remove file (now that it's part of autoconf).
23749
23750 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23751
23752         Rewrite largefile configuration so that we don't need to run
23753         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
23754         AC_CANONICAL_HOST in configure.in -- jmm]
23755
23756         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
23757         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
23758         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
23759         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
23760         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
23761         All uses changed.
23762         Instead of inspecting the output of getconf, try to compile the
23763         test program without and with the macro definition.
23764         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
23765         for getconf.  Instead, check for the needed flags by compiling
23766         test programs.
23767
23768 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23769
23770         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
23771
23772 2000-06-04  Jim Meyering  <meyering@lucent.com>
23773
23774         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
23775         SunOS 4.1.4 for which gid_t is an unsigned type.
23776
23777 2000-06-03  Jim Meyering  <meyering@lucent.com>
23778
23779         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
23780         now that autoconf requires that.
23781
23782         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
23783         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
23784         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
23785
23786 2000-06-03  Jim Meyering  <meyering@lucent.com>
23787
23788         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
23789
23790 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23791
23792         * m4/glibc21.m4: New file.
23793         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
23794
23795 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23796
23797         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
23798         newer, don't install charset.alias.
23799         * lib/config.charset: Change the Linux/glibc rules so they become empty
23800         on glibc-2.1 or newer.
23801
23802 2000-06-02  Jim Meyering  <meyering@lucent.com>
23803
23804         * lib/mountlist.c: Back out last change.  Instead, do this...
23805         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
23806         me_dummy member using the same `ignore'-testing code.
23807         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
23808         fs_type strings.
23809         From Mark D. Roth.
23810
23811 2000-05-29  Jim Meyering  <meyering@lucent.com>
23812
23813         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
23814         mounts with the `ignore' attribute.  Based on a patch from
23815         Mark D. Roth.
23816
23817 2000-05-28  Jim Meyering  <meyering@lucent.com>
23818
23819         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
23820         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23821         * m4/stat.m4: Likewise.
23822         * m4/lstat.m4: Likewise.
23823         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
23824
23825         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
23826         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
23827
23828 2000-05-26  Jim Meyering  <meyering@lucent.com>
23829
23830         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
23831
23832 2000-05-24  Jim Meyering  <meyering@lucent.com>
23833
23834         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
23835         autoconf requires that.
23836         * m4/lib-check.m4: Likewise.
23837         * m4/jm-macros.m4: Likewise.
23838         * m4/strftime.m4: Likewise.
23839
23840         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
23841         AC_CHECK_DECLS, now that autoconf requires that.
23842
23843 2000-05-22  Jim Meyering  <meyering@lucent.com>
23844
23845         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23846         * m4/lstat.m4: Likewise.
23847
23848 2000-05-22  Jim Meyering  <meyering@lucent.com>
23849
23850         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
23851
23852 2000-05-20  Jim Meyering  <meyering@lucent.com>
23853
23854         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
23855         (jm_PREREQ): Use it.
23856
23857 2000-05-18  Jim Meyering  <meyering@lucent.com>
23858
23859         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
23860         back, too, since it may have been modified by allocate_entry.
23861         (hash_delete): Rewrite to use neither the assignment operator
23862         nor the comma operator in an if-expression.
23863
23864 2000-05-15  Paul Eggert  <eggert@twinsun.com>
23865
23866         * lib/closeout.c:
23867         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
23868         Remove; no longer needed.
23869         "quotearg.h": Add include.
23870         (file_name): Do not bother to explicitly initialize to NULL; it's less
23871         efficient on some hosts.
23872         (close_stdout_status): Remove test as to whether stdout was already
23873         closed; it breaks for the case "echo x | sort >&-".
23874         Quote file name colons.
23875         Do not assume that _("write error") lacks format strings.
23876
23877 2000-05-15  Jim Meyering  <meyering@lucent.com>
23878
23879         * lib/version-etc.c (version_etc_copyright): Update the copyright
23880         string used in all --version output.
23881
23882 2000-05-14  Jim Meyering  <meyering@lucent.com>
23883
23884         * lib/closeout.c (close_stdout_set_file_name): New function.
23885         (close_stdout_status): Use new file-scoped global.
23886         Return right away if fstat says the stdout file descriptor is invalid.
23887         * lib/closeout.h (close_stdout_set_file_name): Declare.
23888
23889 2000-05-10  Jim Meyering  <meyering@lucent.com>
23890
23891         * lib/closeout.c [default_exit_status]: New file-scoped variable.
23892         (close_stdout_set_status): New function.
23893         * lib/closeout.h (close_stdout_set_status): Declare.
23894
23895 2000-05-09  Jim Meyering  <meyering@lucent.com>
23896
23897         * m4/gettext.m4: Rename this...
23898         * m4/libintl.m4: ...to this.
23899
23900 2000-05-08  Jim Meyering  <meyering@lucent.com>
23901
23902         * lib/long-options.c: Don't include closeout.h.
23903         (parse_long_options): Don't call close_stdout for --version.
23904
23905 2000-05-06  Paul Eggert  <eggert@twinsun.com>
23906
23907         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
23908         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
23909         2.1.3 bug.  This avoids a clash when files like regex.c define
23910         _GNU_SOURCE.
23911
23912 2000-05-06  Jim Meyering  <meyering@lucent.com>
23913
23914         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
23915         (AC_REPLACE_FUNCS): Add strnlen.
23916
23917         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
23918         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
23919
23920         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
23921         AC_SEARCH_LIBS call for nanosleep.
23922         (LIB_NANOSLEEP): Set and AC_SUBST.
23923
23924 2000-05-06  Jim Meyering  <meyering@lucent.com>
23925
23926         * lib/strnlen.c: Undefine __strnlen and strnlen.
23927         [!weak_alias]: Define __strnlen to strnlen.
23928
23929         * lib/atexit.c: New file, from libiberty.
23930
23931 2000-05-06  Jim Meyering  <meyering@lucent.com>
23932
23933         * lib/closeout.c (close_stdout_status): Also check for errors on the
23934         stderr stream.
23935
23936 2000-05-05  Jim Meyering  <meyering@lucent.com>
23937
23938         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
23939         AC_SEARCH_LIBS call for clock_gettime.
23940         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
23941
23942         * m4/search-libs.m4: Update from autoconf.
23943
23944         su doesn't work on Solaris 2.6.
23945         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
23946         <shadow.h>.  Reported by Dragos Harabor.
23947
23948 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
23949
23950         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
23951         memcpy instead of xmalloc, xrealloc, path_concat.
23952         (locale_charset): Treat empty environment variables as absent.
23953         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
23954
23955 2000-05-04  Jim Meyering  <meyering@lucent.com>
23956
23957         * lib/getopt.c: Update from glibc.
23958         * lib/obstack.c: Likewise.
23959         * lib/obstack.h: Likewise.
23960         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
23961         file
23962
23963         * lib/regex.h: Likewise.
23964         * lib/strndup.c: Likewise.
23965         * lib/strnlen.c: New file, from glibc.
23966
23967 2000-05-03  Jim Meyering  <meyering@lucent.com>
23968
23969         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
23970
23971 2000-05-02  Paul Eggert  <eggert@twinsun.com>
23972
23973         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
23974         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
23975         compile-time test, rather than inspecting host and OS, to
23976         decide whether to define _LARGEFILE_SOURCE.
23977
23978 2000-05-01  Jim Meyering  <meyering@lucent.com>
23979
23980         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
23981
23982         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
23983         Based on a patch from Bruno Haible.
23984
23985 2000-05-01  Jim Meyering  <meyering@lucent.com>
23986
23987         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
23988
23989 2000-04-29  Jim Meyering  <meyering@lucent.com>
23990
23991         * lib/path-concat.c: Declare strdup only if it's not defined.
23992         * lib/canon-host.c: Likewise.
23993
23994 2000-04-28  Jim Meyering  <meyering@lucent.com>
23995
23996         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
23997         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
23998         is included first, then limits.h is included by locale.h by libintl.h.
23999         From John David Anglin.
24000
24001 2000-04-25  Jim Meyering  <meyering@lucent.com>
24002
24003         * lib/makepath.c (S_IRWXUGO): Define.
24004         (make_path): Always perform explicit chmod if MODE specifies any
24005         of the `special' permission bits.  Prompted by a bug report against
24006         install from Mate Wierdl and Joost van Baal.
24007
24008 2000-04-18  Jim Meyering  <meyering@lucent.com>
24009
24010         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
24011         (jm_PREREQ): Use it.
24012
24013 2000-04-18  Jim Meyering  <meyering@lucent.com>
24014
24015         * lib/README: New file.
24016
24017         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
24018         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
24019
24020 2000-04-17  Jim Meyering  <meyering@lucent.com>
24021
24022         Get it right :-)
24023         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
24024         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
24025         Suggestion from Akim Demaille.
24026
24027 2000-04-17  Jim Meyering  <meyering@lucent.com>
24028
24029         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
24030         the definition of it to rpl_strftime also defined-away the system's
24031         declaration.
24032
24033 2000-04-15  Jim Meyering  <meyering@lucent.com>
24034
24035         Use `C' to denote so-called `contiguous' files, the same way
24036         that tar does.
24037         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
24038         (ftypelet): Use S_ISCTG.
24039         From Michael Deutschmann.
24040
24041 2000-04-14  Jim Meyering  <meyering@lucent.com>
24042
24043         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
24044         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
24045         clobbered.
24046
24047 2000-04-14  Jim Meyering  <meyering@lucent.com>
24048
24049         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
24050
24051 2000-04-13  Jim Meyering  <meyering@lucent.com>
24052
24053         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
24054         AH_VERBATIM to insert required #ifndef into config.h.in.
24055         Suggestion from Akim Demaille.
24056
24057 2000-04-12  Jim Meyering  <meyering@lucent.com>
24058
24059         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
24060         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
24061         Christian Krackowizer.
24062
24063         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
24064         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
24065         (AC_SYS_LARGEFILE): Require.
24066         (AM_C_PROTOTYPES): Require.
24067
24068 2000-04-08  Jim Meyering  <meyering@lucent.com>
24069
24070         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
24071         names don't conflict.  Reported by Eli Zaretskii.
24072
24073 2000-04-07  Jim Meyering  <meyering@lucent.com>
24074
24075         * lib/putenv.c: Move inclusion of errno.h so it follows that of
24076         sys/types.h, to work around system header problems on AIX 3.2.5.
24077         From Bruno Haible.
24078
24079 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
24080
24081         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
24082         bug.  Deal with the different error behavior of Irix iconv.
24083
24084 2000-04-05  Paul Eggert  <eggert@twinsun.com>
24085
24086         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
24087         IRIX if the installer said otherwise.
24088
24089 2000-04-05  Jim Meyering  <meyering@lucent.com>
24090
24091         Portability tweaks required for ultrix4.3.
24092         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
24093         (jm_CHECK_DECLS): Add getutent to the list of functions.
24094         (_jm_DECL_HEADERS): Add utmpx.h.
24095         From John David Anglin.
24096
24097         * m4/strftime.m4: Back out the 2000-04-02 change.
24098         Instead of that change, simply undefine putenv in the test program.
24099
24100 2000-04-05  Jim Meyering  <meyering@lucent.com>
24101
24102         Portability tweaks required for ultrix4.3.
24103         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
24104         getutent.
24105         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
24106         * lib/canon-host.c: Declare strdup.
24107         * lib/path-concat.c: Likewise.
24108         From John David Anglin.
24109
24110 2000-04-04  Jim Meyering  <meyering@lucent.com>
24111
24112         Be more DOS 8.3-friendly.
24113         * lib/ref-add.sin: Renamed from ref-add.sed.in.
24114         * lib/ref-del.sin: Renamed from ref-del.sed.in.
24115         * lib/Makefile.am: Reflect renaming.
24116         Reported by Eli Zaretskii.
24117
24118         Use a temporary file name that won't clash with `charset.alias'
24119         in the DOS 8.3 name space.
24120         * lib/Makefile.am (charset_tmp): Define.
24121         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
24122         (uninstall-local): Likewise.
24123         Reported by Eli Zaretskii.
24124
24125 2000-04-03  Jim Meyering  <meyering@lucent.com>
24126
24127         * m4/gettext.m4: Fix typo in comment.
24128
24129         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
24130         textutils/configure.in).  Suggestion from Paul Eggert.
24131         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
24132
24133 2000-04-02  Paul Eggert  <eggert@twinsun.com>
24134
24135         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
24136         variable in the shell rather than using putenv, which isn't
24137         portable.  This avoids the configure-time inter-test dependency
24138         on the potentially-renamed putenv function.
24139
24140 2000-03-30  Paul Eggert  <eggert@twinsun.com>
24141
24142         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
24143         before checking struct stat.st_blksize, so that
24144         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
24145
24146 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24147
24148         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
24149         since strftime.c uses HAVE_STRFTIME to decide whether to use
24150         the underlying strftime.
24151
24152 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24153
24154         * lib/time/strftime.c (my_strftime): Make sure we call the system
24155         strftime, not ourselves, when invoking the underlying strftime.
24156
24157 2000-03-24  Jim Meyering  <meyering@lucent.com>
24158
24159         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
24160         (charset_alias): Define.
24161         (install-exec-local): Factor out common code.
24162         (uninstall-local): Split lines longer than 80.
24163         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
24164         (SUFFIXES): Define.
24165         (.sed.in.sed): New rule.  Don't redirect directly to $@.
24166         (CLEANFILES): Add ref-add.sed and ref-del.sed.
24167
24168 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
24169
24170         * lib/config.charset: Output a line containing "Packages using this
24171         file".
24172         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
24173         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
24174         ref-del.sed): New rules.
24175
24176 2000-03-17  Jim Meyering  <meyering@lucent.com>
24177
24178         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
24179         Otherwise, include <strings.h>
24180
24181 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
24182
24183         * lib/unicodeio.c (utf8_wctomb): New function.
24184         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
24185         format instead of in UCS-4 with platform dependent endianness.
24186
24187 2000-03-10  Jim Meyering  <meyering@lucent.com>
24188
24189         * m4/lib-check.m4: Look for getspnam in -lgen, too.
24190         From Marco Franzen.
24191
24192 2000-03-07  Paul Eggert  <eggert@twinsun.com>
24193
24194         * lib/savedir.c (savedir): Work even if directory size is
24195         negative; this can happen with some screwy NFS configurations.
24196
24197 2000-03-06  Jim Meyering  <meyering@lucent.com>
24198
24199         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
24200         if it's NULL (because we ran out of memory).  From Bruno Haible.
24201
24202 2000-03-05  Jim Meyering  <meyering@lucent.com>
24203
24204         * lib/localcharset.c ("path-concat.h"): Include.
24205         (get_charset_aliases): Use path_concat instead of ANSI string
24206         concatenation.
24207
24208         * lib/unicodeio.h (PARAMS): Define.
24209         Use it to guard prototype.
24210
24211 2000-03-04  Jim Meyering  <meyering@lucent.com>
24212
24213         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
24214         for lib/localcharset.c.
24215
24216 2000-03-04  Jim Meyering  <meyering@lucent.com>
24217
24218         * lib/Makefile.am (install-exec-local): Create $(libdir) before
24219         installing into it.
24220         (uninstall-local): Uncomment this rule so `make distcheck' works
24221         once again.
24222
24223         * lib/unicodeio.c (<errno.h>): Include it.
24224         (errno): Declare if not defined.
24225
24226         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
24227
24228         * lib/config.charset: New version, incorporating remarks from a linux
24229         i18n mailing list.  From Bruno Haible.
24230
24231 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
24232
24233         * m4/codeset.m4: New file.
24234         * m4/iconv.m4: New file.
24235         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
24236
24237 2000-03-03  Jim Meyering  <meyering@lucent.com>
24238
24239         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
24240
24241 2000-03-02  Jim Meyering  <meyering@lucent.com>
24242
24243         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
24244         the messages come out on separate lines.
24245
24246         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
24247         rather than jm_CHECK_DECLARATIONS.
24248         * m4/decl.m4: Remove now-unused file.
24249
24250         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
24251         geteuid.
24252
24253 2000-03-02  Jim Meyering  <meyering@lucent.com>
24254
24255         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
24256
24257 2000-03-01  Jim Meyering  <meyering@lucent.com>
24258
24259         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
24260         * lib/unicodeio.c: Likewise.
24261
24262 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
24263
24264         * lib/config.charset: New file.
24265         * lib/localcharset.c: New file.
24266         * lib/unicodeio.h, lib/unicodeio.c: New files.
24267         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
24268         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
24269         (noinst_HEADERS): Add unicodeio.h.
24270         (all-local, install-exec-local, charset.alias): New targets.
24271
24272 2000-02-28  Paul Eggert  <eggert@twinsun.com>
24273
24274         * lib/quotearg.c (ALERT_CHAR): New macro.
24275         (quotearg_buffer_restyled): Use it.
24276
24277 2000-02-27  Jim Meyering  <meyering@lucent.com>
24278
24279         * m4/check-decl.m4: Add getenv to the list.
24280
24281 2000-02-27  Jim Meyering  <meyering@lucent.com>
24282
24283         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
24284         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
24285
24286         * lib/backupfile.c: Guard inclusion of stdlib.h with
24287         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
24288         Declare malloc if needed.
24289
24290         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
24291         `#ifndef HAVE_DECL..'
24292         now that autoconf always defines the HAVE_DECL_ symbols.
24293         * lib/human.c: Likewise.
24294         * lib/same.c: Likewise.
24295         * lib/strtoumax.c: Likewise.
24296
24297         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
24298         declaration check was not run.
24299         * lib/hash.c: Likewise.
24300         * lib/human.c: Likewise.
24301         * lib/same.c: Likewise.
24302         * lib/strtoumax.c: Likewise.
24303
24304         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
24305         `.', then first look up the entire `.'-containing string as a login
24306         name.
24307
24308 2000-02-23  Jim Meyering  <meyering@lucent.com>
24309
24310         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
24311         in place of my hack.
24312
24313 2000-02-18  Paul Eggert  <eggert@twinsun.com>
24314
24315         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
24316         (textint): New typedef.
24317         (parser_control): Member year changed from int to textint.
24318         All uses changed.
24319         (YYSTYPE): Removed; replaced by %union with int and textint members.
24320         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
24321         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
24322         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
24323         (tSNUMBER, tUNUMBER): Now of type <textintval>.
24324         (date, number, to_year): Use width of number in digits, not its value,
24325         to determine whether it's a 2-digit year, or a 2-digit time.
24326         (yylex): Store number of digits of numeric tokens.
24327         Reported by John Kendall.
24328
24329         (parser_control): Changed from struct parser_control to typedef (for
24330         consistency).  All uses changed.
24331
24332         (tID): Removed; not used.
24333         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
24334
24335 2000-02-14  Paul Eggert  <eggert@twinsun.com>
24336
24337         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
24338         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
24339
24340 2000-02-12  Jim Meyering  <meyering@lucent.com>
24341
24342         * lib/userspec.c (ISDIGIT): Define it.
24343         (isdigit): Remove definition.
24344         (is_number): Use ISDIGIT, not isdigit.
24345         <libintl.h>: Include.
24346         (_ and N_): Define.
24347         (parse_user_spec): Mark translatable strings.
24348
24349 2000-02-10  Jim Meyering  <meyering@lucent.com>
24350
24351         With these changes, nanosleep.[ch] are finally enough like the other
24352         lib/* replacement files to compile on a few more losing systems.
24353
24354         * lib/nanosleep.h: Don't include config.h.
24355         Remove prototype from declaration of nanosleep.
24356         (PARAMS): Remove now-unneeded definition.
24357         * lib/nanosleep.c: #undef nanosleep.
24358         (rpl_nanosleep): Rename from nanosleep.
24359
24360 2000-02-10  Jim Meyering  <meyering@lucent.com>
24361
24362         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
24363         gnu_nanosleep to rpl_nanosleep.
24364
24365 2000-02-09  Jim Meyering  <meyering@lucent.com>
24366
24367         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
24368         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
24369
24370 2000-02-08  Akim Demaille  <akim@epita.fr>
24371
24372         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
24373         `[' and `]' and remove uses of `changequote'.
24374         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
24375         (AC_SYS_LARGEFILE): Likewise.
24376         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
24377         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
24378         of changequote.
24379         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
24380         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
24381         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
24382         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
24383
24384 2000-02-05  Jim Meyering  <meyering@lucent.com>
24385
24386         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
24387         Remove explicit use of AC_HEADER_TIME.  It is required by
24388         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
24389         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
24390         in autoconf whereby the expansion of the latter ended up preceding
24391         the expansion of its prerequisite, AC_HEADER_TIME.
24392         Reported by Volker Borchert.
24393
24394 2000-02-03  Jim Meyering  <meyering@lucent.com>
24395
24396         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
24397
24398 2000-02-03  Jim Meyering  <meyering@lucent.com>
24399
24400         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
24401         rather than with `#if HAVE_UTMPNAME'.
24402
24403 2000-02-02  Jim Meyering  <meyering@lucent.com>
24404
24405         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
24406         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
24407         Reported by Eli Zaretskii.
24408
24409 2000-02-01  Jim Meyering  <meyering@lucent.com>
24410
24411         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
24412
24413 2000-01-31  Jim Meyering  <meyering@lucent.com>
24414
24415         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
24416         functions.  Add the time.h and sys/time.h headers along with the
24417         AC_REQUIRE'ment of AC_HEADER_TIME.
24418
24419 2000-01-31  Jim Meyering  <meyering@lucent.com>
24420
24421         * lib/nanosleep.h (nanosleep): Guard declaration with
24422         `#if ! HAVE_DECL_NANOSLEEP'.
24423         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
24424         the declaration in that vendor's sys/timers.h.
24425         Reported by Christian Krackowizer.
24426
24427         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
24428         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
24429         (ISPRINT): Likewise.
24430         Reported by Tom Tromey.
24431
24432 2000-01-30  Jim Meyering  <meyering@lucent.com>
24433
24434         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
24435
24436         * m4/prereq.m4 (utmp_includes): Define.
24437         Check for ut_user and ut_name members in both struct utmpx
24438         and struct utmp.
24439
24440 2000-01-30  Jim Meyering  <meyering@lucent.com>
24441
24442         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
24443         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
24444         header files where only utmpx.ut_user is declared.
24445
24446         * lib/readutmp.h (UT_USER): Define.
24447
24448 2000-01-29  Jim Meyering  <meyering@lucent.com>
24449
24450         * m4/lib-check.m4: New file containing library-related checks from
24451         fileutils and sh-utils (textutils had none).
24452
24453 2000-01-28  Jim Meyering  <meyering@lucent.com>
24454
24455         * m4/perl.m4: Change format of warning message to look more like that
24456         from the missing script.  Suggestion from François Pinard.
24457
24458 2000-01-25  Jim Meyering  <meyering@lucent.com>
24459
24460         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
24461         well as time.h in the compile check.
24462         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
24463         Fix typo in cross-compiling case: s/yes/no/.
24464
24465 2000-01-23  Jim Meyering  <meyering@lucent.com>
24466
24467         * m4/jm-macros.m4: Move df-related tests here from
24468         fileutils/configure.in
24469
24470         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
24471         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
24472
24473         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
24474         s/space/ac_fsusage_space/.
24475         (jm_FILE_SYSTEM_USAGE): Take two parameters.
24476
24477         * m4/ftruncate.m4: New file (derived from part of
24478         fileutils/configure.in).
24479         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
24480         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
24481
24482         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
24483         AC_SUBST these here, rather than just in sh-util/configure.in, so
24484         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
24485         all the same.
24486         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
24487         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
24488         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
24489         (AC_SUBST(POW_LIBM)): Likewise.
24490         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
24491
24492 2000-01-23  Jim Meyering  <meyering@lucent.com>
24493
24494         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
24495         obstack.c.
24496
24497 2000-01-22  Jim Meyering  <meyering@lucent.com>
24498
24499         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
24500
24501         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
24502
24503         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
24504         configure.in
24505         (AC_CHECK_HEADERS): Likewise for sh-utils.
24506         (AC_CHECK_HEADERS): Likewise for textutils.
24507         Merge the three lists of headers.
24508
24509         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
24510         from fileutils' configure.in.
24511
24512         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
24513         code. Moved tests into their own function (_jm_DECL_HEADERS) in
24514         check-decl.m4.
24515
24516         * m4/check-decl.m4: Use #if rather than #ifdef.
24517         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
24518         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
24519         (_jm_DECL_HEADERS): Define new function.
24520         (jm_CHECK_DECLARATIONS): Require it.
24521
24522 2000-01-22  Jim Meyering  <meyering@lucent.com>
24523
24524         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
24525         [! HAVE_DECL_STRTOULL]: Declare strtoull.
24526         Required for some AIX systems.  Reported by Christian Krackowizer.
24527         [TESTING] (main): New function.
24528
24529         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
24530         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
24531         letters.
24532
24533         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
24534         iswprint.
24535
24536         * lib/strverscmp.c (ISDIGIT): Define.
24537         (strverscmp): Use ISDIGIT, not isdigit.
24538
24539 2000-01-19  Jim Meyering  <meyering@lucent.com>
24540
24541         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
24542         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
24543         defines `struct timespec' in <sys/time.h>
24544
24545         * m4/c-bs-a.m4: Remove uses of changequote altogether.
24546         Thanks to Akim for explaining.
24547
24548 2000-01-17  Paul Eggert  <eggert@twinsun.com>
24549
24550         * lib/nanosleep.c (nanosleep):
24551         Don't use SA_INTERRUPT to decide whether to call sigaction, as
24552         POSIX.1 doesn't require SA_INTERRUPT and some systems
24553         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
24554         it's been part of POSIX.1 since day 1 (in 1988).
24555
24556 2000-01-17  Jim Meyering  <meyering@lucent.com>
24557
24558         * lib/interlock: Remove unused file.  Reported by François Pinard.
24559
24560 2000-01-16  Paul Eggert  <eggert@twinsun.com>
24561
24562         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
24563         alert, backslash, formfeed, and vertical tab unnecessarily in
24564         shell quoting style.
24565
24566 2000-01-16  Jim Meyering  <meyering@lucent.com>
24567
24568         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
24569         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
24570         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
24571         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
24572
24573 2000-01-16  Jim Meyering  <meyering@lucent.com>
24574
24575         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
24576         because the latter didn't work.
24577
24578 2000-01-15  Jim Meyering  <meyering@lucent.com>
24579
24580         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
24581         (AC_REPLACE_FUNCS): Add memcpy and memset.
24582         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
24583         Add strpbrk.
24584         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
24585
24586 2000-01-12  Jim Meyering  <meyering@lucent.com>
24587
24588         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
24589         (jm_PREREQ): Use it.
24590         (jm_PREREQ_READUTMP): New macro.
24591         (jm_PREREQ): Use it.
24592
24593 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24594
24595         Quote multibyte characters correctly.
24596         * m4/c-bs-a.m4: New file.
24597         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
24598         (jm_PREREQ): Use it.
24599
24600 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24601
24602         * m4/uintmax_t.m4: Port to autoconf 2.13.
24603
24604 2000-01-08  Jim Meyering  <meyering@ascend.com>
24605
24606         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
24607         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
24608
24609 2000-01-04  Jim Meyering  <meyering@ascend.com>
24610
24611         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
24612         jm_STRUCT_DIRENT_D_TYPE.
24613         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
24614         jm_STRUCT_DIRENT_D_INO.
24615         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
24616         jm_STRUCT_UTIMBUF.
24617         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
24618         renamings.
24619         * m4/utime.m4: Likewise.
24620
24621         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
24622         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
24623
24624 2000-01-03  Paul Eggert  <eggert@twinsun.com>
24625
24626         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
24627         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
24628
24629 2000-01-02  Jim Meyering  <meyering@ascend.com>
24630
24631         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
24632         remember if this is necessary.
24633
24634 1999-12-26  Jim Meyering  <meyering@ascend.com>
24635
24636         * m4/jm-macros.m4: Use it here.
24637         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
24638
24639 1999-12-23  Jim Meyering  <meyering@ascend.com>
24640
24641         * m4/jm-macros.m4: Check for clock_gettime (moved from
24642         fileutils/configure.in)
24643         Check for gettimeofday.
24644
24645 1999-12-20  Jim Meyering  <meyering@ascend.com>
24646
24647         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
24648         autoconf-2.14a-1999-12-20.
24649
24650 1999-12-19  Jim Meyering  <meyering@ascend.com>
24651
24652         * m4/lstat-slash.m4: New file.
24653         * m4/jm-macros.m4: Use the new macro:
24654         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24655
24656 1999-12-07  Jim Meyering  <meyering@ascend.com>
24657
24658         * m4/perl.m4: Require that File::Compare be available, too.
24659         Too many systems seem to lack it.
24660
24661         * m4/strftime.m4: Add checks for most of the cpp macros tested in
24662         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
24663
24664 1999-11-18  Paul Eggert  <eggert@twinsun.com>
24665
24666         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
24667         problem with the QNX 4.25 shell, which doesn't propagate exit
24668         status of failed commands inside shell assignments.
24669
24670 1999-11-17  Jim Meyering  <meyering@ascend.com>
24671
24672         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
24673
24674 1999-11-07  Jim Meyering  <meyering@ascend.com>
24675
24676         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
24677
24678 1999-11-06  Jim Meyering  <meyering@ascend.com>
24679
24680         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
24681         * m4/jm-macros.m4 (jm_MACROS): Use it here.
24682
24683 1999-11-05  Jim Meyering  <meyering@ascend.com>
24684
24685         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
24686         configure.in of textutils, fileutils, and sh-utils into this one
24687         (shared between those packages) file.
24688         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
24689         AC_STRUCT_ST_BLKSIZE.
24690
24691 1999-11-03  Jim Meyering  <meyering@ascend.com>
24692
24693         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
24694         of AC_CHECK_TYPE checks includes unistd.h.
24695         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
24696         Suggestion from Akim Demaille.
24697
24698 1999-10-30  Jim Meyering  <meyering@ascend.com>
24699
24700         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
24701         m4-quoted string.
24702         * m4/ls-mntd-fs.m4: Likewise.
24703         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
24704         * m4/jm-winsz1.m4: Likewise.
24705
24706         * m4/const.m4: Remove file, since the fix made it into the experimental
24707         version of autoconf.
24708         * m4/mktime.m4: Likewise.
24709
24710         * m4/check-type.m4: Remove file, now that the latest version of
24711         AC_CHECK_TYPE takes a third arg to specify additional #includes.
24712
24713         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
24714         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
24715         AC_CHECK_TYPE.
24716
24717 1999-10-04  Jim Meyering  <meyering@ascend.com>
24718
24719         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
24720
24721 1999-09-22  Paul Eggert  <eggert@twinsun.com>
24722
24723         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
24724         2.95.1 bug with HP-UX 10.20.
24725
24726 1999-09-17  Jim Meyering  <meyering@ascend.com>
24727
24728         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
24729         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
24730         due to missing strdup (against sh-utils-2.0).
24731
24732 1999-08-29  Jim Meyering  <meyering@ascend.com>
24733
24734         * m4/jm-macros.m4: Require jm_BISON.
24735         * m4/bison.m4: New file.
24736
24737 1999-08-17  Paul Eggert  <eggert@twinsun.com>
24738
24739         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
24740         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
24741
24742 1999-08-05  Jim Meyering  <meyering@ascend.com>
24743
24744         * m4/getline.m4: Rename test file from conftestdata to conftest.data
24745         to avoid conflicts with `conftest' on 8+3 filesystems.
24746         Suggestion from Eli Zaretskii.
24747
24748 1999-08-04  Jim Meyering  <meyering@ascend.com>
24749
24750         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
24751         fileutils and sh-utils (textutils's getline test was inadequate).
24752         (AM_FUNC_GETLINE): Run this test.
24753         (AC_CHECK_FUNCS): Check for getdelim.
24754         Reported by Bob Proulx.
24755
24756 1999-08-02  Jim Meyering  <meyering@ascend.com>
24757
24758         * m4/jm-macros.m4: Add a comment.
24759
24760 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24761
24762         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
24763         <inttypes.h> defines strtoumax as a macro (and not as a
24764         function).
24765
24766 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24767
24768         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
24769         that we can shift, multiply and divide unsigned long long
24770         values; Ultrix cc can't do it.
24771
24772 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24773
24774         * m4/mktime.m4: New file, which is a preview of what should appear
24775         in the next public autoconf release.
24776
24777 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24778
24779         * m4/lfs.m4: Remove this file.
24780         * m4/largefile.m4: New file.  It contains the old contents of
24781         lfs.m4, except that all names with prefix AC_LFS have been
24782         changed to use the prefix AC_SYS_LARGEFILE instead, to be
24783         compatible with future autoconf versions.  Also, some minor m4
24784         quoting problems have been fixed.
24785
24786 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24787
24788         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
24789         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
24790         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
24791         and simplify the shell code.
24792
24793 1999-08-01  Jim Meyering  <meyering@ascend.com>
24794
24795         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
24796         m4.
24797
24798 1999-07-20  Jim Meyering  <meyering@ascend.com>
24799
24800         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
24801
24802 1999-07-15  Jim Meyering  <meyering@ascend.com>
24803
24804         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
24805
24806 1999-05-22  Jim Meyering  <meyering@ascend.com>
24807
24808         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
24809
24810 1999-05-20  Jim Meyering  <meyering@ascend.com>
24811
24812         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
24813         Add a colon after each `then' in case $4 is empty.
24814
24815 1999-05-16  Jim Meyering  <meyering@ascend.com>
24816
24817         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
24818
24819 1999-05-10  Jim Meyering  <meyering@ascend.com>
24820
24821         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
24822
24823         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
24824         AC_FUNC_MKTIME.
24825
24826 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
24827
24828         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
24829
24830 1999-05-04  Paul Eggert  <eggert@twinsun.com>
24831
24832         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
24833         not CPPFLAGS, so that linking works correctly in IRIX.
24834
24835 1999-04-30  Paul Eggert  <eggert@twinsun.com>
24836
24837         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
24838
24839 1999-04-20  Paul Eggert  <eggert@twinsun.com>
24840
24841         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
24842         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
24843         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
24844         jm_AC_TYPE_UNSIGNED_LONG_LONG.
24845         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
24846
24847         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
24848
24849 1999-04-20  Jim Meyering  <meyering@ascend.com>
24850
24851         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
24852         AC_REPLACE xstroull if necessary.  From Paul Eggert.
24853         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
24854
24855 1999-04-18  Jim Meyering  <meyering@ascend.com>
24856
24857         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
24858         * m4/jm-macros.m4: Use it.
24859
24860 1999-04-06  Jim Meyering  <meyering@ascend.com>
24861
24862         * m4/strftime.m4: Remove test for %f.
24863
24864 1999-03-29  Jim Meyering  <meyering@ascend.com>
24865
24866         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
24867         superset of the AC_TYPE_* checks in the textutils, fileutils,
24868         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
24869         AC_TYPE_PID_T.
24870
24871 1999-03-28  Jim Meyering  <meyering@ascend.com>
24872
24873         * m4/jm-macros.m4: Define GNU_PACKAGE here.
24874         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
24875         replaced e.g., in the *.sh files of the sh-utils.
24876
24877 1999-03-20  Jim Meyering  <meyering@ascend.com>
24878
24879         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
24880         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
24881         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
24882
24883 1999-03-19  Jim Meyering  <meyering@ascend.com>
24884
24885         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
24886
24887 1999-03-12  Jim Meyering  <meyering@ascend.com>
24888
24889         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
24890
24891 1999-03-07  Jim Meyering  <meyering@ascend.com>
24892
24893         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
24894         declared.
24895
24896 1999-02-17  Jim Meyering  <meyering@ascend.com>
24897
24898         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
24899         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
24900
24901 1999-02-07  Jim Meyering  <meyering@ascend.com>
24902
24903         * m4/group-member.m4: New file -- extracted from sh-utils'
24904         configure.in.
24905
24906         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
24907         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
24908
24909 1999-02-06  Jim Meyering  <meyering@ascend.com>
24910
24911         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
24912         * m4/fnmatch.m4: Likewise.
24913         * m4/getgroups.m4: Likewise.
24914         * m4/lstat.m4: Likewise.
24915         * m4/malloc.m4: Likewise.
24916         * m4/putenv.m4: Likewise.
24917         * m4/realloc.m4: Likewise.
24918         * m4/regex.m4: Likewise.
24919         * m4/stat.m4: Likewise.
24920         * m4/strftime.m4: Likewise.
24921         Suggestion from Alain Magloire.
24922
24923         * m4/chown.m4: Use `.$ac_objext', not `.o'.
24924         * m4/fnmatch.m4: Likewise.
24925         * m4/getgroups.m4: Likewise.
24926         * m4/getline.m4: Likewise.
24927         * m4/lstat.m4: Likewise.
24928         * m4/malloc.m4: Likewise.
24929         * m4/memcmp.m4: Likewise.
24930         * m4/putenv.m4: Likewise.
24931         * m4/realloc.m4: Likewise.
24932         * m4/regex.m4: Likewise.
24933         * m4/stat.m4: Likewise.
24934         * m4/strftime.m4: Likewise.
24935         Suggestion from Alain Magloire.
24936
24937         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
24938         an argument.
24939
24940         * m4/regex.m4: Add a run-time Test for proper operation of
24941         re_compile_pattern.
24942
24943 1999-01-31  Jim Meyering  <meyering@ascend.com>
24944
24945         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
24946
24947 1999-01-30  Jim Meyering  <meyering@ascend.com>
24948
24949         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
24950
24951         * m4/jm-mktime.m4: Make this a wrapper around the official
24952         AM_FUNC_MKTIME rather than my private copy, now that the official one
24953         is up to date.
24954         * m4/mktime.m4: Remove file.
24955
24956         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
24957         * m4/uptime.m4: Likewise.
24958         * m4/uintmax_t.m4: Likewise.
24959
24960 1999-01-28  Jim Meyering  <meyering@ascend.com>
24961
24962         * m4/jm-macros.m4: Use jm_AFS.
24963         * m4/afs.m4: New file (from fileutils' configure.in).
24964
24965         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
24966         * m4/chown.m4: Likewise.
24967         * m4/d-ino.m4: Likewise.
24968         * m4/d-type.m4: Likewise.
24969         * m4/fnmatch.m4: Likewise.
24970         * m4/getgroups.m4: Likewise.
24971         * m4/gettext.m4: Likewise.
24972         * m4/jm-mktime.m4: Likewise.
24973         * m4/jm-winsz2.m4: Likewise.
24974         * m4/lcmessage.m4: Likewise.
24975         * m4/ls-mntd-fs.m4: Likewise.
24976         * m4/malloc.m4: Likewise.
24977         * m4/memcmp.m4: Likewise.
24978         * m4/putenv.m4: Likewise.
24979         * m4/realloc.m4: Likewise.
24980         * m4/st_mtim.m4: Likewise.
24981         * m4/strftime.m4: Likewise.
24982
24983 1999-01-16  Jim Meyering  <meyering@ascend.com>
24984
24985         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
24986         (ARGMATCH_DIE_DECL): Define.
24987
24988 1999-01-12  Jim Meyering  <meyering@ascend.com>
24989
24990         * m4/Makefile.am.in: Rewrite to avoid using fmt.
24991         Reported by Lars Hecking.
24992
24993 1999-01-10  Jim Meyering  <meyering@ascend.com>
24994
24995         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
24996         gross kludge.
24997         * m4/inttypes_h.m4: Likewise.
24998         * m4/lstat.m4: Likewise.
24999         * m4/malloc.m4: Likewise.
25000         * m4/readdir.m4: Likewise.
25001         * m4/realloc.m4: Likewise.
25002         * m4/st_dm_mode.m4: Likewise.
25003         * m4/stat.m4: Likewise.
25004         * m4/utimbuf.m4: Likewise.
25005         * m4/utimes.m4: Likewise.
25006
25007         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
25008         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
25009         comments in config.h.in are meaningful.
25010
25011         * m4/jm-macros.m4: Require autoconf-2.13 here.
25012
25013         * m4/regex.m4: By default, don't use the included regex.c on systems
25014         with glibc 2.  Suggestion from Uli Drepper.
25015
25016 1999-01-02  Jim Meyering  <meyering@ascend.com>
25017
25018         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
25019
25020 1998-12-18  Jim Meyering  <meyering@ascend.com>
25021
25022         * m4/Makefile.am.in (Makefile.am): Simplify rule.
25023         Based on a suggestion from Lars Hecking.
25024
25025 1998-11-16  Paul Eggert  <eggert@twinsun.com>
25026
25027         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
25028
25029 1998-11-16  Jim Meyering  <meyering@ascend.com>
25030
25031         * m4/lfs.m4: Double-quote the `uname...` expression.
25032
25033 1998-11-14  Jim Meyering  <meyering@ascend.com>
25034
25035         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
25036         * m4/stat.m4: Likewise.
25037
25038 1998-11-03  Jim Meyering  <meyering@ascend.com>
25039
25040         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
25041         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
25042
25043 1998-10-18  Jim Meyering  <meyering@ascend.com>
25044
25045         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
25046
25047 1998-10-17  Jim Meyering  <meyering@ascend.com>
25048
25049         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
25050         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
25051         calls for those previously hard-coded headers.  Instead, take a new
25052         parameter.
25053         (jm_CHECK_DECLARATIONS): Reflect interface change.
25054         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
25055         (jm_CHECK_DECL_LOCALTIME_R): New macro.
25056
25057         * m4/mktime.m4: Test for spring-forward gap before long-running test.
25058
25059 1998-10-14  Jim Meyering  <meyering@ascend.com>
25060
25061         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
25062         instead of "TZ=America/Vancouver".  From Paul Eggert.
25063
25064 1998-10-11  Jim Meyering  <meyering@ascend.com>
25065
25066         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
25067         This adds a test for a recently added compatibility fix for mktime.c.
25068         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
25069
25070 1998-09-27  Jim Meyering  <meyering@ascend.com>
25071
25072         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
25073
25074         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
25075         ../configure.in, including a change from Gordon Matzigkeit to allow
25076         cross-compiling for the Hurd.
25077
25078         * m4/glibc.m4: New file/macro to test for the GNU C Library
25079         versions 1 and 2.  From Gordon Matzigkeit.
25080         Indent.
25081
25082 1998-09-21  Jim Meyering  <meyering@ascend.com>
25083
25084         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
25085
25086 1998-08-18  Paul Eggert  <eggert@twinsun.com>
25087
25088         Port nanosecond-resolution times to UnixWare 2.1.2 and
25089         pedantic Solaris 2.6.
25090
25091         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
25092         AC_STRUCT_ST_MTIM.
25093         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
25094         Generate name of ns member, instead of just 1 or undef.
25095         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
25096
25097 1998-08-15  Jim Meyering  <meyering@ascend.com>
25098
25099         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
25100         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
25101         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
25102         instead of jm_TYPE_SSIZE_T.
25103
25104 1998-08-12  Jim Meyering  <meyering@ascend.com>
25105
25106         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
25107
25108 1998-08-02  Jim Meyering  <meyering@ascend.com>
25109
25110         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
25111         in acconfig.h manually.
25112
25113 1998-07-31  Paul Eggert  <eggert@twinsun.com>
25114
25115         * m4/st_mtim.m4: New file.
25116
25117 1998-07-28  Jim Meyering  <meyering@ascend.com>
25118
25119         * m4/utimes.m4: Undef stat.
25120
25121 1998-07-25  Jim Meyering  <meyering@ascend.com>
25122
25123         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
25124         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
25125
25126 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
25127
25128         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
25129         uid and gid actually remain unchanged.
25130
25131 1998-07-07  Jim Meyering  <meyering@ascend.com>
25132
25133         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
25134
25135 1998-07-04  Jim Meyering  <meyering@ascend.com>
25136
25137         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
25138         to prove that this macro can be used in packages without regex.c.
25139
25140 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
25141
25142         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
25143         is to be used.
25144
25145 1998-07-03  Jim Meyering  <meyering@ascend.com>
25146
25147         * m4/gettext.m4: Add -lintl if it's found to be necessary.
25148
25149         * m4/gettext.m4: New file -- from gettext-0.10.35.
25150         * m4/lcmessage.m4: Likewise.
25151         * m4/progtest.m4: Likewise.
25152
25153         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
25154         * m4/jm-macros.m4: Require the new macro.
25155
25156 1998-06-29  Jim Meyering  <meyering@ascend.com>
25157
25158         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
25159         for the definition of NGROUPS (used in a system header included
25160         by sys/mount.h).
25161
25162 1998-06-28  Jim Meyering  <meyering@ascend.com>
25163
25164         * m4/ls-mntd-fs.m4: New file.
25165         * m4/fstypename.m4: New file.
25166
25167         * m4/jm-macros.m4: Require the new macro.
25168         * m4/jm-glibc-io.m4: New file.
25169
25170 1998-05-19  Jim Meyering  <meyering@ascend.com>
25171
25172         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
25173         * m4/lchown.m4: New file.
25174
25175         * m4/Makefile.am.in: New file.
25176         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
25177
25178 1998-05-14  Jim Meyering  <meyering@ascend.com>
25179
25180         * m4/Makefile.am (EXTRA_DIST): Add them.
25181         * m4/jm-macros.m4: New file.
25182         * m4/utimbuf.m4: New file.
25183
25184 1998-05-12  Jim Meyering  <meyering@ascend.com>
25185
25186         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
25187
25188 1998-05-11  Jim Meyering  <meyering@ascend.com>
25189
25190         * m4/isc-posix.m4: New file.
25191
25192 1998-05-10  Jim Meyering  <meyering@ascend.com>
25193
25194         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
25195
25196 1998-05-09  Jim Meyering  <meyering@ascend.com>
25197
25198         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
25199         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
25200         with automake.
25201
25202         * m4/ssize_t.m4: New file.
25203         * m4/mktime.m4: Remove file -- the new automake has this now.
25204
25205 1998-04-26  Jim Meyering  <meyering@ascend.com>
25206
25207         * m4/assert.m4: New file.
25208         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
25209
25210 1998-04-05  Jim Meyering  <meyering@ascend.com>
25211
25212         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
25213         (jm_PREREQ): Use it here.
25214
25215 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
25216
25217         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
25218         in acconfig.h.
25219
25220 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
25221
25222         * m4/prereq.m4: New file.
25223         * m4/error.m4: New file.
25224         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
25225
25226 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
25227
25228         * m4/getline.m4: Don't set am_cv_func_working_getline before the
25229         cache-check for the same variable -- that defeated the purpose of
25230         the test; the test program was never run.  This was a problem only
25231         on systems with losing getline functions -- HP-UX 10.20 is one.
25232         Reported by Bjorn Helgaas.
25233
25234 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
25235
25236         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
25237
25238 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
25239
25240         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
25241
25242         * m4/const.m4: New file.  Use an initializer in this declaration
25243         typedef int charset[2]; const charset x;
25244         Reported by Bob Glickstein.
25245
25246 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
25247
25248         * m4/chown.m4: Fix reversed types on -1 args to chown.
25249         From Kaveh Ghazi.
25250
25251 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
25252
25253         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
25254         Add lseek and memchr.
25255
25256         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
25257         T.E.Dickey <dickey@clark.net> said that some older preprocessors
25258         have a 20-character limit on names.
25259
25260 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
25261
25262         * m4/inttypes_h.m4: New file.
25263         * m4/uintmax_t.m4: New file.
25264         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
25265
25266 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
25267   Free Software Foundation, Inc.
25268 Copying and distribution of this file, with or without modification,
25269 are permitted provided the copyright notice and this notice are preserved.