ed3916dcb0c6f0b405825f197a7c3702e3031785
[pspp] / ChangeLog
1 2007-01-15  Bruno Haible  <bruno@clisp.org>
2
3         * modules/striconveh: New file.
4         * lib/striconveh.h: New file.
5         * lib/striconveh.c: New file.
6         * MODULES.html.sh (Internationalization functions): Add striconveh.
7
8 2007-01-15  Bruno Haible  <bruno@clisp.org>
9
10         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
11         not from GNU libiconv or GNU libc.
12
13 2007-01-15  Bruno Haible  <bruno@clisp.org>
14
15         * doc/gnulib-intro.texi (Copyright): Explain the different license
16         terms for module descriptions, autoconf macros, tests, documentation.
17
18 2007-01-14  Bruno Haible  <bruno@clisp.org>
19
20         * modules/striconv-tests: New file.
21         * tests/test-striconv.c: New file.
22
23 2007-01-14  Bruno Haible  <bruno@clisp.org>
24
25         * modules/iconv-tests: New file.
26         * tests/test-iconv.c: New file.
27
28 2007-01-14  Bruno Haible  <bruno@clisp.org>
29
30         * gnulib-tool (func_get_license): For test modules, use the license of
31         the main module.
32
33 2007-01-14  Bruno Haible  <bruno@clisp.org>
34
35         * modules/iconv (Include): Clarify that <iconv.h> can only be included
36         if iconv is found to exist.
37
38 2007-01-14  Bruno Haible  <bruno@clisp.org>
39
40         * modules/c-ctype-tests: New file.
41         * tests/test-c-ctype.c: New file.
42
43 2007-01-14  Bruno Haible  <bruno@clisp.org>
44
45         * modules/binary-io-tests: New file.
46         * tests/test-binary-io.sh: New file.
47         * tests/test-binary-io.c: New file.
48
49 2007-01-14  Bruno Haible  <bruno@clisp.org>
50
51         * modules/array-oset-tests: New file.
52         * tests/test-array_oset.c: New file.
53
54 2007-01-14  Bruno Haible  <bruno@clisp.org>
55
56         * modules/array-list-tests: New file.
57         * tests/test-array_list.c: New file.
58
59 2007-01-14  Bruno Haible  <bruno@clisp.org>
60
61         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
62         and make.
63         Reported by Simon Josefsson in
64         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
65
66 2007-01-14  Bruno Haible  <bruno@clisp.org>
67
68         * modules/allocsa-tests: New file.
69         * tests/test-allocsa.c: New file.
70
71 2007-01-14  Bruno Haible  <bruno@clisp.org>
72
73         * modules/fchdir (Depends-on): Add absolute-header.
74         * modules/unistd (Depends-on): Likewise.
75
76 2006-12-30  Bruno Haible  <bruno@clisp.org>
77
78         * modules/fchdir: New file.
79         * modules/unistd (Files): Add lib/unistd_.h.
80         (Makefile.am): Generate unistd.h from unistd_.h.
81         * lib/fchdir.c: New file.
82         * lib/dirent_.h: New file.
83         * lib/unistd_.h: New file.
84         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
85         * m4/fchdir.m4: New file.
86         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
87         (gl_HEADER_UNISTD): Invoke it.
88         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
89         function.
90         * lib/backupfile.c (opendir, closedir): Undefine.
91         * lib/chown.c (open, close): Undefine.
92         * lib/clean-temp.c (open, close): Undefine.
93         * lib/copy-file.c (open, close): Undefine.
94         * lib/execute.c (open, close): Undefine.
95         * lib/fsusage.c (open, close): Undefine.
96         * lib/gc-gnulib.c (open, close): Undefine.
97         * lib/getcwd.c (opendir, closedir): Undefine.
98         * lib/glob.c (opendir, closedir): Undefine.
99         * lib/javacomp.c (open, close): Undefine.
100         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
101         * lib/openat-proc.c (open, close): Undefine.
102         * lib/pagealign_alloc.c (open, close): Undefine.
103         * lib/pipe.c (open, close): Undefine.
104         * lib/progreloc.c (open, close): Undefine.
105         * lib/savedir.c (opendir, closedir): Undefine.
106         * lib/utime.c (open, close): Undefine.
107         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
108
109 2007-01-10  Bruno Haible  <bruno@clisp.org>
110
111         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
112
113 2007-01-12  Eric Blake  <ebb9@byu.net>
114
115         Provide a robust <wchar.h>.  Further simplifications are now
116         possible in other modules, but not included here.
117         * modules/wchar: New module.
118         * m4/wchar.m4: New file.
119         * lib/wchar_.h: Likewise.
120         * modules/mbchar (Depends-on): Depend on wchar, as the first use
121         of the new module.
122         * MODULES.html.sh (Extended multibyte and wide character utilities):
123         New section.
124
125 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
126
127         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
128         to a reasonable default for memory allocation.
129         (xreadlink): Don't allocate a huge buffer, to work around a buggy
130         file system that reports garbage st_size values for symlinks.
131         Problem reported by Liyang Hu.
132
133 2007-01-11  Simon Josefsson  <simon@josefsson.org>
134
135         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
136         Emacs .#* auto-save files).
137
138 2007-01-11  Bruno Haible  <bruno@clisp.org>
139
140         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
141         directory.
142
143 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
144
145         Use @...@ consistently in lib/wctype_.h.
146         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
147         on it being set to 1 or 0.
148         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
149         go back to AC_SUBSTing it.
150         * modules/wctype (Makefile.am): Undo previous change.
151
152 2007-01-10  Eric Blake  <ebb9@byu.net>
153
154         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
155         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
156         * modules/wctype (Makefile.am): Likewise.
157         Reported by Chris McGuire.
158
159 2007-01-10  Jim Meyering  <jim@meyering.net>
160
161         fts.c: a small readability/maintainability improvement
162         * lib/fts.c (fts_read): Make this code slightly more readable and
163         maintainable by hoisting the "sp->fts_cur = p" assignments to
164         immediately follow the statements that set P.  Derived from
165         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
166
167 2007-01-10  Eric Blake  <ebb9@byu.net>
168
169         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
170         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
171         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
172         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
173         Reported by Chris McGuire.
174
175 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
176
177         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
178         in sed script.
179
180 2007-01-09  Bruno Haible  <bruno@clisp.org>
181
182         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
183         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
184         variables.
185         (func_module): Use them.
186
187 2007-01-09  Bruno Haible  <bruno@clisp.org>
188
189         * modules/unistr/base: New file.
190         * lib/unistr.h: New file.
191
192         * modules/unistr/u8-to-u16: New file.
193         * lib/unistr/u8-to-u16.c: New file.
194
195         * modules/unistr/u8-to-u32: New file.
196         * lib/unistr/u8-to-u32.c: New file.
197
198         * modules/unistr/u16-to-u8: New file.
199         * lib/unistr/u16-to-u8.c: New file.
200
201         * modules/unistr/u16-to-u32: New file.
202         * lib/unistr/u16-to-u32.c: New file.
203
204         * modules/unistr/u32-to-u8: New file.
205         * lib/unistr/u32-to-u8.c: New file.
206
207         * modules/unistr/u32-to-u16: New file.
208         * lib/unistr/u32-to-u16.c: New file.
209
210         * modules/unistr/u8-check: New file.
211         * modules/unistr/u16-check: New file.
212         * modules/unistr/u32-check: New file.
213         * lib/unistr/u8-check.c: New file.
214         * lib/unistr/u16-check.c: New file.
215         * lib/unistr/u32-check.c: New file.
216
217         * modules/unistr/u8-chr: New file.
218         * modules/unistr/u16-chr: New file.
219         * modules/unistr/u32-chr: New file.
220         * lib/unistr/u8-chr.c: New file.
221         * lib/unistr/u16-chr.c: New file.
222         * lib/unistr/u32-chr.c: New file.
223
224         * modules/unistr/u8-cmp: New file.
225         * modules/unistr/u16-cmp: New file.
226         * modules/unistr/u32-cmp: New file.
227         * lib/unistr/u8-cmp.c: New file.
228         * lib/unistr/u16-cmp.c: New file.
229         * lib/unistr/u32-cmp.c: New file.
230
231         * modules/unistr/u8-cpy: New file.
232         * modules/unistr/u16-cpy: New file.
233         * modules/unistr/u32-cpy: New file.
234         * lib/unistr/u8-cpy.c: New file.
235         * lib/unistr/u16-cpy.c: New file.
236         * lib/unistr/u32-cpy.c: New file.
237         * lib/unistr/u-cpy.h: New file.
238
239         * modules/unistr/u8-cpy-alloc: New file.
240         * modules/unistr/u16-cpy-alloc: New file.
241         * modules/unistr/u32-cpy-alloc: New file.
242         * lib/unistr/u8-cpy-alloc.c: New file.
243         * lib/unistr/u16-cpy-alloc.c: New file.
244         * lib/unistr/u32-cpy-alloc.c: New file.
245         * lib/unistr/u-cpy-alloc.h: New file.
246
247         * modules/unistr/u8-endswith: New file.
248         * modules/unistr/u16-endswith: New file.
249         * modules/unistr/u32-endswith: New file.
250         * lib/unistr/u8-endswith.c: New file.
251         * lib/unistr/u16-endswith.c: New file.
252         * lib/unistr/u32-endswith.c: New file.
253         * lib/unistr/u-endswith.h: New file.
254
255         * modules/unistr/u8-mblen: New file.
256         * modules/unistr/u16-mblen: New file.
257         * modules/unistr/u32-mblen: New file.
258         * lib/unistr/u8-mblen.c: New file.
259         * lib/unistr/u16-mblen.c: New file.
260         * lib/unistr/u32-mblen.c: New file.
261
262         * modules/unistr/u8-mbtouc: New file.
263         * modules/unistr/u16-mbtouc: New file.
264         * modules/unistr/u32-mbtouc: New file.
265         * lib/unistr/u8-mbtouc.c: New file.
266         * lib/unistr/u16-mbtouc.c: New file.
267         * lib/unistr/u32-mbtouc.c: New file.
268
269         * modules/unistr/u8-mbtouc-safe: New file.
270         * modules/unistr/u16-mbtouc-safe: New file.
271         * modules/unistr/u32-mbtouc-safe: New file.
272         * lib/unistr/u8-mbtouc-safe.c: New file.
273         * lib/unistr/u16-mbtouc-safe.c: New file.
274         * lib/unistr/u32-mbtouc-safe.c: New file.
275
276         * modules/unistr/u8-move: New file.
277         * modules/unistr/u16-move: New file.
278         * modules/unistr/u32-move: New file.
279         * lib/unistr/u8-move.c: New file.
280         * lib/unistr/u16-move.c: New file.
281         * lib/unistr/u32-move.c: New file.
282         * lib/unistr/u-move.h: New file.
283
284         * modules/unistr/u8-next: New file.
285         * modules/unistr/u16-next: New file.
286         * modules/unistr/u32-next: New file.
287         * lib/unistr/u8-next.c: New file.
288         * lib/unistr/u16-next.c: New file.
289         * lib/unistr/u32-next.c: New file.
290
291         * modules/unistr/u8-prev: New file.
292         * modules/unistr/u16-prev: New file.
293         * modules/unistr/u32-prev: New file.
294         * lib/unistr/u8-prev.c: New file.
295         * lib/unistr/u16-prev.c: New file.
296         * lib/unistr/u32-prev.c: New file.
297
298         * modules/unistr/u8-set: New file.
299         * modules/unistr/u16-set: New file.
300         * modules/unistr/u32-set: New file.
301         * lib/unistr/u8-set.c: New file.
302         * lib/unistr/u16-set.c: New file.
303         * lib/unistr/u32-set.c: New file.
304         * lib/unistr/u-set.h: New file.
305
306         * modules/unistr/u8-startswith: New file.
307         * modules/unistr/u16-startswith: New file.
308         * modules/unistr/u32-startswith: New file.
309         * lib/unistr/u8-startswith.c: New file.
310         * lib/unistr/u16-startswith.c: New file.
311         * lib/unistr/u32-startswith.c: New file.
312         * lib/unistr/u-startswith.h: New file.
313
314         * modules/unistr/u8-stpcpy: New file.
315         * modules/unistr/u16-stpcpy: New file.
316         * modules/unistr/u32-stpcpy: New file.
317         * lib/unistr/u8-stpcpy.c: New file.
318         * lib/unistr/u16-stpcpy.c: New file.
319         * lib/unistr/u32-stpcpy.c: New file.
320         * lib/unistr/u-stpcpy.h: New file.
321
322         * modules/unistr/u8-stpncpy: New file.
323         * modules/unistr/u16-stpncpy: New file.
324         * modules/unistr/u32-stpncpy: New file.
325         * lib/unistr/u8-stpncpy.c: New file.
326         * lib/unistr/u16-stpncpy.c: New file.
327         * lib/unistr/u32-stpncpy.c: New file.
328         * lib/unistr/u-stpncpy.h: New file.
329
330         * modules/unistr/u8-strcat: New file.
331         * modules/unistr/u16-strcat: New file.
332         * modules/unistr/u32-strcat: New file.
333         * lib/unistr/u8-strcat.c: New file.
334         * lib/unistr/u16-strcat.c: New file.
335         * lib/unistr/u32-strcat.c: New file.
336         * lib/unistr/u-strcat.h: New file.
337
338         * modules/unistr/u8-strchr: New file.
339         * modules/unistr/u16-strchr: New file.
340         * modules/unistr/u32-strchr: New file.
341         * lib/unistr/u8-strchr.c: New file.
342         * lib/unistr/u16-strchr.c: New file.
343         * lib/unistr/u32-strchr.c: New file.
344
345         * modules/unistr/u8-strcmp: New file.
346         * modules/unistr/u16-strcmp: New file.
347         * modules/unistr/u32-strcmp: New file.
348         * lib/unistr/u8-strcmp.c: New file.
349         * lib/unistr/u16-strcmp.c: New file.
350         * lib/unistr/u32-strcmp.c: New file.
351
352         * modules/unistr/u8-strcpy: New file.
353         * modules/unistr/u16-strcpy: New file.
354         * modules/unistr/u32-strcpy: New file.
355         * lib/unistr/u8-strcpy.c: New file.
356         * lib/unistr/u16-strcpy.c: New file.
357         * lib/unistr/u32-strcpy.c: New file.
358         * lib/unistr/u-strcpy.h: New file.
359
360         * modules/unistr/u8-strcspn: New file.
361         * modules/unistr/u16-strcspn: New file.
362         * modules/unistr/u32-strcspn: New file.
363         * lib/unistr/u8-strcspn.c: New file.
364         * lib/unistr/u16-strcspn.c: New file.
365         * lib/unistr/u32-strcspn.c: New file.
366         * lib/unistr/u-strcspn.h: New file.
367
368         * modules/unistr/u8-strdup: New file.
369         * modules/unistr/u16-strdup: New file.
370         * modules/unistr/u32-strdup: New file.
371         * lib/unistr/u8-strdup.c: New file.
372         * lib/unistr/u16-strdup.c: New file.
373         * lib/unistr/u32-strdup.c: New file.
374         * lib/unistr/u-strdup.h: New file.
375
376         * modules/unistr/u8-strlen: New file.
377         * modules/unistr/u16-strlen: New file.
378         * modules/unistr/u32-strlen: New file.
379         * lib/unistr/u8-strlen.c: New file.
380         * lib/unistr/u16-strlen.c: New file.
381         * lib/unistr/u32-strlen.c: New file.
382         * lib/unistr/u-strlen.h: New file.
383
384         * modules/unistr/u8-strmblen: New file.
385         * modules/unistr/u16-strmblen: New file.
386         * modules/unistr/u32-strmblen: New file.
387         * lib/unistr/u8-strmblen.c: New file.
388         * lib/unistr/u16-strmblen.c: New file.
389         * lib/unistr/u32-strmblen.c: New file.
390
391         * modules/unistr/u8-strmbtouc: New file.
392         * modules/unistr/u16-strmbtouc: New file.
393         * modules/unistr/u32-strmbtouc: New file.
394         * lib/unistr/u8-strmbtouc.c: New file.
395         * lib/unistr/u16-strmbtouc.c: New file.
396         * lib/unistr/u32-strmbtouc.c: New file.
397
398         * modules/unistr/u8-strncat: New file.
399         * modules/unistr/u16-strncat: New file.
400         * modules/unistr/u32-strncat: New file.
401         * lib/unistr/u8-strncat.c: New file.
402         * lib/unistr/u16-strncat.c: New file.
403         * lib/unistr/u32-strncat.c: New file.
404         * lib/unistr/u-strncat.h: New file.
405
406         * modules/unistr/u8-strncmp: New file.
407         * modules/unistr/u16-strncmp: New file.
408         * modules/unistr/u32-strncmp: New file.
409         * lib/unistr/u8-strncmp.c: New file.
410         * lib/unistr/u16-strncmp.c: New file.
411         * lib/unistr/u32-strncmp.c: New file.
412
413         * modules/unistr/u8-strncpy: New file.
414         * modules/unistr/u16-strncpy: New file.
415         * modules/unistr/u32-strncpy: New file.
416         * lib/unistr/u8-strncpy.c: New file.
417         * lib/unistr/u16-strncpy.c: New file.
418         * lib/unistr/u32-strncpy.c: New file.
419         * lib/unistr/u-strncpy.h: New file.
420
421         * modules/unistr/u8-strnlen: New file.
422         * modules/unistr/u16-strnlen: New file.
423         * modules/unistr/u32-strnlen: New file.
424         * lib/unistr/u8-strnlen.c: New file.
425         * lib/unistr/u16-strnlen.c: New file.
426         * lib/unistr/u32-strnlen.c: New file.
427         * lib/unistr/u-strnlen.h: New file.
428
429         * modules/unistr/u8-strpbrk: New file.
430         * modules/unistr/u16-strpbrk: New file.
431         * modules/unistr/u32-strpbrk: New file.
432         * lib/unistr/u8-strpbrk.c: New file.
433         * lib/unistr/u16-strpbrk.c: New file.
434         * lib/unistr/u32-strpbrk.c: New file.
435         * lib/unistr/u-strpbrk.h: New file.
436
437         * modules/unistr/u8-strrchr: New file.
438         * modules/unistr/u16-strrchr: New file.
439         * modules/unistr/u32-strrchr: New file.
440         * lib/unistr/u8-strrchr.c: New file.
441         * lib/unistr/u16-strrchr.c: New file.
442         * lib/unistr/u32-strrchr.c: New file.
443
444         * modules/unistr/u8-strspn: New file.
445         * modules/unistr/u16-strspn: New file.
446         * modules/unistr/u32-strspn: New file.
447         * lib/unistr/u8-strspn.c: New file.
448         * lib/unistr/u16-strspn.c: New file.
449         * lib/unistr/u32-strspn.c: New file.
450         * lib/unistr/u-strspn.h: New file.
451
452         * modules/unistr/u8-strstr: New file.
453         * modules/unistr/u16-strstr: New file.
454         * modules/unistr/u32-strstr: New file.
455         * lib/unistr/u8-strstr.c: New file.
456         * lib/unistr/u16-strstr.c: New file.
457         * lib/unistr/u32-strstr.c: New file.
458         * lib/unistr/u-strstr.h: New file.
459
460         * modules/unistr/u8-strtok: New file.
461         * modules/unistr/u16-strtok: New file.
462         * modules/unistr/u32-strtok: New file.
463         * lib/unistr/u8-strtok.c: New file.
464         * lib/unistr/u16-strtok.c: New file.
465         * lib/unistr/u32-strtok.c: New file.
466         * lib/unistr/u-strtok.h: New file.
467
468         * modules/unistr/u8-uctomb: New file.
469         * modules/unistr/u16-uctomb: New file.
470         * modules/unistr/u32-uctomb: New file.
471         * lib/unistr/u8-uctomb.c: New file.
472         * lib/unistr/u16-uctomb.c: New file.
473         * lib/unistr/u32-uctomb.c: New file.
474
475         * MODULES.html.sh (Unicode string functions): Add the new modules.
476
477 2007-01-08  Bruno Haible  <bruno@clisp.org>
478
479         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
480         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
481         subdirectories.
482
483 2007-01-08  Karl Berry  <karl@gnu.org>
484
485         * doc/error.texi: mention that main() fns must set program_name
486         when progname is used.
487
488 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
489
490         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
491         WCTYPE_H is empty, for the benefit of builds from non-distclean
492         directories.  Problem reported by Eric Blake in
493         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
494
495 2007-01-08  Bruno Haible  <bruno@clisp.org>
496
497         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
498         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
499         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
500         PROVIDE_CANONICALIZE_FILENAME_MODE.
501         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
502
503 2007-01-08  Bruno Haible  <bruno@clisp.org>
504
505         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
506         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
507         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
508         * lib/fts.c: Likewise.
509         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
510
511 2006-12-25  Bruno Haible  <bruno@clisp.org>
512
513         * modules/utf8-ucs4-safe: New file.
514         * lib/utf8-ucs4-safe.h: New file.
515         * lib/unistr/utf8-ucs4-safe.c: New file.
516
517         * modules/utf16-ucs4-safe: New file.
518         * lib/utf16-ucs4-safe.h: New file.
519         * lib/unistr/utf16-ucs4-safe.c: New file.
520
521         * MODULES.html.sh (Unicode string functions): Add the new modules.
522
523 2007-01-08  Bruno Haible  <bruno@clisp.org>
524
525         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
526         (Depends-on): Add unitypes.
527         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
528         (u8_mbtouc_aux): Move out to separate file.
529         (u8_mbtouc): Use ucs4_t, uint8_t types.
530         * lib/unistr/utf8-ucs4.c: New file.
531
532         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
533         (Depends-on): Add unitypes.
534         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
535         (u16_mbtouc_aux): Move out to separate file.
536         (u16_mbtouc): Use ucs4_t, uint16_t types.
537         * lib/unistr/utf16-ucs4.c: New file.
538
539         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
540         (Depends-on): Add unitypes.
541         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
542         (u8_uctomb_aux): Move out to separate file.
543         (u8_uctomb): Use ucs4_t, uint8_t types.
544         * lib/unistr/ucs4-utf8.c: New file.
545
546         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
547         (Depends-on): Add unitypes.
548         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
549         (u16_uctomb_aux): Move out to separate file.
550         (u16_uctomb): Use ucs4_t, uint16_t types.
551         * lib/unistr/ucs4-utf16.c: New file.
552
553 2006-12-25  Bruno Haible  <bruno@clisp.org>
554
555         * modules/unitypes: New file.
556         * lib/unitypes.h: New file.
557         * MODULES.html.sh (func_all_modules): New section "Unicode string
558         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
559         this section. Add unitypes.
560
561 2007-01-08  Bruno Haible  <bruno@clisp.org>
562
563         Avoid variable names that conflict with those from libtool.
564         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
565         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
566         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
567         library_names_spec to acl_library_names_spec, hardcode_* to
568         acl_hardcode_*.
569         Reported by Ralf Wildenhues.
570
571 2007-01-08  Bruno Haible  <bruno@clisp.org>
572
573         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
574         definition.
575         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
576         definition.
577         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
578         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
579         definition.
580         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
581         definition.
582         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
583         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
584         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
585         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
586         definition.
587         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
588         definition.
589         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
590         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
591         GC_USE_<algorithm>.
592         * lib/gc-libgcrypt.c: Likewise.
593         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
594         * modules/gc-arctwo (configure.ac): Likewise.
595         * modules/gc-des (configure.ac): Likewise.
596         * modules/gc-hmac-md5 (configure.ac): Likewise.
597         * modules/gc-hmac-sha1 (configure.ac): Likewise.
598         * modules/gc-md2 (configure.ac): Likewise.
599         * modules/gc-md4 (configure.ac): Likewise.
600         * modules/gc-md5 (configure.ac): Likewise.
601         * modules/gc-random (configure.ac): Likewise.
602         * modules/gc-rijndael (configure.ac): Likewise.
603         * modules/gc-sha1 (configure.ac): Likewise.
604
605 2007-01-08  Bruno Haible  <bruno@clisp.org>
606
607         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
608         macro definition.
609         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
610         definition.
611         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
612         definition.
613         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
614         * modules/fcntl-safer (configure.ac): Likewise.
615         * modules/fopen-safer (configure.ac): Likewise.
616         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
617         GNULIB_FWRITEERROR macro definition.
618
619 2007-01-08  Bruno Haible  <bruno@clisp.org>
620
621         * m4/gnulib-common.m4: New file.
622         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
623         (func_get_filelist): Add m4/gnulib-common.m4.
624
625 2007-01-08  Bruno Haible  <bruno@clisp.org>
626
627         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
628         command.
629
630 2007-01-08  Jim Meyering  <jim@meyering.net>
631
632         Use a more robust test for a "can't happen" condition.
633         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
634         narrowed the st_size value.  Presuming the "can't happen" condition
635         is true, that narrowing could conceivably convert an invalid st_size
636         value into a valid one.  Instead, use a change based on Matthew
637         Woehlke's original patch.
638
639         Slight readability improvement: use an assert-like macro
640         in place of literal "abort ()" uses.
641         * lib/fts.c (fts_assert): Define.
642         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
643         Use this macro instead of a bare 'abort'.
644
645 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
646
647         Don't worry about using IRIX 5.3's wctype.h broken definitions;
648         simply work around them.
649         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
650         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
651         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
652         Don't bother to define as macros, since the standard doesn't require it.
653         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
654         longer worry about IRIX 5.3.
655         (HAVE_WCTYPE_CTMP_BUG): Remove.
656
657 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
658
659         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
660         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
661         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
662         Problems reported by Georg Schwarz for IRIX 5.3.
663
664         * gnulib-tool (autoconf_minversion): Take the maximum version number
665         found, not the minimum.  Problem reported by James Youngman.
666
667 2007-01-03  Karl Berry  <karl@gnu.org>
668
669         * doc/error.texi: new file, explaining interaction with progname.
670         * doc/gnulib.texi: include it.  Update copyright.
671
672 2007-01-03  Simon Josefsson  <simon@josefsson.org>
673
674         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
675         AC_CANONICAL_HOST, to improve autobuild outputs.
676
677 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
678             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
679
680         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
681         sockets, server sockets, and other file descriptors.  Count errors
682         to compute the return value.  Reorder the code a bit to be easier
683         to follow.  Don't set event bits that were not requested (except
684         POLLERR and POLLHUP).
685
686 2007-01-01  Bruno Haible  <bruno@clisp.org>
687
688         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
689
690 2007-01-03  Jim Meyering  <jim@meyering.net>
691
692         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
693
694 2007-01-02  Bruno Haible  <bruno@clisp.org>
695
696         * modules/settime (Include): Require timespec.h.
697         * modules/nanosleep (Include): Likewise.
698
699 2007-01-01  Bruno Haible  <bruno@clisp.org>
700
701         * gnulib-tool (func_emit_copyright_notice): Bump year.
702         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
703
704 2007-01-01  Bruno Haible  <bruno@clisp.org>
705
706         Improve support for OpenBSD.
707         * build-aux/config.rpath (libname_spec): Export.
708         (library_names_spec): New variable. Export.
709         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
710         library_names_spec from the config.rpath output. Locate shared library
711         through the name pattern in library_names_spec.
712
713 2007-01-01  Eric Blake  <ebb9@byu.net>
714
715         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
716
717 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
718
719         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
720         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
721         assume the C locale, and avoid an "eval" that could cause trouble.
722         Problem with SORT reported by Bob Proulx.
723
724         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
725         Define.  Trivial patch from Henning Nielsen Lund, originally
726         sent to bug-grep@gnu.org today.
727
728 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
729
730         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
731         struct stat.  Problem reported by Henning Nielsen Lund.
732         * lib/acl.c: Include acl.h first, to check interface.  Don't
733         bother to include sys/types.h and sys/stat.h again.
734
735 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
736
737         Import the following change from libc; problem reported by
738         Sven Verdoolaege.
739
740         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
741
742         [BZ #1373]
743         * lib/argp.h: Remove __NTH for __argp_usage inline function.
744
745 2006-12-28  Jim Meyering  <jim@meyering.net>
746
747         * build-aux/announce-gen: Do not assume that the package
748         builds any of tar.gz, tar.bz2, and .xdelta files.
749         Suggestion from Simon Josefsson.
750
751 2006-12-28  Simon Josefsson  <simon@josefsson.org>
752
753         * modules/announce-gen: New file.
754
755 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
756
757         * lib/mbchar.h: Just include <wctype.h>; the wctype module
758         handles its gotchas now.
759         * lib/mbswidth.c: Likewise.
760         * lib/wcwidth.h: Likewise.
761         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
762         and iswcntrl; the wctype module does this stuff now.
763         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
764         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
765         * modules/mbchar (Depends-on): Add wctype.
766         * modules/mbswidth (Depends-on): Likewise.
767         * modules/wcwidth (Depends-on): Likewise.
768
769 2006-12-27  Eric Blake  <ebb9@byu.net>
770
771         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
772         module uses more than what <wctype.h> is required to provide.
773
774 2006-12-26  Eric Blake  <ebb9@byu.net>
775
776         * gnulib-tool (sed_extract_prog): Avoid space-tab.
777
778 2006-12-26  Eric Blake  <ebb9@byu.net>
779
780         * modules/absolute-header: New module.
781         * modules/fcntl (Depends-on): Depend on it.
782         * modules/inttypes (Depends-on): Likewise.
783         * modules/stdint (Depends-on): Likewise.
784         * modules/sys_stat (Depends-on): Likewise.
785         * modules/wctype (Depends-on): Likewise.
786         * MODULES.html.sh (Support for building libraries and
787         executables): Document it.
788
789 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
790
791         * gnulib-tool (SED): Remove, undoing previous change.
792         The problem was that it broke coreutils on Solaris, because
793         "sed --posix" leaked into a makefile.
794         (sed): New alias, if 'alias' and GNU sed.
795
796 2006-12-24  Jim Meyering  <jim@meyering.net>
797
798         Work around an fchownat bug in glibc-2.4:
799         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
800         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
801         in spite of the -P option.
802         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
803         New macros.
804         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
805         * modules/openat (Files): Add lib/fchownat.c.
806         * lib/openat.c (fchownat): Don't define here.  Move to...
807         * lib/fchownat.c: ...this new file.
808
809 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
810
811         Fix bug reported by Bruno Haible in
812         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
813         where quotearg.c didn't compile on Mac OS X 10.2 because it
814         lacks <wchar.h> and wint_t.
815         * lib/wctype_.h (__wctype_wint_t): New type.
816         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
817         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
818         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
819         Arg is now of type __wctype_wint_t, not wint_t.
820         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
821         substitute HAVE_WINT_T.
822         * modules/wctype (Files): Add m4/wint_t.m4.
823         (wctype.h): Substitute HAVE_WINT_T.
824
825 2006-12-23  Bruno Haible  <bruno@clisp.org>
826
827         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
828
829 2006-12-23  Bruno Haible  <bruno@clisp.org>
830
831         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
832         S_ISLNK.
833         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
834         mingw.
835
836 2006-12-22  Bruno Haible  <bruno@clisp.org>
837
838         * lib/copy-file.c: Include acl.h.
839         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
840         Close the file descriptors only after being done with copy_acl.
841         * modules/copy-file (Depends-on): Add acl.
842
843 2006-12-22  Bruno Haible  <bruno@clisp.org>
844
845         * gnulib-tool (SED): New variable.
846         Use $SED instead of sed everywhere.
847
848 2006-12-22  Bruno Haible  <bruno@clisp.org>
849
850         * modules/no-c++: New file.
851         * m4/no-c++.m4: New file.
852         * MODULES.html.sh (Support for building libraries and executables):
853         Add no-c++.
854
855 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
856
857         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
858         Include <limits.h>, and use its INT_MAX to rewrite the
859         j loop so that it does not overflow 'int'.  Problem reported by
860         Ralf Wildenhues in
861         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
862         Play it safe by shifting left by 1 rather than multiplying by 2,
863         as GCC is less likely to optimize this away when the value
864         is signed (when it assumes overflow leads to undefined behavior).
865         Also, don't assume time_t uses two's complement.
866
867 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
868
869         * MODULES.html.sh: New module wctype.
870         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
871         * lib/fnmatch.c: Don't bother to include <wchar.h> before
872         <wctype.h>, since the new wctype module should fix this.
873         * lib/quotearg.c: Include <wctype.h> unconditionally, since
874         the wctype module should arrange for it.
875         * lib/regex_internal.h: Likewise.
876         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
877         since the wctype module should handle this now.
878         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
879         * modules/fnmatch (Depends-on): Add wctype.
880         * modules/quotearg (Depends-on): Likewise.
881         * modules/regex (Depends-on): Likewise.
882
883 2006-12-19  Bruno Haible  <bruno@clisp.org>
884
885         * lib/strdup.h [C++]: Wrap definitions in extern "C".
886         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
887
888 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
889
890         * modules/savewd (Depends-on): Fix dependency on fcntl.
891
892 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
893
894         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
895         conforms to C99, rather than relying on the user's environment
896         setting of STDINT_H.
897
898 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
899         and Eric Blake  <ebb9@byu.net>
900
901         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
902         This is more consistent with the other defines here.
903         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
904         Port to z/OS.  Problem reported by Paul Gilmartin.
905         Change local vars to use gl_ prefix rather than ac_.
906         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
907         with other defines.
908         * modules/double-slash-root: New module.
909         * modules/dirname (Files): Remove m4/double-slash-root.m4.
910         (Depends-on): Add double-slash-root.
911         * MODULES.html.sh (File system functions): Mention new module.
912
913 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
914
915         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
916         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
917         This is for the benefit of gzip, which doesn't do i18n.
918
919 2006-12-12  Jim Meyering  <jim@meyering.net>
920
921         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
922         Reported by Andreas Schwab <schwab@suse.de>.
923
924 2006-12-12  Bruno Haible  <bruno@clisp.org>
925
926         Merge these changes.
927         2006-09-05  Bruno Haible  <bruno@clisp.org>
928         * lib/iconvme.c (iconv_string): No need to save and restore errno when
929         iconv_alloc succeeded.
930         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
931         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
932         test for " && dest " at the end - dest is always != NULL there. Call
933         iconv with 4xNULL arguments initially, to reset the state. Call iconv
934         with 2xNULL arguments, also to flush the state storage. Handle the
935         IRIX iconv behaviour. Realloc the final result, to throw away unused
936         memory.
937
938 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
939
940         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
941         and fchmodat unconditionally, since glibc 2.4 has them.
942         Problem reported by Arkadiusz Miskiewicz.
943
944 2006-12-10  Bruno Haible  <bruno@clisp.org>
945
946         * gnulib-tool (func_import): Show the include files only for those
947         modules that are copied and specified.
948         Reported by Karl Berry.
949
950 2006-12-08  Jim Meyering  <jim@meyering.net>
951
952         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
953         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
954
955         * build-aux/announce-gen: Add two new options, both optional:
956         --bootstrap-tools=TOOL_LIST
957               a comma-separated list of tools, e.g.,
958               autoconf,automake,bison,gnulib
959         --gnulib-snapshot-date=DATE
960               if gnulib is in the bootstrap tool list,
961               then report this as the snapshot date.
962               If not specified, use the current date/time.
963               If you specify a date here, be sure it's UTC.
964
965 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
966
967         * tests/test-argp-2.sh: Fix test to match actual output.
968         (func_compare): Fix sed script to be portable.
969
970 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
971
972         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
973         workaround for this case.  It is not autoconfigured now; offhand
974         it's hard to see how to autoconfigure it.
975
976 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
977
978         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
979         a directory that is about to be chowned.  Such a directory's
980         initial file permissions should permit the owner only and this
981         should not be changed until after the chown, since the group and
982         other bits would be incorrect if they granted permission before
983         the chown.
984
985         Fix porting problem for iswctype reported by Georg Schwarz in:
986         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
987         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
988         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
989         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
990         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
991
992 2006-12-03  Jim Meyering  <jim@meyering.net>
993
994         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
995         p->fts_statp may not yet be defined.
996         (fts_read): Instead, set it in the caller, once p->fts_statp is
997         sure to be defined, and corresponds to a top-level directory.
998         This bug made du -x fail.  Here's the coreutils test case:
999         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
1000         Reported by Mike Frysinger.
1001
1002 2006-12-01  Jim Meyering  <jim@meyering.net>
1003
1004         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
1005         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
1006         Reported by Simon Josefsson.
1007
1008 2006-11-30  Jim Meyering  <jim@meyering.net>
1009
1010         * m4/warning.m4: Use the all-permissive copyright notice
1011         recommended by RMS (rather than LGPL).
1012         * m4/vararrays.m4: Likewise.
1013         * m4/flexmember.m4: Likewise.
1014
1015 2006-11-29  Bruno Haible  <bruno@clisp.org>
1016
1017         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1018         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
1019         using +=.
1020         Reported by Simon Josefsson <simon@josefsson.org>.
1021
1022 2006-11-28  James Youngman <jay@gnu.org>
1023
1024         * README: Advise users that they might find the bug-gnulib@gnu.org
1025         and autotools-announce@gnu.org mailing lists useful.
1026
1027 2006-11-28  Bruno Haible  <bruno@clisp.org>
1028
1029         * m4/ptrdiff_max.m4: Remove file.
1030
1031 2006-11-21  Bruno Haible  <bruno@clisp.org>
1032
1033         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
1034         _AC_COMPUTE_INT.
1035         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1036         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
1037         _AC_COMPUTE_INT.
1038         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1039         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
1040         _AC_COMPUTE_INT.
1041         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1042
1043 2006-11-28  Jim Meyering  <jim@meyering.net>
1044
1045         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
1046         warning from "gcc -Wshadow" about shadowing the builtin.
1047
1048 2006-11-27  Bruno Haible  <bruno@clisp.org>
1049
1050         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
1051         _AC_COMPUTE_INT.
1052         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1053
1054 2006-11-27  Bruno Haible  <bruno@clisp.org>
1055             Paul Eggert  <eggert@cs.ucla.edu>
1056
1057         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
1058
1059 2006-11-26  Bruno Haible  <bruno@clisp.org>
1060
1061         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1062         noinst_LTLIBRARIES.
1063
1064 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
1065             Bruno Haible  <bruno@clisp.org>
1066
1067         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
1068         if compiling with "gcc -ansi".
1069
1070 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
1071
1072         Fix some incompatibilities with gcc -ansi -pedantic.
1073         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
1074         if compiling pedantically with GCC, unless it's C99 or later.
1075         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
1076         it mishandles gcc -ansi -pedantic as well.
1077         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
1078         if gcc -pedantic.
1079         * lib/regexec.c (check_node_accept_bytes): Don't use auto
1080         initializers for struct if -pedantic, unless it's C99 or later.
1081
1082 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
1083
1084         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
1085         Don't close an fd more than once. Identical atimes indicate
1086         success, not failure.
1087
1088 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
1089
1090         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
1091
1092 2006-11-23  Jim Meyering  <jim@meyering.net>
1093
1094         * build-aux/announce-gen: New file.  From coreutils.
1095
1096 2006-11-22  Jim Meyering  <jim@meyering.net>
1097
1098         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
1099         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
1100         (fts_read): Use a temporary to narrow the overused st_size member
1101         before using it in a switch statement.  Reported by Matthew Woehlke.
1102
1103         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
1104         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
1105
1106 2006-11-20  Bruno Haible  <bruno@clisp.org>
1107
1108         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
1109         changequote instead of pairs of brackets.
1110         Reported by Andreas Schwab <schwab@suse.de>.
1111
1112 2006-11-21  Jim Meyering  <jim@meyering.net>
1113
1114         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
1115         so as to remain compatible with older compilers.
1116         Patch from Michael Deutschmann.
1117
1118 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1119
1120         * MODULES.html.sh (File system functions): Add openat.
1121
1122         * lib/openat.h (rpl_fstatat): New macro, if
1123         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
1124         (fstatat): Define to rpl_fstatat under the same conditions,
1125         unless COMPILING_FSTATAT.
1126         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
1127         seems to have the bug.
1128         * lib/fstatat.c: New file.
1129         * modules/openat (Files): Add it.
1130
1131 2006-11-20  Bruno Haible  <bruno@clisp.org>
1132
1133         * Makefile: New file.
1134
1135 2006-11-20  Jim Meyering  <jim@meyering.net>
1136
1137         The beginnings of syntax-related checks for gnulib.
1138         * lib/Makefile: New file.
1139         * lib/t-idcache: New script.  Ensure that the two halves of
1140         idcache.c stay in sync.
1141
1142         * lib/idcache.c: Adjust comments in user- and group- portions to
1143         be more accurate, and to be consistent with one another.
1144
1145 2006-11-20  Jim Meyering  <jim@meyering.net>
1146
1147         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
1148         continue using the flexible array member (thus, this module performs
1149         half as many malloc calls), with the addition that...
1150         (getgroup, getuser): Consistently record a non-match via an empty
1151         "name" string, and map an empty string match to a NULL return value.
1152         * modules/idcache (Depends-on): Re-add flexmember.
1153
1154         * lib/idcache.c (getuser): Remove all uses of the register keyword.
1155         (getuidbyname, getgroup, getgidbyname): Likewise.
1156
1157         Use cleaner syntax: NULL rather than 0.
1158         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
1159
1160 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1161
1162         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
1163         It mishandled the case where the group was missing.
1164         Problem reported by Greg Schafer.
1165         * modules/idcache: Likewise.
1166
1167 2006-11-18  Jim Meyering  <jim@meyering.net>
1168
1169         * check-module (%exempt_header): Add exception for some
1170         conditionally-included headers.
1171
1172         * modules/i-ring (Depends-on): Add verify.
1173         (License): Change to LGPL.
1174
1175 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
1176
1177         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
1178         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
1179         and inttostr.h.  Use snprintf rather than uinttostr, so that
1180         LGPLed code doesn't depend on GPLed.
1181
1182 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
1183
1184         * modules/inline (License): Change from GPL to LGPL.
1185
1186 2006-11-17  Jim Meyering  <jim@meyering.net>
1187
1188         * modules/d-type (License): Switch to LGPL.
1189
1190 2006-11-15  Bruno Haible  <bruno@clisp.org>
1191
1192         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
1193
1194 2006-11-15  Eric Blake  <ebb9@byu.net>
1195
1196         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
1197         the module dependency.
1198
1199 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1200             Bruno Haible  <bruno@clisp.org>
1201
1202         * gnulib-tool (func_create_testdir): Add license consistency check.
1203
1204 2006-11-15  Eric Blake  <ebb9@byu.net>
1205
1206         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
1207         random "(cached)" in configure output.
1208
1209 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1210
1211         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
1212         test for conforming inttypes.h is both announced and cached.
1213
1214         * MODULES.html.sh (seen_modules, seen_files): New variables.
1215         (func_module): Rewrite to use a few less gnulib-tool and sed
1216         invocations.  Avoid a couple of quadratic algorithms for ...
1217         (missed_modules, missed_files): ... these, with ...
1218         (func_append, func_tmpdir): ... these new functions, from
1219         gnulib-tool.  Analogously, install traps for cleanup.
1220
1221         * tests/test-gc.c (main): Remove unused variables.
1222         * tests/test-read-file.c: Include stdlib.h, for 'free'.
1223
1224 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
1225
1226         * modules/inttostr (License): Change to LGPL.
1227
1228 2006-11-14  Eric Blake  <ebb9@byu.net>
1229
1230         * modules/tempname (License): Change to LGPL.
1231
1232 2006-11-14  Eric Blake  <ebb9@byu.net>
1233
1234         * doc/functions.texi (Function Portability): *printf functions on
1235         Cygwin now understand all POSIX size specifiers.
1236
1237 2006-11-14  Bruno Haible  <bruno@clisp.org>
1238
1239         * modules/c-ctype (License): Change to LGPL.
1240
1241 2006-11-12  Bruno Haible  <bruno@clisp.org>
1242
1243         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
1244         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
1245         for GNOME libraries, for which the include files are installed in
1246         subdirectories of $prefix/include.
1247
1248 2006-11-12  Bruno Haible  <bruno@clisp.org>
1249
1250         * m4/lib-link.m4: Require at least autoconf-2.54.
1251         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
1252         name to underscores for the --with option.
1253
1254 2006-11-13  Bruno Haible  <bruno@clisp.org>
1255
1256         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
1257         the tests directory.
1258         Reported by Ralf Wildenhues.
1259
1260 2006-11-13  Bruno Haible  <bruno@clisp.org>
1261
1262         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
1263         (func_emit_initmacro_end): Undo the override here.
1264         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
1265         Works around the famous automake error in coreutils.
1266
1267 2006-11-13  Eric Blake  <ebb9@byu.net>
1268
1269         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
1270         element, not its node.
1271
1272 2006-11-12  Bruno Haible  <bruno@clisp.org>
1273
1274         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
1275         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
1276
1277 2006-11-12  Bruno Haible  <bruno@clisp.org>
1278
1279         * gnulib-tool: New option --local-symlink.
1280         (func_usage): Document it.
1281         (lsymbolic): New variable.
1282         (func_import, func_create_testdir): If --symlink was not specified,
1283         test whether --local-symlink was specified and the file comes from
1284         the local_gnulib_dir.
1285
1286 2006-11-12  Bruno Haible  <bruno@clisp.org>
1287
1288         * gnulib-tool (func_ln): New function.
1289         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
1290
1291 2006-11-12  Bruno Haible  <bruno@clisp.org>
1292
1293         Finish support for source files in subdirectories.
1294         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
1295         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
1296         AUTOMAKE_OPTIONS.
1297         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
1298
1299 2006-11-12  Bruno Haible  <bruno@clisp.org>
1300
1301         * gnulib-tool (func_get_automake_snippet): Synthesize also an
1302         EXTRA_lib_SOURCES augmentation.
1303         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
1304
1305 2006-11-12  Jim Meyering  <jim@meyering.net>
1306
1307         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
1308         file descriptors.  This also averts a failure on systems with
1309         native openat support when a traversed directory lacks "x" access.
1310         * lib/fts_.h: Include "i-ring.h"
1311         (struct FTS) [fts_fd_ring]: New member.
1312         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
1313         (FCHDIR): Add parentheses.
1314         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
1315         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
1316         When descending, rather than simply closing the previous
1317         fts_cwd_fd value, push that file descriptor onto the ring.
1318         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
1319         (fts_open): Initialize the new fd_ring member.
1320         (fts_close): Clear the ring.
1321         (fts_safe_changedir): When possible, use our new fd_ring to skip
1322         the diropen and fstat and dev/ino comparison that would normally
1323         accompany a virtual `chdir ("..")'.
1324
1325         * modules/fts (Depends-on): Add i-ring.
1326         * modules/i-ring: New module.
1327         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
1328         * m4/i-ring.m4: New file.
1329
1330 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1331
1332         * gnulib-tool (func_create_testdir): Fix replacement of
1333         `build-aux' in configure.ac.  Run autotools in gltests
1334         subdirectory.
1335         (func_create_testdir, func_create_megatestdir, test): There is
1336         no need for '--force' in most autotool invocations in a new
1337         tree.  Actually fail the whole test if any of the tools, or the
1338         configure or make stages fail.
1339
1340         Sync from Automake.
1341         * build-aux/gnupload: Revert last change.  Add pointer to upload
1342         instructions of the GNU Maintenance Instructions.
1343         Suggestion by Karl Berry.
1344
1345 2006-11-10  Jim Meyering  <jim@meyering.net>
1346
1347         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
1348
1349 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1350
1351         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
1352         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
1353         (bind_textdomain_codeset) [! ENABLE_NLS]:
1354         Evaluate all the arguments.  That way, callers get compatible behavior
1355         if the arguments have side effects.  Also, it avoids some GCC
1356         diagnostics in some cases; Joel E. Denny reported problems when Bison
1357         was configured with --enable-gcc-warnigs.
1358
1359 2006-11-10  Jim Meyering  <jim@meyering.net>
1360
1361         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
1362         relevant options in CFLAGS (like -O, -fno-inline) are taken into
1363         account.
1364
1365 2006-11-10  Jim Meyering  <jim@meyering.net>
1366
1367         * modules/inline: New file/module.
1368         * modules/xalloc (Files): Remove m4/inline.m4.
1369         (Depends-on): Add inline, instead.
1370         * modules/oset: Likewise.
1371         * modules/list: Likewise.
1372
1373 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1374
1375         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
1376         Problem reported by Matthew Woehlke.
1377
1378 2006-11-09  Bruno Haible  <bruno@clisp.org>
1379
1380         * lib/tempname.c (gen_tempname): Remove variant that invokes
1381         __gen_tempname.
1382         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
1383         __gen_tempname.
1384
1385 2006-11-08  Bruno Haible  <bruno@clisp.org>
1386
1387         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
1388         to 'yes' instead of 'cross-compiling'.
1389
1390 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
1391
1392         * lib/quotearg.h (quotearg_free): New decl.
1393         * lib/quotearg.c (quotearg_free): New function.
1394         (slot0, nslots, slotvec0, slotvec):
1395         Now file-scope so that quotearg_free can get at them.
1396
1397 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1398
1399         Sync from Automake.
1400         * build-aux/gnupload: Add missing 'gnu' to example URL.
1401         Report by Karl Berry.
1402
1403 2006-11-08  Bruno Haible  <bruno@clisp.org>
1404
1405         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
1406         Suggested by Paul Eggert.
1407
1408 2006-11-08  Jim Meyering  <jim@meyering.net>
1409
1410         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
1411         It's already included if !_LIBC.
1412         (fts_safe_changedir): Add a comment.
1413
1414 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1415
1416         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
1417         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
1418         Matthew Woehlke.
1419
1420         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
1421         definitions up, to avoid colliding with change below.
1422         (static_inline) [HAVE_INLINE]: New macro.
1423         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
1424         Provide extern decls when !HAVE_INLINE.  Do not define unless
1425         static_inline is defined, either by us or by xmalloc.c.  Use
1426         static_inline rather than static inline.
1427         (XCALLOC): Optimize sizeof(T) = 1 case.
1428         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
1429
1430 2006-11-07  Bruno Haible  <bruno@clisp.org>
1431
1432         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
1433         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
1434         AC_C_INLINE.
1435         * modules/xalloc (Files): Add m4/inline.m4.
1436
1437 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1438
1439         * README: Fix typo.
1440         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
1441         (Miscellanous Notes): ...from this.
1442
1443 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1444
1445         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
1446         Mention that offsetof should be used instead of sizeof.
1447         From Bruno Haible.
1448
1449 2006-11-07  Bruno Haible  <bruno@clisp.org>
1450
1451         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
1452
1453 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1454
1455         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1456         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
1457         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1458         (gl_tree_add_before, gl_tree_add_after):
1459         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
1460         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
1461         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1462         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
1463         (gl_linked_add_after, gl_linked_add_at): Likewise.
1464         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
1465         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1466         (gl_tree_add_before, gl_tree_add_after): Likewise.
1467         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
1468         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
1469         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
1470
1471 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1472
1473         * lib/gl_oset.h: Use C comment style, not C++ comment style.
1474
1475 2006-11-06  Bruno Haible  <bruno@clisp.org>
1476
1477         * m4/inline.m4: New file.
1478         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
1479         * modules/list (Files): Add m4/inline.m4.
1480         * modules/oset (Files): Likewise.
1481
1482 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1483
1484         * lib/idcache.c: Include <stddef.h>, for offsetof.
1485         (struct userid.name): Change from char * to a flexible array member.
1486         All uses changed.
1487         * modules/idcache (Depends-on): Add flexmember.
1488
1489         * MODULES.html.sh (Core language properties): New module flexmember.
1490         * modules/flexmember, m4/flexmember.m4: New files.
1491
1492         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
1493         inline functions that are identical with the old xnmalloc_inline,
1494         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
1495         that we can avoid some unnecessary integer multiplications and
1496         divisions in the common case where the element size is known at
1497         compile time.
1498         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
1499         needed.
1500         (xnboundedmalloc): Remove.
1501         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
1502         arguments, for consistency with rest of this header.
1503         (xcharalloc): Rewrite using XNMALLOC.
1504         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
1505         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
1506         versions have been moved to lib/xalloc.h and renamed to be the
1507         non-*_inline versions.
1508         (xmalloc, xrealloc): Implement without reference to the xnmalloc
1509         and xnrealloc functions, since those functions are now inline and
1510         now call us.
1511         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
1512         renaming described above.
1513         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
1514         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
1515         captures the dependency in AC_C_INLINE.
1516
1517         New module canonicalize-lgpl, proposed by Charles Wilson in
1518         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
1519         with a few small changes afterwards.
1520         * MODULES.html.sh (File system functions): New module
1521         canonicalize-lgpl.
1522         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
1523         and canonicalize_file_name.
1524         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
1525         * modules/canonicalize-lgpl: New files.
1526
1527 2006-11-05  Bruno Haible  <bruno@clisp.org>
1528
1529         * gnulib-tool (func_import, func_create_testdir): Create directories
1530         also for files in subdirectories of lib/.
1531
1532 2006-11-05  Bruno Haible  <bruno@clisp.org>
1533
1534         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
1535         ANSI C compliant.
1536
1537 2006-11-03  Bruno Haible  <bruno@clisp.org>
1538
1539         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1540         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
1541         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
1542         (xnboundedmalloc): New inline function.
1543         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
1544         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
1545         xmalloc.
1546         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
1547         xmalloc.
1548         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
1549         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
1550         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
1551         xmalloc.
1552         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1553         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
1554         xmalloc.
1555         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
1556         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1557         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
1558         xmalloc.
1559         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1560         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
1561         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1562         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
1563         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
1564         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
1565         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
1566
1567 2006-11-03  Bruno Haible  <bruno@clisp.org>
1568
1569         * lib/c-ctype.h [C++]: Define functions without name mangling.
1570         * lib/fwriteerror.h [C++]: Likewise.
1571         * lib/gcd.h [C++]: Likewise.
1572         * lib/linebreak.h [C++]: Likewise.
1573
1574 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
1575
1576         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
1577         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
1578         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
1579         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1580         Check for functions and headers just once.
1581         Check for declaration of canonicalize_file_name.
1582         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
1583
1584 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1585
1586         * gnulib-tool (func_import): Fix typo in actioncmd.
1587
1588 2006-11-02  Bruno Haible  <bruno@clisp.org>
1589
1590         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
1591         newline sequence in the Makefile.am snippet as a space, like "make"
1592         does.
1593         Reported by Roger Persson <perrog@gmail.com>.
1594
1595 2006-11-01  Bruno Haible  <bruno@clisp.org>
1596
1597         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
1598         already declared in <string.h>.
1599         * lib/strcase.h (strncasecmp): Don't declare it if yes.
1600
1601 2006-11-01  Bruno Haible  <bruno@clisp.org>
1602
1603         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
1604         * lib/strcase.h: Include <string.h>.
1605         (strcasecmp): Define to rpl_strcasecmp here.
1606
1607 2006-11-01  Bruno Haible  <bruno@clisp.org>
1608
1609         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
1610
1611 2006-11-01  Eric Blake  <ebb9@byu.net>
1612
1613         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
1614
1615         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
1616
1617 2006-10-29  Bruno Haible  <bruno@clisp.org>
1618
1619         Make it compile in C++ mode.
1620         * lib/full-write.c (full_rw): Add a cast.
1621
1622 2006-11-01  Bruno Haible  <bruno@clisp.org>
1623
1624         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
1625         be POSIX compliant.
1626         Reported by Roger Persson <perrog@gmail.com>.
1627
1628 2006-11-01  Eric Blake  <ebb9@byu.net>
1629
1630         * lib/getopt_.h: Fix comments.
1631
1632 2006-10-31  Eric Blake  <ebb9@byu.net>
1633
1634         * modules/tmpdir (Depends-on): Add sys_stat.
1635         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
1636         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
1637         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
1638         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
1639         tempname.
1640
1641 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
1642
1643         Avoid some C++ diagnostics reported by Bruno Haible.
1644         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
1645         xmalloc.
1646         (quotearg_alloc): Use xcharalloc rather than xmalloc.
1647         (struct slotvec): Move to top level.
1648         (quotearg_n_options): Rewrite to avoid xmalloc.
1649         * lib/xalloc.h (xcharalloc): New function.
1650         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
1651         [defined __cplusplus]: Add function template that provides result
1652         type propagation.  This part of the change is from Bruno Haible.
1653
1654 2006-10-29  Bruno Haible  <bruno@clisp.org>
1655
1656         Make it compile in C++ mode.
1657         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
1658         * lib/strnlen1.c (strnlen1): Cast memchr result.
1659         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
1660         * lib/clean-temp.c (string_equals, string_hash): Add casts.
1661         (create_temp_dir): Rename local variable 'template'.
1662         (compile_csharp_using_sscli): Add cast.
1663         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
1664         * lib/findprog.c (find_in_path): Likewise.
1665         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
1666         * lib/wait-process.c (register_slave_subprocess): Likewise.
1667
1668 2006-10-22  Bruno Haible  <bruno@clisp.org>
1669
1670         * modules/tsearch: New file.
1671         * lib/tsearch.h: New file.
1672         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
1673         * m4/tsearch.m4: New file.
1674         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
1675
1676 2006-10-29  Eric Blake  <ebb9@byu.net>
1677
1678         * lib/arcfour.c: Assume config.h.
1679         * lib/arctwo.c: Likewise.
1680         * lib/base64.c: Likewise.
1681         * lib/check-version.c: Likewise.
1682         * lib/crc.c: Likewise.
1683         * lib/des.c: Likewise.
1684         * lib/gc-gnulib.c: Likewise.
1685         * lib/gc-libgcrypt.c: Likewise.
1686         * lib/gc-pbkdf2-sha1.c: Likewise.
1687         * lib/getaddrinfo.c: Likewise.
1688         * lib/getdelim.c: Likewise.
1689         * lib/getline.c: Likewise.
1690         * lib/hmac-md5.c: Likewise.
1691         * lib/hmac-sha1.c: Likewise.
1692         * lib/iconvme.c: Likewise.
1693         * lib/md2.c: Likewise.
1694         * lib/md4.c: Likewise.
1695         * lib/memxor.c: Likewise.
1696         * lib/read-file.c: Likewise.
1697         * lib/readline.c: Likewise.
1698         * lib/rijndael-alg-fst.c: Likewise.
1699         * lib/rijndael-api-fst.c: Likewise.
1700         * lib/xgetdomainname.c: Likewise.
1701
1702 2006-10-28  Eric Blake  <ebb9@byu.net>
1703
1704         * lib/xstrndup.c: Assume config.h.
1705
1706 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
1707
1708         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
1709         stat-macros.h is now for our own macros, whereas stat_h is for
1710         macros in the <sys/stat.h> name space.
1711         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
1712         (STAT_MACROS_H): Remove.
1713         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
1714         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
1715         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
1716         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
1717         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
1718         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
1719         Move these macros to ...
1720         * lib/stat_.h: here.  Don't include stat-macros.h.
1721         * lib/canonicalize.c: Don't include stat-macros.h.
1722         * lib/chown.c: Likewise.
1723         * lib/euidaccess.c: Likewise.
1724         * lib/file-type.c: Likewise.
1725         * lib/filemode.c: Likewise.
1726         * lib/glob.c: Likewise.
1727         * lib/isapipe.c: Likewise.
1728         * lib/lchown.c: Likewise.
1729         * lib/lstat.c: Likewise.
1730         * lib/mkdir-p.c: Likewise.
1731         * lib/rmdir.c: Likewise.
1732         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
1733         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
1734         unless mkdir isn't declared, to speed up 'configure'.
1735         Always create sys/stat.h, since it's unlikely any real sys/stat.h
1736         would define all the S_* symbols.
1737         * modules/canonicalize (Depends-on):
1738         Depend on sys_stat, not stat-macros.
1739         * modules/chown: Likewise.
1740         * modules/euidaccess: Likewise.
1741         * modules/filemode: Likewise.
1742         * modules/file-type: Likewise.
1743         * modules/glob: Likewise.
1744         * modules/isapipe: Likewise.
1745         * modules/lchown: Likewise.
1746         * modules/lstat: Likewise.
1747         * modules/mkancesdirs: Likewise.
1748         * modules/rmdir: Likewise.
1749         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
1750         * modules/modechange: Likewise.
1751         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
1752         (configure.ac): Remove gl_STAT_MACROS.
1753         * modules/sys_stat (Depends-on): Remove stat-macros.
1754
1755 2006-10-27  Bruno Haible  <bruno@clisp.org>
1756
1757         * m4/signed.m4: Remove file.
1758         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
1759         invocation.
1760         * modules/vasnprintf (Files): Remove m4/signed.m4.
1761
1762 2006-10-27  Bruno Haible  <bruno@clisp.org>
1763
1764         Update to GNU gettext 0.16.
1765         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
1766         m4/inttypes-h.m4, m4/signed.m4.
1767         * m4/gettext.m4: Update to GNU gettext 0.16.
1768         * m4/intl.m4: New file, from GNU gettext.
1769         * m4/intldir.m4: New file, from GNU gettext.
1770         * config/srclist.txt: Update
1771
1772 2006-10-27  Eric Blake  <ebb9@byu.net>
1773
1774         * MODULES.html.sh: Document tempname.
1775         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
1776         dependencies.
1777         (Files): Move lib/tempname.c...
1778         * modules/tempname: ...to this new module.
1779         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
1780         (gl_PREREQ_TEMPNAME): Move...
1781         * m4/tempname.m4: ...to this new file.
1782         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
1783         * modules/sys_stat (Depends-on): Add stat-macros.
1784         * lib/stat_.h (includes): Pick up stat macros.
1785         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
1786         if stat macros are broken.
1787         * lib/tempname.c (includes): No need to include "stat-macros.h".
1788         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
1789         (direxists, __path_search) [!_LIBC]: Don't compile these in
1790         gnulib; the tmpdir module covers that.
1791         * lib/tempname.h: New file.
1792
1793 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
1794
1795         * COPYING: Explain how gnulib-tool converts licence headers.
1796         Almost all wording by Eric Blake.
1797
1798 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
1799
1800         * lib/mbchar.h (is_basic_table): Make read-only.
1801         * lib/mbchar.c (is_basic_table): Likewise.
1802         Reported by John Darrington.
1803
1804 2006-10-25  Bruno Haible  <bruno@clisp.org>
1805
1806         * lib/progname.h (set_program_name): Undefine before defining.
1807
1808 2006-10-25  Bruno Haible  <bruno@clisp.org>
1809
1810         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
1811         false for non-gcc C++ compilers.
1812         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
1813
1814 2006-10-24  Bruno Haible  <bruno@clisp.org>
1815
1816         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
1817         iconv implementations like Irix iconv.
1818
1819 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1820
1821         * modules/vararrays: New file.
1822         * m4/vararrays.m4: New file, taken from diffutils.
1823         * MODULES.html.sh: New module vararrays.
1824
1825 2006-10-24  Karl Berry  <karl@gnu.org>
1826
1827         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
1828         Don't call GNU Unix.
1829
1830 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1831
1832         * users.txt: Add Libtool.
1833
1834         Sync from Libtool:
1835
1836         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1837
1838         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
1839         to gnulib's policy of including config.h unconditionally.
1840
1841 2006-10-24  Bruno Haible  <bruno@clisp.org>
1842
1843         * modules/wcwidth (Files): Add m4/wint_t.m4.
1844         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
1845         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
1846
1847 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1848
1849         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
1850         to pacify GCC with some -W flags enabled.  Problem reported by
1851         Bruno Haible.
1852
1853 2006-10-24  Jim Meyering  <jim@meyering.net>
1854
1855         * MODULES.html.sh: Remove uinttostr.  It's not a module.
1856         Reported by Karl Berry.
1857
1858 2006-10-23  Bruno Haible  <bruno@clisp.org>
1859
1860         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
1861
1862 2006-10-24  Bruno Haible  <bruno@clisp.org>
1863
1864         * lib/gl_list.h: Use C comment style, not C++ comment style.
1865
1866 2006-10-23  Eric Blake  <ebb9@byu.net>
1867
1868         * lib/getaddrinfo.c (includes): Add missing include.
1869
1870 2006-10-23  Bruno Haible  <bruno@clisp.org>
1871             Paul Eggert  <eggert@cs.ucla.edu>
1872
1873         Ability to rename obstack_free.
1874         * lib/obstack.h (__obstack_free): New macro. Declare instead of
1875         obstack_free.
1876         (obstack_free): Invoke the __obstack_free macro.
1877         * lib/obstack.c (obstack_free): Use __obstack_free macro.
1878
1879 2006-10-23  Bruno Haible  <bruno@clisp.org>
1880             Paul Eggert  <eggert@cs.ucla.edu>
1881
1882         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
1883         __argc, __argv from the declaration. (They are defined as macros on
1884         mingw.)
1885
1886 2006-10-22  Bruno Haible  <bruno@clisp.org>
1887
1888         * doc/gnulib-intro.texi: New file.
1889         * doc/gnulib.texi: Include it.
1890
1891 2006-10-21  Bruno Haible  <bruno@clisp.org>
1892
1893         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
1894         "Introduction", "Miscellanous Notes", "Particular Modules".
1895
1896 2006-10-21  Bruno Haible  <bruno@clisp.org>
1897
1898         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1899         Change mostlyclean-local rule to avoid sh syntax error from bash
1900         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
1901
1902 2006-10-23  Jim Meyering  <jim@meyering.net>
1903
1904         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
1905         in place of snprintf.
1906
1907         * modules/inttostr (Files): Add lib/uinttostr.c.
1908         * lib/uinttostr.c (inttostr): New file/function.
1909         * lib/inttostr.h (uinttostr): Declare.
1910         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
1911         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
1912         Add uinttostr.
1913         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
1914
1915 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1916
1917         * lib/canonicalize.c (ELOOP): Define if not already defined.
1918         Problem reported by Bruno Haible in
1919         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
1920
1921 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1922
1923         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
1924         Problem reported by Perry Smith and Ville Laurikari.
1925
1926         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
1927         uses.
1928
1929 2006-10-19  Bruno Haible  <bruno@clisp.org>
1930
1931         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
1932         for mingw.
1933
1934 2006-10-19  Bruno Haible  <bruno@clisp.org>
1935
1936         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
1937         Needed for mingw.
1938
1939 2006-10-19  Bruno Haible  <bruno@clisp.org>
1940
1941         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
1942
1943 2006-10-19  Bruno Haible  <bruno@clisp.org>
1944
1945         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
1946         it.
1947
1948 2006-10-19  Bruno Haible  <bruno@clisp.org>
1949
1950         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
1951         invocation.
1952
1953 2006-10-19  Bruno Haible  <bruno@clisp.org>
1954
1955         * gnulib-tool (func_create_testdir): Don't include ftruncate and
1956         mountlist by default.
1957
1958 2006-10-16  Bruno Haible  <bruno@clisp.org>
1959
1960         * lib/c-strstr.c: Include c-strstr.h.
1961
1962 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1963
1964         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
1965         in a slash.
1966
1967 2006-10-18  Bruno Haible  <bruno@clisp.org>
1968
1969         * lib/lock.h [C++]: Wrap definitions in extern "C".
1970
1971 2006-10-18  Bruno Haible  <bruno@clisp.org>
1972
1973         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
1974         gl_LIBOBJS list.
1975
1976 2006-10-18  Bruno Haible  <bruno@clisp.org>
1977
1978         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
1979
1980 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
1981
1982         * lib/xstrtol.h: Include gettext.h.
1983         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
1984         Problem reported by Eric Blake.
1985         * modules/xstrtol (Depends-on): Add gettext-h.
1986
1987 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
1988
1989         * lib/strftime.c (advance): New macro.
1990         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
1991         incomplete type, so you can't add 0 to it.  Problem and patch
1992         reported by Eelco Dolstra for dietlibc.
1993
1994 2006-10-18  Jim Meyering  <jim@meyering.net>
1995
1996         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
1997         type for a local, and rename it: s/up/user_proc/.
1998
1999 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
2000
2001         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
2002         READ_UTMP_USER_PROCESS.
2003         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
2004
2005 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
2006
2007         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
2008         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
2009
2010 2006-10-17  Eric Blake  <ebb9@byu.net>
2011
2012         * lib/sigprocmask.c (sigprocmask): Fix typo.
2013
2014         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
2015
2016         * modules/clean-temp (Makefile.am): Don't add to make output...
2017         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
2018         config.h.
2019
2020 2006-10-17  Bruno Haible  <bruno@clisp.org>
2021
2022         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
2023         differently if DEFAULT_TEXT_DOMAIN is set.
2024
2025 2006-10-16  Bruno Haible  <bruno@clisp.org>
2026
2027         * lib/clean-temp.c: Include fwriteerror.h.
2028
2029 2006-10-16  Bruno Haible  <bruno@clisp.org>
2030
2031         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
2032
2033 2006-10-16  Bruno Haible  <bruno@clisp.org>
2034
2035         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
2036         * lib/sigprocmask.h: Include <sys/types.h>.
2037         (sigset_t): Use the system's definition if present.
2038
2039 2006-10-17  Eric Blake  <ebb9@byu.net>
2040
2041         * lib/xvasprintf.c (includes): Assume config.h.
2042         * lib/xasprintf.c (includes): Likewise.
2043
2044 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
2045
2046         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
2047         at least as wide as intmax_t.
2048
2049 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
2050
2051         (Imported from Automake.)
2052         * build-aux/gnupload: Update to version 1.1 of directive file.
2053
2054 2006-10-16  Eric Blake  <ebb9@byu.net>
2055
2056         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
2057         match Automake 1.10a.
2058
2059 2006-10-14  Bruno Haible  <bruno@clisp.org>
2060
2061         * modules/sigprocmask: New file.
2062         * lib/sigprocmask.h: New file.
2063         * lib/sigprocmask.c: New file.
2064         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
2065         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
2066         request sigprocmask.o.
2067         (gl_PREREQ_SIGPROCMASK): New macro.
2068         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
2069         (Depends-on): Add sigprocmask.
2070         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
2071         gt_SIGNALBLOCKING. Test for 'raise' only once.
2072         * lib/fatal-signal.c: Include sigprocmask.h.
2073         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
2074         unblock_fatal_signals): Define always.
2075         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
2076         sigprocmask.
2077
2078 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
2079
2080         Sync from Automake.
2081         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
2082         which incorrectly sets the mode of an existing destination
2083         directory.  In some cases the unpatched install-sh could do the
2084         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
2085         system.  We hope this is rare in practice, but it's clearly worth
2086         fixing.  Problem reported by Alex Unleashed in
2087         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
2088         Also, don't bother to check for -m bugs unless we're using -m;
2089         suggested by Stepan Kasal.
2090
2091 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2092
2093         Sync from Automake.
2094         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
2095         `-c' flag, so they appear at the same position as in %FASTDEP%
2096         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
2097         which ignores unknown options only after the first non-option.
2098         Bug report against M4 by Nelson H. F. Beebe.
2099
2100 2006-10-13  Jim Meyering  <jim@meyering.net>
2101
2102         Fix a bug in yesterday's change.
2103         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
2104         p->fts_statp->st_dev would be used uninitialized.
2105         Ensures that we always call fts_stat on the very first entry.
2106         Miklos Szeredi reported that find -xdev stopped working.
2107
2108 2006-10-12  Bruno Haible  <bruno@clisp.org>
2109
2110         * gnulib-tool (func_get_automake_snippet): Append an automatically
2111         computed EXTRA_DIST augmentation.
2112         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
2113         * modules/alloca-opt (Makefile.am): Likewise.
2114         * modules/allocsa (Makefile.am): Likewise.
2115         * modules/arcfour (Makefile.am): Likewise.
2116         * modules/arctwo (Makefile.am): Likewise.
2117         * modules/argmatch (Makefile.am): Likewise.
2118         * modules/argz (Makefile.am): Likewise.
2119         * modules/atexit (Makefile.am): Likewise.
2120         * modules/backupfile (Makefile.am): Likewise.
2121         * modules/byteswap (Makefile.am): Likewise.
2122         * modules/c-strtod (Makefile.am): Likewise.
2123         * modules/c-strtold (Makefile.am): Likewise.
2124         * modules/calloc (Makefile.am): Likewise.
2125         * modules/canon-host (Makefile.am): Likewise.
2126         * modules/canonicalize (Makefile.am): Likewise.
2127         * modules/chdir-long (Makefile.am): Likewise.
2128         * modules/chdir-safer (Makefile.am): Likewise.
2129         * modules/check-version (Makefile.am): Likewise.
2130         * modules/chown (Makefile.am): Likewise.
2131         * modules/cloexec (Makefile.am): Likewise.
2132         * modules/close-stream (Makefile.am): Likewise.
2133         * modules/closeout (Makefile.am): Likewise.
2134         * modules/crc (Makefile.am): Likewise.
2135         * modules/csharpexec (Makefile.am): Likewise.
2136         * modules/cycle-check (Makefile.am): Likewise.
2137         * modules/des (Makefile.am): Likewise.
2138         * modules/dev-ino (Makefile.am): Likewise.
2139         * modules/dirfd (Makefile.am): Likewise.
2140         * modules/dirname (Makefile.am): Likewise.
2141         * modules/dup2 (Makefile.am): Likewise.
2142         * modules/eealloc (Makefile.am): Likewise.
2143         * modules/error (Makefile.am): Likewise.
2144         * modules/euidaccess (Makefile.am): Likewise.
2145         * modules/exclude (Makefile.am): Likewise.
2146         * modules/exitfail (Makefile.am): Likewise.
2147         * modules/fcntl-safer (Makefile.am): Likewise.
2148         * modules/fcntl (Makefile.am): Likewise.
2149         * modules/file-type (Makefile.am): Likewise.
2150         * modules/fileblocks (Makefile.am): Likewise.
2151         * modules/filemode (Makefile.am): Likewise.
2152         * modules/filenamecat (Makefile.am): Likewise.
2153         * modules/fnmatch (Makefile.am): Likewise.
2154         * modules/fopen-safer (Makefile.am): Likewise.
2155         * modules/fpending (Makefile.am): Likewise.
2156         * modules/fprintftime (Makefile.am): Likewise.
2157         * modules/free (Makefile.am): Likewise.
2158         * modules/fsusage (Makefile.am): Likewise.
2159         * modules/ftruncate (Makefile.am): Likewise.
2160         * modules/fts (Makefile.am): Likewise.
2161         * modules/gc-arcfour (Makefile.am): Likewise.
2162         * modules/gc-des (Makefile.am): Likewise.
2163         * modules/gc-hmac-md5 (Makefile.am): Likewise.
2164         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
2165         * modules/gc-md4 (Makefile.am): Likewise.
2166         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2167         * modules/gc-sha1 (Makefile.am): Likewise.
2168         * modules/gc (Makefile.am): Likewise.
2169         * modules/getaddrinfo (Makefile.am): Likewise.
2170         * modules/getcwd (Makefile.am): Likewise.
2171         * modules/getdelim (Makefile.am): Likewise.
2172         * modules/getdomainname (Makefile.am): Likewise.
2173         * modules/getgroups (Makefile.am): Likewise.
2174         * modules/gethostname (Makefile.am): Likewise.
2175         * modules/gethrxtime (Makefile.am): Likewise.
2176         * modules/getline (Makefile.am): Likewise.
2177         * modules/getloadavg (Makefile.am): Likewise.
2178         * modules/getlogin_r (Makefile.am): Likewise.
2179         * modules/getndelim2 (Makefile.am): Likewise.
2180         * modules/getopt (Makefile.am): Likewise.
2181         * modules/getpagesize (Makefile.am): Likewise.
2182         * modules/getpass-gnu (Makefile.am): Likewise.
2183         * modules/getpass (Makefile.am): Likewise.
2184         * modules/getsubopt (Makefile.am): Likewise.
2185         * modules/gettime (Makefile.am): Likewise.
2186         * modules/gettimeofday (Makefile.am): Likewise.
2187         * modules/getugroups (Makefile.am): Likewise.
2188         * modules/getusershell (Makefile.am): Likewise.
2189         * modules/glob (Makefile.am): Likewise.
2190         * modules/group-member (Makefile.am): Likewise.
2191         * modules/hard-locale (Makefile.am): Likewise.
2192         * modules/hash (Makefile.am): Likewise.
2193         * modules/hmac-md5 (Makefile.am): Likewise.
2194         * modules/hmac-sha1 (Makefile.am): Likewise.
2195         * modules/human (Makefile.am): Likewise.
2196         * modules/idcache (Makefile.am): Likewise.
2197         * modules/imaxabs (Makefile.am): Likewise.
2198         * modules/imaxdiv (Makefile.am): Likewise.
2199         * modules/inet_ntop (Makefile.am): Likewise.
2200         * modules/inet_pton (Makefile.am): Likewise.
2201         * modules/intprops (Makefile.am): Likewise.
2202         * modules/inttostr (Makefile.am): Likewise.
2203         * modules/inttypes (Makefile.am): Likewise.
2204         * modules/isapipe (Makefile.am): Likewise.
2205         * modules/javaversion (Makefile.am): Likewise.
2206         * modules/lchmod (Makefile.am): Likewise.
2207         * modules/lchown (Makefile.am): Likewise.
2208         * modules/localcharset (Makefile.am): Likewise.
2209         * modules/long-options (Makefile.am): Likewise.
2210         * modules/lstat (Makefile.am): Likewise.
2211         * modules/malloc (Makefile.am): Likewise.
2212         * modules/mathl (Makefile.am): Likewise.
2213         * modules/mbchar (Makefile.am): Likewise.
2214         * modules/md2 (Makefile.am): Likewise.
2215         * modules/md4 (Makefile.am): Likewise.
2216         * modules/md5 (Makefile.am): Likewise.
2217         * modules/memcasecmp (Makefile.am): Likewise.
2218         * modules/memchr (Makefile.am): Likewise.
2219         * modules/memcmp (Makefile.am): Likewise.
2220         * modules/memcoll (Makefile.am): Likewise.
2221         * modules/memcpy (Makefile.am): Likewise.
2222         * modules/memmem (Makefile.am): Likewise.
2223         * modules/memmove (Makefile.am): Likewise.
2224         * modules/mempcpy (Makefile.am): Likewise.
2225         * modules/memrchr (Makefile.am): Likewise.
2226         * modules/memset (Makefile.am): Likewise.
2227         * modules/memxor (Makefile.am): Likewise.
2228         * modules/mkancesdirs (Makefile.am): Likewise.
2229         * modules/mkdir-p (Makefile.am): Likewise.
2230         * modules/mkdir (Makefile.am): Likewise.
2231         * modules/mkdtemp (Makefile.am): Likewise.
2232         * modules/mkstemp (Makefile.am): Likewise.
2233         * modules/mktime (Makefile.am): Likewise.
2234         * modules/modechange (Makefile.am): Likewise.
2235         * modules/mountlist (Makefile.am): Likewise.
2236         * modules/nanosleep (Makefile.am): Likewise.
2237         * modules/obstack (Makefile.am): Likewise.
2238         * modules/openat (Makefile.am): Likewise.
2239         * modules/pagealign_alloc (Makefile.am): Likewise.
2240         * modules/pathmax (Makefile.am): Likewise.
2241         * modules/physmem (Makefile.am): Likewise.
2242         * modules/poll (Makefile.am): Likewise.
2243         * modules/posixtm (Makefile.am): Likewise.
2244         * modules/posixver (Makefile.am): Likewise.
2245         * modules/putenv (Makefile.am): Likewise.
2246         * modules/quote (Makefile.am): Likewise.
2247         * modules/quotearg (Makefile.am): Likewise.
2248         * modules/raise (Makefile.am): Likewise.
2249         * modules/read-file (Makefile.am): Likewise.
2250         * modules/readline (Makefile.am): Likewise.
2251         * modules/readlink (Makefile.am): Likewise.
2252         * modules/readtokens (Makefile.am): Likewise.
2253         * modules/readutmp (Makefile.am): Likewise.
2254         * modules/realloc (Makefile.am): Likewise.
2255         * modules/regex (Makefile.am): Likewise.
2256         * modules/rename-dest-slash (Makefile.am): Likewise.
2257         * modules/rename (Makefile.am): Likewise.
2258         * modules/rijndael (Makefile.am): Likewise.
2259         * modules/rmdir (Makefile.am): Likewise.
2260         * modules/rpmatch (Makefile.am): Likewise.
2261         * modules/safe-read (Makefile.am): Likewise.
2262         * modules/safe-write (Makefile.am): Likewise.
2263         * modules/same-inode (Makefile.am): Likewise.
2264         * modules/same (Makefile.am): Likewise.
2265         * modules/save-cwd (Makefile.am): Likewise.
2266         * modules/savedir (Makefile.am): Likewise.
2267         * modules/setenv (Makefile.am): Likewise.
2268         * modules/settime (Makefile.am): Likewise.
2269         * modules/sha1 (Makefile.am): Likewise.
2270         * modules/sig2str (Makefile.am): Likewise.
2271         * modules/snprintf (Makefile.am): Likewise.
2272         * modules/stat-macros (Makefile.am): Likewise.
2273         * modules/stat-time (Makefile.am): Likewise.
2274         * modules/stdbool (Makefile.am): Likewise.
2275         * modules/stdint (Makefile.am): Likewise.
2276         * modules/stdlib-safer (Makefile.am): Likewise.
2277         * modules/stpcpy (Makefile.am): Likewise.
2278         * modules/stpncpy (Makefile.am): Likewise.
2279         * modules/strcase (Makefile.am): Likewise.
2280         * modules/strcasestr (Makefile.am): Likewise.
2281         * modules/strchrnul (Makefile.am): Likewise.
2282         * modules/strcspn (Makefile.am): Likewise.
2283         * modules/strdup (Makefile.am): Likewise.
2284         * modules/strerror (Makefile.am): Likewise.
2285         * modules/strftime (Makefile.am): Likewise.
2286         * modules/strndup (Makefile.am): Likewise.
2287         * modules/strnlen (Makefile.am): Likewise.
2288         * modules/strpbrk (Makefile.am): Likewise.
2289         * modules/strsep (Makefile.am): Likewise.
2290         * modules/strstr (Makefile.am): Likewise.
2291         * modules/strtod (Makefile.am): Likewise.
2292         * modules/strtoimax (Makefile.am): Likewise.
2293         * modules/strtok_r (Makefile.am): Likewise.
2294         * modules/strtol (Makefile.am): Likewise.
2295         * modules/strtoll (Makefile.am): Likewise.
2296         * modules/strtoul (Makefile.am): Likewise.
2297         * modules/strtoull (Makefile.am): Likewise.
2298         * modules/strtoumax (Makefile.am): Likewise.
2299         * modules/strverscmp (Makefile.am): Likewise.
2300         * modules/sys_socket (Makefile.am): Likewise.
2301         * modules/sys_stat (Makefile.am): Likewise.
2302         * modules/sysexits (Makefile.am): Likewise.
2303         * modules/time_r (Makefile.am): Likewise.
2304         * modules/timegm (Makefile.am): Likewise.
2305         * modules/timespec (Makefile.am): Likewise.
2306         * modules/tmpfile-safer (Makefile.am): Likewise.
2307         * modules/trim (Makefile.am): Likewise.
2308         * modules/unistd-safer (Makefile.am): Likewise.
2309         * modules/unlinkdir (Makefile.am): Likewise.
2310         * modules/unlocked-io (Makefile.am): Likewise.
2311         * modules/userspec (Makefile.am): Likewise.
2312         * modules/utime (Makefile.am): Likewise.
2313         * modules/utimecmp (Makefile.am): Likewise.
2314         * modules/utimens (Makefile.am): Likewise.
2315         * modules/vasnprintf (Makefile.am): Likewise.
2316         * modules/vasprintf (Makefile.am): Likewise.
2317         * modules/vsnprintf (Makefile.am): Likewise.
2318         * modules/xalloc (Makefile.am): Likewise.
2319         * modules/xgetcwd (Makefile.am): Likewise.
2320         * modules/xnanosleep (Makefile.am): Likewise.
2321         * modules/xreadlink (Makefile.am): Likewise.
2322         * modules/xstrtod (Makefile.am): Likewise.
2323         * modules/xstrtol (Makefile.am): Likewise.
2324         * modules/xstrtold (Makefile.am): Likewise.
2325         * modules/yesno (Makefile.am): Likewise.
2326         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
2327
2328 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2329
2330         * modules/error (Makefile.am): Distribute files through
2331         EXTRA_DIST, not lib_SOURCES.
2332
2333 2006-10-12  Eric Blake  <ebb9@byu.net>
2334
2335         * modules/error (Makefile.am): Distribute files in /lib.
2336         * modules/obstack (Makefile.am): Likewise.
2337
2338 2006-10-12  Bruno Haible  <bruno@clisp.org>
2339
2340         * modules/acl (Makefile.am): Distribute all files in lib/ through
2341         EXTRA_DIST.
2342         * modules/arcfour (Makefile.am): Likewise.
2343         * modules/arctwo (Makefile.am): Likewise.
2344         * modules/argmatch (Makefile.am): Likewise.
2345         * modules/argz (Makefile.am): Likewise.
2346         * modules/atexit (Makefile.am): Likewise.
2347         * modules/backupfile (Makefile.am): Likewise.
2348         * modules/c-strtod (Makefile.am): Likewise.
2349         * modules/c-strtold (Makefile.am): Likewise.
2350         * modules/calloc (Makefile.am): Likewise.
2351         * modules/canon-host (Makefile.am): Likewise.
2352         * modules/canonicalize (Makefile.am): Likewise.
2353         * modules/chdir-long (Makefile.am): Likewise.
2354         * modules/chdir-safer (Makefile.am): Likewise.
2355         * modules/check-version (Makefile.am): Likewise.
2356         * modules/chown (Makefile.am): Likewise.
2357         * modules/cloexec (Makefile.am): Likewise.
2358         * modules/close-stream (Makefile.am): Likewise.
2359         * modules/closeout (Makefile.am): Likewise.
2360         * modules/crc (Makefile.am): Likewise.
2361         * modules/cycle-check (Makefile.am): Likewise.
2362         * modules/des (Makefile.am): Likewise.
2363         * modules/dirfd (Makefile.am): Likewise.
2364         * modules/dirname (Makefile.am): Likewise.
2365         * modules/dup2 (Makefile.am): Likewise.
2366         * modules/euidaccess (Makefile.am): Likewise.
2367         * modules/exclude (Makefile.am): Likewise.
2368         * modules/exitfail (Makefile.am): Likewise.
2369         * modules/fcntl-safer (Makefile.am): Likewise.
2370         * modules/file-type (Makefile.am): Likewise.
2371         * modules/fileblocks (Makefile.am): Likewise.
2372         * modules/filemode (Makefile.am): Likewise.
2373         * modules/filenamecat (Makefile.am): Likewise.
2374         * modules/fnmatch (Makefile.am): Likewise.
2375         * modules/fopen-safer (Makefile.am): Likewise.
2376         * modules/fpending (Makefile.am): Likewise.
2377         * modules/fprintftime (Makefile.am): Likewise.
2378         * modules/free (Makefile.am): Likewise.
2379         * modules/fsusage (Makefile.am): Likewise.
2380         * modules/ftruncate (Makefile.am): Likewise.
2381         * modules/fts (Makefile.am): Likewise.
2382         * modules/gc (Makefile.am): Likewise.
2383         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2384         * modules/getaddrinfo (Makefile.am): Likewise.
2385         * modules/getcwd (Makefile.am): Likewise.
2386         * modules/getdelim (Makefile.am): Likewise.
2387         * modules/getdomainname (Makefile.am): Likewise.
2388         * modules/getgroups (Makefile.am): Likewise.
2389         * modules/gethostname (Makefile.am): Likewise.
2390         * modules/gethrxtime (Makefile.am): Likewise.
2391         * modules/getline (Makefile.am): Likewise.
2392         * modules/getloadavg (Makefile.am): Likewise.
2393         * modules/getlogin_r (Makefile.am): Likewise.
2394         * modules/getopt (Makefile.am): Likewise.
2395         * modules/getpass (Makefile.am): Likewise.
2396         * modules/getpass-gnu (Makefile.am): Likewise.
2397         * modules/getsubopt (Makefile.am): Likewise.
2398         * modules/gettime (Makefile.am): Likewise.
2399         * modules/gettimeofday (Makefile.am): Likewise.
2400         * modules/getugroups (Makefile.am): Likewise.
2401         * modules/getusershell (Makefile.am): Likewise.
2402         * modules/glob (Makefile.am): Likewise.
2403         * modules/group-member (Makefile.am): Likewise.
2404         * modules/hard-locale (Makefile.am): Likewise.
2405         * modules/hash (Makefile.am): Likewise.
2406         * modules/hmac-md5 (Makefile.am): Likewise.
2407         * modules/hmac-sha1 (Makefile.am): Likewise.
2408         * modules/human (Makefile.am): Likewise.
2409         * modules/idcache (Makefile.am): Likewise.
2410         * modules/imaxabs (Makefile.am): Likewise.
2411         * modules/imaxdiv (Makefile.am): Likewise.
2412         * modules/inet_ntop (Makefile.am): Likewise.
2413         * modules/inet_pton (Makefile.am): Likewise.
2414         * modules/inttostr (Makefile.am): Likewise.
2415         * modules/isapipe (Makefile.am): Likewise.
2416         * modules/lchown (Makefile.am): Likewise.
2417         * modules/long-options (Makefile.am): Likewise.
2418         * modules/lstat (Makefile.am): Likewise.
2419         * modules/malloc (Makefile.am): Likewise.
2420         * modules/mathl (Makefile.am): Likewise.
2421         * modules/mbchar (Makefile.am): Likewise.
2422         * modules/md2 (Makefile.am): Likewise.
2423         * modules/md4 (Makefile.am): Likewise.
2424         * modules/md5 (Makefile.am): Likewise.
2425         * modules/memcasecmp (Makefile.am): Likewise.
2426         * modules/memchr (Makefile.am): Likewise.
2427         * modules/memcmp (Makefile.am): Likewise.
2428         * modules/memcoll (Makefile.am): Likewise.
2429         * modules/memcpy (Makefile.am): Likewise.
2430         * modules/memmem (Makefile.am): Likewise.
2431         * modules/memmove (Makefile.am): Likewise.
2432         * modules/mempcpy (Makefile.am): Likewise.
2433         * modules/memrchr (Makefile.am): Likewise.
2434         * modules/memset (Makefile.am): Likewise.
2435         * modules/memxor (Makefile.am): Likewise.
2436         * modules/mkancesdirs (Makefile.am): Likewise.
2437         * modules/mkdir (Makefile.am): Likewise.
2438         * modules/mkdir-p (Makefile.am): Likewise.
2439         * modules/mkdtemp (Makefile.am): Likewise.
2440         * modules/mkstemp (Makefile.am): Likewise.
2441         * modules/mktime (Makefile.am): Likewise.
2442         * modules/modechange (Makefile.am): Likewise.
2443         * modules/mountlist (Makefile.am): Likewise.
2444         * modules/nanosleep (Makefile.am): Likewise.
2445         * modules/openat (Makefile.am): Likewise.
2446         * modules/pagealign_alloc (Makefile.am): Likewise.
2447         * modules/physmem (Makefile.am): Likewise.
2448         * modules/poll (Makefile.am): Likewise.
2449         * modules/posixtm (Makefile.am): Likewise.
2450         * modules/posixver (Makefile.am): Likewise.
2451         * modules/putenv (Makefile.am): Likewise.
2452         * modules/quote (Makefile.am): Likewise.
2453         * modules/quotearg (Makefile.am): Likewise.
2454         * modules/raise (Makefile.am): Likewise.
2455         * modules/read-file (Makefile.am): Likewise.
2456         * modules/readline (Makefile.am): Likewise.
2457         * modules/readlink (Makefile.am): Likewise.
2458         * modules/readtokens (Makefile.am): Likewise.
2459         * modules/readutmp (Makefile.am): Likewise.
2460         * modules/realloc (Makefile.am): Likewise.
2461         * modules/regex (Makefile.am): Likewise.
2462         * modules/rename (Makefile.am): Likewise.
2463         * modules/rename-dest-slash (Makefile.am): Likewise.
2464         * modules/rijndael (Makefile.am): Likewise.
2465         * modules/rmdir (Makefile.am): Likewise.
2466         * modules/rpmatch (Makefile.am): Likewise.
2467         * modules/safe-read (Makefile.am): Likewise.
2468         * modules/safe-write (Makefile.am): Likewise.
2469         * modules/same (Makefile.am): Likewise.
2470         * modules/save-cwd (Makefile.am): Likewise.
2471         * modules/savedir (Makefile.am): Likewise.
2472         * modules/setenv (Makefile.am): Likewise.
2473         * modules/settime (Makefile.am): Likewise.
2474         * modules/sha1 (Makefile.am): Likewise.
2475         * modules/sig2str (Makefile.am): Likewise.
2476         * modules/snprintf (Makefile.am): Likewise.
2477         * modules/stdlib-safer (Makefile.am): Likewise.
2478         * modules/stpcpy (Makefile.am): Likewise.
2479         * modules/stpncpy (Makefile.am): Likewise.
2480         * modules/strcase (Makefile.am): Likewise.
2481         * modules/strcasestr (Makefile.am): Likewise.
2482         * modules/strchrnul (Makefile.am): Likewise.
2483         * modules/strcspn (Makefile.am): Likewise.
2484         * modules/strdup (Makefile.am): Likewise.
2485         * modules/strerror (Makefile.am): Likewise.
2486         * modules/strftime (Makefile.am): Likewise.
2487         * modules/strndup (Makefile.am): Likewise.
2488         * modules/strnlen (Makefile.am): Likewise.
2489         * modules/strpbrk (Makefile.am): Likewise.
2490         * modules/strsep (Makefile.am): Likewise.
2491         * modules/strstr (Makefile.am): Likewise.
2492         * modules/strtod (Makefile.am): Likewise.
2493         * modules/strtoimax (Makefile.am): Likewise.
2494         * modules/strtok_r (Makefile.am): Likewise.
2495         * modules/strtol (Makefile.am): Likewise.
2496         * modules/strtoll (Makefile.am): Likewise.
2497         * modules/strtoul (Makefile.am): Likewise.
2498         * modules/strtoull (Makefile.am): Likewise.
2499         * modules/strtoumax (Makefile.am): Likewise.
2500         * modules/strverscmp (Makefile.am): Likewise.
2501         * modules/time_r (Makefile.am): Likewise.
2502         * modules/timegm (Makefile.am): Likewise.
2503         * modules/tmpfile-safer (Makefile.am): Likewise.
2504         * modules/unistd-safer (Makefile.am): Likewise.
2505         * modules/unlinkdir (Makefile.am): Likewise.
2506         * modules/userspec (Makefile.am): Likewise.
2507         * modules/utime (Makefile.am): Likewise.
2508         * modules/utimecmp (Makefile.am): Likewise.
2509         * modules/utimens (Makefile.am): Likewise.
2510         * modules/vasnprintf (Makefile.am): Likewise.
2511         * modules/vasprintf (Makefile.am): Likewise.
2512         * modules/vsnprintf (Makefile.am): Likewise.
2513         * modules/xalloc (Makefile.am): Likewise.
2514         * modules/xgetcwd (Makefile.am): Likewise.
2515         * modules/xnanosleep (Makefile.am): Likewise.
2516         * modules/xreadlink (Makefile.am): Likewise.
2517         * modules/xstrtod (Makefile.am): Likewise.
2518         * modules/xstrtol (Makefile.am): Likewise.
2519         * modules/xstrtold (Makefile.am): Likewise.
2520         * modules/yesno (Makefile.am): Likewise.
2521
2522 2006-10-12  Jim Meyering  <jim@meyering.net>
2523
2524         * m4/getloadavg.m4: Revert the change below.
2525
2526         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
2527         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
2528         fail with a symlink, which is what coreutils' ./bootstrap now
2529         creates by default.
2530
2531 2006-10-12  Bruno Haible  <bruno@clisp.org>
2532
2533         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
2534         mingw.
2535         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
2536         MSVC and mingw explicitly.
2537
2538 2006-10-11  Simon Josefsson  <jas@extundo.com>
2539             Bruno Haible  <bruno@clisp.org>
2540
2541         Add support for multiple gnulib-tool invocations in the scope of a
2542         single configure.ac file.
2543         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
2544         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
2545         with the same contents as the _LIBADD variable.
2546         (func_emit_initmacro_start, func_emit_initmacro_end,
2547         func_emit_initmacro_done): New functions.
2548         (func_import, func_create_testdir): Invoke them. Allow the identifiers
2549         gl_LIBOBJS and gl_LTLIBOBJS.
2550
2551 2006-10-11  Bruno Haible  <bruno@clisp.org>
2552
2553         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
2554         (func_create_testdir): Don't create po/Makefile.am, don't invoke
2555         autoreconf. Instead, invoke autopoint explicitly but move back the
2556         *.m4 files from gnulib.
2557
2558 2006-10-11  Bruno Haible  <bruno@clisp.org>
2559
2560         * gnulib-tool (func_usage): Make module names after --create-testdir
2561         optional.
2562         (func_create_testdir): If no module was specified, use nearly all
2563         modules.
2564
2565 2006-10-12  Jim Meyering  <jim@meyering.net>
2566
2567         Big performance improvement for fts-based tools that use FTS_NOSTAT.
2568         Avoid spurious inode-mismatch problems on non-POSIX file systems.
2569         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
2570         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
2571         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
2572         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
2573         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
2574         (fts_set_stat_required): New function.
2575         (fts_open): Defer the calls to fts_stat, if possible or requested.
2576         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
2577         into fts_stat itself.
2578         (fts_read): Perform any required (deferred) fts_stat call.
2579         (fts_build): Likewise, for the directory we're about to open and read.
2580         In the readdir loop, carefully decide whether each entry will require
2581         an eventual call to fts_stat, using dirent.d_type info if available.
2582         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
2583         a command line argument into this function.  Update all callers.
2584         Map a return value of FTS_DOT to FTS_D for a command line argument.
2585         * modules/fts (Depends-on): Add d-type.  Alphabetize.
2586         Thanks to Miklos Szeredi for his tenacity and for the initial
2587         bug report about "find" failing on a FUSE-based file system.
2588
2589         * lib/fts.c (fts_open): Use consistent indentation.
2590
2591 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2592
2593         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
2594         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
2595         reported by Jim Meyering.  All uses of cache variables renamed
2596         to match Autoconf's.
2597         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
2598         the other one.
2599
2600         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
2601         Fix misspelling in diagnostic.
2602
2603 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2604
2605         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
2606         defined.  Problem reported by Matthew Woehlke.
2607
2608         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
2609         Add support for Tandem NonStop R series.
2610         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
2611         Use new macro.
2612
2613         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
2614         (has_trailing_slash): Omit size arg; all callers changed.
2615         Omit 'inline', since it doesn't help performance and we'd
2616         need to configure it.
2617         Don't count //, ///, etc. as having a trailing slash.
2618         As a side effect, this removes a C99ism reported by Matthew Woehlke.
2619         (rpl_rename_dest_slash): On failure, use rename's errno rather
2620         than (in some cases) an incorrect or junk errno.
2621         Simplify code by removing need to compute length; this does
2622         cause it to make two passes instead of one over the file name,
2623         but it's worth it.
2624
2625         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
2626         change, since Autoconf's version may no longer be appropriate now
2627         that we are using CVS Autoconf's version.  Add support for Tandem.
2628
2629 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2630             Bruno Haible  <bruno@clisp.org>
2631
2632         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
2633         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
2634         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
2635         gl_AC_TYPE_LONG_LONG.
2636
2637         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
2638         instead of HAVE_LONG_LONG.
2639         * lib/printf-args.c (printf_fetchargs): Likewise.
2640         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
2641         * lib/vasnprintf.c (VASNPRINTF): Likewise.
2642         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
2643         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
2644         gl_AC_TYPE_LONG_LONG.
2645
2646 2006-10-11  Bruno Haible  <bruno@clisp.org>
2647
2648         * m4/longlong.m4: Add comments.
2649         * m4/ulonglong.m4: Likewise.
2650
2651 2006-10-10  Bruno Haible  <bruno@clisp.org>
2652
2653         Make it possible to #define stpcpy, strdup to aliases.
2654         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
2655         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
2656
2657 2006-10-10  Bruno Haible  <bruno@clisp.org>
2658
2659         Make it possible to #define gcd to an alias.
2660         * lib/gcd.c: Include config.h.
2661
2662 2006-10-10  Bruno Haible  <bruno@clisp.org>
2663
2664         Make it possible to #define c_isascii to an alias.
2665         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
2666         defined. Undefine the macros before defining them, to avoid gcc
2667         warnings.
2668         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
2669         define NO_C_CTYPE_MACROS early.
2670
2671 2006-10-10  Bruno Haible  <bruno@clisp.org>
2672
2673         Make it possible to #define set_program_name to an alias.
2674         * lib/progname.c: Don't undefine set_program_name; instead, undefine
2675         ENABLE_RELOCATABLE early.
2676
2677 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
2678
2679         Port to Tandem NSK OSS, which has 64-bit signed int but at most
2680         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
2681         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
2682         More generally, don't assume that 64-bit signed int is available
2683         if unsigned int is, and vice versa.
2684         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
2685         unsigned symbols, not on their signed counterparts.
2686         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
2687         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
2688         (UINT64_C, UINTMAX_C):
2689         Likewise.
2690         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
2691         unsigned counterparts.
2692         (Have_long_long, Unsigned): New macros.
2693         (Int): Renamed from INT.
2694         (strtoimax): Use the new macros.
2695         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
2696         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
2697         * modules/inttypes (inttypes.h): Substitute
2698         HAVE_UNSIGNED_LONG_LONG_INT.
2699         * modules/stdint (stdint.h): Likewise.
2700         (Files): Add m4/ulonglong.m4.
2701
2702 2006-10-10  Bruno Haible  <bruno@clisp.org>
2703
2704         Fix a gcc -Wshadow warning.
2705         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
2706         to 'bucket'.
2707         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
2708         gl_linked_indexof_from_to): Likewise.
2709         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
2710         Likewise.
2711         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
2712         Likewise.
2713         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
2714         Reported by Eric Blake.
2715
2716 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2717
2718         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
2719         for NetBSD.  Problem reported by Bruno Haible.
2720
2721 2006-10-09  Jim Meyering  <jim@meyering.net>
2722
2723         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
2724         Patch from Bruno Haible.
2725
2726 2006-10-09  Jim Meyering  <jim@meyering.net>
2727
2728         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
2729         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
2730         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
2731
2732 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
2733
2734         Don't include <config.h> twice; this doesn't work in some cases,
2735         e.g., when config.h has "#define intmax_t long long int" and
2736         we include <config.h>, <inttypes.h>, <config.h> in that order.
2737         Problem reported by Matthew Woehlke in:
2738         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
2739         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
2740         * lib/fts-cycle.c: Don't include config.h.
2741         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
2742         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
2743         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
2744         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
2745         inttypes.h.
2746         * lib/xstrtoumax.c: Likewise.
2747         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
2748         __strtol and the like, so that this module is more like its siblings.
2749         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
2750         Remove; no longer needed now that we assume gnulib inttypes.h.
2751
2752 2006-10-08  Bruno Haible  <bruno@clisp.org>
2753
2754         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
2755         option.
2756
2757 2006-10-07  Jim Meyering  <jim@meyering.net>
2758
2759         * modules/inttypes (inttypes.h): Revert what seems to have been
2760         an inadvertent part of today's change: use "|", not "/" in the
2761         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
2762
2763 2006-10-07  Bruno Haible  <bruno@clisp.org>
2764
2765         * modules/sublist: New file.
2766
2767 2006-10-07  Bruno Haible  <bruno@clisp.org>
2768
2769         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
2770         * modules/argz (argz.h): Likewise.
2771         * modules/arpa_inet (arpa/inet.h): Likewise.
2772         * modules/byteswap (byteswap.h): Likewise.
2773         * modules/configmake (configmake.h): Likewise.
2774         * modules/fcntl (fcntl.h): Likewise.
2775         * modules/fnmatch (fnmatch.h): Likewise.
2776         * modules/getopt (getopt.h): Likewise.
2777         * modules/glob (glob.h): Likewise.
2778         * modules/inttypes (inttypes.h): Likewise.
2779         * modules/netinet_in (netinet/in.h): Likewise.
2780         * modules/poll (poll.h): Likewise.
2781         * modules/stdbool (stdbool.h): Likewise.
2782         * modules/stdint (stdint.h): Likewise.
2783         * modules/sys_select (sys/select.h): Likewise.
2784         * modules/sys_socket (sys/socket.h): Likewise.
2785         * modules/sys_stat (sys/stat.h): Likewise.
2786         * modules/sysexits (sysexits.h): Likewise.
2787         * modules/unistd (unistd.h): Likewise.
2788         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2789         Add a "DO NOT EDIT" comment to the generated file.
2790         (func_import): Likewise for gnulib-comp.m4.
2791
2792 2006-10-07  Bruno Haible  <bruno@clisp.org>
2793
2794         * lib/gl_sublist.h: New file.
2795         * lib/gl_sublist.c: New file.
2796
2797 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
2798
2799         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
2800         name (relative to the original working directory) and the file
2801         name component (relative to the temporary working directory).  All
2802         callers changed.
2803         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
2804         * lib/mkdir-p.c (make_dir_parents): Likewise.
2805         * lib/mkdir-p.h (make_dir_parents): Likewise.
2806
2807 2006-10-06  Eric Blake  <ebb9@byu.net>
2808
2809         Define several macros for use by the clean-temp module.
2810         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
2811         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
2812         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
2813
2814         * lib/clean-temp.h (close_stream_temp): New declaration.
2815         * lib/clean-temp.c (includes): Pull in headers according to what
2816         other modules are in use.
2817         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
2818
2819 2006-10-06  Bruno Haible  <bruno@clisp.org>
2820
2821         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
2822         instead of fopen, fwriteerror.
2823
2824 2006-10-06  Bruno Haible  <bruno@clisp.org>
2825
2826         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
2827         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
2828         int.
2829         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
2830         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
2831         Return an error indicator.
2832         Suggested by Eric Blake.
2833
2834 2006-10-06  Bruno Haible  <bruno@clisp.org>
2835
2836         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
2837         Reported by Eric Blake.
2838
2839 2006-10-06  Bruno Haible  <bruno@clisp.org>
2840
2841         * modules/closeout (Description): Mention stderr too.
2842
2843 2006-10-06  Bruno Haible  <bruno@clisp.org>
2844         and Paul Eggert  <eggert@cs.ucla.edu>
2845
2846         * lib/closeout.c (close_stdout): Also close stderr.
2847         * lib/closeout.h: Update comment.
2848
2849 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
2850
2851         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
2852         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
2853         * lib/dirchownmod.c: Include lchown.h.
2854         * lib/lchown.c: Don't include files that lchown.h now includes.
2855         Don't declare chown, since lchown.h now does that.
2856         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
2857         (lchown): Define to rpl_chown if lchown is declared but
2858         does not exist.  Declare using a prototype if lchown is not
2859         declared.  Add a copyright notice.
2860         * lib/mkstemp.h: Include <unistd.h>.
2861         * lib/openat.c: Include lchown.h.
2862
2863         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
2864         we now test for that separately.
2865         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
2866         rather than O_NOFOLLOW, when testing whether it's possible to
2867         avoid a race condition reliably.
2868         * lib/savewd.c (savewd_chdir): Likewise.
2869
2870         Remove macros that are no longer needed now that stdint.h is
2871         reliable.
2872         * lib/fsusage.c (UINTMAX_MAX): Remove.
2873         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
2874         * lib/utimecmp.c (SIZE_MAX): Remove.
2875
2876         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
2877
2878         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
2879         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
2880         O_NOATIME works.
2881
2882 2006-10-05  Bruno Haible  <bruno@clisp.org>
2883
2884         * lib/gl_list.h (gl_sortedlist_search_from_to,
2885         gl_sortedlist_indexof_from_to): New declarations.
2886         (gl_list_implementation): New fields sortedlist_search_from_to,
2887         sortedlist_indexof_from_to.
2888         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
2889         inline functions.
2890         * lib/gl_list.c (gl_sortedlist_search_from_to,
2891         gl_sortedlist_indexof_from_to): New functions.
2892         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
2893         function.
2894         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
2895         (gl_array_sortedlist_search_from_to): New function.
2896         (gl_array_list_implementation): Update.
2897         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
2898         function.
2899         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
2900         (gl_carray_sortedlist_search_from_to): New function.
2901         (gl_carray_list_implementation): Update.
2902         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
2903         gl_linked_sortedlist_indexof_from_to): New functions.
2904         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2905         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2906         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
2907         gl_tree_sortedlist_indexof_from_to): New functions.
2908         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2909         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2910         Update.
2911         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2912         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
2913         Update.
2914
2915 2006-10-05  Bruno Haible  <bruno@clisp.org>
2916
2917         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
2918         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
2919         (struct gl_list_implementation): Add fields search_from_to,
2920         indexof_from_to. Remove fields search, indexof.
2921         (gl_list_search): Use the search_from_to method.
2922         (gl_list_search_from, gl_list_search_from_to): New functions.
2923         (gl_list_indexof): Use the indexof_from_to method.
2924         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2925         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
2926         (gl_list_search_from, gl_list_search_from_to): New functions.
2927         (gl_list_indexof): Use the indexof_from_to method.
2928         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2929         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
2930         gl_array_indexof. Add start_index, end_index arguments.
2931         (gl_array_search_from_to): Renamed from gl_array_search. Add
2932         start_index, end_index arguments.
2933         (gl_array_remove, gl_array_list_implementation): Update.
2934         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
2935         gl_carray_indexof. Add start_index, end_index arguments.
2936         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
2937         start_index, end_index arguments.
2938         (gl_carray_remove, gl_carray_list_implementation): Update.
2939         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
2940         gl_linked_search. Add start_index, end_index arguments.
2941         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
2942         start_index, end_index arguments.
2943         (gl_linked_remove): Update.
2944         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2945         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2946         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
2947         field to 'size_t'.
2948         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
2949         gl_tree_search. Add start_index, end_index arguments.
2950         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2951         start_index, end_index arguments.
2952         (gl_tree_remove): Update.
2953         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2954         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2955         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
2956         function.
2957         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
2958         gl_tree_search. Add start_index, end_index arguments.
2959         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2960         start_index, end_index arguments.
2961         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2962         Update.
2963         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
2964
2965 2006-10-05  Bruno Haible  <bruno@clisp.org>
2966
2967         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
2968
2969         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
2970         fwriteerror_temp): New declarations.
2971         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
2972         (descriptors): New variable.
2973         (cleanup): First, close the descriptors.
2974         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
2975         fclose_temp, fwriteerror_temp): New functions.
2976
2977 2006-10-04  Jim Meyering  <jim@meyering.net>
2978
2979         * lib/fts.c (fts_open): Tiny comment change.
2980
2981 2006-10-04  Bruno Haible  <bruno@clisp.org>
2982
2983         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
2984         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
2985         gl_LOCK_BODY.
2986         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
2987         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
2988         gl_LOCK_EARLY_BODY.
2989         (gl_LOCK): Require gl_LOCK_BODY.
2990
2991 2006-10-04  Bruno Haible  <bruno@clisp.org>
2992
2993         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
2994         (gl_oset_search_atleast): New declaration.
2995         (struct gl_oset_implementation): Add field 'search_atleast'.
2996         (gl_oset_search_atleast): New inline function.
2997         * lib/gl_oset.c (gl_oset_search_atleast): New function.
2998         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
2999         (gl_array_oset_implementation): Update.
3000         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
3001         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
3002         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
3003
3004 2006-10-04  Bruno Haible  <bruno@clisp.org>
3005
3006         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
3007
3008 2006-10-03  Bruno Haible  <bruno@clisp.org>
3009
3010         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
3011         from gl_avltreehash_list_implementation.
3012
3013 2006-10-03  Bruno Haible  <bruno@clisp.org>
3014
3015         * lib/gl_oset.c (gl_oset_add): Fix return type.
3016
3017 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
3018
3019         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
3020
3021 2006-10-02  Eric Blake  <ebb9@byu.net>
3022
3023         * modules/strnlen (Depends-on): Add extensions.
3024
3025 2006-10-02  Eric Blake  <ebb9@byu.net>
3026
3027         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
3028         definition in 2.60+.
3029
3030 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
3031
3032         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
3033         checks.
3034
3035 2006-10-02  Bruno Haible  <bruno@clisp.org>
3036
3037         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
3038         to the AUTOMAKE_OPTIONS.
3039         Reported by Jim Meyering.
3040
3041 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
3042
3043         Work around bug in Solaris 10 /proc file system:
3044         /proc/self/fd/NNN/.. isn't the parent directory of
3045         the directory whose file descriptor is NNN.  This needs to
3046         be worked around at run time, not compile time, since a
3047         program might be built on Solaris 8, where things work, and
3048         run on Solaris 10.
3049         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
3050         to use the following interface instead:
3051         (OPENAT_BUFFER_SIZE): New macro.
3052         (openat_proc_name): New function.
3053         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
3054         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
3055         Likewise.
3056         * lib/openat-proc.c: New file.
3057         * modules/openat (Files): Add lib/openat-proc.c.
3058         (Depends-on): Add same-inode, stdbool.
3059         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
3060
3061 2006-09-29  Bruno Haible  <bruno@clisp.org>
3062
3063         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
3064         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
3065         argument. Set stdout_closed before testing for ferror, not after.
3066         (fwriteerror, fwriteerror_no_ebadf): New functions.
3067
3068 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3069
3070         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
3071
3072 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
3073
3074         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
3075         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
3076
3077 2006-09-28  Jim Meyering  <jim@meyering.net>
3078
3079         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
3080         Include <unistd.h>.
3081
3082 2006-09-28  Bruno Haible  <bruno@clisp.org>
3083
3084         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
3085         * modules/linkedhash-list (Depends-on): Likewise.
3086         * modules/rbtreehash-list (Depends-on): Likewise.
3087
3088 2006-09-28  Bruno Haible  <bruno@clisp.org>
3089
3090         * lib/strndup.h: Simplify the redefinition of strndup.
3091         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
3092         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
3093
3094 2006-09-28  Bruno Haible  <bruno@clisp.org>
3095
3096         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
3097         * lib/gl_linkedhash_list.c: Likewise.
3098         * lib/gl_rbtreehash_list.c: Likewise.
3099
3100 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
3101
3102         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
3103         getaddrinfo.
3104
3105         * lib/__fpending.h: Don't include <stdio_ext.h> unless
3106         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
3107         it causes <stdio_ext.h> to cause a compile-time error.
3108         Problem reported by Nelson H. F. Beebe.
3109         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
3110         of HAVE_DECL___PENDING.
3111
3112         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
3113         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
3114         declaration.
3115
3116 2006-09-27  Jim Meyering  <jim@meyering.net>
3117
3118         This file could end up with a definition for a function
3119         named __strndup, rather than rpl_strndup on a system with
3120         incomplete weak_alias support.
3121         * lib/strndup.c (strndup): Rename from __strndup.
3122         Remove #defines that used to map __strndup to strndup.
3123         Don't use K&R prototypes.
3124         Remove LIBC-related code, since this file is not sync'd with glibc.
3125         * lib/strndup.h: Revamp, accordingly.
3126         * m4/strndup.m4: Modernize.
3127
3128 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
3129
3130         * modules/savewd (Depends-on): Add 'raise'.
3131         * lib/savewd.c: Include <signal.h>, for 'raise'.
3132
3133 2006-09-26  Jim Meyering  <jim@meyering.net>
3134
3135         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
3136         when we detect Darwin 8.7.0's acl_get_file bug.
3137         Rearrange to perform the new (below) run-test while $LIBS
3138         contains any acl-related library.  Set USE_ACL at the end.
3139         (gl_ACL_GET_FILE): New function.
3140
3141 2006-09-26  Eric Blake  <ebb9@byu.net>
3142
3143         * lib/verror.c: Include <config.h> unconditionally.
3144
3145 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
3146
3147         * modules/clock-time (Maintainer): Add self.
3148         * modules/getlogin_r (Depends-on): Add extensions.
3149
3150 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3151
3152         * modules/clock-time: New module.
3153         * modules/nanosleep (Depends-on): Add clock-time.
3154         * modules/gethrxtime (Depends-on): Likewise.
3155         * modules/gettime (Depends-on): Likewise.
3156         * modules/settime (Depends-on): Likewise.
3157
3158         * modules/fts-lgpl: Depend on openat.
3159         * modules/mkancesdirs: Depend on savewd.
3160         * modules/mkdir-p: Likewise.
3161
3162 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3163
3164         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
3165
3166         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
3167         `gl_have_arbitrary_file_name_length_limit' to
3168         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
3169         actually works between configure runs.
3170
3171 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3172             Bruno Haible  <bruno@clisp.org>
3173
3174         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
3175
3176 2006-09-25  Jim Meyering  <jim@meyering.net>
3177
3178         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
3179         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
3180
3181 2006-09-25  Eric Blake  <ebb9@byu.net>
3182
3183         * gnulib-tool (func_import, func_create_testdir): Fix typos in
3184         exec's in 2006-09-18 patch when shuffling fds.
3185
3186 2006-09-25  Bruno Haible  <bruno@clisp.org>
3187
3188         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
3189         Reported by Jim Meyering.
3190
3191 2006-09-24  Jim Meyering  <jim@meyering.net>
3192
3193         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
3194         compare a pointer against a literal "0".  That caused failures with
3195         at least HP-UX's hpcc.
3196
3197 2006-09-22  Simon Josefsson  <jas@extundo.com>
3198
3199         * modules/gc-sha1:
3200         * modules/gc-md4:
3201         * modules/gc-hmac-sha1:
3202         * modules/gc-hmac-md5:
3203         * modules/gc-des:
3204         * modules/gc-arcfour: Distribute more files.
3205
3206 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3207
3208         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
3209         (gl_linked_iterator_from_to): Initialize struct completely.
3210         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
3211         (gl_tree_iterator_from_to): Likewise
3212         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
3213         * lib/gl_array_list.c [lint] (gl_array_iterator)
3214         (gl_array_iterator_from_to): Likewise.
3215         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
3216         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
3217         (gl_carray_iterator_from_to): Likewise.
3218
3219         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
3220         * lib/md4.c (md4_process_block): Remove unused variable.
3221         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
3222         parentheses for clarity.
3223
3224 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3225
3226         * modules/bison-i18n (Depends-on): Add gettext.
3227
3228 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3229
3230         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
3231         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
3232         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
3233         also add missing comma that caused broken test.
3234         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
3235         stdlib.h, for `abort'.
3236         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
3237         variables.
3238         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
3239         include unistd.h if present, for `rmdir'.
3240         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
3241         variables.
3242         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
3243         in the process include standard headers for prototypes.
3244         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
3245         gets declared on GNU/Linux.
3246         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
3247         unistd.h, for `rmdir'.
3248         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
3249
3250         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
3251         always true.
3252         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
3253
3254         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
3255
3256 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3257
3258         * gnulib-tool (func_version): Create output all at once.  This
3259         may help avoid triggering unnecessary SIGPIPEs, and at any
3260         rate it doesn't hurt.
3261
3262 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3263             Bruno Haible  <bruno@clisp.org>
3264
3265         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
3266         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
3267         * m4/signed.m4 (bh_C_SIGNED): Likewise.
3268
3269         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
3270         (gl_FUNC_VASPRINTF): Invoke it.
3271
3272 2006-09-22  Bruno Haible  <bruno@clisp.org>
3273
3274         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
3275         getloadavg.c as first argument.
3276
3277 2006-09-22  Bruno Haible  <bruno@clisp.org>
3278
3279         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
3280         at the beginning of the gl_INIT macro.
3281         * modules/getloadavg (configure.ac): Pass $gl_source_base to
3282         gl_GETLOADAVG.
3283
3284 2006-09-22  Bruno Haible  <bruno@clisp.org>
3285
3286         * gnulib-tool (func_create_megatestdir): Don't include the config-h
3287         module.
3288         Suggested by Ralf Wildenhues.
3289
3290 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
3291
3292         Import this patch from libc:
3293
3294         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
3295
3296         * lib/regex_internal.c (re_string_reconstruct): Handle
3297         offset < pstr->valid_raw_len && pstr->offsets_needed case.
3298         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
3299         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
3300         re_string_context_at.
3301
3302         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
3303         now requires it.
3304         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
3305         gl_REGEX now does it for us.
3306         (gl_REGEX): Add test taken from
3307         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
3308
3309         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
3310         Check that large offsets work.  Modernize Autoconf usages.
3311         Prefer "yes" to mean a good thing rather than a bad.
3312         Don't put "#define mkstemp" in config.h, as this might interfere
3313         with standard system headers that "#define mkstemp mkstemp64".
3314
3315         * modules/mkstemp (Depends-on): Add extensions, so that
3316         mkstemp is visible on some platforms.
3317         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
3318         (Include): Change to "mkstemp.h" from <stdlib.h>.
3319         (Files): Add mkstemp.h.
3320
3321         * lib/mkstemp.h: New file, since some standard headers
3322         #define mkstemp.
3323         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
3324         Include "mkstemp.h".
3325         Make the _LIBC code resemble glibc original more,
3326         e.g., use K&R style.
3327         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
3328         (mkstemp): Remove, since mkstemp.h does this for us.
3329         * lib/stdlib--.h: Include mkstemp.h.
3330
3331         Import this patch from libc:
3332
3333         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3334
3335         * lib/tempname.c (__gen_tempname): Change attempts_min
3336         into a macro.  Use preprocessor to decide how to initialize
3337         attempts [Coverity CID 67].
3338
3339 2006-09-20  Bruno Haible  <bruno@clisp.org>
3340
3341         * lib/mkdtemp.c: Import from libc.
3342         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3343                 * sysdeps/posix/tempname.c (__gen_tempname): Change
3344                 attempts_min into a macro.  Use preprocessor to decide how to
3345                 initialize attempts [Coverity CID 67].
3346         2001-11-27  Paul Eggert  <eggert@twinsun.com>
3347                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
3348                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
3349
3350 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3351
3352         * gnulib-tool (func_exit): New function, to allow to pass the
3353         exit status portably through the trap.  Use everywhere.
3354         (--help, --version): Signal a write error.
3355         (trap): catch SIGPIPE, for write errors.
3356         Exit at the end of the trap, with the correct exit status.
3357
3358 2006-09-19  Karl Berry  <karl@gnu.org>
3359
3360         * doc/gnulib.texi: note about the license texinfo files.
3361
3362 2006-09-19  Eric Blake  <ebb9@byu.net>
3363
3364         * gnulib-tool: Avoid space-tab.
3365
3366 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3367
3368         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
3369         that prevented coreutils 6.1 from building.  Problem reported
3370         by Petter Reinholdtsen.
3371
3372 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3373
3374         * gnulib-tool (avoidlist): Fix typo that broke options like
3375         --avoid=lock that are used by coreutils bootstrap.
3376
3377 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
3378
3379         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
3380         more systematically.
3381
3382 2006-09-18  Jim Meyering  <jim@meyering.net>
3383
3384         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
3385
3386 2006-09-18  Bruno Haible  <bruno@clisp.org>
3387
3388         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
3389
3390 2006-09-18  Bruno Haible  <bruno@clisp.org>
3391
3392         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
3393         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
3394         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
3395         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
3396         * m4/gettext.m4: Require autoconf >= 2.52.
3397         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
3398         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
3399         of gl_cv_header_inttypes_h.
3400
3401 2006-09-18  Bruno Haible  <bruno@clisp.org>
3402
3403         * lib/javaversion.c: Include configmake.h.
3404
3405 2006-09-18  Bruno Haible  <bruno@clisp.org>
3406
3407         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
3408         avoid that the while loops be executed in a subshell.
3409
3410 2006-09-18  Bruno Haible  <bruno@clisp.org>
3411
3412         * MODULES.html.sh (func_module): Break long lines.
3413         Suggested by Bruce Korb <bkorb@gnu.org>.
3414
3415 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3416
3417         Speed up by a factor of 1.12.
3418         * gnulib-tool (nl): New variable.
3419         (func_import): Rewrite include directive extraction to only read each
3420         directive once.
3421
3422 2006-09-17  Bruno Haible  <bruno@clisp.org>
3423
3424         * modules/javaversion (Makefile.am): Remove DEFS setting.
3425         (Depends-on): Add configmake, for PKGDATADIR definition.
3426
3427 2006-09-17  Bruno Haible  <bruno@clisp.org>
3428
3429         * gnulib-tool (func_create_testdir): Rewrite all files at once.
3430
3431 2006-09-17  Bruno Haible  <bruno@clisp.org>
3432
3433         * gnulib-tool (func_append): New function, stolen from libtool.m4.
3434         (func_modules_transitive_closure, func_modules_add_dummy,
3435         func_modules_to_filelist, func_import, func_create_testdir,
3436         func_create_megatestdir, ...): Use it wherever possible.
3437         Suggested by Ralf Wildenhues.
3438
3439 2006-09-16  Karl Berry  <karl@gnu.org>
3440
3441         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
3442         to avoid sectioning errors.
3443         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
3444         [ifinfo]: blank line after @center-ed titles.
3445         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
3446         Spell FSF address consistently with others.
3447         (These changes approved by rms.)
3448
3449 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3450
3451         Speed up by a factor of 1.61.
3452         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
3453         already checked module names again.
3454
3455 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3456
3457         Speed up by a factor of 1.13.
3458         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
3459         for new_files, and the input to func_add_or_update.
3460
3461 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3462
3463         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
3464         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
3465
3466 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3467
3468         * modules/mkancesdirs (Depends-on): Add fcntl.
3469         * modules/savewd: New file.
3470         * MODULES.html.sh (File system functions): Add savewd.
3471
3472         * modules/configmake (Makefile.am): Add support for the
3473         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
3474
3475 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3476
3477         * m4/savewd.m4: New file.
3478
3479 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3480
3481         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
3482         (dirchownmod): New arg FD.  All callers changed.
3483         Use FD rather than opening the directory ourself, as opening is
3484         now the caller's responsibility.
3485         * lib/dirchownmod.h: Likewise.
3486         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
3487         hosts that require <sys/types.h> before <sys/stat.h>.  Include
3488         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
3489         (test_dir): Remove.
3490         (mkancesdirs): Return length of prefix of FILE that has already
3491         been made, or -2 if there is a child doing the work.  Redo
3492         algorithm so that it is O(N) rather than O(N**2).  Optimize away
3493         ".", and treat ".." specially since it might stray back into
3494         already-created areas.  Use a subprocess if necessary.  New arg
3495         WD; all users changed.  MAKE_DIR function should now return 1
3496         if it creates a directory that is not readable.  Return -2 if
3497         a child process is spun off.
3498         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
3499         Adjust signature to match code.
3500         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
3501         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
3502         all users changed.
3503         * lib/savewd.c, lib/savewd.h: New files.
3504
3505 2006-09-15  Jim Meyering  <jim@meyering.net>
3506
3507         * modules/rename-dest-slash: New module.
3508         * MODULES.html.sh (posix_compat): Add it here.
3509
3510         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
3511
3512 2006-09-15  Jim Meyering  <jim@meyering.net>
3513
3514         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
3515         file.
3516
3517         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
3518
3519 2006-09-15  Jim Meyering  <jim@meyering.net>
3520
3521         * lib/rename-dest-slash.c (has_trailing_slash): Use
3522         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
3523         (rpl_rename_dest_slash): Perform the cheaper trailing slash
3524         test before testing whether SRC is a directory.
3525         Suggestions from Bruno Haible.
3526
3527         Avoid a warning about an unused variable.
3528         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
3529         into the #ifdef block where it's used.
3530
3531         * lib/rename-dest-slash.c: New file.
3532
3533 2006-09-14  Bruno Haible  <bruno@clisp.org>
3534
3535         * lib/allocsa.c: Include <config.h> unconditionally.
3536         * lib/asnprintf.c: Likewise.
3537         * lib/asprintf.c: Likewise.
3538         * lib/c-strcasecmp.c: Likewise.
3539         * lib/c-strcasestr.c: Likewise.
3540         * lib/c-strncasecmp.c: Likewise.
3541         * lib/c-strstr.c: Likewise.
3542         * lib/classpath.c: Likewise.
3543         * lib/clean-temp.c: Likewise.
3544         * lib/concatpath.c: Likewise.
3545         * lib/copy-file.c: Likewise.
3546         * lib/csharpcomp.c: Likewise.
3547         * lib/csharpexec.c: Likewise.
3548         * lib/execute.c: Likewise.
3549         * lib/fatal-signal.c: Likewise.
3550         * lib/findprog.c: Likewise.
3551         * lib/fwriteerror.c: Likewise.
3552         * lib/gl_array_list.c: Likewise.
3553         * lib/gl_array_oset.c: Likewise.
3554         * lib/gl_avltree_list.c: Likewise.
3555         * lib/gl_avltree_oset.c: Likewise.
3556         * lib/gl_avltreehash_list.c: Likewise.
3557         * lib/gl_carray_list.c: Likewise.
3558         * lib/gl_linked_list.c: Likewise.
3559         * lib/gl_linkedhash_list.c: Likewise.
3560         * lib/gl_list.c: Likewise.
3561         * lib/gl_oset.c: Likewise.
3562         * lib/gl_rbtree_list.c: Likewise.
3563         * lib/gl_rbtree_oset.c: Likewise.
3564         * lib/gl_rbtreehash_list.c: Likewise.
3565         * lib/imaxabs.c: Likewise.
3566         * lib/imaxdiv.c: Likewise.
3567         * lib/javacomp.c: Likewise.
3568         * lib/javaexec.c: Likewise.
3569         * lib/javaversion.c: Likewise.
3570         * lib/linebreak.c: Likewise.
3571         * lib/localcharset.c: Likewise.
3572         * lib/lock.c: Likewise.
3573         * lib/mbchar.c: Likewise.
3574         * lib/mbswidth.c: Likewise.
3575         * lib/mkdtemp.c: Likewise.
3576         * lib/pipe.c: Likewise.
3577         * lib/printf-args.c: Likewise.
3578         * lib/printf-parse.c: Likewise.
3579         * lib/progname.c: Likewise.
3580         * lib/progreloc.c: Likewise.
3581         * lib/readlink.c: Likewise.
3582         * lib/sh-quote.c: Likewise.
3583         * lib/stpcpy.c: Likewise.
3584         * lib/stpncpy.c: Likewise.
3585         * lib/strcasecmp.c: Likewise.
3586         * lib/strcasestr.c: Likewise.
3587         * lib/strcspn.c: Likewise.
3588         * lib/striconv.c: Likewise.
3589         * lib/strncasecmp.c: Likewise.
3590         * lib/strnlen1.c: Likewise.
3591         * lib/strstr.c: Likewise.
3592         * lib/strtok_r.c: Likewise.
3593         * lib/tls.c: Likewise.
3594         * lib/tmpdir.c: Likewise.
3595         * lib/unicodeio.c: Likewise.
3596         * lib/unsetenv.c: Likewise.
3597         * lib/vasnprintf.c: Likewise.
3598         * lib/vasprintf.c: Likewise.
3599         * lib/wait-process.c: Likewise.
3600         * lib/xallocsa.c: Likewise.
3601         * lib/xsetenv.c: Likewise.
3602         * lib/xstriconv.c: Likewise.
3603
3604 2006-09-13  Simon Josefsson  <jas@extundo.com>
3605
3606         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
3607         that internally, suggested by Ralf Wildenhues
3608         <Ralf.Wildenhues@gmx.de>.
3609
3610 2006-09-13  Simon Josefsson  <jas@extundo.com>
3611
3612         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
3613         @LIBOBJS@.
3614         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3615
3616 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
3617
3618         * lib/_fpending.c: Include <config.h> unconditionally, since we no
3619         longer worry about uses that don't define HAVE_CONFIG_H.
3620         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
3621         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
3622         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
3623         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
3624         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
3625         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
3626         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
3627         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
3628         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
3629         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
3630         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
3631         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
3632         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
3633         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
3634         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
3635         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
3636         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
3637         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
3638         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
3639         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
3640         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
3641         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
3642         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
3643         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
3644         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
3645         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
3646         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
3647         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
3648         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
3649         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
3650         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
3651         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
3652         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
3653         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
3654         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
3655         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
3656         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
3657         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
3658         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
3659         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
3660         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
3661         Likewise.
3662
3663 2006-09-13  Eric Blake  <ebb9@byu.net>
3664
3665         * lib/getopt.c: Fix typo in last commit.
3666
3667 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
3668
3669         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
3670         dgettext.
3671
3672 2006-09-12  Jim Meyering  <jim@meyering.net>
3673
3674         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
3675         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
3676         Reported by Nelson H. F. Beebe.
3677
3678 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
3679
3680         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
3681         program_invocation_name and program_invocation_short_name are
3682         initialized.
3683         * lib/argp-namefrob.h: Move declarations of program_invocation_name
3684         and program_invocation_short_name to argp.h, so they are visible
3685         to user programs.
3686         * lib/argp.h: Likewise
3687
3688 2006-09-10  Bruno Haible  <bruno@clisp.org>
3689
3690         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
3691         m4/inttypes_h.m4, m4/uintmax_t.m4.
3692
3693 2006-09-10  Bruno Haible  <bruno@clisp.org>
3694
3695         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
3696         gl_AC_TYPE_UINTMAX_T.
3697
3698 2006-09-10  Bruno Haible  <bruno@clisp.org>
3699
3700         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
3701
3702 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
3703
3704         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
3705         convention.  Text proposed by Bruno Haible.
3706         (struct argp_option): Document the use of N_() wrappers.
3707
3708         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
3709         '\v', and translate the two parts separately, instead of feeding
3710         the whole string to gettext.  This allows to exclude
3711         '\v' from the strings visible to the translator by writing doc
3712         strings as N_("..") "\v" N_("..").
3713
3714 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
3715
3716         * config/srclist.txt: Undo latest change; the bug was fixed.
3717
3718 2006-09-09  Bruno Haible  <bruno@clisp.org>
3719
3720         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
3721         assignments if building a library without libtool.
3722         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
3723         in func_emit_lib_Makefile_am.
3724         (func_import): When building a static library libfoo.a, arrange to
3725         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
3726         (func_create_testdir): Likewise.
3727         * modules/gc (configure.ac, Makefile.am): If building statically,
3728         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
3729         * modules/iconvme (configure.ac, Makefile.am): Likewise.
3730         * modules/striconv (configure.ac, Makefile.am): Likewise.
3731         Based on a suggestion by Ralf Wildenhues.
3732
3733 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3734
3735         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
3736         Check for unistd.h too, since Autoconf doesn't assume POSIX.
3737         Also:
3738
3739         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3740         Add year_2050_test to catch glibc bug 2821
3741         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3742
3743         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
3744         Prefer #ifdef to #if.
3745
3746         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
3747         Return from 'main' instead of calling 'exit'.
3748
3749 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3750
3751         * lib/mktime.c (guess_time_tm): Fix bug where mktime
3752         returned the maximum time_t value rather than (time_t) -1.
3753         Problem originally reported by William Bardwell
3754         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3755
3756         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3757         Moved to here ...
3758         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3759         ... from here.
3760
3761 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3762
3763         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
3764         2821 is fixed.
3765
3766 2006-09-08  Jim Meyering  <jim@meyering.net>
3767
3768         Don't make generated files read-only.  That would bother too many
3769         people.  However, do retain the ability to work when targets are
3770         read-only: remove the destination and temporary files before writing
3771         them (when generated via sed or echo), or by using the -f option for
3772         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
3773         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3774         * modules/byteswap, modules/configmake, modules/fcntl:
3775         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3776         * modules/localcharset, modules/netinet_in, modules/poll:
3777         * modules/stdbool, modules/stdint, modules/sys_select:
3778         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3779
3780 2006-09-08  Jim Meyering  <jim@meyering.net>
3781
3782         Avoid new build failure on FreeBSD 6.0.
3783         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
3784         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
3785         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
3786
3787 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3788
3789         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
3790
3791 2006-09-07  Jim Meyering  <jim@meyering.net>
3792
3793         Fix global typo in last change: use chmod u-w, not chmod u-x.
3794         Spotted by Paul Eggert and Bruce Korb.
3795         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3796         * modules/byteswap, modules/configmake, modules/fcntl:
3797         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3798         * modules/localcharset, modules/netinet_in, modules/poll:
3799         * modules/stdbool, modules/stdint, modules/sys_select:
3800         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3801
3802 2006-09-06  Jim Meyering  <jim@meyering.net>
3803
3804         Make generated files be read-only.
3805         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
3806         Ensure that each generated file is now read-only.
3807         * modules/argz: Likewise.
3808         * modules/arpa_inet: Likewise.
3809         * modules/byteswap: Likewise.
3810         * modules/configmake: Likewise.
3811         * modules/fcntl: Likewise.
3812         * modules/fnmatch: Likewise.
3813         * modules/getopt: Likewise.
3814         * modules/glob: Likewise.
3815         * modules/inttypes: Likewise.
3816         * modules/netinet_in: Likewise.
3817         * modules/poll: Likewise.
3818         * modules/stdbool: Likewise.
3819         * modules/stdint: Likewise.
3820         * modules/sys_select: Likewise.
3821         * modules/sys_socket: Likewise.
3822         * modules/sys_stat: Likewise.
3823         * modules/sysexits: Likewise.
3824         * modules/localcharset: Same as above, but continue using temporary
3825         file named "t-$@" (why different?) rather than the "$@-t" used
3826         everywhere else.
3827
3828         * modules/sysexits (Makefile.am): Replace literal occurrences
3829         of "sysexit.h" more readable, and more consistent, "$@".
3830
3831 2006-09-06  Bruno Haible  <bruno@clisp.org>
3832
3833         * modules/striconv: New file.
3834         * modules/xstriconv: New file.
3835         * MODULES.html.sh (Internationalization functions): Add striconv,
3836         xstriconv.
3837
3838 2006-09-06  Bruno Haible  <bruno@clisp.org>
3839
3840         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
3841         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
3842         not using libtool correctly.
3843
3844 2006-09-06  Bruno Haible  <bruno@clisp.org>
3845
3846         * lib/striconv.h: New file.
3847         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
3848         iconvstring.c.
3849         * lib/xstriconv.h: New file.
3850         * lib/xstriconv.c: New file.
3851
3852 2006-09-06  Bruno Haible  <bruno@clisp.org>
3853
3854         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
3855         lib_..._LDFLAGS.
3856
3857 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3858
3859         * lib/argz_.h: Sync from Libtool.
3860
3861         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
3862                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3863
3864         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
3865
3866 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3867
3868         * modules/trim: New file.
3869
3870 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3871
3872         * lib/trim.h: New file.
3873         * lib/trim.c: New file.
3874
3875 2006-09-05  Bruno Haible  <bruno@clisp.org>
3876
3877         * MODULES.html.sh (String handling): Add trim.
3878
3879 2006-09-04  Karl Berry  <karl@gnu.org>
3880
3881         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
3882         until next release.
3883
3884 2006-09-03  Bruno Haible  <bruno@clisp.org>
3885
3886         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
3887         correctly.
3888
3889 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3890
3891         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
3892         not gl_GETLOADAVG.  Omit unneeded semicolons.
3893         Problems reported by Ralf Wildenhues in
3894         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3895         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
3896         at the end, which is the usual gnulib style.
3897
3898         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
3899         of doing all the work ourselves.
3900         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
3901         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
3902
3903 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3904
3905         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
3906         Problem reported by Ralf Wildenhues in
3907         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3908
3909         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
3910         HAVE_STRUCT_STATFS_F_FSTYPENAME.
3911
3912 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3913
3914         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
3915         yesterday's patch by changing test -n to test -z.
3916
3917 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3918
3919         * modules/getloadavg (Files): Add m4/getloadavg.m4.
3920         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
3921         the former is now obsolescent.
3922
3923         * modules/chdir-long (Depends-on): Add fcntl.
3924
3925 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3926
3927         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
3928         obsolescent, and programs should use gnulib instead.
3929         * m4/getloadavg.m4: New file, with contents taken from Autoconf
3930         but with prefixes changed.
3931
3932 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3933
3934         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
3935         or stdbool.h, because they might not exist while configuring.
3936
3937         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
3938         Don't include unistd.h or limits.h; not needed, since chdir-long.h
3939         does that for us.
3940         (O_DIRECTORY): Remove.
3941
3942 2006-08-31  Eric Blake  <ebb9@byu.net>
3943
3944         * gnulib-tool: Don't let emacs change spaces to TAB.
3945
3946 2006-08-31  Bruno Haible  <bruno@clisp.org>
3947
3948         * gnulib-tool: When calling func_import more than once, do it in a
3949         subshell.
3950         Reported by Eric Blake <ebb9@byu.net>.
3951
3952 2006-08-31  Bruno Haible  <bruno@clisp.org>
3953
3954         * gnulib-tool (nl): Remove variable.
3955         (sed_transform_lib_file): Use more robust test for config-h module.
3956         (func_import): Fix typo in 2006-08-25 patch.
3957
3958 2006-08-31  Bruno Haible  <bruno@clisp.org>
3959
3960         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
3961         specified, augment Makefile.am variables instead of assigning them.
3962
3963 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3964
3965         Work around a bug in both the Linux and SunOS 64-bit kernels:
3966         nanosleep mishandles sleeps for longer than 2**31 seconds.
3967         Problem reported by Frank v Waveren in
3968         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3969         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
3970         Check for nanosleep bug.
3971         (LIB_NANOSLEEP): Append clock_gettime library if needed.
3972
3973 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3974
3975         Work around a bug in both the Linux and SunOS 64-bit kernels:
3976         nanosleep mishandles sleeps for longer than 2**31 seconds.
3977         Problem reported by Frank v Waveren in
3978         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3979         * lib/nanosleep.c (BILLION): New constant.
3980         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
3981         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
3982         implementation.
3983
3984 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3985
3986         * modules/nanosleep (Depends-on): Add gettime.
3987
3988 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3989         and Simon Josefsson  <jas@extundo.com>
3990         and Oskar Liljeblad  <oskar@osk.mine.nu>
3991
3992         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
3993         * gnulib-tool (func_import): New license type 'unmodifiable license
3994         text'.
3995         * modules/fdl: Use it.  Longer description.
3996         * module/gpl, module/lgpl: New files.
3997
3998 2006-08-30  Jim Meyering  <jim@meyering.net>
3999
4000         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
4001         shadowing the parameter.
4002
4003 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4004
4005         Sync from Libtool:
4006
4007         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4008
4009         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
4010         sharing with gnulib.  Report by Eric Blake.
4011
4012 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4013
4014         * modules/isapipe: New file.
4015         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
4016
4017 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4018
4019         * modules/configmake (Makefile.am): Add a comment, and omit
4020         the CONFIGMAKE_ prefix from generated macro names.  Suggested
4021         by Bruno Haible.
4022
4023 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4024
4025         * m4/isapipe.m4: New file.
4026
4027 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4028
4029         * lib/isapipe.c, lib/isapipe.h: New files.
4030
4031 2006-08-29  Jim Meyering  <jim@meyering.net>
4032
4033         * modules/configmake (Makefile.am): Make configmake.h depend on
4034         Makefile.  Otherwise, a stale configmake.h could hang around.
4035
4036 2006-08-29  Eric Blake  <ebb9@byu.net>
4037
4038         * lib/error.c (error_at_line, print_errno_message): Match libc, after
4039         resolution of upstream bug 3044.
4040
4041 2006-08-29  Bruno Haible  <bruno@clisp.org>
4042
4043         * modules/localcharset (Depends-on): Add configmake.
4044         (Makefile.am): Remove setting of LIBDIR through DEFS.
4045
4046 2006-08-29  Bruno Haible  <bruno@clisp.org>
4047
4048         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
4049         defined.
4050
4051 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4052
4053         * modules/fcntl: New file.
4054         * modules/chdir-safer (Depends-on): Add fcntl.
4055         * modules/fts: Likewise.
4056         * modules/mkdir-p: Likewise.
4057
4058         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
4059         This undoes the most recent change, since we're now addressing the
4060         problem in a different way.
4061
4062         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
4063         into output, since the output might be called Makefile.am even
4064         if $makefile_name is something different.
4065         (func_import): Use $makefile_am rather than
4066         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
4067         empty.
4068
4069         * modules/inttypes (Files): Add m4/inttypes-h.m4.
4070
4071 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4072
4073         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
4074         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
4075         recent change to stdint.m4, since we're now addressing the problem in a
4076         different way.
4077
4078 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4079
4080         * m4/fcntl_h.m4: New file.
4081
4082 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4083
4084         * lib/fcntl_.h: New file.
4085         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
4086         the fcntl module.
4087         * lib/dirchownmod.c: Likewise.
4088         * lib/fts.c: Likewise.
4089
4090         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
4091         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
4092         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
4093         just before including <inttypes.h>, to avoid circular inclusion.
4094
4095 2006-08-28  Jim Meyering  <jim@meyering.net>
4096
4097         * doc/visibility.texi: Actually read and correct the grammar of the
4098         sentence affected by yesterday's change.
4099
4100 2006-08-28  Eric Blake  <ebb9@byu.net>
4101
4102         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
4103         needs wrapper.
4104
4105 2006-08-28  Eric Blake  <ebb9@byu.net>
4106
4107         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
4108
4109 2006-08-28  Eric Blake  <ebb9@byu.net>
4110
4111         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
4112
4113 2006-08-28  Bruno Haible  <bruno@clisp.org>
4114
4115         * modules/c-strstr: New file, from GNU gettext.
4116         * MODULES.html.sh (String handling): Add c-strstr.
4117
4118 2006-08-28  Bruno Haible  <bruno@clisp.org>
4119
4120         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
4121         macros.
4122         Reported by Eric Blake.
4123
4124 2006-08-28  Bruno Haible  <bruno@clisp.org>
4125
4126         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
4127         (VASNPRINTF): Return a string of length > INT_MAX without failing.
4128         * lib/vasprintf.c: Include errno.h, limits.h.
4129         (EOVERFLOW): New fallback definition.
4130         (vasprintf): Test here whether the string length is > INT_MAX.
4131         * lib/vsnprintf.c: Include errno.h, limits.h.
4132         (EOVERFLOW): New fallback definition.
4133         (vsnprintf): Fix bug when generated string was too long for the buffer.
4134         Test here whether the string length is > INT_MAX.
4135
4136 2006-08-28  Bruno Haible  <bruno@clisp.org>
4137
4138         * lib/inttypes_.h (SCNX*): Remove definitions.
4139         Reported by Eric Blake.
4140
4141 2006-08-28  Bruno Haible  <bruno@clisp.org>
4142
4143         * lib/c-strstr.h: New file, from GNU gettext.
4144         * lib/c-strstr.c: New file, from GNU gettext.
4145
4146 2006-08-28  Bruno Haible  <bruno@clisp.org>
4147
4148         * gnulib-tool: Reorder some statements.
4149
4150 2006-08-28  Bruno Haible  <bruno@clisp.org>
4151
4152         * gnulib-tool: New option --makefile-name.
4153         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
4154         $makefile_name.
4155         (func_import): Write $makefile_name to the cache file, and read it from
4156         there unless explicitly specified. Use $makefile_name as file name
4157         instead of Makefile.am. Adjust the recommendations accordingly.
4158
4159 2006-08-28  Bruno Haible  <bruno@clisp.org>
4160
4161         * gnulib-tool (func_verify_module): Check against misapplying patch.
4162
4163 2006-08-28  Bruno Haible  <bruno@clisp.org>
4164
4165         * gnulib-tool (func_relativize, func_relconcat): New functions.
4166         Give an error if --local-dir is given with --update.
4167         Remove trailing slashes from $local_gnulib_dir.
4168         (func_import): Store the relativized $local_gnulib_dir in
4169         gnulib-cache.m4, and read it from there if not specified explicitly.
4170
4171 2006-08-28  Bruno Haible  <bruno@clisp.org>
4172
4173         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
4174         is the current directory. Respect also $local_gnulib_dir.
4175
4176 2006-08-28  Bruno Haible  <bruno@clisp.org>
4177             Simon Josefsson  <jas@extundo.com>
4178
4179         BeOS portability.
4180         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
4181
4182 2006-08-27  Jim Meyering  <jim@meyering.net>
4183
4184         * doc/visibility.texi: Remove duplicate word: "pointer".
4185
4186 2006-08-26  Bruno Haible  <bruno@clisp.org>
4187
4188         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
4189         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
4190         (Makefile.am): Create inttypes.h from inttypes_.h.
4191         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
4192
4193         * modules/imaxabs: New file.
4194
4195         * modules/imaxdiv: New file.
4196
4197 2006-08-26  Bruno Haible  <bruno@clisp.org>
4198
4199         * m4/inttypes.m4: New file.
4200         * m4/_inttypes_h.m4: Remove file.
4201         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
4202         PRI_MACROS_BROKEN.
4203         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
4204
4205         * m4/imaxabs.m4: New file.
4206
4207         * m4/imaxdiv.m4: New file.
4208
4209 2006-08-26  Bruno Haible  <bruno@clisp.org>
4210
4211         * lib/inttypes_.h: New file.
4212         * lib/inttypes.h: Remove file.
4213         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
4214
4215         * lib/imaxabs.c: New file.
4216
4217         * lib/imaxdiv.c: New file.
4218
4219 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4220
4221         New config-h module, so that "make" output needn't be cluttered
4222         by -DHAVE_CONFIG_H.
4223         * MODULES.html.sh (Support for building libraries and executables):
4224         Add config-h.
4225         * modules/config-h: New file.
4226         * gnulib-tool (nl, sed_transform_lib_file): New vars.
4227         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
4228         the config-h module is used.
4229
4230         New configmake module, so that "make" output needn't be cluttered
4231         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
4232         * MODULES.html.sh (Support for building libraries and executables):
4233         Add configmake.
4234         * modules/configmake: New file.
4235
4236 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4237
4238         * m4/config-h.m4: New file.
4239
4240 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4241
4242         * config/srclist.txt: Add elisp-comp.
4243
4244 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4245
4246         * MODULES.html.sh (Support for building libraries and executables):
4247         Add elisp-comp.
4248         * build-aux/elisp-comp: New file.
4249         * modules/elisp-comp: New file.
4250
4251 2006-08-24  Bruno Haible  <bruno@clisp.org>
4252
4253         * gnulib-tool (func_create_testdir): Use non-default values of
4254         sourcebase and m4base.
4255
4256 2006-08-24  Bruno Haible  <bruno@clisp.org>
4257
4258         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
4259         HTML structure.
4260
4261 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
4262
4263         * modules/openat (Depends-on): Add lchown.
4264
4265 2006-08-23  Bruno Haible  <bruno@clisp.org>
4266
4267         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
4268         of gl_LOCK_EARLY instead of gl_LOCK.
4269
4270 2006-08-23  Bruno Haible  <bruno@clisp.org>
4271
4272         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
4273         on OSF/1 to no.
4274         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
4275
4276 2006-08-23  Bruno Haible  <bruno@clisp.org>
4277
4278         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
4279         as unusable.
4280
4281         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
4282         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
4283         (gl_LOCK): New macro.
4284
4285 2006-08-22  Simon Josefsson  <jas@extundo.com>
4286
4287         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
4288         to md5 module.
4289
4290 2006-08-22  Simon Josefsson  <jas@extundo.com>
4291
4292         * MODULES.html.sh: Add "Support for maintaining and release
4293         projects".
4294
4295         * build-aux/gnupload: New file, from coreutils.
4296
4297 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4298
4299         Avoid the need for AC_LIBSOURCES in m4 macros.
4300         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
4301         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
4302         * modules/check-version (EXTRA_DIST): Add check-version.h.
4303         * modules/crc (EXTRA_DIST): Add crc.h.
4304         * modules/des (EXTRA_DIST): Add des.h.
4305         * modules/gc (EXTRA_DIST): Add gc.h.
4306         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
4307         * modules/getline (EXTRA_DIST): Add getline.h.
4308         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
4309         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
4310         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
4311         * modules/md2 (EXTRA_DIST): Add md2.h.
4312         * modules/md4 (EXTRA_DIST): Add md4.h.
4313         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
4314         * modules/read-file (EXTRA_DIST): Add read-file.h.
4315         * modules/readline (EXTRA_DIST): Add readline.h.
4316         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
4317         rijndael-api-fst.h.
4318
4319 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4320
4321         * m4/rijndael.m4 (gl_ARCFOUR):
4322         * m4/arctwo.m4 (gl_ARCTWO):
4323         * m4/check-version.m4 (gl_CHECK_VERSION):
4324         * m4/crc.m4 (gl_CRC):
4325         * m4/des.m4 (gl_DES):
4326         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
4327         * m4/gc.m4 (gl_GC):
4328         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
4329         * m4/getline.m4 (gl_FUNC_GETLINE):
4330         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
4331         * m4/hmac-md5.m4 (gl_HMAC_MD5):
4332         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
4333         * m4/md2.m4 (gl_MD2):
4334         * m4/md4.m4 (gl_MD4):
4335         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
4336         * m4/read-file.m4 (gl_FUNC_READ_FILE):
4337         * m4/readline.m4 (gl_FUNC_READLINE):
4338         * m4/rijndael.m4 (gl_RIJNDAEL):
4339         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4340         to get the necessary .h files and whatnot.
4341
4342 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4343
4344         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
4345         gnulib rather than the other way around.
4346         * config/srclistvars.sh (COREUTILS): Remove.
4347
4348 2006-08-22  Jim Meyering  <jim@meyering.net>
4349
4350         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
4351
4352         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
4353
4354 2006-08-22  Eric Blake  <ebb9@byu.net>
4355
4356         * modules/regexprops-generic: New file.
4357         * MODULES.html.sh (Support for building documentation): List it.
4358
4359 2006-08-22  Eric Blake  <ebb9@byu.net>
4360
4361         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
4362         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
4363         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
4364         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
4365
4366 2006-08-22  Bruno Haible  <bruno@clisp.org>
4367
4368         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
4369         and lib_LTLIBRARIES like the other lib_* variables.
4370
4371 2006-08-22  Bruno Haible  <bruno@clisp.org>
4372
4373         * build-aux/x-to-1.in: New file, from GNU gettext.
4374
4375 2006-08-22  Bruno Haible  <bruno@clisp.org>
4376
4377         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
4378         <utmpx.h> exists.
4379
4380 2006-08-22  Bruno Haible  <bruno@clisp.org>
4381
4382         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
4383         <utmpx.h> exists.
4384
4385 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4386
4387         BeOS portability.
4388         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
4389         exist.
4390         Problem reported by Bruno Haible.
4391
4392 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4393
4394         Avoid the need for AC_LIBSOURCES in m4 macros.
4395         * modules/acl (EXTRA_DIST): Add acl.h.
4396         * modules/argmatch (Files): Add m4/argmatch.m4.
4397         (configure.ac): Add gl_ARGMATCH.
4398         (EXTRA_DIST): Renamed from lib_SOURCES, for
4399         consistency with the other modules.  Remove argmatch.c.
4400         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
4401         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
4402         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
4403         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
4404         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
4405         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
4406         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
4407         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
4408         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
4409         * modules/closeout (EXTRA_DIST): Add closeout.h.
4410         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
4411         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
4412         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
4413         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
4414         dirname.h; remove basename.c and stripslash.c.
4415         * modules/exclude (EXTRA_DIST): Add exclude.h.
4416         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
4417         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
4418         * modules/file-type (EXTRA_DIST): Add file-type.h.
4419         * modules/filemode (EXTRA_DIST): Add filemode.h.
4420         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
4421         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4422         * modules/fpending (EXTRA_DIST): Add __fpending.h.
4423         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
4424         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
4425         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
4426         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
4427         * modules/getdate (EXTRA_DIST): Add getdate.c.
4428         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
4429         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
4430         * modules/getpass (EXTRA_DIST): Add getpass.h.
4431         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
4432         * modules/group-member (EXTRA_DIST): Add group-member.h.
4433         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
4434         * modules/hash (EXTRA_DIST): Add hash.h.
4435         * modules/human (EXTRA_DIST): Add human.h.
4436         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
4437         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
4438         * modules/lchown (EXTRA_DIST): Add lchown.h.
4439         * modules/long-options (EXTRA_DIST): Add long-options.h.
4440         * modules/lstat (EXTRA_DIST): Add lstat.h.
4441         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
4442         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
4443         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
4444         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
4445         * modules/memxor (EXTRA_DIST): Add memxor.h.
4446         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
4447         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
4448         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
4449         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
4450         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
4451         * modules/physmem (EXTRA_DIST): Add physmem.h.
4452         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
4453         * modules/posixver (EXTRA_DIST): Add posixver.h.
4454         * modules/quote (EXTRA_DIST): Add quote.h.
4455         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
4456         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
4457         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
4458         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
4459         regex_internal.h regexec.c.
4460         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
4461         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
4462         * modules/same (EXTRA_DIST): Add same.h.
4463         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
4464         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
4465         * modules/savedir (EXTRA_DIST): Add savedir.h.
4466         * modules/sha1 (EXTRA_DIST): Add sha1.h.
4467         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
4468         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
4469         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
4470         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
4471         * modules/strdup (EXTRA_DIST): Add strdup.h.
4472         * modules/strftime (EXTRA_DIST): Add strftime.h.
4473         * modules/strndup (EXTRA_DIST): Add strndup.h.
4474         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
4475         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
4476         * modules/time_r (EXTRA_DIST): Add time_r.h.
4477         * modules/timespec (EXTRA_DIST): Add timespec.h.
4478         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4479         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
4480         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
4481         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
4482         * modules/userspec (EXTRA_DIST): Add userspec.h.
4483         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
4484         * modules/utimens (EXTRA_DIST): Add utimens.h.
4485         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
4486         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
4487         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
4488         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
4489         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
4490         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
4491         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
4492         * modules/yesno (EXTRA_DIST): Add yesno.h.
4493
4494 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4495
4496         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
4497
4498         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
4499         * m4/dev-ino.m4, same-inode.m4: Remove.
4500
4501         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
4502         * m4/acl.m4 (AC_FUNC_ACL):
4503         * m4/backupfile.m4 (gl_BACKUPFILE):
4504         * m4/c-strtod.m4 (gl_C99_STRTOLD):
4505         * m4/canon-host.m4 (gl_CANON_HOST):
4506         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4507         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
4508         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
4509         * m4/cloexec.m4 (gl_CLOEXEC):
4510         * m4/close-stream.m4 (gl_CLOSE_STREAM):
4511         * m4/closeout.m4 (gl_CLOSEOUT):
4512         * m4/dirfd.m4 (gl_FUNC_DIRFD):
4513         * m4/dirname.m4 (gl_DIRNAME):
4514         * m4/exclude.m4 (gl_EXCLUDE):
4515         * m4/exitfail.m4 (gl_EXITFAIL):
4516         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
4517         * m4/file-type.m4 (gl_FILE_TYPE):
4518         * m4/filemode.m4 (gl_FILEMODE):
4519         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
4520         * m4/fpending.m4 (gl_FUNC_FPENDING):
4521         * m4/fprintftime.m4 (gl_FPRINTFTIME):
4522         * m4/fts.m4 (gl_FUNC_FTS):
4523         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
4524         * m4/getdate.m4 (gl_GETDATE):
4525         * m4/gethrxtime.m4 (gl_GETHRXTIME):
4526         * m4/getpagesize.m4 (gl_GETPAGESIZE):
4527         * m4/getpass.m4 (gl_FUNC_GETPASS):
4528         * m4/gettime.m4 (gl_GETTIME):
4529         * m4/getugroups.m4 (gl_GETUGROUPS):
4530         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
4531         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
4532         * m4/hard-locale.m4 (gl_HARD_LOCALE):
4533         * m4/hash.m4 (gl_HASH):
4534         * m4/idcache.m4 (gl_IDCACHE):
4535         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
4536         * m4/lchown.m4 (gl_FUNC_LCHOWN):
4537         * m4/long-options.m4 (gl_LONG_OPTIONS):
4538         * m4/lstat.m4 (gl_FUNC_LSTAT):
4539         * m4/md5.m4 (gl_MD5):
4540         * m4/memcasecmp.m4 (gl_MEMCASECMP):
4541         * m4/memcoll.m4 (gl_MEMCOLL):
4542         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
4543         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
4544         * m4/memxor.m4 (gl_MEMXOR):
4545         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
4546         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
4547         * m4/modechange.m4 (gl_MODECHANGE):
4548         * m4/mountlist.m4 (gl_MOUNTLIST):
4549         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4550         * m4/openat.m4 (gl_FUNC_OPENAT):
4551         * m4/pathmax.m4 (gl_PATHMAX):
4552         * m4/physmem.m4 (gl_PHYSMEM):
4553         * m4/posixtm.m4 (gl_POSIXTM):
4554         * m4/posixver.m4 (gl_POSIXVER):
4555         * m4/quote.m4 (gl_QUOTE):
4556         * m4/quotearg.m4 (gl_QUOTEARG):
4557         * m4/readtokens.m4 (gl_READTOKENS):
4558         * m4/readutmp.m4 (gl_READUTMP):
4559         * m4/regex.m4 (gl_REGEX):
4560         * m4/safe-read.m4 (gl_SAFE_READ):
4561         * m4/safe-write.m4 (gl_SAFE_WRITE):
4562         * m4/same.m4 (gl_SAME):
4563         * m4/save-cwd.m4 (gl_SAVE_CWD):
4564         * m4/savedir.m4 (gl_SAVEDIR):
4565         * m4/settime.m4 (gl_SETTIME):
4566         * m4/sha1.m4 (gl_SHA1):
4567         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
4568         * m4/stat-macros.m4 (gl_STAT_MACROS):
4569         * m4/stat-time.m4 (gl_STAT_TIME):
4570         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
4571         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
4572         * m4/strdup.m4 (gl_FUNC_STRDUP):
4573         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
4574         * m4/strndup.m4 (gl_FUNC_STRNDUP):
4575         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
4576         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
4577         * m4/time_r.m4 (gl_TIME_R):
4578         * m4/timespec.m4 (gl_TIMESPEC):
4579         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
4580         * m4/unlinkdir.m4 (gl_UNLINKDIR):
4581         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
4582         * m4/userspec.m4 (gl_USERSPEC):
4583         * m4/utimecmp.m4 (gl_UTIMECMP):
4584         * m4/utimens.m4 (gl_UTIMENS):
4585         * m4/xalloc.m4 (gl_XALLOC):
4586         * m4/xgetcwd.m4 (gl_XGETCWD):
4587         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
4588         * m4/xreadlink.m4 (gl_XREADLINK):
4589         * m4/xstrtod.m4 (gl_XSTRTOD):
4590         * m4/yesno.m4 (gl_YESNO):
4591         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4592         to get the necessary .h files and whatnot.
4593
4594 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
4595             Bruno Haible  <bruno@clisp.org>
4596
4597         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
4598         /bin/sh understanding of '!' conditional negation.
4599
4600 2006-08-21  Jim Meyering  <jim@meyering.net>
4601
4602         * modules/openat (Depends-on): Really alphabetize.
4603
4604         * modules/acl (Depends-on): Add error and quote.
4605
4606         * check-module (find_included_lib_files): Add at-func.c to the
4607         ok-to-include-more-than-once white list.
4608
4609         * modules/openat (Depends-on): Add lstat.  Alphabetize.
4610
4611 2006-08-21  Bruno Haible  <bruno@clisp.org>
4612
4613         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4614         Emit a pkgdata_DATA variable only if some snippets add contents to it.
4615         Reported by Martin Lambers <marlam@marlam.de>.
4616
4617 2006-08-21  Bruno Haible  <bruno@clisp.org>
4618
4619         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
4620         specify an installation location, don't emit a noinst_LIBRARIES or
4621         noinst_LTLIBRARIES assignment.
4622
4623 2006-08-21  Bruno Haible  <bruno@clisp.org>
4624
4625         BeOS portability.
4626         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
4627         BeOS has mbrtowc() but no <wctype.h>.
4628
4629 2006-08-21  Bruno Haible  <bruno@clisp.org>
4630
4631         BeOS portability.
4632         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
4633         exist.
4634
4635 2006-08-21  Bruno Haible  <bruno@clisp.org>
4636
4637         BeOS portability.
4638         * lib/mbchar.h: Include <wctype.h> only if it exists.
4639
4640 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4641
4642         Remove files that are no longer needed by their respective modules.
4643         * m4/obstack.m4: Remove.
4644         * m4/strerror_r.m4: Remove.
4645         * m4/uint32_t.m4: Remove.
4646         * m4/uintptr_t.m4: Remove.
4647         * m4/ullong_max.m4: Remove.
4648         * m4/xstrtoimax.m4: Remove.
4649         * m4/xstrtoumax.m4: Remove.
4650
4651         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
4652         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
4653         dependencies now capture this.
4654
4655         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
4656         Do not use AC_LIBSOURCES, since gnulib modules now do this.
4657         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
4658         * m4/human.m4 (gl_HUMAN): Likewise.
4659         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
4660         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
4661
4662         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
4663
4664         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
4665         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
4666         stdint.
4667         * m4/human.m4 (gl_HUMAN): Likewise.
4668         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
4669         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
4670         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4671         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4672         * m4/xstrtol (gl_XSTRTOL): Likewise.
4673
4674         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
4675         AC_TYPE_LONG_LONG_INT.
4676         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4677         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
4678         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
4679         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4680
4681         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
4682         on stdbool.
4683
4684         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
4685         (gl_PREREQ_XSTRTOUL): Remove.
4686
4687         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
4688
4689         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
4690         mode.
4691
4692 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4693
4694         Add and change modules to make it easier for coreutils to use
4695         gnulib-tool.
4696         * modules/backupfile (Files): Remove m4/d-ino.m4.
4697         (Depends-on): Add d-ino.
4698         * modules/cycle-check (Depends-on): Add stdint.
4699         (lib_SOURCES): Add cycle-check.h.
4700         * modules/d-ino: New module.
4701         * modules/d-type: New module.
4702         * modules/error (Files): Remove m4/strerror_r.m4.
4703         * modules/filemode (Files): Add m4/st_dm_mode.m4.
4704         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4705         m4/inttypes_h.m4, m4/uintmax_t.m4.
4706         (Depends-on): Add stdint.
4707         (lib_SOURCES): Add fsusage.h.
4708         * modules/getcwd (Files): Remove d-ino.m4.
4709         (Depends-on): Add d-ino.
4710         * modules/getndelim2 (Depends-on): Add stdint.
4711         * modules/glob (Files): Remove m4/d-type.m4.
4712         (Depends-on): Add d-type.
4713         * modules/host-os: New module.
4714         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
4715         m4/inttypes_h.m4, m4/uintmax_t.m4.
4716         * Depends-on: Add stdint.
4717         (lib_SOURCES): Add human.h.
4718         * modules/inttostr (Files): Remove m4/intmax_t.m4,
4719         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
4720         m4/uintmax_t.m4, m4/ulonglong.m4.
4721         (Depends-on): Add stdint.
4722         (EXTRA_DIST): Add inttostr.h.
4723         * modules/lchmod: New module.
4724         * modules/link-follow: New module.
4725         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
4726         (Depends-on): Add lchmod.
4727         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
4728         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
4729         (Depends-on): Add stdint.
4730         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
4731         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
4732         (Depends-on): Add stdint.
4733         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
4734         * modules/perl: New module.
4735         * modules/regex (Depends-on): Add stdint.
4736         * modules/rmdir-errno: New module.
4737         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4738         m4/intmax_t.m4.
4739         (Depends-on): Add stdint.
4740         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4741         m4/uintmax_t.m4.
4742         (Depends-on): Add stdint.
4743         * modules/unlink-busy: New module.
4744         * modules/utimecmp (Depends-on): Add stdint.
4745         * modules/uptime: New module.
4746         * modules/winsz-ioctl: New module.
4747         * modules/winsz-termios: New module.
4748         * modules/xnanosleep (Depends-on): Add nanosleep.
4749         * modules/ullong_max: Remove.
4750         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
4751         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
4752         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
4753         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
4754         (Depends-on): Add inttypes.
4755         (lib_SOURCES): Add xstrtol.h.
4756         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
4757         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
4758         * MODULES.html.sh: Move 'assert' into the assert section.
4759         Move 'dummy' into the linking section.
4760         Remove ullong_max.
4761         Add section for compatibility checks for POSIX:2001 functions,
4762         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
4763         winsz-ioctl, and winsz-termios into it.
4764         Add lchmod.
4765         Add top-level Misc section and put host-os, perl, and uptime
4766         into it.
4767
4768 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4769
4770         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
4771         now assume the stdint module.  Do not include inttypes.h.
4772         * lib/fsusage.h: Likewise.
4773         * lib/getndelim2.c: Likewise.
4774         * lib/human.h: Likewise.
4775         * lib/inttostr.h: Likewise.
4776         * lib/obstack.c: Likewise.
4777         * lib/regex_internal.h: Likewise.
4778         * lib/tempname.c: Likewise.
4779         * lib/utimecmp.c: Likewise.
4780         * lib/xstrtol.h: Likewise.
4781
4782         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
4783
4784         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
4785         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
4786         * lib/xtime.h: Likewise.
4787
4788 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4789
4790         * modules/openat (Files): Add lib/fchmodat.c.
4791         Fixes problem reported by Jay Youngman.
4792
4793 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4794
4795         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
4796         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
4797
4798 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
4799             Bruno Haible  <bruno@clisp.org>
4800
4801         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
4802         and is a script that invokes bison. Tighten the code. Add comments.
4803
4804 2006-08-18  Jim Meyering  <jim@meyering.net>
4805
4806         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
4807         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
4808         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
4809         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
4810
4811 2006-08-18  Bruno Haible  <bruno@clisp.org>
4812
4813         * modules/bison-i18n: New file.
4814         * MODULES.html.sh (Internationalization functions): Add it.
4815
4816 2006-08-18  Bruno Haible  <bruno@clisp.org>
4817
4818         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
4819         sys/statvfs.h. When getmntinfo was found, check its declaration and
4820         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
4821
4822 2006-08-18  Bruno Haible  <bruno@clisp.org>
4823
4824         * m4/bison-i18n.m4: New file, from bison.
4825
4826 2006-08-18  Bruno Haible  <bruno@clisp.org>
4827
4828         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
4829         (ME_DUMMY): Treat "kernfs" as a dummy.
4830         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
4831
4832 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4833
4834         Update from coreutils.
4835
4836         2006-08-15  Jim Meyering  <jim@meyering.net>
4837
4838         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
4839
4840         2006-01-17  Jim Meyering  <jim@meyering.net>
4841
4842         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
4843
4844         2006-01-11  Jim Meyering  <jim@meyering.net>
4845
4846         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
4847         Check for the lchmod function.
4848
4849 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4850
4851         Update from coreutils.
4852
4853         * lib/__fpending.h: Add copyright notice.
4854         * lib/fprintftime.h: Likewise.
4855         * lib/savedir.c: Use (C) in copyright notice.
4856         * lib/savedir.h: Likewise.
4857
4858         2006-08-15  Jim Meyering  <jim@meyering.net>
4859
4860         * lib/at-func.c: New file, with the logic of all emulated at-functions.
4861         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
4862         in support of the EXPECTED_ERRNO macro.
4863         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
4864         definitions.  Instead, define the appropriate symbols and include
4865         "at-func.c".
4866         * lib/mkdirat.c (mkdirat): Likewise.
4867         * lib/fchmodat.c (fchmodat): Likewise.
4868         (ENOSYS): Remove definition.
4869         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
4870         it.  Don't include "unistd--.h" -- it wasn't ever used.
4871
4872         2006-01-17  Jim Meyering  <jim@meyering.net>
4873
4874         Rewrite fts.c not to change the current working directory,
4875         by using openat, fstatat, fdopendir, etc..
4876
4877         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
4878         (HAVE_OPENAT_SUPPORT): Define.
4879         [_LIBC] (fchdir): Don't undef or define; no longer used.
4880         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
4881         Now, this `function' always succeeds, and consumes its file descriptor
4882         parameter -- so callers must not close such FDs.  Update callers.
4883         (diropen_fd, opendirat, cwd_advance_fd): New functions.
4884         (diropen): Add parameter, SP.  Adjust all callers.
4885         Implement using diropen_fd, rather than open.
4886         (fts_open): Initialize new member, fts_cwd_fd.
4887         Remove fts_rft-setting code.
4888         (fts_close): Close fts_cwd_fd, if necessary.
4889         (__opendir2): Define in terms of opendir or opendirat,
4890         depending on whether the FST_NOCHDIR flag is set.
4891         (fts_build): Since fts_safe_changedir consumes its FD, and since
4892         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
4893         and close the dup'd file descriptor upon failure.
4894         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
4895         (fts_safe_changedir): Tweak semantics to reflect that this function
4896         now calls cwd_advance_fd and hence consumes its FD argument.
4897         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
4898         [struct FTS] (fts_rft): Remove now-unused member.
4899         [struct FTS] (fts_cycle.state): Improve comment.
4900
4901         * lib/openat.c (openat_needs_fchdir): New function.
4902         * lib/openat.h (openat_needs_fchdir): Declare it.
4903
4904 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
4905
4906         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
4907         Problem and fix reported by Pádraig Brady in
4908         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
4909
4910 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4911
4912         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
4913
4914 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4915
4916         * lib/memcoll.c (memcoll): Optimize for the common case where the
4917         arguments are bytewise equal.
4918
4919 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4920
4921         * doc/regexprops-generic.texi: Add a copyright notice.
4922
4923 2006-08-15  Bruno Haible  <bruno@clisp.org>
4924
4925         * modules/tmpdir (License): Change to LGPL.
4926
4927 2006-08-15  Bruno Haible  <bruno@clisp.org>
4928
4929         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
4930         module.
4931
4932 2006-08-14  Simon Josefsson  <jas@extundo.com>
4933
4934         * config/srclist.txt: Add gnupload.
4935
4936 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4937
4938         Change copyright notice from LGPL 2 to GPL 2, since that's the
4939         standard form used in the gnulib repository.
4940         * tests/test-lock.c: Likewise.
4941         * tests/test-stdint.c: Likewise.
4942         * tests/test-tls.c: Likewise.
4943
4944         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
4945         prelude-manager.  User shorter URLs for GNU projects, without '?'.
4946         Add copyright notice.
4947
4948         * check-module: Add copyright notice.  Output a copyright
4949         notice if "--version" is specified.
4950         * modules/COPYING: New file.
4951         * tests/test-getaddrinfo.c: Add copyright notice.
4952         * tests/test-verify.c: Likewise.
4953
4954 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4955
4956         Change copyright notice from LGPL 2 to GPL 2, since that's the
4957         standard form used in the gnulib repository.
4958         * lib/lock.c: LGPL -> GPL.
4959         * lib/lock.h: Likewise.
4960         * lib/strnlen1.c: Likewise.
4961         * lib/strnlen1.h: Likewise.
4962         * lib/tls.c: Likewise.
4963         * lib/tls.h: Likewise.
4964         * lib/tmpdir.c: Likewise.
4965
4966         * lib/TODO: Remove; this belongs only in coreutils.
4967
4968 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4969
4970         Add copyright notices to long-enough files that lack them, since
4971         otherwise the files aren't clearly free.  Use the same notice that
4972         getdate.texi already uses.
4973         * doc/alloca-opt.texi: Add copyright notice.
4974         * doc/alloca.texi: Likewise.
4975         * doc/ctime.texi: Likewise.
4976         * doc/functions.texi: Likewise.
4977         * doc/gcd.texi: Likewise.
4978         * doc/gnulib-tool.texi: Likewise.
4979         * doc/inet_ntoa.texi: Likewise.
4980         * doc/visibility.texi: Likewise.
4981
4982         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
4983         * doc/quote.texi: Add copyright notice.
4984
4985         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
4986         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
4987         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
4988         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
4989         is now obsolete, and give a pointer to the Sun list.
4990         Add copyright notice.
4991
4992 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4993
4994         * config/srclistvars.sh: Add copyright notice.
4995
4996 2006-08-14  Eric Blake  <ebb9@byu.net>
4997
4998         Import the following change from libc:
4999
5000         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
5001
5002         Upstream bug 2997.
5003         * lib/misc/error.c: Add space between program name and message if file
5004         name is missing.
5005
5006 2006-08-12  Karl Berry  <karl@gnu.org>
5007
5008         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
5009         remove, these originate in gnulib now.
5010
5011 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5012
5013         * doc/Makefile (standards.info standards.html standards.dvi):
5014         Also depend on make-stds.texi.
5015
5016 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
5017
5018         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
5019         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
5020
5021         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
5022         in wchar_t.  Problem reported by Eric Blake.
5023
5024         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
5025         LEN is smaller than SIZE.  Suggested by Bruno Haible.
5026         Also, help the compiler to keep LEN in a register.
5027
5028 2006-08-11  Eric Blake  <ebb9@byu.net>
5029
5030         * users.txt: Sort.  Add tar.
5031
5032 2006-08-11  Bruno Haible  <bruno@clisp.org>
5033
5034         * users.txt: New file.
5035
5036 2006-08-11  Bruno Haible  <bruno@clisp.org>
5037
5038         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
5039         before <wchar.h>. Needed for OSF/1 and BSD/OS.
5040
5041 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5042
5043         * modules/snprintf (Depends-on): Remove minmax.
5044         (Maintainer): Add self and Bruno.
5045
5046 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5047
5048         * lib/.cppi-disable: Add snprintf.h, socket_.h.
5049         * lib/snprintf.c: Include <errno.h> and <limits.h>.
5050         (EOVERFLOW): Define if the system does not.
5051         Do not include "minmax.h"; it wasn't used.
5052         (snprintf): Don't assume size_t promotes to an unsigned type.
5053         Fix bug when generated string was too long for the buffer: the
5054         buffer's contents are supposed to be the initial prefix of the
5055         output.  Don't assume vasnprintf returns EOVERFLOW if the size
5056         exceeds INT_MAX; do the check ourselves.
5057
5058         Import the following changes from libc:
5059
5060         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
5061
5062         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
5063         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
5064         set wc to the byte which couldn't be converted.
5065         (re_string_reconstruct): Don't clear valid_raw_len before calling
5066         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
5067         tip_context using re_string_context_at.
5068
5069         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
5070
5071         * lib/posix/regex.h: g++ still cannot handled [restrict].
5072
5073         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
5074
5075         * lib/posix/regex.h: Remove special handling for VMS.
5076
5077 2006-08-10  Jim Meyering  <jim@meyering.net>
5078
5079         * modules/same-inode: New module.
5080         * modules/dev-ino: New module.
5081         * modules/cycle-check: Depend on these modules, rather than simply
5082         including their .h files.
5083         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
5084         required via m4/cycle-check.m4.
5085         * modules/same: Depend on new same-inode module, rather than
5086         including same-inode.h.
5087         * modules/chdir-safer: New file.
5088
5089         * modules/chown (Depends-on): Add stat-macros.
5090
5091 2006-08-10  Jim Meyering  <jim@meyering.net>
5092
5093         * m4/cycle-check.m4: New file.
5094         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
5095         * m4/dev-ino.m4, m4/same-inode.m4: New files.
5096
5097 2006-08-10  Eric Blake  <ebb9@byu.net>
5098
5099         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
5100         in from original proposal.
5101
5102 2006-08-10  Eric Blake  <ebb9@byu.net>
5103         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
5104
5105         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
5106         namespace.
5107
5108 2006-08-10  Bruno Haible  <bruno@clisp.org>
5109
5110         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
5111         as well.
5112
5113 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5114
5115         Sync from coreutils.
5116
5117         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
5118
5119         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
5120         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
5121
5122 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5123
5124         * modules/restrict: Remove; no longer needed now that we assume
5125         Autoconf 2.59 or later.
5126         * MODULES.html.sh: Remove 'restrict'.
5127         * modules/argp (Depends-on): Remove 'restrict'.
5128         * modules/base64 (Depends-on): Likewise.
5129         * modules/gc (Depends-on): Likewise.
5130         * modules/getaddrinfo (Depends-on): Likewise.
5131         * modules/glob (Depends-on): Likewise.
5132         * modules/inet_ntop (Depends-on): Likewise.
5133         * modules/inet_pton (Depends-on): Likewise.
5134         * modules/memxor (Depends-on): Likewise.
5135         * modules/regex (Depends-on): Likewise.
5136         * modules/strtok_r (Depends-on): Likewise.
5137         * modules/time_r (Depends-on): Likewise.
5138
5139 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5140
5141         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
5142         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
5143         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5144         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
5145         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
5146         * m4/memxor.m4 (gl_MEMXOR): Likewise.
5147         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
5148         gl_C_RESTRICT replaced by AC_C_RESTRICT.
5149
5150         Merge from coreutils.
5151         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
5152         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
5153         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
5154         * m4/time_r.m4 (gl_TIME_R): Likewise.
5155
5156 2006-08-09  Karl Berry  <karl@gnu.org>
5157
5158         * config/srclist.txt: no more gettext-tools, per Bruno.
5159
5160 2006-08-08  Eric Blake  <ebb9@byu.net>
5161
5162         * modules/verror: New module.
5163         * MODULES.html.sh: Document it.
5164
5165 2006-08-08  Eric Blake  <ebb9@byu.net>
5166
5167         * lib/verror.h, lib/verror.c: New files.
5168
5169 2006-08-08  Eric Blake  <ebb9@byu.net>
5170
5171         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
5172         verror_at_line output complies with GNU Coding Standards even when
5173         file is NULL.
5174
5175 2006-08-07  Bruno Haible  <bruno@clisp.org>
5176
5177         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
5178         versions of AIX.
5179         Reported by Ralf Wildenhues.
5180
5181 2006-08-07  Bruno Haible  <bruno@clisp.org>
5182
5183         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
5184         in an AC_DEFUN. Needed so that the autoconf snippets can use
5185         AC_REQUIRE.
5186
5187 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5188
5189         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5190         Initialize pkgdata_DATA.
5191         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
5192         overriding it.
5193
5194 2006-08-06  Eric Blake  <ebb9@byu.net>
5195
5196         * lib/error.h: Fold in some upstream changes from glibc.
5197         * lib/error.c: Likewise.
5198
5199 2006-08-04  Bruno Haible  <bruno@clisp.org>
5200
5201         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5202         Make the mostlyclean-local rule depend on mostlyclean-generic.
5203         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
5204
5205 2006-07-31  Bruno Haible  <bruno@clisp.org>
5206
5207         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
5208         <stdlib.h>, <string.h>.
5209
5210 2006-07-30  Bruno Haible  <bruno@clisp.org>
5211
5212         * modules/readlink (License): Change to LGPL.
5213
5214 2006-07-30  Bruno Haible  <bruno@clisp.org>
5215
5216         * modules/javaversion (Makefile.am): Distribute javaversion.java and
5217         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
5218         set PKGDATADIR to point to it.
5219
5220 2006-07-30  Bruno Haible  <bruno@clisp.org>
5221
5222         * modules/csharpexec (configure.ac): Comment out macro invocation.
5223         * modules/javaexec (configure.ac): Likewise.
5224         * modules/javacomp-script (configure.ac): Likewise.
5225
5226         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
5227
5228 2006-07-30  Bruno Haible  <bruno@clisp.org>
5229
5230         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
5231         linked-list.
5232
5233 2006-07-30  Bruno Haible  <bruno@clisp.org>
5234
5235         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
5236
5237 2006-07-30  Bruno Haible  <bruno@clisp.org>
5238
5239         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5240         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
5241         get removed.
5242
5243 2006-07-29  Bruno Haible  <bruno@clisp.org>
5244
5245         Make it possible for gnulib-tool to work with locally modified or
5246         augmented gnulib repositories.
5247         * gnulib-tool (func_usage): Document --local-dir option.
5248         (local_gnulib_dir): New variable.
5249         Handle --local-dir option.
5250         (func_lookup_file): New function.
5251         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
5252         (func_get_description, func_get_filelist, func_get_description,
5253         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
5254         func_get_automake_snippet, func_get_include_directive,
5255         func_get_license, func_get_maintainer): Use func_lookup_file.
5256         (func_import, func_create_testdir): Use func_lookup_file.
5257
5258 2006-07-29  Bruno Haible  <bruno@clisp.org>
5259
5260         * modules/setenv (Depends-on): Add unistd.
5261
5262 2006-07-29  Bruno Haible  <bruno@clisp.org>
5263
5264         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
5265
5266 2006-07-29  Bruno Haible  <bruno@clisp.org>
5267
5268         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
5269
5270 2006-07-29  Bruno Haible  <bruno@clisp.org>
5271
5272         * gnulib-tool (import, update): If there is no Makefile.am, look at
5273         aclocal.m4, instead of bailing out.
5274
5275 2006-07-29  Bruno Haible  <bruno@clisp.org>
5276
5277         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
5278         Categorize the options by when they are useful.
5279
5280 2006-07-29  Bruno Haible  <bruno@clisp.org>
5281
5282         * gnulib-tool (func_usage): Document option --no-libtool.
5283         Handle option --no-libtool.
5284         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
5285         for changed semantics of $libtool variable.
5286         (func_import): Likewise. If libtool is not used, show this through
5287         an option --no-libtool.
5288         (func_create_testdir): Update.
5289
5290 2006-07-29  Bruno Haible  <bruno@clisp.org>
5291
5292         * gnulib-tool (func_import): Extend error message about missing
5293         --doc-base.
5294
5295 2006-07-29  Bruno Haible  <bruno@clisp.org>
5296
5297         * gnulib-tool (func_import): Don't create the $docbase directory if
5298         there is no file to store there.
5299
5300 2006-07-29  Bruno Haible  <bruno@clisp.org>
5301
5302         * gnulib-tool (autoconf_minversion): If a --dir option is given and
5303         relevant, look for configure.ac there, not in the current directory.
5304         Also use a simple search for AC_PREREQ, not "autoconf --trace".
5305
5306 2006-07-29  Bruno Haible  <bruno@clisp.org>
5307
5308         * gnulib-tool (SORT): New variable.
5309         (func_usage): Undocument --assume-autoconf option.
5310         Remove --assume-autoconf option handling.
5311         (autoconf_minversion): Determine from the contents of configure.ac.
5312         (func_import): Remove autoconf_minversion handling.
5313         Suggested by Eric Blake.
5314
5315 2006-07-29  Bruno Haible  <bruno@clisp.org>
5316
5317         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
5318
5319 2006-07-29  Bruno Haible  <bruno@clisp.org>
5320
5321         * config/srclist.txt (*setenv.[ch]): Remove rules.
5322
5323 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5324
5325         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
5326
5327 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5328
5329         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
5330         arpa/inet.h.
5331
5332 2006-07-28  Simon Josefsson  <jas@extundo.com>
5333
5334         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
5335         * modules/inet_pton (Depends-on): Likewise.
5336
5337 2006-07-28  Simon Josefsson  <jas@extundo.com>
5338
5339         * m4/netinet_in_h.m4: New file.
5340
5341 2006-07-28  Simon Josefsson  <jas@extundo.com>
5342
5343         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
5344         #include's.
5345
5346 2006-07-28  Simon Josefsson  <jas@extundo.com>
5347
5348         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
5349         #include's.
5350
5351 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
5352
5353         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
5354         setgid on directories only if they set these bits.
5355         * lib/modechange.h: Remove obsolete comment about masks.
5356
5357 2006-07-28  Eric Blake  <ebb9@byu.net>
5358
5359         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
5360         macro expansion.
5361
5362 2006-07-28  Bruno Haible  <bruno@clisp.org>
5363
5364         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
5365
5366 2006-07-28  Bruno Haible  <bruno@clisp.org>
5367
5368         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
5369
5370 2006-07-28  Bruno Haible  <bruno@clisp.org>
5371
5372         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
5373         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
5374         Define fallbacks.
5375         Avoids link error on FreeBSD 4.x.
5376         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
5377
5378         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
5379         encoding.
5380         * lib/mbswidth.c (iswcntrl): Likewise.
5381
5382 2006-07-27  Bruno Haible  <bruno@clisp.org>
5383
5384         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
5385         test.
5386
5387 2006-07-27  Bruno Haible  <bruno@clisp.org>
5388
5389         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
5390         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
5391         defined.
5392
5393 2006-07-26  Eric Blake  <ebb9@byu.net>
5394
5395         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
5396
5397 2006-07-26  Eric Blake  <ebb9@byu.net>
5398
5399         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
5400         like mingw that lack mkstemp.
5401         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
5402         avoid compilation warning on mingw.
5403
5404 2006-07-26  Bruno Haible  <bruno@clisp.org>
5405
5406         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
5407         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
5408         INT_FAST*_MIN, INTPTR_MIN.
5409
5410 2006-07-25  Bruno Haible  <bruno@clisp.org>
5411
5412         * modules/version-etc (Depends-on): Add stdarg.
5413
5414 2006-07-25  Bruno Haible  <bruno@clisp.org>
5415
5416         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
5417         complex commands.
5418
5419 2006-07-25  Bruno Haible  <bruno@clisp.org>
5420
5421         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
5422         defined in <stdarg.h> or config.h.
5423
5424 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5425
5426         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
5427         (gl_STDIO_SAFER): Remove.
5428
5429 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5430
5431         * MODULES.html.sh (File stream based Input/Output):
5432         Add fopen-safer, tmpfile-safer; remove stdio-safer.
5433         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
5434         * modules/fopen-safer, modules/tmpfile-safer: New files.
5435         * modules/stdio-safer: Remove.
5436
5437 2006-07-24  Bruno Haible  <bruno@clisp.org>
5438
5439         * modules/tmpdir: New file.
5440         * MODULES.html.sh (File system functions): Add it.
5441
5442 2006-07-24  Bruno Haible  <bruno@clisp.org>
5443
5444         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
5445         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
5446
5447 2006-07-24  Bruno Haible  <bruno@clisp.org>
5448
5449         * modules/clean-temp: New file.
5450
5451 2006-07-24  Bruno Haible  <bruno@clisp.org>
5452
5453         * m4/tmpdir.m4: New file, from GNU gettext.
5454
5455 2006-07-24  Bruno Haible  <bruno@clisp.org>
5456
5457         * lib/tmpdir.h: New file, from GNU gettext.
5458         * lib/tmpdir.c: New file, from GNU gettext.
5459
5460 2006-07-24  Bruno Haible  <bruno@clisp.org>
5461
5462         * lib/clean-temp.h: New file, from GNU gettext.
5463         * lib/clean-temp.c: New file, from GNU gettext.
5464
5465 2006-07-23  Eric Blake  <ebb9@byu.net>
5466
5467         * modules/stdio-safer (Files): Add tmpfile-safer.c.
5468         (Depends-on): Add binary-io.
5469
5470 2006-07-23  Eric Blake  <ebb9@byu.net>
5471
5472         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
5473
5474 2006-07-23  Eric Blake  <ebb9@byu.net>
5475
5476         * lib/tmpfile-safer.c: New file.
5477         * lib/stdio-safer.h (fopen_safer): Add prototype.
5478         * lib/stdio--.h (tmpfile): Make safer.
5479
5480 2006-07-23  Bruno Haible  <bruno@clisp.org>
5481
5482         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
5483         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
5484         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
5485         gl_linked_remove_at): Use it.
5486
5487 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5488         and Simon Josefsson <jas@extundo.com>
5489
5490         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
5491
5492         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
5493
5494 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5495
5496         * modules/close-stream: New file.
5497         * modules/closeout (Description): Make it clear that it exits
5498         with a diagnostic on error.
5499         (Depends-on): Add close-stream.  Remove fpending, stdbool.
5500         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
5501
5502 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5503
5504         * m4/close-stream.m4: New file.
5505
5506 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5507
5508         * lib/close-stream.c, lib/close-stream.h: New files.
5509
5510 2006-07-22  Bruno Haible  <bruno@clisp.org>
5511
5512         Merge from GNU gettext 0.15.
5513
5514         2006-05-01  Bruno Haible  <bruno@clisp.org>
5515
5516                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
5517
5518         2006-07-22  Bruno Haible  <bruno@clisp.org>
5519
5520                 * modules/javaversion: New file.
5521                 * MODULES.html.sh (Java): Add javaversion.
5522
5523         2006-03-12  Bruno Haible  <bruno@clisp.org>
5524
5525                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
5526
5527         2005-12-04  Bruno Haible  <bruno@clisp.org>
5528
5529                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
5530                 (untested).
5531
5532         2006-06-21  Bruno Haible  <bruno@clisp.org>
5533
5534                 Avoid warnings from recent versions of mcs.
5535                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
5536                 -o, -L, -r any more. Use options documented since mcs-1.0
5537                 instead. Similarly for -g.
5538
5539         2005-12-04  Bruno Haible  <bruno@clisp.org>
5540
5541                 * build-aux/csharpcomp.sh.in: Suffix for resources is
5542                 .resources, not .resource.
5543
5544         2005-07-09  Bruno Haible  <bruno@clisp.org>
5545
5546                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
5547                 add a .dll suffix.
5548                 Reported by Mark Junker <mjscod@gmx.de>.
5549
5550         2006-07-22  Bruno Haible  <bruno@clisp.org>
5551
5552                 * modules/gettext: Upgrade to gettext-0.15.
5553                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
5554                 m4/visibility.m4.
5555                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
5556
5557 2006-07-22  Bruno Haible  <bruno@clisp.org>
5558
5559         Merge from GNU gettext 0.15.
5560
5561         2006-03-25  Bruno Haible  <bruno@clisp.org>
5562
5563                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
5564
5565         2006-07-21  Bruno Haible  <bruno@clisp.org>
5566
5567                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
5568                 "1.1".
5569
5570         2006-05-09  Bruno Haible  <bruno@clisp.org>
5571
5572                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
5573                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
5574                 for the conftestver execution.
5575
5576         2006-05-01  Bruno Haible  <bruno@clisp.org>
5577
5578                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
5579                 optional target-version argument. Verify that the compiler
5580                 groks source of the specified source-version, or add -source
5581                 option as necessary. Verify that the compiler produces
5582                 bytecode in the specified target-version, or add -target and
5583                 -source options as necessary. Make the result of the test
5584                 available as variable CONF_JAVAC. Also log error output in
5585                 config.log.
5586
5587         2006-03-11  Bruno Haible  <bruno@clisp.org>
5588
5589                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
5590
5591         2006-05-09  Bruno Haible  <bruno@clisp.org>
5592
5593                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
5594                 CLASSPATH_SEPARATOR to a semicolon.
5595
5596         2006-03-12  Bruno Haible  <bruno@clisp.org>
5597
5598                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
5599                 available as variable CONF_JAVA, for subsequent autoconf
5600                 tests. Also log error output in config.log.
5601
5602         2006-07-19  Bruno Haible  <bruno@clisp.org>
5603
5604                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
5605                 that getline works on glibc2 systems. Needed to avoid trouble
5606                 in relocatable.c.
5607                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
5608
5609         2005-12-04  Bruno Haible  <bruno@clisp.org>
5610
5611                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
5612                 launcher (untested).
5613
5614         2005-12-04  Bruno Haible  <bruno@clisp.org>
5615
5616                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
5617
5618         2006-07-22  Bruno Haible  <bruno@clisp.org>
5619
5620                 * gettext.m4: Update from GNU gettext-0.15.
5621                 * nls.m4: Likewise.
5622                 * po.m4: Likewise.
5623                 * inttypes-pri.m4: Likewise.
5624                 * inttypes-h.m4: Renamed from inttypes.m4.
5625                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
5626
5627 2006-07-22  Bruno Haible  <bruno@clisp.org>
5628
5629         Merge from GNU gettext 0.15.
5630
5631         2005-07-05  Bruno Haible  <bruno@clisp.org>
5632
5633                 * printf-args.c (printf_fetchargs): Work around broken
5634                 definition of wint_t on mingw.
5635
5636         2005-02-12  Bruno Haible  <bruno@clisp.org>
5637
5638                 * xallocsa.h: Add extern "C" for C++.
5639
5640         2006-05-17  Bruno Haible  <bruno@clisp.org>
5641
5642                 Cygwin portability.
5643                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
5644
5645         2006-04-30  Bruno Haible  <bruno@clisp.org>
5646
5647                 * progreloc.c: Include <mach-o/dyld.h> if available.
5648                 (find_executable): Use _NSGetExecutablePath when possible.
5649
5650         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5651
5652                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
5653                 function.
5654
5655         2005-12-29  Bruno Haible  <bruno@clisp.org>
5656
5657                 * progreloc.c (set_program_name_and_installdir): Fix
5658                 compilation error.
5659
5660         2005-12-04  Bruno Haible  <bruno@clisp.org>
5661
5662                 Cygwin portability.
5663                 * progreloc.c: Include <windows.h> also on Cygwin.
5664                 (find_executable): Add support for Cygwin.
5665                 (set_program_name_and_installdir): Handle also platforms with
5666                 nonempty EXEEXT.
5667
5668         2006-07-11  Bruno Haible  <bruno@clisp.org>
5669
5670                 * javacomp.c: Fix a comment.
5671                 Reported by Jim Meyering.
5672
5673         2006-04-30  Bruno Haible  <bruno@clisp.org>
5674
5675                 * javacomp.h (compile_java_class): Add source_version,
5676                 target_version arguments.
5677                 * javacomp.c: Rewritten to choose only a compiler that
5678                 respects the specified source_version and target_version.
5679
5680         2006-06-27  Bruno Haible  <bruno@clisp.org>
5681
5682                 Assume correct S_ISDIR macro.
5683                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
5684
5685         2006-07-22  Bruno Haible  <bruno@clisp.org>
5686
5687                 * javaversion.h: New file, from GNU gettext.
5688                 * javaversion.c: New file, from GNU gettext.
5689                 * javaversion.java: New file, from GNU gettext.
5690                 * javaversion.class: New file, from GNU gettext.
5691
5692         2006-05-17  Bruno Haible  <bruno@clisp.org>
5693
5694                 Cygwin portability.
5695                 * javaexec.c (execute_java_class): Test for jview program
5696                 also on Cygwin.
5697
5698         2006-04-09  Bruno Haible  <bruno@clisp.org>
5699
5700                 * fatal-signal.c: Don't include string.h.
5701                 (at_fatal_signal): Use a copying loop instead of memcpy.
5702
5703         2005-12-04  Bruno Haible  <bruno@clisp.org>
5704
5705                 * csharpexec.c: Add support for 'clix' launcher (untested).
5706                 (execute_csharp_using_sscli): New function.
5707                 (execute_csharp_program): Call it.
5708
5709         2006-06-21  Bruno Haible  <bruno@clisp.org>
5710
5711                 Avoid warnings from recent versions of mcs.
5712                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
5713                 -o, -L, -r any more. Use options documented since mcs-1.0
5714                 instead. Similarly for -g.
5715
5716         2005-07-09  Bruno Haible  <bruno@clisp.org>
5717
5718                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
5719                 add a .dll suffix.
5720                 Reported by Mark Junker <mjscod@gmx.de>.
5721
5722         2006-06-17  Bruno Haible  <bruno@clisp.org>
5723
5724                 * config.charset: Update for NetBSD 3.0.
5725
5726         2006-05-17  Bruno Haible  <bruno@clisp.org>
5727
5728                 Cygwin portability.
5729                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
5730
5731         2006-05-16  Bruno Haible  <bruno@clisp.org>
5732
5733                 * localcharset.c [CYGWIN]: Include <windows.h>.
5734                 (get_charset_aliases): For Cygwin, return the same CPxxx
5735                 aliases list as under WIN32.
5736                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
5737                 the environment variables. Fall back to GetACP().
5738
5739         2006-04-05  Bruno Haible  <bruno@clisp.org>
5740
5741                 * config.charset: Update Juan Manuel Guerrero's address.
5742
5743         2005-02-12  Bruno Haible  <bruno@clisp.org>
5744
5745                 * allocsa.h: Add extern "C" for C++.
5746
5747         2005-02-10  Bruno Haible  <bruno@clisp.org>
5748
5749                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
5750                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
5751
5752         2006-07-22  Bruno Haible  <bruno@clisp.org>
5753
5754                 * gettext.h: Update to GNU gettext-0.15.
5755
5756 2006-07-22  Bruno Haible  <bruno@clisp.org>
5757
5758         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
5759         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
5760         lib-prefix.m4, longdouble.m4, ssize_t.m4.
5761
5762 2006-07-21  Eric Blake  <ebb9@byu.net>
5763
5764         * modules/stdlib-safer: New file.
5765         * MODULES.html.sh (File stream based Input/Output): Add
5766         stdlib-safer.
5767
5768 2006-07-21  Eric Blake  <ebb9@byu.net>
5769
5770         * lib/stdlib-safer.h: New file from coreutils, required by
5771         stdlib--.h.
5772
5773 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
5774
5775         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
5776
5777 2006-07-20  Bruno Haible  <bruno@clisp.org>
5778
5779         * gnulib-tool: Recognize new option --assume-autoconf.
5780         (autoconf_minversion): New variable.
5781         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
5782
5783 2006-07-20  Bruno Haible  <bruno@clisp.org>
5784
5785         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
5786
5787 2006-07-19  Derek R. Price  <derek@ximbiot.com>
5788
5789         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
5790         Reindent and repaginate.
5791
5792 2006-07-19  Derek Price  <derek@ximbiot.com>
5793
5794         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
5795         Correct grammar.
5796
5797 2006-07-17  Bruno Haible  <bruno@clisp.org>
5798
5799         * modules/list: New file.
5800         * modules/array-list: New file.
5801         * modules/carray-list, modules/carray-list-tests: New files.
5802         * modules/linked-list, modules/linked-list-tests: New files.
5803         * modules/avltree-list, modules/avltree-list-tests: New files.
5804         * modules/rbtree-list, modules/rbtree-list-tests: New files.
5805         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
5806         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
5807         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
5808         * modules/oset: New file.
5809         * modules/array-oset: New file.
5810         * modules/avltree-oset, modules/avltree-oset-tests: New files.
5811         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
5812         * tests/test-carray_list.c: New file.
5813         * tests/test-linked_list.c: New file.
5814         * tests/test-avltree_list.c: New file.
5815         * tests/test-rbtree_list.c: New file.
5816         * tests/test-linkedhash_list.c: New file.
5817         * tests/test-avltreehash_list.c: New file.
5818         * tests/test-rbtreehash_list.c: New file.
5819         * tests/test-avltree_oset.c: New file.
5820         * tests/test-rbtree_oset.c: New file.
5821         * MODULES.html.sh (Container data structures): New section.
5822
5823 2006-07-17  Bruno Haible  <bruno@clisp.org>
5824
5825         * m4/gl_list.m4: New file.
5826
5827 2006-07-17  Bruno Haible  <bruno@clisp.org>
5828
5829         * lib/gl_list.h: New file.
5830         * lib/gl_list.c: New file.
5831         * lib/gl_array_list.h: New file.
5832         * lib/gl_array_list.c: New file.
5833         * lib/gl_carray_list.h: New file.
5834         * lib/gl_carray_list.c: New file.
5835         * lib/gl_linked_list.h: New file.
5836         * lib/gl_linked_list.c: New file.
5837         * lib/gl_anylinked_list1.h: New file.
5838         * lib/gl_anylinked_list2.h: New file.
5839         * lib/gl_avltree_list.h: New file.
5840         * lib/gl_avltree_list.c: New file.
5841         * lib/gl_anyavltree_list1.h: New file.
5842         * lib/gl_anyavltree_list2.h: New file.
5843         * lib/gl_rbtree_list.h: New file.
5844         * lib/gl_rbtree_list.c: New file.
5845         * lib/gl_anyrbtree_list1.h: New file.
5846         * lib/gl_anyrbtree_list2.h: New file.
5847         * lib/gl_anytree_list1.h: New file.
5848         * lib/gl_anytree_list2.h: New file.
5849         * lib/gl_linkedhash_list.h: New file.
5850         * lib/gl_linkedhash_list.c: New file.
5851         * lib/gl_anyhash_list1.h: New file.
5852         * lib/gl_anyhash_list2.h: New file.
5853         * lib/gl_avltreehash_list.h: New file.
5854         * lib/gl_avltreehash_list.c: New file.
5855         * lib/gl_rbtreehash_list.h: New file.
5856         * lib/gl_rbtreehash_list.c: New file.
5857         * lib/gl_anytreehash_list1.h: New file.
5858         * lib/gl_anytreehash_list2.h: New file.
5859
5860         * lib/gl_oset.h: New file.
5861         * lib/gl_oset.c: New file.
5862         * lib/gl_array_oset.h: New file.
5863         * lib/gl_array_oset.c: New file.
5864         * lib/gl_avltree_oset.h: New file.
5865         * lib/gl_avltree_oset.c: New file.
5866         * lib/gl_rbtree_oset.h: New file.
5867         * lib/gl_rbtree_oset.c: New file.
5868         * lib/gl_anytree_oset.h: New file.
5869
5870 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5871
5872         * m4/mkancesdirs.m4: New file.
5873         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
5874         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
5875         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
5876         it.
5877
5878 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5879
5880         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
5881         * lib/mkancesdirs.h: New files.
5882         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
5883         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
5884         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
5885         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
5886         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
5887         callers changed.  Revamp internals significantly, by not
5888         attempting to create directories that are temporarily more
5889         permissive than the final results.  Do not attempt to use
5890         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
5891         This removes some race conditions, fixes some bugs, and simplifies
5892         things.  Use new dirchownmod function to do owner and mode changes.
5893         * lib/mkdir-p.h: Likewise.
5894         * lib/modechange.c (octal_to_mode): New function.
5895         (struct mode_change): New member mentioned.
5896         (make_node_op_equals): New arg mentioned.  All callers changed.
5897         (mode_compile): Keep track of which mode bits the user has explicitly
5898         mentioned.
5899         (mode_adjust): New arg DIR, so that we implement the X op correctly.
5900         New arg PMODE_BITS, to keep track of which mode bits the user
5901         mentioned; it treats S_ISUID and S_ISGID speciall.
5902         All callers changed.
5903         * lib/modechange.h: Likewise.
5904
5905 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5906
5907         * MODULES.html.sh: Add mkancestors.
5908         * modules/mkancesdirs: New module.
5909         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
5910         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
5911         The chdir-safer and afs files are now orphans; I'll remove them
5912         unless someone speaks up.
5913         Add lib/dirchownmod.c, lib/dirchownmod.h.
5914         (Depends-on): Remove alloca, chown, save-cwd, dirname.
5915         Add lchown, mkancesdirs.
5916         (Maintainer): Add self.
5917
5918 2006-07-15  Karl Berry  <karl@gnu.org>
5919
5920         * gnulib-tool: help message wording/arrangement.
5921
5922 2006-07-14  Simon Josefsson  <jas@extundo.com>
5923
5924         * doc/gnulib.texi (Libtool and Windows): New section.
5925
5926 2006-07-12  Simon Josefsson  <jas@extundo.com>
5927
5928         * modules/gendocs (License): Fix license, approved by Karl.
5929
5930 2006-07-12  Eric Blake  <ebb9@byu.net>
5931
5932         * MODULES.html.sh: Add gendocs.
5933
5934 2006-07-11  Eric Blake  <ebb9@byu.net>
5935
5936         * modules/fdl: New module, to install doc/fdl.texi.
5937         * MODULES.html.sh: Add new section for documentation modules.
5938         * gnulib-tool: Avoid space-tab.
5939         (--doc-base): New option, to manage files from doc.
5940
5941 2006-07-11  Eric Blake  <ebb9@byu.net>
5942
5943         * m4/absolute-header.m4: Fix comments to match recent change.
5944
5945 2006-07-11  Eric Blake  <ebb9@byu.net>
5946
5947         * gnulib-tool: List --doc-base before --tests-base.
5948
5949 2006-07-11  Derek R. Price  <derek@ximbiot.com>
5950
5951         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
5952
5953 2006-07-11  Bruno Haible  <bruno@clisp.org>
5954
5955         * README: Mention where to put documentation.
5956
5957 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5958
5959         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
5960
5961 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5962
5963         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
5964         to stdint.m4.
5965
5966 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5967
5968         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
5969         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
5970         "no/such/file/stdint.h" when there is no such file, so that
5971         the resulting C code can be parsed by dodgy compilers.
5972         Problems reported by Bob Proulx.
5973
5974 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5975
5976         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
5977         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5978         macros into the GNU _D_EXACT_NAMLEN.
5979         * lib/savedir.c:  Likewise.
5980         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
5981
5982 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5983         and Paul Eggert  <eggert@cs.ucla.edu>
5984
5985         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
5986         * m4/savedir.m4:
5987         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5988         macros into the GNU _D_EXACT_NAMLEN.
5989
5990 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5991
5992         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
5993         around the absolute name, to work around a problem with the HP-UX
5994         11.23 native C compiler, reported by Bob Proulx.
5995
5996 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5997
5998         * doc/maintain.texi, make-stds.texi: Sync from
5999         <http://savannah.gnu.org/projects/gnustandards>.
6000
6001 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6002
6003         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
6004
6005 2006-07-09  Jim Meyering  <jim@meyering.net>
6006
6007         * m4/glob.m4: Remove a doubled word in a comment.
6008
6009 2006-07-09  Jim Meyering  <jim@meyering.net>
6010
6011         * lib/argp-pv.c: Remove a doubled word in a comment.
6012         * lib/check-version.c (check_version): Likewise.
6013         * lib/javacomp.c (compile_java_class): Likewise.
6014
6015 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
6016
6017         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
6018         for the benefit of people using Autoconf 2.60.  If you want to
6019         support older Autoconf versions you can copy m4/onceonly_2_57.m4
6020         (or m4/onceonly.m4, if pre-2.57) manually.
6021
6022 2006-07-08  Jim Meyering  <jim@meyering.net>
6023
6024         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
6025         comment.
6026         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
6027         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
6028         comment.
6029
6030 2006-07-08  Jim Meyering  <jim@meyering.net>
6031
6032         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
6033
6034 2006-07-07  Simon Josefsson  <jas@extundo.com>
6035
6036         * tests/test-crc.c: Change expected crc value, the test vector
6037         were probably computed using the old broken crc.c?
6038
6039 2006-07-06  Simon Josefsson  <jas@extundo.com>
6040
6041         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
6042         now the canonical place for the M4 file).
6043
6044         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
6045         from the sys_socket dependency now.
6046
6047         * modules/inet_pton (Files): Ditto.
6048
6049         * modules/inet_ntop (Files): Ditto.
6050
6051 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
6052
6053         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
6054         not gl_PREREQ_GETUSERSHELL.
6055
6056 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6057
6058         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
6059         with only one argument, for Autoconf 2.60.
6060         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
6061         expand to nothing, so add a shell command to avoid syntax error.
6062         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
6063
6064 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6065
6066         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
6067
6068 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6069
6070         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
6071         no longer needed.  Check for isblank decl.
6072         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
6073         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
6074         of existence.
6075
6076 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6077
6078         * lib/getloadavg.c: Use __VMS, not VMS.
6079         * lib/getopt.c: Likewise.
6080         * lib/getpagesize.h: Likewise.
6081         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
6082         and probably does not work.
6083
6084 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6085
6086         * lib/.cppi-disable: Add wcwidth.
6087         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
6088         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
6089         (ISGRAPH): Remove.  All uses changed to isgraph.
6090         (FOLD) [!defined _LIBC]: Remove special case.
6091         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
6092         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
6093         HAVE_ISBLANK.
6094         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
6095         case.
6096
6097 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6098
6099         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
6100         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
6101         brackets.  Other minor changes to suppress some compiler
6102         warnings.
6103
6104 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6105         and Paul Eggert  <eggert@cs.ucla.edu>
6106
6107         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
6108         of invoking obsolescent AC_HEADER_DIRENT macro.
6109         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
6110         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
6111         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
6112         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
6113         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
6114         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
6115         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
6116         * m4/readdir.m4: Remove; no longer needed.
6117
6118 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6119         and Paul Eggert  <eggert@cs.ucla.edu>
6120
6121         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
6122         Don't worry about this obsolete case any more.
6123         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
6124         directories.
6125         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
6126         worry about this obsolete case any more.
6127         * lib/fts.c: Likewise.
6128         * lib/getcwd.c: Likewise.
6129         * lib/glob.h: Likewise.
6130         * lib/savedir.c: Likewise.
6131
6132 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6133
6134         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
6135         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
6136         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
6137         needed.
6138         All uses removed.
6139         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6140         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6141         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
6142         needed.
6143         * m4/getdate.m4 (gl_GETDATE): Likewise.
6144         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6145         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6146         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6147         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6148         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6149         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6150         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
6151         needed.
6152
6153 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6154
6155         * lib/memcasecmp.c: Include <limits.h>.
6156         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
6157         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
6158         Don't assume isdigit succeeds only on '0' through '9'.
6159
6160 2006-07-05  Eric Blake  <ebb9@byu.net>
6161
6162         * modules/getaddrinfo (Depends-on): Add snprintf.
6163
6164 2006-07-05  Eric Blake  <ebb9@byu.net>
6165
6166         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
6167         to avoid 'header present but could not be compiled' on cygwin.
6168
6169 2006-07-05  Eric Blake  <ebb9@byu.net>
6170
6171         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
6172         missing from netdb.h.
6173         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
6174
6175 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6176
6177         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
6178         no longer needed.
6179         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
6180         * m4/getdate.m4 (gl_GETDATE): Likewise.
6181         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6182         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6183         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6184         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6185         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6186
6187 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6188
6189         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
6190         All uses of is_space replaced by isspace.
6191         * lib/exit.h: Don't talk about STDC_HEADERS.
6192         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
6193         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
6194         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
6195         replaced by isprint etc.
6196         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
6197         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6198         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
6199         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
6200         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
6201         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6202
6203 2006-07-05  Bruno Haible  <bruno@clisp.org>
6204
6205         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
6206         the function exists, before testing against AIX.
6207         Reported by Martin Lambers <marlam@marlam.de>.
6208
6209 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6210
6211         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
6212         From Mark D. Baushke.
6213
6214 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6215
6216         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
6217         to the absolute name, not just one, to bypass Sun C 5.8's
6218         "warning: #include of /usr/include/... may be non-portable".
6219
6220 2006-07-04  Eric Blake  <ebb9@byu.net>
6221
6222         * modules/dirname-tests: New test module.
6223         * tests/test-dirname.c: New file, replacing dirname.c
6224         TEST_DIRNAME section that was recently deleted.
6225
6226 2006-07-04  Bruno Haible  <bruno@clisp.org>
6227
6228         Assume ANSI C header files and <ctype.h> functions.
6229         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
6230         (mbsnwidth): Use isprint, iscntrl instead.
6231
6232 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6233
6234         Merge from coreutils.
6235         * MODULES.html.sh: Add xstrtold.
6236         * modules/xstrtold: New file.
6237         * modules/cycle-check (Files): Add lib/same-inode.h.
6238         * modules/dirname (Files): Add m4/double-slash-root.m4.
6239         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
6240         * modules/mkdir-p (Files): Add lib/same-inode.h.
6241         * modules/same (Files): Add lib/same-inode.h.
6242
6243 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6244
6245         * m4/absolute-header.m4: Renamed from full-header-path.m4.
6246         This is to keep the terminology clean; POSIX talks about
6247         "absolute pathnames", not "full pathnames", but the GNU
6248         Coding Standards say to use "path" for something else;
6249         so use "absolute" to keep both sides happy.
6250         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
6251         Set gl_absolute_header, not gl_full_header_path.
6252         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
6253         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
6254         All uses changed.
6255
6256         Merge from coreutils.
6257
6258         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6259
6260         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
6261         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
6262         want to require the building of c-strtod.o.
6263         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
6264         needs -lm directly.
6265         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
6266
6267         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6268
6269         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
6270         --as-needed option if available.  Problem reported by Albert Chin in
6271         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
6272         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
6273         cc merely issues a bunch of annoying warnings for --as-needed
6274         (this problem was reported by Bob Proulx).  Also, try linking with
6275         -lm to detect a bug in binutils 2.16 (this problem was reported
6276         by Ralf Wildenhues).
6277
6278         2006-06-18  Jim Meyering  <jim@meyering.net>
6279
6280         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
6281         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
6282         macro.
6283         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
6284         also check for glibc-2.4's abort-inducing bug.
6285
6286         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
6287         Low-probability clean-up should be to use rmdir to get rid of
6288         the just-created directory, not unlink.
6289
6290         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
6291         configure fail, and request a bug report to inform us about it.
6292         Add a comment that, barring reports to the contrary, in 2007 we'll
6293         assume ftruncate is universally available.
6294
6295         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6296
6297         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
6298
6299         2006-03-12  Jim Meyering  <jim@meyering.net>
6300
6301         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
6302         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
6303         * m4/same.m4 (gl_SAME): Likewise.
6304         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
6305
6306         2006-03-11  Eric Blake  <ebb9@byu.net>
6307
6308         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
6309         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
6310         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
6311         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
6312
6313 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6314
6315         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
6316         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
6317         reported by Mark D. Baushke, one in
6318         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
6319
6320         Merge from coreutils.
6321
6322         * lib/.cppi-disable: Add stdint_.h.
6323         * lib/.cvsignore: Add stdint.h.
6324
6325         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6326
6327         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
6328         both double and long double versions.
6329         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
6330         * lib/xstrtold.c: New file.
6331         * lib/xstrtod.h (xstrtold): New decl.
6332
6333         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
6334
6335         * lib/filemode.c (setst): Remove.
6336         (strmode): Rewrite to avoid setst.  This makes the code shorter,
6337         (arguably) clearer, and the generated code is a bit smaller on my
6338         Debian GNU/Linux stable x86 host.
6339
6340         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6341
6342         * lib/filemode.c: Include "filemode.h" first, to test the interface.
6343         Assume that filemode.h includes sys/types.h and sys/stat.h.
6344         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
6345         (ftypelet): Reorder to put common cases first, for efficiency.
6346         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
6347         to do 'M'.
6348         (strmode): Renamed from mode_string, and now stores 12 bytes instead
6349         of 10, for compatibility with FreeBSD.  All callers changed.
6350         (filemodestring): Now stores 12 bytes instead of 10, and sets file
6351         types that can't be deduced solely from st_mode.  First arg is now a
6352         const pointer.
6353         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
6354         (strmode): Renamed from mode_string.
6355         (filemodestring): New decl.
6356         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
6357         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
6358         needed.
6359         (S_ISPORT, S_ISWHT): New macros, if not already defined.
6360
6361         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
6362
6363         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
6364         fsusage.h now does that.  Include fsusage.h first, to test interface.
6365         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
6366         at most one method (the old code could have generated decls that
6367         didn't conform to C89, not that this was ever exercised).
6368         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
6369
6370         2006-03-19  Jim Meyering  <jim@meyering.net>
6371
6372         Work even in a chroot where d_ino values for entries in "/"
6373         don't match the stat.st_ino values for the same names.
6374         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
6375         number, iterate through all entries again, using lstat instead.
6376         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
6377         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
6378
6379         * lib/getcwd.c (__getcwd): Clarify a comment.
6380         Use memcpy in place of a call to strcpy.
6381
6382         2006-03-12  Jim Meyering  <jim@meyering.net>
6383
6384         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
6385         matches that of the current directory (which we're about to chdir ".."
6386         out of), then save the dev-ino of the parent, instead.
6387
6388         * lib/same-inode.h (SAME_INODE): New file/macro.
6389         * lib/chdir-safer.c (SAME_INODE): Remove definition.
6390         Include "same-inode.h", instead.
6391         * lib/same.c: Likewise.
6392         * lib/cycle-check.h: Include "same-inode.h".
6393         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
6394         * lib/cycle-check.c (SAME_INODE): Remove definition.
6395         * lib/root-dev-ino.h: Include "same-inode.h".
6396
6397         2006-03-11  Eric Blake  <ebb9@byu.net>
6398
6399         * lib/same.c (same_name): s/base_name/last_component/
6400         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
6401         * lib/filenamecat.c (file_name_concat): Likewise.
6402
6403         2006-03-11  Eric Blake  <ebb9@byu.net>,
6404                     Paul Eggert  <eggert@cs.ucla.edu>
6405
6406         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
6407         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
6408         drive prefix.
6409         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
6410         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
6411         (last_component): New method.
6412         * lib/dirname.c (dir_len): Determine when drive letters need a
6413         subsequent slash.  Preserve // when it is special.
6414         (dir_name): Don't append dot when drive letter is absolute.
6415         [TEST_DIRNAME]: Move into a full-blown gnulib test.
6416         * lib/basename.c (base_name): New semantics - malloc the result.
6417         Preserve // when it is special.  Preserve relative files that look
6418         like drive letters.
6419         (base_len): Preserve // when it is special.
6420         (last_component): New method, similar to old base_name semantics.
6421         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
6422         base_name.  Strip redundant slashes from ///.
6423
6424 2006-07-03  Jim Meyering  <jim@meyering.net>
6425
6426         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
6427         macro is used before the first cycle_check call.
6428
6429 2006-07-03  Eric Blake  <ebb9@byu.net>
6430
6431         * modules/dirname (Depends-on): Add xstrndup.
6432
6433 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6434
6435         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
6436         test cases, so that config.log is a bit easier to follow.
6437
6438 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6439
6440         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
6441         both are 64 bits, since this seems to be the tradition, and this
6442         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
6443         we ever run into a host that prefers long long to long in this
6444         case, we'll need another configure-time test.  Problem reported by
6445         Jim Meyering.
6446
6447 2006-07-02  Eric Blake  <ebb9@byu.net>
6448
6449         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
6450
6451 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6452
6453         * modules/inttypes (Depends-on): No longer depends on stdint.
6454         * modules/stdint (Description): Say more about assumptions.
6455         Say that the fast types might differ.  Say macros are used.
6456         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
6457         (Makefile.am): Revise list of substituted symbols to match
6458         new stdint.m4.
6459         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
6460         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
6461         * tests/test-stdint.c (verify_same_types)
6462         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
6463         the code conforms to C99/C89.
6464         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
6465         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
6466
6467 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6468
6469         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
6470         but fix a bug, by requiring at least 64 bits.
6471         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
6472         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
6473         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
6474         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
6475
6476         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
6477         changes.  Make 2.59 a prerequisite.  Check and substitute for
6478         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
6479         inttypes.h.  Do not use special include files; just use the
6480         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
6481         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
6482         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
6483         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
6484         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
6485         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
6486         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
6487         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
6488         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
6489         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
6490         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
6491         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
6492         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
6493         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
6494         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
6495         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
6496         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
6497         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
6498         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
6499         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
6500         WINT_MAX.  Check for C99 conformance more strictly, by detecting
6501         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
6502         not check for things that C99 does not require, e.g., int8_t.  If
6503         a test isn't needed unless <stdint.h> isn't working, and is
6504         unlikely to be needed for any other reason, then don't do it
6505         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
6506         size_t, since we assume C89 freestanding at least.  Do not check
6507         for sig_atomic_t, wchar_t, or wint_t, since the code now does
6508         the right thing even if the types are not defined.  Instead use:
6509         (gl_STDINT_TYPE_PROPERTIES): New macro.
6510         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
6511         testing whether <sys/types.h> clashes, as Autoconf does this for
6512         us now.  All uses removed.
6513         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
6514         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
6515         (gl_CHECK_TYPE_SAME):
6516         Remove; no longer needed.
6517         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
6518         exists, since we'll return 0 anyway in that case.
6519         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
6520
6521 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6522
6523         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
6524         possible collision with system files.
6525         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
6526         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
6527         WCHAR_MIN and WCHAR_MAX in this case.
6528         (<stddef.h>): Do not include; no longer needed.
6529         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
6530         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
6531         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
6532         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
6533         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
6534         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
6535         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
6536         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
6537         !defined(__c99))]: Include in this case too, since it's harmless
6538         now.
6539         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
6540         dangerous to do so.
6541         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
6542         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
6543         (_STDINT_MIN, _STDINT_MAX): New macros.
6544         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
6545         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
6546         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
6547         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
6548         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
6549         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
6550         macros, not typedefs; this simplifies things quite a bit.
6551         Use long int for all types narrower than int64_t.
6552         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
6553         Define in terms of long long int or int64_t or long int,
6554         not int64_t or int32_t.  This saves some compile-time testing.
6555         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
6556         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
6557         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
6558         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
6559         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
6560         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
6561         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
6562         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
6563         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
6564         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
6565         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6566         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6567         undef any previous version and define our own version, for
6568         simplicity and consistency with the new macros for types.
6569         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6570         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6571         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
6572         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
6573         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
6574         @WINT_T_SUFFIX@ to keep things simple here.
6575         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
6576         Simplify by assuming typical 8/16/32/64 host, since we're
6577         already doing that elsewhere anyway.
6578         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
6579         and assume long long int is 64 bits if available.  This
6580         speeds up 'configure'.
6581
6582 2006-07-01  Eric Blake  <ebb9@byu.net>
6583
6584         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
6585         Reported by Andreas Buening.
6586
6587 2006-07-01  Eric Blake  <ebb9@byu.net>
6588
6589         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
6590
6591 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6592
6593         * lib/getaddrinfo.c: fixed typo
6594
6595 2006-06-29  Jim Meyering  <jim@meyering.net>
6596
6597         * modules/strftime (Maintainer): Add my name, since with the
6598         FPRINTFTIME changes strftime.c has forked from glibc.
6599
6600 2006-06-29  Eric Blake  <ebb9@byu.net>
6601
6602         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
6603
6604 2006-06-29  Eric Blake  <ebb9@byu.net>
6605
6606         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
6607
6608 2006-06-29  Eric Blake  <ebb9@byu.net>
6609
6610         * lib/stat_.h: New file.
6611
6612 2006-06-29  Eric Blake  <ebb9@byu.net>
6613
6614         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
6615         unused static function.
6616
6617 2006-06-29  Eric Blake  <ebb9@byu.net>
6618
6619         * doc/functions.texi (Function Portability): Document missing lstat
6620         on mingw.
6621
6622 2006-06-29  Eric Blake  <ebb9@byu.net>
6623
6624         * MODULES.html.sh: Add sys_stat.
6625         * modules/sys_stat: New module.
6626         * modules/mkstemp (Depends-on): Add sys_stat.
6627
6628 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6629
6630         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
6631
6632 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6633
6634         * m4/c-bs-a.m4: Removed.
6635
6636 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6637
6638         * lib/strftime.c: Assume strftime() exists.
6639
6640 2006-06-29  Derek Price  <derek@ximbiot.com>
6641
6642         * modules/c-bs-a: Removed - \a is C89.
6643         * MODULES.html.sh: Remove c-bs-a.
6644
6645 2006-06-29  Bruno Haible  <bruno@clisp.org>
6646
6647         * modules/wcwidth (License): Change to LGPL.
6648
6649 2006-06-28  Simon Josefsson  <jas@extundo.com>
6650
6651         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
6652         on _WIN32.
6653
6654         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
6655         getnameinfo.
6656
6657 2006-06-28  Simon Josefsson  <jas@extundo.com>
6658
6659         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
6660
6661 2006-06-28  Simon Josefsson  <jas@extundo.com>
6662
6663         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
6664         functions there.  It will succeed on Windows XP, but on Windows
6665         2000 and (presumably) earlier, it will fail, and use the internal
6666         re-implementation.
6667         (use_win32_p): New function.
6668         (getaddrinfo): Use strtoul on servname, to support numeric ports.
6669         Support AI_NUMERICSERV to disable getservbyname.
6670         (getnameinfo): New function, only supports
6671         NI_NUMERICHOST|NI_NUMERICSERV for now.
6672
6673         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
6674         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
6675         getnameinfo.
6676
6677 2006-06-28  Eric Blake  <ebb9@byu.net>
6678
6679         * modules/wcwidth: New file.
6680         * modules/mbchar (Depends-on): Add wcwidth.
6681         * modules/mbswidth (Depends-on): Add wcwidth.
6682         * MODULES.html.sh: Add wcwidth.
6683
6684 2006-06-28  Eric Blake  <ebb9@byu.net>
6685
6686         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
6687         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
6688
6689 2006-06-28  Eric Blake  <ebb9@byu.net>
6690
6691         * lib/xvasprintf.h: Fix comments.
6692
6693 2006-06-28  Eric Blake  <ebb9@byu.net>
6694
6695         * lib/mbchar.h (wcwidth): Include wcwidth.h.
6696         * lib/mbswidth.c (wcwidth): Move from here...
6697         * lib/wcwidth.h: ...to this new file.
6698
6699 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6700
6701         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
6702
6703         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
6704         it's obsolete.
6705         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
6706
6707 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6708
6709         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
6710         Autoconf 2.60 says this stuff was obsolete.
6711
6712 2006-06-28  Bruno Haible  <bruno@clisp.org>
6713
6714         * modules/wcwidth (Files): Add m4/wchar_t.m4.
6715
6716 2006-06-28  Bruno Haible  <bruno@clisp.org>
6717
6718         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
6719         gt_TYPE_WCHAR_T.
6720
6721 2006-06-28  Bruno Haible  <bruno@clisp.org>
6722
6723         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
6724         declaration for wcwidth.
6725         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
6726
6727 2006-06-28  Bruno Haible  <bruno@clisp.org>
6728
6729         * lib/mkdtemp.c [MINGW]: Include <io.h>.
6730         (mkdir): Define using _mkdir.
6731
6732 2006-06-28  Bruno Haible  <bruno@clisp.org>
6733
6734         * lib/getaddrinfo.h: Fix POSIX URL.
6735         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
6736         _WIN32.
6737         (use_win32_p): Make static.
6738         (getaddrinfo): Reject service name if it is empty or does not consist
6739         solely of decimal digits, or if its value is > 65535.
6740         (getnameinfo): Remove useless casts.
6741
6742 2006-06-27  Simon Josefsson  <jas@extundo.com>
6743
6744         * modules/sys_select: New file, suggested by Bruno Haible, Paul
6745         Eggert and Martin Lambers.
6746
6747 2006-06-27  Simon Josefsson  <jas@extundo.com>
6748
6749         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
6750         Eggert and Martin Lambers.
6751
6752 2006-06-27  Bruno Haible  <bruno@clisp.org>
6753
6754         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
6755         result to 0, not to empty.
6756         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
6757
6758 2006-06-27  Bruno Haible  <bruno@clisp.org>
6759
6760         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
6761
6762 2006-06-26  Simon Josefsson  <jas@extundo.com>
6763
6764         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
6765         present.
6766
6767 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
6768
6769         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
6770         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
6771         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
6772
6773 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
6774
6775         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
6776
6777 2006-06-26  Bruno Haible  <bruno@clisp.org>
6778
6779         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
6780
6781 2006-06-26  Bruno Haible  <bruno@clisp.org>
6782
6783         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
6784
6785 2006-06-26  Bruno Haible  <bruno@clisp.org>
6786
6787         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
6788         SGI C compiler in pre-C99 mode.
6789         Suggested by Mark D. Baushke and Larry Jones.
6790
6791 2006-06-26  Bruno Haible  <bruno@clisp.org>
6792
6793         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
6794         WCHAR_MAX.
6795         Reported by Mark D. Baushke and Larry Jones.
6796
6797 2006-06-26  Bruno Haible  <bruno@clisp.org>
6798
6799         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
6800         in pre-C99 mode.
6801         Suggested by Mark D. Baushke and Larry Jones.
6802
6803 2006-06-23  Simon Josefsson  <jas@extundo.com>
6804             Bruno Haible  <bruno@clisp.org>
6805
6806         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
6807         Emit mostlyclean-local rule.
6808         (func_emit_tests_Makefile_am): Likewise.
6809         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
6810
6811 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
6812
6813         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
6814
6815 2006-06-23  Bruno Haible  <bruno@clisp.org>
6816
6817         * tests/test-stdint.c: Update to match ISO C 99 Technical
6818         Corrigendum 1.
6819
6820 2006-06-23  Bruno Haible  <bruno@clisp.org>
6821
6822         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
6823
6824 2006-06-23  Bruno Haible  <bruno@clisp.org>
6825
6826         * lib/stdint_.h: Treat IRIX like OpenBSD.
6827
6828 2006-06-23  Bruno Haible  <bruno@clisp.org>
6829
6830         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
6831         ISO C 99 Technical Corrigendum 1.
6832
6833 2006-06-22  Simon Josefsson  <jas@extundo.com>
6834
6835         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
6836         MinGW.
6837
6838 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
6839
6840         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
6841         needed.  Some compiler complained about some of them.  Problem reported
6842         by Larry Jones in
6843         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
6844
6845 2006-06-21  Simon Josefsson  <jas@extundo.com>
6846
6847         * tests/test-getaddrinfo.c: New file.
6848
6849         * modules/getaddrinfo-tests: New file.
6850
6851         * MODULES.html.sh: Add inet_pton.
6852
6853         * modules/inet_pton: New file.
6854
6855 2006-06-21  Simon Josefsson  <jas@extundo.com>
6856
6857         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
6858         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
6859         of using the (limited) gnulib implementation on Windows XP.
6860
6861         * m4/inet_pton.m4: New file.
6862
6863 2006-06-21  Simon Josefsson  <jas@extundo.com>
6864
6865         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
6866         variable.
6867
6868         * lib/socket_.h: Don't define WINVER.
6869
6870         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
6871         slightly modified to work in gnulib.
6872
6873 2006-06-21  Simon Josefsson  <jas@extundo.com>
6874
6875         * doc/gnulib.texi (Windows sockets): Add.
6876
6877 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
6878
6879         * lib/read-file.c (fread_file): Start with buffer allocation of
6880         0 bytes rather than 1 byte; this simplifies the code.
6881         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
6882         code to free buffer and save/restore errno.
6883         (internal_read_file): Remove unused local.
6884
6885 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
6886
6887         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
6888         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
6889         Problem reported by Denis Excoffier in
6890         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
6891
6892 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6893
6894         * modules/sys_socket, modules/socklen: Include sys/types since
6895         FreeBSD 4.x's sys/socket.h needs it.
6896
6897 2006-06-19  Simon Josefsson  <jas@extundo.com>
6898
6899         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
6900
6901 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6902
6903         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
6904
6905 2006-06-19  Bruno Haible  <bruno@clisp.org>
6906
6907         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
6908         and FULL_PATH_INTTYPES_H in angle brackets.
6909         Reported by Mark D. Baushke <mdb@gnu.org>.
6910
6911 2006-06-17  Eric Blake  <ebb9@byu.net>
6912
6913         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
6914         errno.
6915
6916 2006-06-17  Bruno Haible  <bruno@clisp.org>
6917
6918         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
6919         <sys/inttypes.h>.
6920
6921 2006-06-17  Bruno Haible  <bruno@clisp.org>
6922
6923         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
6924         whether errno is declared. Assume <errno.h> declares errno.
6925
6926 2006-06-17  Bruno Haible  <bruno@clisp.org>
6927
6928         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
6929
6930 2006-06-17  Bruno Haible  <bruno@clisp.org>
6931
6932         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
6933         problem on Solaris 2.5.1.
6934
6935 2006-06-16  Eric Blake  <ebb9@byu.net>
6936
6937         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
6938         * lib/unicodeio.c [!defined errno]: Likewise.
6939         * lib/strtol.c [!defined errno]: Likewise.
6940         * lib/strtod.c [!defined errno]: Likewise.
6941
6942 2006-06-15  Eric Blake  <ebb9@byu.net>
6943
6944         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
6945
6946 2006-06-15  Eric Blake  <ebb9@byu.net>
6947
6948         * config/srclist.txt (ssize_t.m4): Lose sync.
6949
6950 2006-06-15  Bruno Haible  <bruno@clisp.org>
6951
6952         * modules/stdint (Files): Include m4/full-header-path.m4,
6953         m4/size_max.m4, m4/wchar_t.m4.
6954         (Makefile.am): Many more substitutions.
6955         * modules/stdint-tests: New file.
6956         * tests/test-stdint.c: New file.
6957
6958 2006-06-15  Bruno Haible  <bruno@clisp.org>
6959
6960         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
6961         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
6962         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
6963         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
6964         gl_CHECK_TYPE_SAME): New macros.
6965
6966 2006-06-15  Bruno Haible  <bruno@clisp.org>
6967
6968         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
6969
6970 2006-06-15  Bruno Haible  <bruno@clisp.org>
6971
6972         * lib/stdint_.h: Rewritten to be fully auto-configured.
6973         Fixes bug on HP-UX/IA64.
6974
6975 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
6976
6977         * lib/getdate.y (__attribute__): Don't define if already defined.
6978         Problem reported by Larry Jones.
6979         * lib/utimens.c (__attribute__): Likewise.
6980
6981 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
6982
6983         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
6984         reported by Andreas Schwab.
6985
6986 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6987             Bruno Haible  <bruno@clisp.org>
6988
6989         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
6990         check for the declaration of strnlen and a run test that exposes the
6991         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
6992         rpl_strndup.
6993
6994 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6995             Bruno Haible  <bruno@clisp.org>
6996
6997         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
6998
6999 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7000
7001         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
7002         compile test, for Tru64 4.0D.
7003
7004 2006-05-28  Karl Berry  <karl@gnu.org>
7005
7006         * config/srclist.txt (printf-args.c): lose sync.
7007
7008 2006-05-26  Martin Lambers  <marlam@marlam.de>
7009
7010         * lib/getpass.c: Updates the test for the native W32 API, and adds
7011         missing includes, thus fixing compilation warnings.
7012
7013 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7014
7015         * lib/exclude.c (exclude_fnmatch): New function.
7016         (excluded_file_name): Call exclude_fnmatch.
7017         * lib/exclude.h (excluded_file_name): New prototype
7018
7019 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
7020
7021         * lib/tempname.c (small_open, large_open): New macros.
7022         (__open, __open64) [!_LIBC]: Remove.
7023         (__gen_tempname): Use small_open and large_open instead of __open
7024         and __open64.  This fixes a portability bug on HP-UX 11.11i
7025         reported by Simon Wing-Tang in
7026         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
7027
7028 2006-05-24  Bruno Haible  <bruno@clisp.org>
7029
7030         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
7031         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
7032         Reported by Thorsten Maerz <torte@netztorte.de> via
7033         Aaron Stone <aaron@serendipity.cx>.
7034
7035 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7036
7037         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
7038         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
7039         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
7040         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
7041         not really conditional on the cache.
7042         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
7043
7044 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7045
7046         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
7047         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
7048         (my_usleep): Don't mishandle maximum value.
7049
7050 2006-05-19  Jim Meyering  <jim@meyering.net>
7051
7052         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
7053
7054 2006-05-17  Bruno Haible  <bruno@clisp.org>
7055
7056         Cygwin portability.
7057         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
7058
7059 2006-05-17  Bruno Haible  <bruno@clisp.org>
7060
7061         * lib/stdint_.h: Fix recognition of Cygwin.
7062
7063 2006-05-15  Bruno Haible  <bruno@clisp.org>
7064
7065         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
7066         on libtool patch by Ralf Wildenhues.
7067
7068 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
7069
7070         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
7071         test for C99 conformance; (bool) 0.5 is an integer constant
7072         expression, but (bool) -0.5 is not.  Problem reported by Fedor
7073         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
7074
7075 2006-05-11  Simon Josefsson  <jas@extundo.com>
7076
7077         * m4/xvasprintf.m4: Fix obvious typo.
7078
7079 2006-05-11  Jim Meyering  <jim@meyering.net>
7080
7081         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
7082         James Lemley.
7083
7084 2006-05-10  Simon Josefsson  <jas@extundo.com>
7085
7086         * lib/md4.c: Typo fix, update copyright years.
7087         (K1, K2): Don't use L because it turn computations into 64-bit on
7088         64-bit platforms.
7089
7090 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
7091
7092         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
7093         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
7094         unwanted sign propagation, e.g., on hosts with 64-bit int.
7095         There still are some problems with reeelly weird theoretical hosts
7096         (e.g., 33-bit int) but it's not worth worrying about now.
7097         * lib/sha1.c (rol): Likewise.
7098         (K1, K2, K3, K4): Remove unnecessary L suffix.
7099
7100 2006-05-10  Bruno Haible  <bruno@clisp.org>
7101
7102         * lib/des.c: Cast to avoid warnings.
7103
7104 2006-05-09  Bruno Haible  <bruno@clisp.org>
7105
7106         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
7107         (Depends-on): Depend also on xsize, stdarg.
7108         (configure.ac): Add gl_XVASPRINTF.
7109
7110 2006-05-09  Bruno Haible  <bruno@clisp.org>
7111
7112         * m4/xvasprintf.m4: New file.
7113
7114 2006-05-09  Bruno Haible  <bruno@clisp.org>
7115
7116         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
7117         (EOVERFLOW): Define fallback value.
7118         (xstrcat): New function.
7119         (xvasprintf): Recognize the special case of a string concatenation.
7120
7121 2006-05-08  Eric Blake  <ebb9@byu.net>
7122
7123         * gnulib-tool (func_version): Base copyright year on CVS date.
7124         (func_emit_copyright_notice): New function.
7125         (func_emit_lib_Makefile_am): Use it.
7126         (func_emit_tests_Makefile_am): Likewise.
7127         (func_import): Likewise.
7128
7129 2006-05-08  Bruno Haible  <bruno@clisp.org>
7130
7131         * modules/stdarg: New file.
7132         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
7133
7134 2006-05-08  Bruno Haible  <bruno@clisp.org>
7135
7136         * m4/stdarg.m4: New file, from GNU gettext.
7137
7138 2006-05-08  Bruno Haible  <bruno@clisp.org>
7139
7140         * config/srclist.txt (build-aux/config.rpath): different from latest
7141         release.
7142
7143 2006-05-08  Bruno Haible  <bruno@clisp.org>
7144
7145         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
7146
7147 2006-05-05  Jim Meyering  <jim@meyering.net>
7148
7149         * m4/warning.m4: New file, derived from bison's file by the same name.
7150
7151 2006-05-03  Bruno Haible  <bruno@clisp.org>
7152
7153         * lib/stdint_.h: Shorter URL.
7154         * lib/inttypes.h: Likewise.
7155
7156 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7157
7158         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
7159
7160 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7161
7162         * lib/verify.h: Document the internals better.  Most of this change
7163         was written by Bruno Haible.
7164
7165 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7166
7167         * doc/verify.texi: New file, partly based on a proposal by
7168         Bruno Haible.
7169
7170 2006-05-02  Bruno Haible  <bruno@clisp.org>
7171
7172         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
7173         test from here...
7174         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
7175
7176 2006-04-29  Bruno Haible  <bruno@clisp.org>
7177
7178         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
7179         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
7180
7181 2006-04-29  Bruno Haible  <bruno@clisp.org>
7182
7183         * gnulib-tool: Make --update option actually work.
7184
7185 2006-04-29  Bruno Haible  <bruno@clisp.org>
7186
7187         * doc/gcd.texi: New file.
7188         * doc/gnulib.texi: Include it.
7189
7190 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
7191
7192         * lib/getdate.y (get_date): When adding relative date, start with the
7193         initial time, not with the result of the first mktime call.
7194
7195 2006-04-25  Bruno Haible  <bruno@clisp.org>
7196
7197         * gnulib-tool (func_import): Output the include directives in three
7198         blocks, sorted separately.
7199         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7200
7201 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7202
7203         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
7204         to define main with arguments, for C++.  Reported by Eric Blake.
7205         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
7206         Prefer 'int main ()' to 'int main (void)', for C++.
7207         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
7208         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
7209         for 'main', for C99 and C++.
7210
7211 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7212
7213         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
7214         Don't assume that exit status -1 is valid.
7215         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7216         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
7217         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7218         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
7219         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
7220         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
7221         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
7222         functions can be used without declaring them, or that you can
7223         exit with status -1.
7224         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7225
7226 2006-04-24  Karl Berry  <karl@gnu.org>
7227
7228         * config/srclist.txt (longdouble.m4): sync lost.
7229
7230 2006-04-24  Eric Blake  <ebb9@byu.net>
7231
7232         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
7233
7234 2006-04-24  Bruno Haible  <bruno@clisp.org>
7235
7236         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
7237         poll() implementation in AIX.
7238         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7239
7240 2006-04-24  Bruno Haible  <bruno@clisp.org>
7241
7242         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
7243         assigned exactly once.
7244
7245 2006-04-23  Claudio Fontana  <claudio@gnu.org>
7246             Bruno Haible  <bruno@clisp.org>
7247
7248         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
7249         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
7250         for AM_CPPFLAGS.
7251
7252 2006-04-23  Bruno Haible  <bruno@clisp.org>
7253
7254         * modules/copy-file: Depend on unistd.
7255         * modules/execute: Likewise.
7256         * modules/fatal-signal: Likewise.
7257         * modules/findprog: Likewise.
7258         * modules/mkdtemp : Likewise.
7259         * modules/pipe: Likewise.
7260         * modules/wait-process: Likewise.
7261
7262 2006-04-23  Bruno Haible  <bruno@clisp.org>
7263
7264         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
7265         condition was already detected.
7266         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7267
7268 2006-04-23  Bruno Haible  <bruno@clisp.org>
7269
7270         * lib/copy-file.c: Include <unistd.h> unconditionally.
7271         * lib/execute.c: Likewise.
7272         * lib/fatal-signal.c: Likewise.
7273         * lib/findprog.c: Likewise.
7274         * lib/mkdtemp.c: Likewise.
7275         * lib/pipe.h: Likewise.
7276         * lib/pipe.c: Likewise.
7277         * lib/wait-process.h: Likewise.
7278
7279 2006-04-23  Bruno Haible  <bruno@clisp.org>
7280
7281         * gnulib-tool (func_usage): Fix --import description. Document
7282         --update.
7283         (func_import): Create temporary file in a temporary directory, if
7284         --dry-run is specified. Silence errors from 'grep' when there are no
7285         m4 files in $m4dir.
7286         (func_create_testdir): Silence errors from 'grep' when there are no
7287         m4 files in $m4dir.
7288         Reported by Karl Berry <karl@freefriends.org>.
7289
7290 2006-04-20  Bruno Haible  <bruno@clisp.org>
7291
7292         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
7293         one argument, so that the code will be portable to Autoconf 2.60.
7294         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
7295         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7296         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
7297
7298 2006-04-19  Derek Price  <derek@ximbiot.com>
7299             Eric Blake  <ebb9@byu.net>
7300
7301         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
7302         rather than "/full/path.h".  Update comment to match.  Shorten &
7303         generalize m4_translit call via AS_TR_CPP.
7304
7305 2006-04-19  Derek Price  <derek@ximbiot.com>
7306             Eric Blake  <ebb9@byu.net>
7307
7308         * lib/inttypes.h: Correct grammar in comment.
7309
7310 2006-04-18  Derek Price  <derek@ximbiot.com>
7311             Paul Eggert  <eggert@cs.ucla.edu>
7312
7313         * modules/inttypes: New file.
7314         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
7315
7316 2006-04-18  Derek Price  <derek@ximbiot.com>
7317             Paul Eggert  <eggert@cs.ucla.edu>
7318
7319         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
7320         New files.
7321
7322 2006-04-18  Derek Price  <derek@ximbiot.com>
7323             Paul Eggert  <eggert@cs.ucla.edu>
7324
7325         * lib/inttypes.h: New file.
7326         * lib/strtoimax.c: Assume <inttypes.h>.
7327
7328 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
7329
7330         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
7331         isn't mounted.  Problem reported by Kir Kolyshkin.
7332
7333 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
7334
7335         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
7336         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
7337         Derek R. Price.
7338         * lib/regex.h (RE_DUP_MAX): Update comment to match current
7339         implementation.
7340
7341 2006-04-12  Eric Blake  <ebb9@byu.net>
7342
7343         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
7344         is now done automatically by the corresponding Autoconf macro.
7345
7346 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
7347
7348         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
7349         time_r.h.
7350
7351 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7352
7353         Merge regex changes from libc, removing some of our
7354         POSIX-conformance changes that were rejected and redoing them in a
7355         less-intrusive way.
7356
7357         * lib/regcomp.c (re_compile_internal, init_dfa):
7358         Length arg is now size_t, not Idx.  All uses changed.
7359         (peek_token): Forward decl now says internal_function.
7360         (__re_error_msgid, __re_error_msgid_idx):
7361         Now static rather than extern with attribute_hidden.
7362         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
7363         For some reason libc prefers K&R style defns for external functions.
7364         (regerror) [!defined _LIBC]: Likewise.
7365         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
7366         (seek_collating_symbol_entry, lookup_collation_sequence_value):
7367         (build_range_exp, build_collating_symbol):
7368         Use K&R-style defn.
7369         (re_compile_fastmap): Use '\0' to memset, not 0.
7370         (utf8_sb_map): Make the calculations more obvious.
7371         (init_dfa, parse_bracket_exp, build_charclass_op):
7372         Call calloc and cast result, as glibc does.
7373         (init_word_char, fetch_token, peek_token, peek_token_bracket):
7374         (build_range_exp, build_collating_symbol):
7375         Now internal functions.
7376
7377         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
7378
7379         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
7380         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
7381         Don't depend on VMS; depend on __VMS instead, for POSIX
7382         namespace cleanness.
7383         (regoff_t): Define to ssize_t, not long int.
7384
7385         Remove the REG_ macros named below.  Instead, make the old names
7386         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
7387         __USE_GNU_REGEX.
7388         (REG_BACKSLASH_ESCAPE_IN_LISTS):
7389         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
7390         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
7391         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
7392         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
7393         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
7394         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
7395         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
7396         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
7397         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
7398         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
7399         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
7400         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
7401         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
7402         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
7403         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
7404         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
7405         (REG_NREGS):
7406         Remove.  All uses replaced by the old RE_* names.
7407         (RE_BACKSLASH_ESCAPE_IN_LISTS):
7408         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
7409         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
7410         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
7411         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
7412         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
7413         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
7414         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
7415         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
7416         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
7417         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
7418         Don't bother having these macros be independent of each others'
7419         values, since they no longer exist in the POSIX name space.
7420
7421         Rename the following member names back to their old names,
7422         unless !__USE_GNU_REGEX.  All uses changed back.
7423         (buffer): Renamed from re_buffer.
7424         (allocated): Renamed from re_allocated.
7425         (used): Renamed from re_used.
7426         (syntax): Renamed from re_syntax.
7427         (fastmap): Renamed from re_fastmap.
7428         (translate): Renamed from re_translate.
7429         (can_be_null): Renamed from re_can_be_null.
7430         (regs_allocated): Renamed from re_regs_allocated.
7431         (fastmap_accurate): Renamed from re_fastmap_accurate.
7432         (no_sub): Renamed from re_no_sub.
7433         (not_bol): Renamed from re_not_bol.
7434         (not_eol): Renamed from re_not_eol.
7435         (newline_anchor): Renamed from re_newline_anchor.
7436         (num_regs): Renamed from rm_num_regs.
7437         (start): Renamed from rm_start.
7438         (end): Renamed from rm_end.
7439
7440         (free_state): Move up a bit.
7441
7442         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
7443         #define to be empty.
7444         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
7445         when that is what is intended.
7446         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
7447         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
7448         (MAX): New macro.
7449         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
7450         All uses changed back to re_malloc, etc.  It's now the caller's
7451         responsibility to check for overflow; all callers changed.
7452         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
7453         (re_x2nrealloc): Remove.
7454         (free_state): Remove decl.
7455
7456         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
7457         (re_set_registers, re_exec):
7458         Use K&R-style defn.
7459
7460         2006-01-31  Roland McGrath  <roland@redhat.com>
7461
7462         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
7463         Reported by Mike Frysinger <vapier@gentoo.org>.
7464
7465         2006-01-15  Andreas Jaeger  <aj@suse.de>
7466
7467         [BZ #1950]
7468         * lib/regex_internal.c (re_string_reconstruct): Adjust for
7469         build_wcs_upper_buffer change.
7470         (build_wcs_upper_buffer): Change return type.
7471
7472         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
7473
7474         * lib/regex_internal.h: Include <stdint.h> if available.
7475
7476         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
7477
7478         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
7479
7480         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7481
7482         * lib/regcomp.c: Adjust for changed secondary hash function.
7483
7484         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
7485
7486         * lib/regex.h: Pretty printing.
7487         Clean up namespace a bit.
7488
7489         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
7490
7491         * lib/regexec.c (update_cur_sifted_state, check_arrival,
7492         check_arrival_add_next_nodes): Avoid using uninitialized variable.
7493
7494         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7495                     Ulrich Drepper  <drepper@redhat.com>
7496
7497         [BZ #1302]
7498         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
7499         changed.
7500         (bitset_word_t): Renamed from bitset_word.  All uses changed.
7501
7502         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
7503
7504         [BZ #281]
7505         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
7506         * lib/regcomp.c: Remove unnecessary uses of
7507         unsigned RE_TRANSLATE_TYPE.
7508         * lib/regex_internal.h: Likewise.
7509         * lib/regex_internal.c: Likewise.
7510         * lib/regexec.c: Likewise.
7511         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
7512
7513         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
7514
7515         * lib/regexec.c (find_recover_state): Remove unnecessary
7516         initialization.
7517         (transit_state_bkref): Make DFA a const pointer.
7518         (get_subexp): Likewise.
7519         (check_arrival): Likewise.
7520         (update_cur_sifted_state): Likewise.
7521         (re_search_internal): Likewise.
7522         (prune_impossible_nodes): Likewise.
7523         (acquire_init_state_context): Likewise.
7524         (proceed_next_node): Likewise.
7525         (set_regs): Likewise.
7526         (free_fail_stack_return): Likewise.
7527         (check_arrival_expand_ecl): Mark DFA parameter as const.
7528         (check_arrival_expand_ecl_sub): Likewise.
7529         (check_subexp_limits): Likewise.
7530         (sub_epsilon_src_nodes):  Likewise.
7531         (add_epsilon_src_nodes):  Likewise.
7532         (merge_state_array): Likewise.
7533         (update_regs): Likewise.
7534         (build_trtable): Likewise.
7535         (sift_states_backward): Mark MCTX parameter as const.
7536         (build_sifted_states): Likewise.
7537         (update_cur_sifted_state): Likewise.
7538         (sift_states_mkref): Likewise.
7539         (check_arrival_expand_ecl): Mark eclosure as const.
7540         (check_dst_limits_calc_pos_1): Likewise.
7541         * lib/regex_internal.h (re_match_context_t): Make dfa a const
7542         pointer.
7543
7544         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
7545
7546         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
7547         (transit_state_sb): Likewise.
7548         (transit_state_mb): Likewise.
7549         (sift_states_iter_mb): Likewise.
7550         (check_arrival_add_next_nodes): Likewise.
7551         (check_node_accept_bytes): Change first parameter to pointer-to-const.
7552         [_LIBC] (re_search_2_stub): Use mempcpy.
7553
7554         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
7555         mbrtowc for very simple UTF-8 case.
7556
7557         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
7558         a pointer-to-const.
7559         (re_acquire_state_context): Likewise.
7560         * lib/regex_internal.h: Adjust prototypes.
7561
7562         * lib/regex.c: Prevent using C++ compilers.
7563
7564         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
7565         (re_acquire_state_context): Likewise.
7566
7567 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7568
7569         * modules/regex (Depends-on): Add ssize_t.
7570
7571 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7572
7573         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
7574         translation table.
7575
7576 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7577
7578         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
7579
7580 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
7581             Bruno Haible  <bruno@clisp.org>
7582
7583         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
7584         <sys/types.h> and <inttypes.h>.
7585
7586 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7587
7588         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
7589         `__error_t_defined', so argp.h will not typedef the former.
7590
7591 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
7592
7593         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
7594         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
7595         glibc names.  Even if glibc is changed to conform to POSIX, the
7596         traditional names will be available anyway, since regex depends on
7597         the extensions module.  Also, fix a longstanding typo in the
7598         implementation of Spencer ERE test #75 from grep 2.3.  Problems
7599         reported by Emanuele Giaquinta.  Also, change sense of cached
7600         variable, so that the message makes sense.
7601
7602 2006-03-24  Simon Josefsson  <jas@extundo.com>
7603
7604         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
7605         including some doc fixes.
7606         (base64_encode_alloc): Fix +1 bug on allocation failures.
7607
7608 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7609
7610         * lib/base64.c (base64_encode): Do not read past end of array with
7611         unsanitized input on systems with CHAR_BIT > 8.
7612
7613 2006-03-24  Eric Blake  <ebb9@byu.net>
7614
7615         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
7616
7617 2006-03-22  Karl Berry  <karl@gnu.org>
7618
7619         * config/srclist.txt (*setenv.[ch]): get from coreutils.
7620         * config/srclistvars.sh (COREUTILS): new var.
7621
7622 2006-03-17  Jim Meyering  <jim@meyering.net>
7623
7624         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
7625         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
7626
7627 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7628
7629         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
7630         no longer needs it.  Instead, check that regoff_t is as least
7631         as wide as ptrdiff_t.
7632
7633         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
7634         so that our regex.h stays compatible with the installed regex.
7635         This is helpful for installers who configure --without-included-regex.
7636         Problem reported by Emanuele Giaquinta.
7637
7638 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7639
7640         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
7641         Typedef to long int, not to off_, as POSIX will likely change
7642         in that direction.
7643
7644 2006-03-15  Eric Blake  <ebb9@byu.net>
7645
7646         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
7647
7648 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7649
7650         * lib/argp-help.c (validate_uparams): Fix typo
7651         * lib/argp-parse.c (argp_default_options): Consistently begin help
7652         messages with a lowercase letter.
7653
7654 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
7655
7656         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
7657         overrun buffers and shouldn't be used (much as gets shouldn't be
7658         used).
7659         * lib/time_r.c (asctime_r, ctime_r): Likewise.
7660
7661 2006-03-08  Simon Josefsson  <jas@extundo.com>
7662
7663         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
7664         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7665
7666 2006-03-08  Simon Josefsson  <jas@extundo.com>
7667
7668         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
7669         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7670
7671 2006-03-08  Simon Josefsson  <jas@extundo.com>
7672
7673         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
7674         signal that configure disabled the device.
7675
7676 2006-03-08  Simon Josefsson  <jas@extundo.com>
7677
7678         * build-aux/maint.mk: Fix refresh-po, to handle no translated
7679         languages.
7680
7681 2006-03-07  Simon Josefsson  <jas@extundo.com>
7682
7683         * modules/getopt (Depends-on): Add unistd.
7684
7685         * modules/unistd: New file.
7686
7687 2006-03-07  Simon Josefsson  <jas@extundo.com>
7688
7689         * modules/gc-random: New file.
7690
7691 2006-03-07  Simon Josefsson  <jas@extundo.com>
7692
7693         * m4/unistd_h.m4: New file.
7694
7695 2006-03-07  Simon Josefsson  <jas@extundo.com>
7696
7697         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
7698         test to be side-effect free by storing the result in the cache
7699         variable gl_cv_lib_readline, and moving the assignment of
7700         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
7701         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7702
7703 2006-03-07  Simon Josefsson  <jas@extundo.com>
7704
7705         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
7706         error on missing devices (the functions will return an error).
7707
7708         * m4/gc.m4: Move random stuff to gc-random.m4
7709
7710 2006-03-07  Simon Josefsson  <jas@extundo.com>
7711
7712         * lib/unistd_.h: New file.
7713
7714 2006-03-07  Simon Josefsson  <jas@extundo.com>
7715
7716         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
7717
7718 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7719
7720         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
7721         Problem reported by Juan Manuel Guerrero.
7722
7723 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7724
7725         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
7726         the unistd module.
7727         * lib/getlogin_r.c: Likewise.
7728         * lib/getlogin_r.h: Likewise.
7729         * lib/glob.c: Likewise.
7730         * lib/pagealign_alloc.c: Likewise.
7731         * lib/unistd_.h: Remove; no longer needed.
7732
7733 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7734
7735         * MODULES.html.sh (Support for systems lacking POSIX:2001):
7736         Add unistd.
7737         * modules/c-stack (Depends-on): Add unistd.
7738         * modules/getlogin_r: Likewise.
7739         * modules/glob: Likewise.
7740         * modules/pagealign_alloc: Likewise.
7741         * modules/unistd (Files): Remove lib/unistd_.h.
7742         (EXTRA_DIST): Remove.
7743         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
7744         need unistd_.h.
7745         (MOSTLYCLEANFILES): Remove unistd.h-t.
7746
7747 2006-03-03  Simon Josefsson  <jas@extundo.com>
7748
7749         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
7750
7751 2006-03-03  Simon Josefsson  <jas@extundo.com>
7752
7753         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
7754         libidn and bison.
7755
7756 2006-03-03  Simon Josefsson  <jas@extundo.com>
7757
7758         * build-aux/maint.mk: Add indent target.
7759
7760 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
7761
7762         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
7763         our replacement poll.h in any case, to avoid a differing
7764         declaration from a system header.  Seen on AIX.
7765
7766 2006-03-01  Simon Josefsson  <jas@extundo.com>
7767
7768         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
7769         <kasal@ucw.cz>.
7770
7771 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7772
7773         * modules/gettime (Depends-on): Add extensions module.
7774         * modules/nanosleep (Depends-on): Likewise.
7775         * modules/settime (Depends-on): Likewise.
7776
7777 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7778
7779         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
7780         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
7781         pedantically.
7782         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7783         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
7784
7785         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
7786         not "==".  Reported by Ralf Wildenhues.
7787
7788 2006-03-01  Karl Berry  <karl@gnu.org>
7789
7790         * doc/Copyright/request-*: new files, synced from gnuorg.
7791
7792 2006-03-01  Karl Berry  <karl@gnu.org>
7793
7794         * config/srclist.txt (Copyright/*): new entries.
7795
7796 2006-02-28  Simon Josefsson  <jas@extundo.com>
7797
7798         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
7799
7800 2006-02-27  Simon Josefsson  <jas@extundo.com>
7801
7802         * lib/base64.h: Indent #define's.  From Jim Meyering
7803         <jim@meyering.net>.
7804
7805 2006-02-27  Jim Meyering  <jim@meyering.net>
7806
7807         Revert the change of 2006-02-24, so these files can continue
7808         to be sync'd from gettext.
7809         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
7810         of `config.h'.
7811
7812 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
7813
7814         * modules/intprops: New file.
7815         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7816         Add intprops.
7817         * modules/getloadavg (Files): Remove lib/intprops.h.
7818         (Depends-on): Add intprops.
7819         * modules/human: Likewise.
7820         * modules/inttostr: Likewise.
7821         * modules/openat: Likewise.
7822         * modules/sig2str: Likewise.
7823         * modules/userspec: Likewise.
7824         * modules/utimecmp: Likewise.
7825         * modules/xnanosleep: Likewise.
7826         * modules/xstrtol: Likewise.
7827
7828 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
7829
7830         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
7831         * modules/lock-tests (TESTS): Use $(EXEEXT).
7832         * modules/tls-tests: Likewise.
7833         * modules/argp-tests: Likewise.
7834         (check_PROGRAMS): New var, replacing...
7835         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
7836
7837 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7838
7839         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
7840         `config.h'.
7841
7842 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
7843
7844         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
7845
7846 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7847
7848         Sync from coreutils.
7849         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
7850         gl_CHDIR_SAFER.
7851
7852 2006-02-22  Jim Meyering  <jim@meyering.net>
7853
7854         Sync from coreutils.
7855         * m4/chdir-safer.m4: New file.
7856
7857 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
7858
7859         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
7860         AT_FDCWD exceeds INT_MAX.
7861         * lib/openat.h (AT_FDCWD): Likewise.
7862
7863 2006-02-17  Eric Blake  <address@hidden>
7864
7865         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
7866
7867 2006-02-16  Simon Josefsson  <jas@extundo.com>
7868
7869         * modules/getaddrinfo (Depends-on): Add sys_socket.
7870
7871 2006-02-15  Simon Josefsson  <jas@extundo.com>
7872
7873         * build-aux/maint.mk: Add dsyntax-check rule.
7874
7875 2006-02-15  Eric Blake  <ebb9@byu.net>
7876
7877         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
7878         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
7879         'present but cannot compile' warnings on cygwin.
7880         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
7881         use ws2tcpip.h if sys/socket.h works.
7882         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
7883         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
7884
7885 2006-02-14  Simon Josefsson  <jas@extundo.com>
7886
7887         * modules/maintainer-makefile (Files): Rename.
7888
7889         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
7890         and (the local) Makefile.cfg to maint-cfg.mk.
7891
7892         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
7893         to the latter.
7894
7895         * modules/maintainer-makefile: New module.
7896
7897         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
7898         severaly stripped to make it possible to build it up from scratch
7899         with reliable tests.
7900
7901         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
7902         fixes to permit overriding the default actions when configure and
7903         makefile are not available.
7904
7905 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
7906
7907         Sync from coreutils.
7908         * modules/lstat (Depends-on): Don't depend on xalloc.
7909         (License): Change from GPL to LGPL, since this is now simply a
7910         replacement for a libc function.
7911
7912 2006-02-14  Jim Meyering  <jim@meyering.net>
7913
7914         Sync from coreutils.
7915
7916         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
7917         failure on deficient systems, and simplify gnulib lgpl dependencies.
7918         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
7919         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
7920
7921         * lib/xalloc-die.c: Remove unused definition of N_.
7922
7923 2006-02-14  Jim Meyering  <jim@meyering.net>
7924
7925         Sync from coreutils.
7926         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
7927         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
7928         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
7929         double-quote uses of that variable, to accommodate the rare case in
7930         which getmntent is available in none of the libraries checked.  This
7931         happens at least on FreeBSD 5.0.
7932
7933 2006-02-13  Simon Josefsson  <jas@extundo.com>
7934
7935         * gnulib-tool (Usage): Fix --import, from
7936         karl@freefriends.org (Karl Berry).
7937
7938 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7939
7940         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
7941
7942 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
7943
7944         * lib/argp-namefrob.h: Restore changes accidentally lost during the
7945         "autoupdate" on 2005-12-12.
7946
7947 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7948
7949         * modules/closeout (Depends-on): Remove atexit.
7950
7951 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7952
7953         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
7954         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
7955
7956 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
7957
7958         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
7959         __EXTENSIONS__ if this causes compilation to fail.  Problem
7960         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
7961         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
7962
7963 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
7964
7965         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
7966         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
7967         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
7968         All uses changed.
7969
7970 2006-01-26  Simon Josefsson  <jas@extundo.com>
7971
7972         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
7973         prototype is visible on mingw32.
7974
7975         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
7976         for mingw32.
7977
7978         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
7979         mingw32).
7980
7981 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7982
7983         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
7984         attempt to open for write; this always fails, at least on POSIX
7985         hosts.  This reinstates the 2006-01-09 change, which was
7986         inadvertently removed.
7987
7988 2006-01-26  Bruno Haible  <bruno@clisp.org>
7989
7990         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
7991         Reported by Paul Eggert.
7992
7993 2006-01-26  Bruno Haible  <bruno@clisp.org>
7994             Paul Eggert  <eggert@cs.ucla.edu>
7995
7996         * lib/stdbool_.h (_Bool)
7997         [(! (defined __cplusplus || defined __BEOS__)
7998           && !defined __GNUC__
7999           && !(defined __HP_cc || defined __xlc__
8000                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
8001                || defined __sgi))]:
8002         #define to signed char in these cases too; this simplifies
8003         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
8004         etc., separately) and makes it more conservative.
8005
8006 2006-01-25  Simon Josefsson  <jas@extundo.com>
8007
8008         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
8009         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
8010         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
8011
8012 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
8013
8014         * lib/argp-namefrob.h: Bugfix. Remove stray #
8015
8016 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
8017
8018         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
8019         so that we test the test.
8020         Check for yet another HP-UX cc bug involving *bool |= bool.
8021
8022 2006-01-25  Karl Berry  <karl@gnu.org>
8023
8024         * config/srclist.txt (vasnprintf.c): sync lost.
8025
8026 2006-01-25  Jim Meyering  <jim@meyering.net>
8027
8028         Sync from the stable (b5) branch of coreutils:
8029
8030         * lib/fts.c (fts_children): Don't let close() clobber errno from
8031         failed fchdir().
8032
8033         * lib/fts.c (fts_stat): When following a symlink-to-directory,
8034         don't necessarily interpret stat-fails+lstat-succeeds as indicating
8035         a dangling symlink.  That can also happen at least for ELOOP.
8036         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
8037         FYI, this bug predates the inclusion of fts.c in coreutils.
8038
8039         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
8040         in their own block, so pre-c99 compilers don't object.
8041
8042         Avoid the double-free (first in fts_read, second in fts_close) that
8043         would occur when an `active' directory is made inaccessible (e.g.,
8044         via chmod a-x) during a traversal.
8045         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8046         before returning.  Reproduce this failure by
8047         mkdir -p a/b; cd a; chmod a-x . b
8048         Reported by Stavros Passas.
8049
8050 2006-01-25  Jim Meyering  <jim@meyering.net>
8051
8052         * lib/fileblocks.c: Remove more useless parentheses.
8053         * lib/readutmp.h: Likewise.
8054
8055 2006-01-25  Bruno Haible  <bruno@clisp.org>
8056
8057         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
8058         warnings.
8059         Reported by Paul Eggert.
8060
8061 2006-01-25  Bruno Haible  <bruno@clisp.org>
8062
8063         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
8064         rid of a trap command. For Solaris sh.
8065         Reported by Mark D. Baushke <mdb@gnu.org>.
8066
8067 2006-01-24  Simon Josefsson  <jas@extundo.com>
8068
8069         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
8070         Bruno.
8071
8072 2006-01-24  Karl Berry  <karl@gnu.org>
8073
8074         * config/srclist.txt (argp-namefrob.h): sync lost.
8075
8076 2006-01-24  Jim Meyering  <jim@meyering.net>
8077
8078         * modules/openat (Files): Add lib/intprops.h.
8079         From Mark D. Baushke.
8080
8081 2006-01-24  Jim Meyering  <jim@meyering.net>
8082
8083         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
8084         Reported by Mark D. Baushke.
8085
8086 2006-01-24  Jim Meyering  <jim@meyering.net>
8087
8088         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
8089
8090 2006-01-24  Bruno Haible  <bruno@clisp.org>
8091
8092         * modules/strnlen (Maintainer): Change from glibc to all.
8093
8094 2006-01-24  Bruno Haible  <bruno@clisp.org>
8095
8096         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
8097         Patch by Paul Eggert.
8098
8099 2006-01-24  Bruno Haible  <bruno@clisp.org>
8100
8101         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
8102         already has it.
8103         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
8104         2005-11-26.
8105
8106         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
8107         'signed char' to avoid problems with the built-in _Bool type.
8108         Reported by Paul Eggert on 2005-11-26.
8109
8110 2006-01-24  Bruno Haible  <bruno@clisp.org>
8111
8112         * gnulib-tool (func_import): Avoid constructing complicated sed
8113         expressions inside backquote.
8114         Report and solution by Mark D. Baushke <mdb@gnu.org>.
8115
8116 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
8117
8118         These changes imported from libc.
8119         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
8120         test and two separate function calls.
8121         * lib/strndup.c (__strndup): Add libc_hidden_def.
8122
8123 2006-01-23  Simon Josefsson  <jas@extundo.com>
8124
8125         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
8126         Remove the test_*_SOURCES variable: automake infers it by default.
8127         * modules/tls-tests: Likewise.
8128
8129 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8130
8131         Work around porting bugs reported by Dieter in
8132         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
8133         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
8134         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
8135         Include "getopt.h" first, to check interface.
8136         (getenv): Declare only if defined HAVE_DECL_GETENV &&
8137         !HAVE_DECL_GETENV.
8138         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
8139         (__strndup): Revert to K&R-style function dfns, the glibc style.
8140         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
8141         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
8142         Include strnlen.h first, to get prototype properly.
8143         (strnlen): Renamed from __strnlen.
8144         Remove weak alias.
8145
8146 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8147
8148         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
8149
8150 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8151
8152         * config/srclist.txt: Adjust to reflect glibc reorganization.
8153         This affects only comments.
8154
8155 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
8156
8157          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
8158          Reported by Bruce Korb <bkorb@gnu.org>.
8159
8160 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
8161
8162         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
8163         to pacify gcc -Wswitch-default.
8164
8165 2006-01-22  Bruno Haible  <bruno@clisp.org>
8166
8167         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
8168         temporary buffer for sprintf, take into account the precision also
8169         for 'd', 'i', 'u', 'o', 'x', 'X'.
8170
8171 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8172
8173         * modules/argp-tests: New module
8174         * tests/test-argp.c: New file
8175         * tests/test-argp-2.sh: New file
8176
8177 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8178
8179         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
8180         (__argp_base_name): Removed
8181         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
8182         typo.
8183         (__argp_base_name): Provide macro definition or extern declaration
8184         depending on the configuration
8185
8186 2006-01-20  Simon Josefsson  <jas@extundo.com>
8187
8188         * modules/inet_ntop (Depends-on): Depend on sys_socket.
8189
8190 2006-01-20  Simon Josefsson  <jas@extundo.com>
8191
8192         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
8193
8194 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
8195
8196         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
8197         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
8198         Suggested by Bruno Haible.
8199
8200 2006-01-20  Karl Berry  <karl@gnu.org>
8201
8202         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
8203         until changes propagate, I guess.
8204
8205 2006-01-19  Simon Josefsson  <jas@extundo.com>
8206
8207         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
8208
8209 2006-01-19  Simon Josefsson  <jas@extundo.com>
8210
8211         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
8212
8213 2006-01-19  Simon Josefsson  <jas@extundo.com>
8214
8215         * gnulib-tool: Set check_PROGRAMS.
8216
8217         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8218         modules/des-tests, modules/gc-arcfour-tests,
8219         modules/gc-arctwo-tests, modules/gc-des-tests,
8220         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8221         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8222         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8223         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8224         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8225         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
8226         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
8227         test_*_SOURCES.
8228
8229 2006-01-18  Simon Josefsson  <jas@extundo.com>
8230
8231         * modules/socklen (Depends-on): Depend on sys_socket.
8232
8233 2006-01-18  Simon Josefsson  <jas@extundo.com>
8234
8235         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8236         modules/des-tests, modules/gc-arcfour-tests,
8237         modules/gc-arctwo-tests, modules/gc-des-tests,
8238         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8239         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8240         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8241         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8242         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8243         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
8244         $(EXEEXT) to automake TESTS variable, for mingw32.
8245
8246 2006-01-17  Simon Josefsson  <jas@extundo.com>
8247
8248         * modules/socklen (Include): Need sys/socket.h.
8249
8250 2006-01-17  Bruno Haible  <bruno@clisp.org>
8251
8252         * modules/ssize_t (Include): Add <sys/types.h>.
8253
8254 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
8255
8256         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
8257         it's not portable and it doesn't work with cross-compiles.
8258         Problem reported by Bruno Haible.  Fix missing-$ typo in
8259         'test "gl_cv_ignore_unused_libraries" ...' that prevented
8260         -zignore from being used with Sun's C compiler.
8261
8262 2006-01-12  Simon Josefsson  <jas@extundo.com>
8263
8264         * lib/base64.c: Fix warning, reported by Bruno Haible
8265         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
8266
8267 2006-01-12  Bruno Haible  <bruno@clisp.org>
8268
8269         * modules/ldd: New file.
8270         * build-aux/ldd.sh.in: New file.
8271         * MODULES.html.sh (Support for building libraries and executables): Add
8272         ldd.
8273
8274 2006-01-12  Bruno Haible  <bruno@clisp.org>
8275
8276         * m4/ldd.m4: New file.
8277
8278 2006-01-12  Bruno Haible  <bruno@clisp.org>
8279
8280         * gnulib-tool (func_import, func_create_testdir): Don't go into an
8281         endless loop while replacing $auxdir with build-aux.
8282
8283 2006-01-11  Simon Josefsson  <jas@extundo.com>
8284
8285         * lib/stdint_.h (SIZE_MAX): Add missing (.
8286
8287 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
8288
8289         Sync from coreutils.
8290         * lib/md5.c: Fix commentary typos.
8291         (alignof, UNALIGNED_P): No need for a GCC-specific version.
8292         * lib/md5.h (__attribute__): Remove; unused.
8293         * lib/sha1.c: Fix commentary to match md5 better.
8294         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
8295         so that we don't need to worry about alignment.  All uses changed.
8296         This merges the 2005-10-28 md5 change into sha1.
8297
8298 2006-01-11  Jim Meyering  <jim@meyering.net>
8299
8300         Sync from coreutils.
8301         * lib/md5.c (OP): Fix spacing.
8302
8303 2006-01-11  Bruno Haible  <bruno@clisp.org>
8304
8305         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8306         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
8307         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
8308
8309 2006-01-11  Bruno Haible  <bruno@clisp.org>
8310
8311         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8312         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
8313         the "early" section as well.
8314
8315 2006-01-11  Bruno Haible  <bruno@clisp.org>
8316
8317         Avoid "ar: no archive members specified" error on MacOS X.
8318         * gnulib-tool (func_modules_add_dummy): New function.
8319         (func_import, func_create_testdir): Invoke it.
8320
8321 2006-01-11  Bruno Haible  <bruno@clisp.org>
8322
8323         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
8324         with $auxdir in AC_CONFIG_FILES statements.
8325
8326 2006-01-11  Bruno Haible  <bruno@clisp.org>
8327
8328         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8329         Initialize also noinst_HEADERS to empty.
8330
8331 2006-01-11  Bruno Haible  <bruno@clisp.org>
8332
8333         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
8334         variables.
8335         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
8336         autoreconf.
8337
8338 2006-01-11  Bruno Haible  <bruno@clisp.org>
8339
8340         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
8341         overridable by the user.
8342         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8343
8344 2006-01-10  Simon Josefsson  <jas@extundo.com>
8345
8346         * modules/sys_socket: New file.
8347
8348 2006-01-10  Simon Josefsson  <jas@extundo.com>
8349
8350         * m4/sys_socket_h.m4: New file.
8351
8352 2006-01-10  Simon Josefsson  <jas@extundo.com>
8353
8354         * lib/socket_.h: New file.
8355
8356 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8357
8358         * modules/readutmp (Maintainer): Add myself.
8359
8360 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8361
8362         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
8363         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
8364         People who are still concerned with buggy memcmp implementations
8365         can invoke gl_FUNC_MEMCMP themselves.
8366
8367 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8368
8369         * lib/regex_internal.h (BITSET_WORD_BITS):
8370         Work around a bug in 64-bit PGC (before version 6.1-2), where the
8371         preprocessor mishandles large unsigned values as if they were signed.
8372         Problem reported by Claudio Fontana in
8373         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
8374
8375 2006-01-10  Jim Meyering  <jim@meyering.net>
8376
8377         Avoid the double-free (first in fts_read, second in fts_close) that
8378         would occur when an `active' directory is made inaccessible (e.g.,
8379         via chmod a-x) during a traversal.
8380         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8381         before returning.  Reproduce this failure by
8382         mkdir -p a/b; cd a; chmod a-x . b
8383         Reported by Stavros Passas.
8384
8385         Sync from coreutils.
8386         * lib/sha1.c: Tweak grammar in a comment.
8387
8388 2006-01-10  Jim Meyering  <jim@meyering.net>
8389
8390         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
8391         Patch by Joerg Sonnenberger.
8392
8393 2006-01-10  Bruno Haible  <bruno@clisp.org>
8394
8395         * modules/readutmp: Depend on module free.
8396         * modules/strtok_r: Depend on module restrict.
8397
8398 2006-01-10  Bruno Haible  <bruno@clisp.org>
8399
8400         * modules/gettext (configure.ac): Add an invocation of
8401         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
8402
8403 2006-01-10  Bruno Haible  <bruno@clisp.org>
8404
8405         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
8406         Reported by Werner Lemberg <wl@gnu.org>.
8407
8408 2006-01-10  Bruno Haible  <bruno@clisp.org>
8409
8410         * lib/localcharset.c: Update from GNU gettext.
8411
8412 2006-01-10  Bruno Haible  <bruno@clisp.org>
8413
8414         * lib/argp.h (__const): Remove macro. Use const instead.
8415         * lib/argp-fmtstream.h (__const): Likewise.
8416         * lib/glob_.h (__const): Remove macro.
8417         * lib/glob-libc.h: Use const instead of __const.
8418
8419 2006-01-10  Bruno Haible  <bruno@clisp.org>
8420
8421         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
8422         variable.
8423         Needed to avoid an automake error regarding the 'gettext' module.
8424
8425 2006-01-09  Simon Josefsson  <jas@extundo.com>
8426
8427         * modules/inet_ntop (Depends-on): Add restrict.
8428
8429 2006-01-09  Simon Josefsson  <jas@extundo.com>
8430
8431         * modules/gc-rijndael-tests (License): Put under LGPL.
8432
8433         * modules/gc-des-tests (License): Likewise.
8434
8435         * modules/gc-arcfour-tests (License): Likewise.
8436
8437         * modules/gc-arctwo-tests (License): Likewise.
8438
8439         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
8440
8441         * modules/gc-hmac-sha1-tests (Files): Likewise.
8442
8443         * modules/gc-hmac-md5-tests (License): Likewise.
8444
8445         * modules/gc-sha1-tests (License): Likewise.
8446
8447         * modules/gc-md5-tests (License): Likewise.
8448
8449         * modules/gc-md4-tests (License): Likewise.
8450
8451         * modules/gc-md2-tests (License): Likewise.
8452
8453         * modules/gc-tests (License): Likewise.
8454
8455         * modules/des-tests (License): Likewise.
8456
8457         * modules/md4-tests (License): Likewise.
8458
8459         * modules/md2-tests (License): Likewise.
8460
8461 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8462
8463         Sync from coreutils:
8464
8465         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
8466         * modules/lib-ignore: New file.
8467         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
8468         chdir-safer.m4, lchmod.m4.
8469         * modules/openat: Add mkdirat.c, openat-priv.h.
8470
8471 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8472
8473         Sync from coreutils.
8474         * m4/lib-ignore.m4: New file.
8475         * m4/lchmod.m4: New file.
8476
8477 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8478
8479         Sync from coreutils.
8480         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
8481         for write access: POSIX says that must fail.
8482         * lib/fts.c (diropen): Likewise.
8483         * lib/save-cwd.c (save_cwd): Likewise.
8484         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
8485         well, for minor improvements on hosts that lack O_DIRECTORY.
8486         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
8487         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
8488         Fall back on chown if open failed with EACCES.
8489
8490         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
8491         Report an error at compile-time if only a 1-second nominal clock
8492         resolution is found.
8493
8494         * lib/lchmod.h: New file.
8495         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
8496         (make_dir_parents): Use lchown rather than chown, and
8497         lchmod rather than chmod.
8498
8499         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
8500         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
8501         "proc" reported by n0dalus.
8502
8503         * lib/mountlist.c: Include <limits.h>.
8504         (dev_from_mount_options)
8505         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
8506         New function.  It no longer assumes "dev=" has the System V meaning
8507         on Linux (since it doesn't).  It also parses "dev=" more carefully.
8508         (read_file_system_list)
8509         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
8510         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
8511         dev= in that case.
8512
8513         * lib/posixtm.h (PDS_PRE_2000): New macro.
8514         * lib/posixtm.c (year): Arg is now syntax_bits rather than
8515         allow_century.  All usages changed.  Reject dates outside the range
8516         1969-1999 if PDS_PRE_2000 is used.
8517
8518 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8519
8520         Sync from coreutils.
8521         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
8522         (Time of day items): Mention the possibility of leap seconds.
8523         Problem reported by Dr. David Alan Gilbert.
8524
8525 2006-01-09  Jim Meyering  <jim@meyering.net>
8526
8527         Sync from coreutils.
8528
8529         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
8530
8531         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
8532
8533         * lib/modechange.c (mode_compile): Reject an invalid mode string
8534         that starts with an octal digit.  From Andreas Gruenbacher.
8535
8536         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
8537         and dup to open_safer and dup_safer, respectively.
8538         (openat_permissive): Fix typo in comment.
8539
8540         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
8541         "gettext.h"; either no longer needed or are guaranteed by openat.h.
8542         (_): Remove; no longer needed.
8543         (openat): Renamed from rpl_openat; no need for rpl_openat
8544         since openat.h renames openat for us.
8545         Replace most of the body with a call to openat_permissive,
8546         to avoid duplicate code.
8547         Port to (probably hypothetical) environments were mode_t is
8548         wider than int.
8549         (openat_permissive): Require mode arg, so that we can check
8550         types better.  Put it just after flags.  Change cwd failure
8551         indicator from pointer-to-bool to pointer-to-errno-value.
8552         All callers changed.
8553         Invoke openat_save_fail and/or openat_restore_fail if
8554         cwd_errno is null, so that openat can call us.
8555         (openat_permissive, fdopendir, fstatat, unlinkat):
8556         Simplify errno handling to avoid some duplicate code,
8557         as it's OK to set errno on success.
8558         * lib/openat.h: Revamp code so that function macros depend on
8559         __OPENAT_PREFIX only, not also on AT_FDCWD.
8560         (openat_ro): Remove.  Caller changed to use openat_permissive.
8561         (openat_permissive): Now a macro, if not a function.
8562         (openat_restore_fail, openat_save_fail): Now always functions,
8563         since mkdirat needs them even if __OPENAT_PREFIX is defined.
8564
8565         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
8566         and openat.c.
8567         * lib/mkdirat.c: Include openat-priv.h.
8568         Remove definitions of macros defined therein.
8569         * lib/openat.c: Likewise.
8570
8571         * lib/mkdirat.c (mkdirat): New file and function.
8572         * lib/openat.h (mkdirat): Declare.
8573
8574         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
8575
8576         * lib/openat.h (openat_permissive): Declare.
8577         (openat_ro): Define.
8578
8579         * lib/openat.c (EXPECTED_ERRNO): New macro.
8580         (openat_permissive): New function -- used in remove.c rewrite.
8581         (all functions): Set errno just before returning, only if there
8582         was an actual failure.
8583         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
8584
8585         Emulate openat-family functions using Linux's procfs, if possible.
8586         Idea and some code based on Ulrich Drepper's glibc changes.
8587
8588         * lib/openat.c: (BUILD_PROC_NAME): New macro.
8589         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
8590         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
8591         before falling back on save_cwd and restore_cwd.
8592         (fdopendir, fstatat, unlinkat): Likewise.
8593
8594         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
8595         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
8596
8597         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
8598         as second argument to va_arg.  Otherwise, some versions of gcc
8599         warn that `if this code is reached, the program will abort'.
8600
8601 2006-01-09  Jim Meyering  <jim@meyering.net>
8602
8603         Sync from coreutils.
8604         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
8605         Require openat-priv.h.
8606
8607 2006-01-09  Bruno Haible  <bruno@clisp.org>
8608
8609         * modules/strnlen (Include): Use strnlen.h.
8610
8611 2006-01-09  Bruno Haible  <bruno@clisp.org>
8612
8613         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
8614
8615 2006-01-09  Bruno Haible  <bruno@clisp.org>
8616
8617         * lib/sysexit_.h (EX_OK): New macro.
8618         Suggested by Martin Lambers <marlam@marlam.de>.
8619
8620 2006-01-09  Bruno Haible  <bruno@clisp.org>
8621
8622         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
8623         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
8624
8625 2006-01-09  Bruno Haible  <bruno@clisp.org>
8626
8627         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
8628         numbers.
8629
8630 2006-01-09  Bruno Haible  <bruno@clisp.org>
8631
8632         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
8633         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
8634         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
8635         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
8636
8637 2006-01-09  Bruno Haible  <bruno@clisp.org>
8638
8639         * build-aux/javacomp.sh.in: New file, moved from lib/.
8640         * modules/javacomp-script (Files): Update.
8641         (configure.ac): Add AC_CONFIG_FILES invocation.
8642         (EXTRA_DIST): Remove variable.
8643
8644         * build-aux/javaexec.sh.in: New file, moved from lib/.
8645         * modules/javaexec (Files): Update.
8646         (configure.ac): Add AC_CONFIG_FILES invocation.
8647         (EXTRA_DIST): Remove javaexec.sh.in.
8648
8649         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
8650         * modules/csharpcomp-script (Files): Update.
8651         (configure.ac): Add AC_CONFIG_FILES invocation.
8652         (EXTRA_DIST): Remove variable.
8653
8654         * build-aux/csharpexec.sh.in: New file, moved from lib/.
8655         * modules/csharpexec (Files): Update.
8656         (configure.ac): Add AC_CONFIG_FILES invocation.
8657         (EXTRA_DIST): Remove csharpexec.sh.in.
8658
8659 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8660
8661         Sync from coreutils.
8662
8663         Add POSIX ACL support
8664         * lib/acl.h (copy_acl, set_acl): Add declarations.
8665         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
8666         systems other than Linux.
8667         (chmod_or_fchmod): New function: use fchmod when possible,
8668         and chmod otherwise.
8669         (file_has_acl): Add a POSIX ACL implementation, with a
8670         Linux-specific subcase.
8671         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
8672         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
8673         acls are unsupported.
8674         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
8675         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
8676         are unsupported.
8677
8678 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8679
8680         Sync from coreutils.
8681         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
8682
8683 2006-01-07  Bruno Haible  <bruno@clisp.org>
8684
8685         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
8686         gl_EARLY.
8687
8688 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8689
8690         * lib/strftime.c (tzname): Don't declare if it is already #defined.
8691         Problem reported for Mingw by Mark Junker.
8692
8693 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8694
8695         * README: Gnulib normally doesn't generate a tarball.
8696
8697 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
8698
8699         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
8700         long int, not int, for nanosecond counts, so that people who are
8701         used to POSIX struct timespec won't be surprised.  Reported by Jim
8702         Meyering.
8703
8704 2005-12-28  Bruno Haible  <bruno@clisp.org>
8705
8706         * build-aux/config.rpath: Update from GNU gettext.
8707
8708 2005-12-16  Jim Meyering  <jim@meyering.net>
8709
8710         * modules/fprintftime: New module.
8711         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
8712
8713 2005-12-16  Jim Meyering  <jim@meyering.net>
8714
8715         * m4/fprintftime.m4: New file.
8716
8717 2005-12-16  Jim Meyering  <jim@meyering.net>
8718
8719         * lib/fprintftime.c, lib/fprintftime.h: New files.
8720
8721 2005-12-15  Simon Josefsson  <jas@extundo.com>
8722
8723         * modules/socklen (configure.ac): Fix M4 macro name, to align with
8724         new m4/socklen.m4.
8725
8726 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8727
8728         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
8729         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
8730
8731 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8732
8733         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
8734         * lib/argp-help.c (fill_in_uparams): Check if the constructed
8735         struct uparams is valid. Fall back to the default values if it is
8736         not.
8737
8738 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8739
8740         * modules/argp (Files): Add argp-pin.c
8741         (Depends-on): dirname
8742         (lib_SOURCES): Add argp-pin.c
8743
8744 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8745
8746         * m4/argp.m4:  Check if program_invocation_name and
8747         program_invocation_short_name are declared and define appropriate
8748         macros if they are not.
8749
8750 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8751
8752         * lib/argp-help.c (__argp_base_name): New function
8753         (__argp_short_program_name): Rewrite using __argp_base_name
8754         * lib/argp-namefrob.h: Define program_invocation_name and
8755         program_invocation_short_name if requested
8756         (__argp_base_name): Add prototype
8757         * lib/argp-parse.c (argp_def): Use gettext wrappers
8758         (argp_default_parser): Use __argp_base_name
8759         * lib/argp-pin.c: New file. Defines program_invocation_name and
8760         program_invocation_short_name on systems that lack them.
8761
8762 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8763
8764         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
8765         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8766         porting problem reported by Georg Schwarz in
8767         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8768
8769 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8770
8771         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
8772         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8773         porting problem reported by Georg Schwarz in
8774         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8775
8776 2005-12-05  Bruno Haible  <bruno@clisp.org>
8777
8778         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
8779         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
8780         Reported by Mark Junker <mjscod@gmx.de>.
8781
8782 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
8783
8784         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
8785         Use implementation from Albert Chin, with some
8786         comments/corrections by Stepan Kasal and myself.
8787
8788 2005-12-02  Bruno Haible  <bruno@clisp.org>
8789
8790         * gnulib-tool (func_import): Accept GPLed build tool modules when
8791         --lgpl is given.
8792         * modules/csharpcomp-script: New file.
8793         * modules/csharpcomp: Depend on it.
8794         * modules/javacomp-script: New file.
8795         * modules/javacomp: Depend on it.
8796         Suggested by Simon Josefsson.
8797
8798 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
8799
8800         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
8801         statement, to work around an HP-UX 10.20 compiler bug reported by
8802         Peter O'Gorman.
8803
8804 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8805
8806         * modules/savedir (Depends-on): Add openat.
8807
8808 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8809
8810         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
8811         (uintmax_t) [defined uintmax_t]: Do not declare.
8812         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
8813         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
8814         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
8815         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
8816         sake of portability to weird hosts that C allows (though we don't
8817         know of any practical examples).
8818
8819         * lib/savedir.h (fdsavedir): New decl.
8820         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
8821         contains most of the former guts of savedir.
8822         (savedir): Use savedirstream.
8823         Include "openat.h".
8824
8825 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
8826
8827         * modules/obstack (Files): Add m4/ulonglong.m4.
8828         Problem reported by Davide Angelocola.
8829
8830 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
8831
8832         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
8833         coreutils no longer futzes with rounding modes.
8834
8835 2005-11-14  Jim Meyering  <jim@meyering.net>
8836
8837         * lib/mkstemp-safer.c: Include <config.h>, required for possible
8838         replacement of mkstemp.
8839
8840 2005-11-10  Simon Josefsson  <jas@extundo.com>
8841
8842         * lib/readline.c: Remove EOL.
8843
8844 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8845
8846         * modules/gethrxtime (Depends-on): Add gettime.
8847
8848 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8849
8850         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
8851         or gettimeofday; no longer needed.
8852
8853 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8854
8855         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
8856         time business.
8857         (gethrxtime) [! (HAVE_NANOUPTIME
8858         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
8859         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
8860         our own approximation.
8861
8862 2005-11-08  Eric Blake  <ebb9@byu.net>
8863
8864         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8865
8866 2005-11-08  Eric Blake  <ebb9@byu.net>
8867
8868         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8869
8870 2005-11-04  Bruno Haible  <bruno@clisp.org>
8871
8872         * gnulib-tool: Implement --update mode.
8873
8874 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8875
8876         Fix porting problem reported by Theodoros V. Kalamatianos.
8877         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
8878         Don't assume that futimes failing means we must fail.
8879
8880 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8881
8882         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
8883         variables to suggest the intended function of the PATH_MAX check.
8884
8885 2005-10-30  Kean Johnston  <jkj@sco.com>
8886
8887         Trivial changes to support SCO systems.
8888         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
8889         as PATH_MAX.
8890         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
8891         where __ptr is null when no I/O is pending.
8892
8893 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
8894
8895         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
8896         leave errno alone.  Problem reported by Dmitry V. Levin.
8897
8898 2005-10-28  Simon Josefsson  <jas@extundo.com>
8899
8900         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
8901         Test more.
8902
8903         * tests/test-gc-md2.c, tests/test-md2.c: New files.
8904
8905         * modules/md2, modules/md2-tests: New files.
8906
8907 2005-10-28  Simon Josefsson  <jas@extundo.com>
8908
8909         * m4/inet_ntop.m4: More tests.
8910
8911         * m4/gc-md2.m4, md2.m4: New file.
8912
8913 2005-10-28  Simon Josefsson  <jas@extundo.com>
8914
8915         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
8916         "restrict" keywords, as per POSIX.  Protect the function
8917         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
8918         Don't use K&R prototypes.  Check the sprintf return values.
8919         Re-define EAFNOSUPPORT if not present.  Indent.
8920
8921         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
8922         suggested by Bruno Haible <bruno@clisp.org>.
8923
8924         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
8925
8926         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
8927
8928         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
8929         libgcrypt).
8930
8931         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
8932
8933         * lib/md2.h, lib/md2.c: New files.
8934
8935 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
8936
8937         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
8938         errno alone.  Problem reported by Frederic Jolliton.
8939
8940 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8941
8942         * modules/verify (License): Change from GPL to LGPL.  This is a
8943         tiny module and there are apparently near-equivalents that are
8944         under the BSD license.
8945
8946 2005-10-24  Simon Josefsson  <jas@extundo.com>
8947
8948         * modules/sha1: Relicense to LGPL.
8949
8950 2005-10-24  Simon Josefsson  <jas@extundo.com>
8951
8952         * lib/md4.h: Shrink buffer size, now that we changed the type.
8953
8954 2005-10-23  Simon Josefsson  <jas@extundo.com>
8955
8956         * gnulib-tool (func_import): Fix --tests-base.
8957
8958 2005-10-22  Simon Josefsson  <jas@extundo.com>
8959
8960         * modules/arcfour (Depends-on): Need stdint.
8961
8962 2005-10-22  Simon Josefsson  <jas@extundo.com>
8963
8964         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
8965         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
8966
8967 2005-10-22  Simon Josefsson  <jas@extundo.com>
8968
8969         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
8970         suggested by Bruno Haible <bruno@clisp.org>.
8971
8972 2005-10-22  Simon Josefsson  <jas@extundo.com>
8973
8974         * lib/crc.h: Include stddef.h, for size_t.
8975
8976 2005-10-22  Simon Josefsson  <jas@extundo.com>
8977
8978         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
8979         arcfour_context struct (simplify test vector testing in GNU
8980         Shishi).
8981
8982 2005-10-21  Simon Josefsson  <jas@extundo.com>
8983
8984         * modules/des, modules/des-tests: New files.
8985
8986         * modules/gc-des, modules/gc-des-tests: New files.
8987
8988         * tests/test-des.c, tests/test-gc-des.c: New file.
8989
8990 2005-10-21  Simon Josefsson  <jas@extundo.com>
8991
8992         * modules/arctwo, modules/arctwo-tests: New files.
8993
8994         * tests/test-arctwo.c: New file.
8995
8996         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
8997
8998         * tests/test-gc-arctwo.c: New file.
8999
9000 2005-10-21  Simon Josefsson  <jas@extundo.com>
9001
9002         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
9003         Bruno Haible <bruno@clisp.org>.
9004
9005         * m4/gc-des.m4: New file.
9006
9007 2005-10-21  Simon Josefsson  <jas@extundo.com>
9008
9009         * m4/arctwo.m4: New file.
9010
9011         * m4/gc-arctwo.m4: New file.
9012
9013 2005-10-21  Simon Josefsson  <jas@extundo.com>
9014
9015         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
9016         block.
9017
9018 2005-10-21  Simon Josefsson  <jas@extundo.com>
9019
9020         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
9021         <bruno@clisp.org>.
9022
9023         * lib/hmac-sha1.c (hmac_sha1): Likewise.
9024
9025         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
9026         Bruno Haible <bruno@clisp.org>.
9027
9028         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
9029         <bruno@clisp.org>.
9030
9031 2005-10-21  Simon Josefsson  <jas@extundo.com>
9032
9033         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
9034
9035 2005-10-21  Simon Josefsson  <jas@extundo.com>
9036
9037         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
9038
9039 2005-10-21  Simon Josefsson  <jas@extundo.com>
9040
9041         * lib/des.h, lib/des.c: New files.
9042
9043         * lib/gc-gnulib.c: Support DES.c
9044
9045 2005-10-21  Simon Josefsson  <jas@extundo.com>
9046
9047         * lib/arctwo.h, lib/arctwo.c: New files.
9048
9049         * lib/gc-gnulib.c: Support ARCTWO.
9050
9051 2005-10-21  Simon Josefsson  <jas@extundo.com>
9052
9053         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
9054         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
9055
9056 2005-10-21  Simon Josefsson  <jas@extundo.com>
9057
9058         * gnulib-tool (func_import, func_create_testdir): Define automake
9059         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
9060         Makefile.am snippet),
9061         suggested by Bruno Haible <bruno@clisp.org>.
9062
9063         * modules/gc (Makefile.am): Use it.
9064
9065 2005-10-21  Bruno Haible  <bruno@clisp.org>
9066
9067         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
9068         patch.
9069
9070 2005-10-19  Simon Josefsson  <jas@extundo.com>
9071
9072         * tests/test-gc-rijndael.c: New file.
9073
9074         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
9075
9076 2005-10-19  Simon Josefsson  <jas@extundo.com>
9077
9078         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
9079         interface too.
9080
9081 2005-10-19  Simon Josefsson  <jas@extundo.com>
9082
9083         * tests/test-gc-arcfour.c: New file.
9084
9085         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
9086
9087 2005-10-19  Simon Josefsson  <jas@extundo.com>
9088
9089         * modules/gc-md4, modules/gc-md4-tests: New file.
9090
9091         * tests/test-gc-md4.c: New file.
9092
9093 2005-10-19  Simon Josefsson  <jas@extundo.com>
9094
9095         * m4/gc-md4.m4: New file.
9096
9097 2005-10-19  Simon Josefsson  <jas@extundo.com>
9098
9099         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
9100         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
9101         <kasal@ucw.cz>.
9102
9103 2005-10-19  Simon Josefsson  <jas@extundo.com>
9104
9105         * m4/gc-arcfour.m4: New file.
9106
9107         * m4/gc-rijndael.m4: New file.
9108
9109 2005-10-19  Simon Josefsson  <jas@extundo.com>
9110
9111         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
9112
9113 2005-10-19  Simon Josefsson  <jas@extundo.com>
9114
9115         * lib/gc-gnulib.c: Support ARCFOUR.
9116
9117 2005-10-19  Simon Josefsson  <jas@extundo.com>
9118
9119         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
9120         support.
9121
9122         * lib/gc.h: Add ECB enum type.
9123
9124         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
9125
9126 2005-10-18  Simon Josefsson  <jas@extundo.com>
9127
9128         * tests/test-md5.c: New file.
9129
9130         * modules/md5-tests: New file.
9131
9132 2005-10-18  Simon Josefsson  <jas@extundo.com>
9133
9134         * tests/test-md4.c: New file.
9135
9136         * modules/md4, modules/md4-tests: New files.
9137
9138 2005-10-18  Simon Josefsson  <jas@extundo.com>
9139
9140         * m4/md4.m4: New file.
9141
9142 2005-10-18  Simon Josefsson  <jas@extundo.com>
9143
9144         * lib/md4.h, lib/md4.c: New files, based on md5.?.
9145
9146 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
9147
9148         * gnulib-tool (func_create_testdir): Omit the second check whether
9149         BUILT_SOURCES in nonempty.
9150
9151 2005-10-17  Simon Josefsson  <jas@extundo.com>
9152
9153         * tests/test-rijndael.c: New file.
9154
9155 2005-10-17  Simon Josefsson  <jas@extundo.com>
9156
9157         * modules/sha1: Depend on stdint instead of md5.
9158
9159         * modules/md5: Depend on stdint, remove uint32_t.
9160
9161 2005-10-17  Simon Josefsson  <jas@extundo.com>
9162
9163         * modules/gc-sha1-tests: New file.
9164
9165         * tests/test-gc-sha1.c: New file.
9166
9167 2005-10-17  Simon Josefsson  <jas@extundo.com>
9168
9169         * m4/md5.m4: Remove call to uint32_t.m4.
9170
9171 2005-10-17  Simon Josefsson  <jas@extundo.com>
9172
9173         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
9174
9175         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
9176         md5.h.
9177
9178         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
9179
9180         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
9181
9182 2005-10-17  Simon Josefsson  <jas@extundo.com>
9183
9184         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
9185
9186 2005-10-17  Simon Josefsson  <jas@extundo.com>
9187
9188         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
9189
9190 2005-10-17  Simon Josefsson  <jas@extundo.com>
9191
9192         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
9193
9194         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
9195
9196 2005-10-17  Bruno Haible  <bruno@clisp.org>
9197
9198         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
9199         that it can also be used in a test.
9200
9201 2005-10-16  Bruno Haible  <bruno@clisp.org>
9202
9203         * gnulib-tool (func_emit_tests_Makefile_am): Also define
9204         TESTS_ENVIRONMENT, so that individual tests can augment it.
9205
9206         * gnulib-tool (func_create_testdir): Use an intermediate target for
9207         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
9208         macros, like $(ALLOCA_H), which cannot be passed through the command
9209         line.
9210
9211 2005-10-15  Simon Josefsson  <jas@extundo.com>
9212
9213         * modules/rijndael-tests: New file.
9214
9215         * modules/rijndael: New file.
9216
9217 2005-10-15  Simon Josefsson  <jas@extundo.com>
9218
9219         * m4/rijndael.m4: New file.
9220
9221 2005-10-15  Simon Josefsson  <jas@extundo.com>
9222
9223         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
9224
9225         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
9226
9227 2005-10-14  Simon Josefsson  <jas@extundo.com>
9228
9229         * tests/test-arcfour.c: New file.
9230
9231         * modules/arcfour, modules/arcfour-tests: New files.
9232
9233 2005-10-14  Simon Josefsson  <jas@extundo.com>
9234
9235         * m4/arcfour.m4: New file.
9236
9237 2005-10-14  Simon Josefsson  <jas@extundo.com>
9238
9239         * lib/arcfour.h, lib/arcfour.c: New files.
9240
9241 2005-10-14  Roland McGrath  <roland@redhat.com>
9242
9243         Import from libc.  [BZ #1331]
9244         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
9245         macro argument.
9246         Reported by Matej Vela <vela@debian.org>.
9247
9248 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9249
9250         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
9251         include <wchar.h>; no longer needed.
9252
9253 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9254
9255         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
9256
9257 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
9258         and  Ulrich Drepper  <drepper@redhat.com>
9259
9260         Import from libc.
9261         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
9262         instead of inline stream orientation test and two separate
9263         function calls.  Pay no attention to USE_IN_LIBIO.
9264
9265 2005-10-13  Simon Josefsson  <jas@extundo.com>
9266
9267         * modules/gc-hmac-md5-tests: New file.
9268
9269         * tests/test-gc-hmac-sha1.c: New file.
9270
9271         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
9272
9273         * modules/gc-hmac-md5-tests: New file.
9274
9275         * tests/test-gc-md5.c: New file.
9276
9277         * modules/gc-md5-tests: New file.
9278
9279 2005-10-13  Simon Josefsson  <jas@extundo.com>
9280
9281         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
9282         Move memory allocation outside of loop.
9283
9284 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
9285
9286         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
9287         intermediate directory is in a read-only file system.  Problem
9288         reported by Eric Blake.
9289
9290 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
9291
9292         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
9293
9294 2005-10-12  Simon Josefsson  <jas@extundo.com>
9295
9296         * tests/test-hmac-sha1.c: New file.
9297
9298         * modules/hmac-sha1-tests: New file.
9299
9300         * modules/hmac-sha1: New file.
9301
9302 2005-10-12  Simon Josefsson  <jas@extundo.com>
9303
9304         * modules/gc-sha1: New file.
9305
9306 2005-10-12  Simon Josefsson  <jas@extundo.com>
9307
9308         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
9309
9310         * tests/test-gc-pbkdf2-sha1.c: New file.
9311
9312 2005-10-12  Simon Josefsson  <jas@extundo.com>
9313
9314         * modules/gc-md5, modules/gc-hmac-md5: New files.
9315
9316         * modules/gc (Files): Remove md5, memxor and hmac files.
9317
9318 2005-10-12  Simon Josefsson  <jas@extundo.com>
9319
9320         * m4/gc-pbkdf2-sha1.m4: New file.
9321
9322         * m4/gc-hmac-sha1.m4: New file.
9323
9324         * m4/gc-sha1: New file.
9325
9326         * m4/hmac-sha1.m4: New file.
9327
9328 2005-10-12  Simon Josefsson  <jas@extundo.com>
9329
9330         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
9331
9332         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
9333
9334 2005-10-12  Simon Josefsson  <jas@extundo.com>
9335
9336         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
9337         suggested by Bruno Haible <bruno@clisp.org>.
9338
9339 2005-10-12  Simon Josefsson  <jas@extundo.com>
9340
9341         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
9342
9343 2005-10-12  Simon Josefsson  <jas@extundo.com>
9344
9345         * lib/gc-pbkdf2-sha1.c: New file.
9346
9347         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
9348
9349 2005-10-12  Simon Josefsson  <jas@extundo.com>
9350
9351         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
9352
9353         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
9354
9355 2005-10-12  Simon Josefsson  <jas@extundo.com>
9356
9357         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
9358         GC_USE_HMAC_MD5, respectively.
9359
9360         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
9361         (gc_md5): Fix typo.
9362
9363         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
9364
9365         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
9366
9367         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
9368
9369 2005-10-12  Bruno Haible  <bruno@clisp.org>
9370
9371         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
9372         Reported by Stepan Kasal <kasal@ucw.cz>.
9373
9374 2005-10-11  Simon Josefsson  <jas@extundo.com>
9375
9376         * tests/test-crc.c: New file.
9377
9378         * modules/crc, modules/crc-tests: New files.
9379
9380 2005-10-11  Simon Josefsson  <jas@extundo.com>
9381
9382         * m4/crc.m4: New file.
9383
9384 2005-10-11  Simon Josefsson  <jas@extundo.com>
9385
9386         * lib/gc.h: Add gc_hash and gc_hash_buffer.
9387
9388         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
9389
9390         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
9391
9392 2005-10-11  Simon Josefsson  <jas@extundo.com>
9393
9394         * lib/crc.h, lib/crc.c: New files.
9395
9396         * lib/gc.h (gc_hash_buffer): Add doc.
9397
9398 2005-10-11  Bruno Haible  <bruno@clisp.org>
9399
9400         * modules/c-strcasestr: New file.
9401         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
9402
9403 2005-10-11  Bruno Haible  <bruno@clisp.org>
9404
9405         * modules/c-strcase: New file.
9406         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
9407
9408 2005-10-11  Bruno Haible  <bruno@clisp.org>
9409
9410         * lib/strcasecmp.c: Include limits.h.
9411         (strcasecmp): Avoid integer overflow on exotic platforms.
9412         * lib/strncasecmp.c: Include limits.h.
9413         (strncasecmp): Avoid integer overflow on exotic platforms.
9414         Reported by Paul Eggert.
9415
9416 2005-10-11  Bruno Haible  <bruno@clisp.org>
9417
9418         * lib/c-strcasestr.h: New file, from GNU gettext.
9419         * lib/c-strcasestr.c: New file, from GNU gettext.
9420
9421 2005-10-11  Bruno Haible  <bruno@clisp.org>
9422
9423         * lib/c-strcase.h: New file, from GNU gettext.
9424         * lib/c-strcasecmp.c: New file, from GNU gettext.
9425         * lib/c-strncasecmp.c: New file, from GNU gettext.
9426
9427 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9428
9429         * modules/mempcpy (License): GPL -> LGPL.
9430         * modules/strchrnul (License): Likewise.
9431         * modules/sysexits (License): Likewise.
9432
9433 2005-10-08  Simon Josefsson  <jas@extundo.com>
9434
9435         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
9436
9437 2005-10-07  Simon Josefsson  <jas@extundo.com>
9438
9439         * m4/memxor.m4: Remove gl_C_RESTRICT call.
9440
9441 2005-10-06  Simon Josefsson  <jas@extundo.com>
9442
9443         * tests/test-hmac-md5.c: New file.
9444
9445         * modules/hmac-md5-tests: New file.
9446
9447         * modules/hmac-md5: New file.
9448
9449 2005-10-06  Simon Josefsson  <jas@extundo.com>
9450
9451         * m4/hmac-md5.m4: New file.
9452
9453         * m4/memxor.m4: Require gl_C_RESTRICT.
9454
9455 2005-10-06  Simon Josefsson  <jas@extundo.com>
9456
9457         * lib/memxor.c (memxor): Avoid casts and warnings.
9458
9459 2005-10-06  Simon Josefsson  <jas@extundo.com>
9460
9461         * lib/hmac-md5.c: New file.
9462
9463         * lib/hmac.h: New file.
9464
9465 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9466
9467         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
9468         promotes to int, not unsigned int, to catch the AIX 5.3
9469         compiler bug.
9470
9471 2005-10-05  Simon Josefsson  <jas@extundo.com>
9472
9473         * modules/memxor: New file.
9474
9475         * modules/iconv (Files): Move config.rpath to havelib, it is used
9476         there.
9477
9478         * modules/havelib (Files): Add config.rpath.
9479
9480 2005-10-05  Simon Josefsson  <jas@extundo.com>
9481
9482         * m4/memxor.m4: New file.
9483
9484 2005-10-05  Simon Josefsson  <jas@extundo.com>
9485
9486         * lib/memxor.c (memxor): Fix compiler error.
9487
9488         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
9489         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
9490
9491         * lib/memxor.h, lib/memxor.c: New files.
9492
9493         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
9494         we assume all systems have it, suggested by Jim Meyering
9495         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
9496         any systems lack sys/socket.h; mingw32 is known to lack it, but we
9497         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
9498         same reasons.
9499
9500 2005-10-05  Simon Josefsson  <jas@extundo.com>
9501
9502         * config/srclist.txt: Add glibc bug 1423 for md5.h.
9503
9504 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9505
9506         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
9507         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
9508         needed, since the source code now assumes these .h files.
9509
9510 2005-10-05  Derek Price  <derek@ximbiot.com>
9511
9512         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
9513
9514 2005-10-05  Bruno Haible  <bruno@clisp.org>
9515
9516         * modules/stdint (License): Change to LGPL.
9517
9518 2005-10-04  Simon Josefsson  <jas@extundo.com>
9519
9520         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
9521         D. Baushke" <mdb@gnu.org>.
9522
9523 2005-10-04  Bruno Haible  <bruno@clisp.org>
9524
9525         * lib/verify.h (verify_true): Provide alternative definition for C++.
9526
9527 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
9528
9529         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
9530         (SSIZE_MAX): New macro, if not already defined.
9531         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
9532         than 2 GiB.
9533
9534 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9535
9536         Sync from coreutils.
9537         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
9538         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
9539         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
9540         ULLONG_MAX doesn't work with 2.7.2.1.
9541
9542 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9543
9544         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
9545         From Ben Pfaff.
9546
9547         * modules/exclude (Depends-on): Depend on verify.
9548         * modules/strtoimax (Depends-on): Likewise.
9549         * modules/utimecmp (Depends-on): Likewise.
9550
9551 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9552
9553         * lib/exclude.c: Include verify.h.
9554         (verify): Remove.  All callers changed to use verify.h's version.
9555         * lib/strtoimax.c: Likewise.
9556         * lib/utimecmp.c: Likewis.e
9557
9558         Sync from coreutils.
9559         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
9560         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
9561         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
9562         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
9563         bother returning ENOSYS if settimeofday or stime fails; just let
9564         them return whatever errno they want to return.
9565         * lib/utimens.c: Include unistd.h, for dup2.
9566         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
9567         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
9568
9569 2005-10-02  Jim Meyering  <jim@meyering.net>
9570
9571         Sync from coreutils.
9572         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
9573         from glibc-2.2.5 that fails for read-only files.
9574
9575 2005-10-02  Jim Meyering  <jim@meyering.net>
9576
9577         Sync from coreutils.
9578         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
9579         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
9580         `#if HAVE_CONFIG_H'.
9581         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
9582         Remove AT_FDCWD test.
9583         Do not consume the fd unless successful.
9584         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
9585         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
9586         block, so that we don't even try to compile it if settimeofday is
9587         available.  This works around a compilation failure on OSF1 V5.1,
9588         due to stime requiring a `long int*' while tv_sec is `int'.
9589
9590 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
9591
9592         Sync from coreutils.
9593         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
9594         against `yes', rather than just testing for nonempty.
9595
9596 2005-10-01  Simon Josefsson  <jas@extundo.com>
9597
9598         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
9599         and Darwin.
9600
9601         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
9602         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
9603         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
9604         freeaddrinfo and gai_strerror are declared by the POSIX headers.
9605         Check if struct addrinfo is declared.
9606
9607 2005-10-01  Simon Josefsson  <jas@extundo.com>
9608
9609         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
9610         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
9611         AI_* and EAI_* definitions.  Protect function declarations.
9612
9613 2005-10-01  Jim Meyering  <jim@meyering.net>
9614
9615         Sync from coreutils.
9616
9617         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
9618         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
9619         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
9620         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9621         in the inet and nsl libraries.  Required on Solaris 5.7.
9622
9623 2005-10-01  Jim Meyering  <jim@meyering.net>
9624
9625         Sync from coreutils.
9626         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9627         in the inet and nsl libraries.  Required on Solaris 5.7.
9628
9629 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
9630
9631         * lib/getdelim.c (getdelim): Remove unused variables.
9632
9633 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9634
9635         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
9636         so that the code works even with ancient cpp.  Portability problem
9637         with GCC 2.7.2.1 reported by Thomas M.Ott.
9638
9639 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9640
9641         * modules/regex (Depends-on): Add strcase.
9642
9643         * modules/gethostname (Licence): Change from GPL to LGPL, since
9644         gethostname.c is a trivial implementation of a standard library
9645         function.
9646         * modules/poll (License): Change from GPL to LGPL, since it's
9647         derived from LGPL code.
9648
9649 2005-09-27  Jim Meyering  <jim@meyering.net>
9650
9651         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
9652         HAVE_CONFIG_H.
9653
9654         * lib/intprops.h (signed_type_or_expr__): Define.
9655         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
9656         for unsigned types.
9657
9658 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9659
9660         * lib/verify.h (verify_expr): Remove, replacing with:
9661         (verify_true): New macro that returns true instead of void.
9662         (verify_type__): Remove.
9663         (verify): Use verify_true rather than verify_type__.
9664
9665 2005-09-26  Bruno Haible  <bruno@clisp.org>
9666
9667         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
9668         is necessary.
9669         (lib_SOURCES): Remove mbchar.c.
9670         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
9671         (Files): Add m4/mbrtowc.m4.
9672         * modules/mbiter: Likewise.
9673         * modules/mbuiter: Likewise.
9674
9675 2005-09-26  Bruno Haible  <bruno@clisp.org>
9676
9677         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
9678         compile mbchar.c if they are not both present.
9679         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
9680         * m4/mbiter.m4 (gl_MBITER): Likewise.
9681         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
9682         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
9683         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
9684
9685 2005-09-25  Jim Meyering  <jim@meyering.net>
9686
9687         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
9688         also uses socklen_t.
9689
9690 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
9691
9692         * lib/utimens.c (ENOSYS): Define if not already defined.
9693         (futimens): Support having a null PATH if the file descriptor
9694         is nonnegative.
9695
9696         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
9697         Remove.
9698         (__attribute): Define to empty unless GCC 3.1 or later.
9699         This works around a core dump on OpenBSD 3.4, which has GCC
9700         2.95.3, which dumps core when given __attribute__(()).  It also
9701         simplifies other tests, since we really don't want to bother with
9702         worrying about which ancient version of GCC supported what.
9703         Original problem reported by Yoann Vandoorselaere, with part of
9704         the fix suggested by Derek Price.
9705
9706 2005-09-24  Jim Meyering  <jim@meyering.net>
9707
9708         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
9709         so we can once again use a positive bitfield width of 1 -- now we
9710         don't have to explain why we were using a bitfield width of 2.
9711
9712 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9713
9714         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
9715         and similarly for the other external symbols.  Problem reported
9716         by James Gallager.
9717
9718         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
9719         bug reported by Jim Meyering.
9720
9721         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
9722         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
9723         not needed, since socklen is a prerequisite module.
9724
9725 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9726
9727         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
9728         Problem reported by Eric Blake.
9729         (getaddrinfo): Initialize se so that it's not garbage.
9730         Redo internal storage allocation so that it doesn't make unportable
9731         assumptions about alignment.
9732         Fix a memory leak.
9733
9734         * lib/utimens.c (futimens): Use futimesat if available.
9735         Prefer it to futimes since it doesn't have the futimes bug.
9736
9737         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
9738         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
9739         Instead, declare a function that returns a pointer to an array,
9740         and use verify_type__ to declare the size of the array.
9741         Problem and germ of a solution reported by Bruno Haible.
9742         (verify_type__): Use 2, not 1, for bitfield size, to avoid
9743         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
9744
9745 2005-09-23  Jim Meyering  <jim@meyering.net>
9746
9747         Sync from coreutils.
9748         Correct build failure (socklen_t not defined) on at least
9749         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
9750         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
9751
9752 2005-09-23  Jim Meyering  <jim@meyering.net>
9753
9754         * modules/getaddrinfo (Depends-on): Add socklen.
9755
9756 2005-09-23  Bruno Haible  <bruno@clisp.org>
9757
9758         * tests/test-verify.c: New file.
9759
9760 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9761
9762         Sync from coreutils.
9763
9764         * modules/argmatch (Depends-on): Add verify.
9765         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
9766         unistd-safer.
9767         * modules/save-cwd (Depends-on): Likewise.
9768
9769         * modules/openat (Files): Add lib/openat-die.c.
9770         (Depends-on): Remove error, exitfail.
9771         Add dirname.
9772
9773         * modules/verify: New file.
9774         * MODULES.html.sh (Diagnostics <assert.h>): New section,
9775         with "verify" module.
9776
9777 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9778
9779         Sync from coreutils.
9780
9781         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
9782         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
9783         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
9784         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
9785         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
9786         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
9787         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
9788         Don't bother checking for string.h, stdlib.h, unistd.h.
9789         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
9790         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
9791         module's job.
9792         * m4/jm-macros.m4 (gl_MACROS): Likewise.
9793         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
9794
9795         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
9796         (gl_GETDATE): Use it.
9797
9798         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
9799
9800 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9801
9802         Sync from coreutils.
9803
9804         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
9805         stat-time.h.
9806         * lib/argmatch.h: Include verify.h
9807         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
9808         (ARGMATCH_ASSERT): Remove; unused.
9809         * lib/canonicalize.c: Assume STDC_HEADERS.
9810         * lib/exclude.c: Include "strcase.h".
9811         * lib/regex_internal.h [!defined _LIBC]: Likewise.
9812         * lib/getusershell.c: Include stdio--.h rather than stdio.h
9813         and stdio-safer.h.
9814         (getusershell): Call fopen, not fopen_safer.
9815         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
9816         Do not include unistd-safer.h.
9817         (save_cwd): Don't call fd_safer; no longer needed
9818         now that we include fcntl--.h.
9819
9820         * lib/getdate.y (relative_time): New type.
9821         (RELATIVE_TIME_0): New constant.
9822         (parser_control): Use relative_time instead of doing it ourselves.
9823         (%union): Add new relative_time rel member.
9824         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
9825         Now typeless.
9826         (relunit, relunit_snumber): Now of type rel.
9827         (zone, rel, relunit, get_date): Adjust to above changes.
9828
9829         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
9830         Do not include unistd-safer.h.
9831         (getloadavg): Don't call fd_safer; no longer needed
9832         now that we include fcntl--.h.
9833
9834         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
9835         (make_dir_parents): Treat ENOSYS like EEXIST.
9836
9837         Improve quality of diagnostics on restore_cwd failure.
9838         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
9839         (make_dir_parents): Last arg is now int * (for errno), not bool *.
9840         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
9841         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
9842         each time through the loop.  Do not diagnose restore_cwd failure;
9843         that is the caller's job (and perhaps the caller does not care).
9844
9845         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
9846         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
9847         If the file already exists but is not a directory, don't bother
9848         to try to make its parents.
9849         Close potential file descriptor leak if we can't chdir("/") (!).
9850         Don't always return true if chdir($PWD) fails; return true only
9851         if the requested action was done successfully (except for the
9852         chdir($PWD)).
9853         Don't log final directory unless we actually made it.
9854         Refactor to avoid duplicate code to fix up permissions.
9855         Don't attempt to fix up parent permissions if chdir($PWD) fails.
9856
9857         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
9858         to make it a bit faster and (I hope) clearer.
9859         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
9860         Fix bug in formats like %2N.
9861
9862         * lib/verify.h: New file.
9863
9864 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9865
9866         Sync from coreutils.
9867         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
9868
9869 2005-09-22  Jim Meyering  <jim@meyering.net>
9870
9871         Sync from coreutils.
9872
9873         * m4/lstat.m4 (gl_FUNC_LSTAT):
9874         Use AC_LIBSOURCES to require lstat.c and lstat.h.
9875         Remove obsolete comment.
9876         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
9877         * m4/xstrtod.m4: Likewise.
9878
9879         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
9880
9881 2005-09-22  Jim Meyering  <jim@meyering.net>
9882
9883         Sync from coreutils.
9884
9885         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
9886
9887         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
9888         the .tm_year member, since otherwise gcc-4.0 would now warn about
9889         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
9890
9891         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
9892         order to avoid an unsuppressible warning from gcc on 64-bit systems.
9893
9894         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
9895         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
9896         when run in a time zone for which daylight savings time is in effect
9897         for the starting date.
9898
9899         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
9900         stop us from restricting permissions of just-created absolute-named
9901         directories.
9902         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
9903         to restore initial working directory.
9904         * lib/mkdir-p.c (make_dir_parents): New parameter:
9905         different_working_dir, to tell caller if/when we change the working
9906         directory and are unable to return to the initial one.
9907         * lib/mkdir-p.h (make_dir_parents): Update prototype.
9908         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
9909         `return false'.  This fixes a bug introduced on 2004-07-30.
9910
9911         * lib/openat.c (fdopendir): Be sure to close the supplied
9912         file descriptor before returning.  This makes our replacement
9913         implementation a little closer to Solaris's, where fdopendir
9914         ties the file descriptor to the returned DIR* pointer.
9915         * lib/openat.c (unlinkat): New function.
9916         * lib/openat.h (unlinkat): Add prototype.
9917         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
9918         (openat_restore_fail): Rename from openat_restore_die.
9919         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
9920
9921         Provide an alternative to exiting immediately upon save_cwd or
9922         restore_cwd failure.  Now, an application can arrange e.g.,
9923         to perform a longjump in that case.
9924         * lib/openat.c: Include dirname.h.
9925         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
9926         (rpl_openat, fdopendir, fstatat): Call openat_save_die
9927         and openat_restore_die rather than calling error directly.
9928         Don't include "error.h" or "exitfail.h"; they're no longer needed.
9929
9930         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
9931         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
9932         define.
9933
9934         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
9935         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
9936                             int utc, int nanoseconds);
9937         Background:
9938         date should not have to allocate a megabyte of virtual memory to
9939         handle a format argument like +%1048575T.  When implemented with
9940         strftime, it must allocate such a buffer, use strftime to fill it
9941         in, print it, then free it.
9942         With fprintftime, it simply prints everything and exits.
9943         With no need for memory allocation, that's one fewer way to fail.
9944         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
9945         optional field width, not before, so we accept %9:z, not %:9z.
9946         (my_strftime): Be sure to use L_('x') for literals.
9947
9948         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
9949         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
9950         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
9951         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
9952         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
9953         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
9954         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
9955         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
9956         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
9957         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
9958         * lib/xgethostname.c, lib/xreadlink.c:
9959         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
9960
9961         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
9962         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
9963         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
9964         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
9965         and don't include <sys/file.h>).
9966
9967 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
9968
9969         Sync from coreutils.
9970
9971         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
9972         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
9973         [!LDAV_DONE]: Avoid unused variable warning.
9974
9975 2005-09-21  Bruno Haible  <bruno@clisp.org>
9976
9977         * lib/unicodeio.h (unicode_to_mb): New declaration.
9978
9979 2005-09-20  Derek Price  <derek@ximbiot.com>
9980
9981         * lib/getaddrinfo.c: Don't include <netdb.h> included from
9982         getaddrinfo.h.
9983
9984 2005-09-20  Bruno Haible  <bruno@clisp.org>
9985
9986         * gnulib-tool: Remove trailing slashes from the values specified for
9987         --source-base, --m4-base, --tests-base, --aux-dir.
9988         Suggested by Simon Josefsson <jas@extundo.com>.
9989
9990 2005-09-20  Bruno Haible  <bruno@clisp.org>
9991
9992         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
9993         func_modules_to_filelist, func_import, func_create_testdir): Make all
9994         sorting results locale-independent, so that gnulib-cache.m4 doesn't
9995         change when gnulib-tool is invoked in a different locale.
9996
9997 2005-09-19  Simon Josefsson  <jas@extundo.com>
9998
9999         * m4/socklen.m4: Fix typo.
10000
10001 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10002
10003         Use a consistent style for including <config.h>.
10004         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
10005         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
10006         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
10007         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
10008         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
10009         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
10010         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
10011         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
10012         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
10013         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
10014         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
10015         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
10016         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
10017         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
10018         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
10019         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
10020         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
10021         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
10022         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
10023         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
10024         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
10025         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
10026         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
10027         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
10028         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
10029         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
10030         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
10031         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
10032         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
10033         lib/xstrtoumax.c, lib/yesno.c:
10034         Standardize inclusion of config.h.
10035         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
10036         lib/inttostr.h:  Removed inclusion of config.h from header files.
10037         * lib/inttostr.c:  Adjusted in-tree users.
10038         * lib/timespec.h: Remove superfluous warning to include config.h.
10039         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
10040         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
10041         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
10042         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
10043         config.h with HAVE_CONFIG_H.
10044
10045 2005-09-19  Jim Meyering  <jim@meyering.net>
10046
10047         * modules/pathmax (License): Change to LGPL.
10048
10049 2005-09-19  Derek Price  <derek@ximbiot.com>
10050
10051         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
10052
10053 2005-09-19  Bruno Haible  <bruno@clisp.org>
10054
10055         * gnulib-tool (import): Provide default for --tests-base.
10056
10057 2005-09-19  Bruno Haible  <bruno@clisp.org>
10058
10059         * doc/quote.texi: New file, extracted from gnulib.texi.
10060         * doc/ctime.texi: New file, extracted from gnulib.texi.
10061         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
10062         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
10063         * doc/gnulib.texi: Include them.
10064
10065 2005-09-18  Bruno Haible  <bruno@clisp.org>
10066
10067         Portability fix.
10068         * gnulib-tool (func_readlink): New function.
10069         (func_ln_if_changed): Use it.
10070
10071 2005-09-18  Bruno Haible  <bruno@clisp.org>
10072
10073         * gnulib-tool: Support --with-tests also with --import.
10074         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
10075         (func_import): Use variables $testsbase and $inctests. Emit a
10076         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
10077         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
10078         SUBDIRS += $testsdir.
10079         (func_create_testdir): Update.
10080
10081 2005-09-18  Bruno Haible  <bruno@clisp.org>
10082
10083         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
10084         instead of $dry_run.
10085         (func_cp_if_changed, func_mv_if_changed): Remove functions.
10086         (func_ln_if_changed): Don't handle dry-run here.
10087         (func_import): In dry-run mode, detect more precisely which actions
10088         would be performed, and don't use "...ing" verbs.
10089
10090 2005-09-18  Bruno Haible  <bruno@clisp.org>
10091
10092         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
10093         (func_import): Use join on two temporary files instead of three nested
10094         loops, in order to determine which files are new or old.
10095
10096 2005-09-18  Bruno Haible  <bruno@clisp.org>
10097
10098         * gnulib-tool (func_import): Comment out code that spits out the
10099         new files with --dry-run.
10100
10101 2005-09-18  Bruno Haible  <bruno@clisp.org>
10102
10103         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
10104
10105 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10106
10107         * lib/stat-time.h: New file.
10108         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
10109         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
10110         in a different way.
10111         (timespec_cmp): New function.
10112         * lib/utimecmp.c: Include stat-time.h.
10113         (SYSCALL_RESOLUTION): Depend on whether various struct stat
10114         members exist, not on the obsolescent ST_MTIM_NSEC.
10115         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
10116
10117 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10118
10119         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
10120
10121 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10122
10123         * MODULES.html.sh (File system functions): Add stat-time.
10124         * modules/stat-time: New file.
10125         * modules/timespec (Files): Remove m4/st_mtim.m4; this
10126         is now done in a different way, by the stat-time module.
10127         * modules/utimecmp (Depends-on): Add stat-time.
10128
10129 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10130
10131         * m4/st_mtim.m4: Remove.  Superseded by...
10132         * m4/stat-time.m4: New file.
10133         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
10134         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
10135
10136 2005-09-15  Derek Price  <derek@ximbiot.com>
10137
10138         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
10139
10140 2005-09-15  Derek Price  <derek@ximbiot.com>
10141
10142         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
10143         * lib/regex_internal.c: Ditto, using this...
10144         (__GNUC_PREREQ): ...new macro.
10145         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
10146         using...
10147         (__GNUC_PREREQ): ...this new macro.
10148
10149         * lib/strstr.h: Include string.h. Define strstr as a macro here.
10150
10151 2005-09-15  Derek Price  <derek@ximbiot.com>
10152             Paul Eggert  <eggert@cs.ucla.edu>
10153
10154         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
10155         changes, consolidating in...
10156         * lib/regex_internal.h: ...this file.
10157
10158 2005-09-13  Jim Meyering  <jim@meyering.net>
10159
10160         * lib/canon-host.c: Filter through gnu indent and reword comments
10161         slightly.
10162         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
10163
10164 2005-09-13  Derek Price  <derek@ximbiot.com>
10165
10166         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
10167         failure.
10168         Reported by Jim Meyering  <jim@meyering.net>.
10169
10170 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10171
10172         * lib/base64.c: Typo.
10173         (base64_encode): Put b64str in initialized data section.
10174
10175 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
10176
10177         Merge glibc and coreutils changes into gnulib, plus a few
10178         extra fixes.
10179         * lib/md5.c: Use #error rather than a string.
10180         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
10181         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
10182         (__attribute__): Define to empty for non recent-GCC.
10183         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
10184         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
10185         Renamed from their non-__ counterparts, with new macros replacing
10186         them if not _LIBC.  Add __THROW attribute.
10187         (rol): Remove.
10188         (struct md5_ctx): Align buffer if using GCC.
10189         * lib/sha1.h (struct sha1_ctx): Likewise.
10190         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
10191         The old name was backwards.
10192         (NOTSWAP): Remove; not used.
10193         (rol): New macro, moved here from md5.h.
10194         (sha1_process_block): Remove a FIXME that doesn't make sense.
10195
10196 2005-09-12  Derek Price  <derek@ximbiot.com>
10197
10198         Return usable errors from canon-host.
10199         * lib/canon-host.h: New file.
10200         * lib/canon-host.c (canon_host): Wrap...
10201         (canon_host_r): ...this new function, which now relies exclusively on
10202         getaddrinfo.
10203         (ch_strerror): New function.
10204         (last_cherror): New global.
10205         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
10206         interface.
10207         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
10208         void *.
10209         (freeaddrinfo): Free ai->ai_canonname when set.
10210
10211 2005-09-12  Derek Price  <derek@ximbiot.com>
10212
10213         Make canon-host require getaddrinfo.
10214         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
10215         AC_LIBSOURCE canon-host.h.  Call...
10216         (gl_PREREQ_CANON_HOST): ...this new function, which requires
10217         gl_GETADDRINFO.
10218         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
10219
10220 2005-09-12  Derek Price  <derek@ximbiot.com>
10221
10222         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
10223         LGPL.
10224         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
10225
10226 2005-09-12  Derek Price  <derek@ximbiot.com>
10227
10228         * lib/gai_strerror.c: Include config.h when available.  Include
10229         getaddrinfo.h before other headers to test interface.
10230         Reported by Larry Jones <lawrence.jones@ugs.com>.
10231
10232 2005-09-12  Derek Price  <derek@ximbiot.com>
10233             Paul Eggert  <eggert@cs.ucla.edu>
10234
10235         * modules/glob (Files): Add glob-libc.h.
10236
10237 2005-09-12  Derek Price  <derek@ximbiot.com>
10238             Paul Eggert  <eggert@cs.ucla.edu>
10239
10240         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
10241         glob_.h, glob-libc.h.
10242         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
10243
10244 2005-09-12  Derek Price  <derek@ximbiot.com>
10245             Paul Eggert  <eggert@cs.ucla.edu>
10246
10247         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
10248         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
10249         protecting things that should be done only in gnulib contexts.
10250         * lib/glob_.h: New file, containing only the glob things needed for
10251         gnulib.
10252         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
10253         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
10254         (glob, globfree, glob_pattern_p): Now defined simply in terms of
10255         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
10256         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
10257         and to respect the namespace rules better.
10258
10259 2005-09-08  Simon Josefsson  <jas@extundo.com>
10260
10261         * modules/socklen: New file.
10262
10263 2005-09-08  Simon Josefsson  <jas@extundo.com>
10264
10265         * m4/socklen.m4: New file.
10266
10267 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10268
10269         * modules/utimens (Files): Add m4/utimbuf.m4, since
10270         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
10271         Reported by Sergey Poznyakoff.
10272
10273 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10274
10275         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
10276         definitions, since that's the preferred style in glibc.
10277         Fix a minor spacing issue, and update copyright notice to match
10278         glibc's.
10279
10280 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10281
10282         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
10283
10284 2005-09-06  Simon Josefsson  <jas@extundo.com>
10285
10286         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
10287         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
10288
10289 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10290
10291         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
10292         warning.
10293
10294 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10295
10296         * config/srclist.txt: Add glibc bug 1302.
10297
10298 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
10299
10300         Change bitset word type from unsigned int to unsigned long int,
10301         as this has better performance on typical 64-bit hosts.
10302         Port bitset code to hosts with unusual word sizes.
10303         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
10304         (build_collating_symbol):
10305         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
10306         argument is a bitset.  This is merely a style issue, but it makes
10307         it clearer that an entire array is expected.
10308         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
10309         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
10310         Port to the case where bitset_word is not the same as unsigned int.
10311         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10312         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
10313         Likewise.
10314         * lib/regexec.c (check_dst_limits_calc_pos_1,
10315         check_subexp_matching_top):
10316         (build_trtable, group_nodes_into_DFAstates):
10317         Likewise.
10318         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
10319         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
10320         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
10321         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
10322         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
10323         * lib/regcomp.c (optimize_subexps, lower_subexp):
10324         Work even if bitset_word has holes in its bitwise representation.
10325         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
10326         * lib/regexec.c (check_dst_limits_calc_pos_1,
10327         check_subexp_matching_top):
10328         Likewise.
10329         * lib/regex_internal.c (re_string_reconstruct):
10330         Don't assume UCHAR_MAX == 255.
10331         * lib/regex_internal.h (bitset_set_all): Likewise.
10332         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
10333         All uses changed.
10334         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
10335         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
10336         All uses changed.
10337         (BITSET_WORD_MAX): New macro.
10338         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
10339         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
10340         (bitset_empty, bitset_copy):
10341         Prefer sizeof (bitset) to multiplying it out ourselves.
10342         (bitset_not_merge): Remove; unused.
10343         (bitset_contain): Return bool, not unsigned int with one bit on.
10344         All callers changed.
10345         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
10346         alignment than re_node_set; do this by defining a new internal
10347         type struct dests_alloc and using it to allocate memory.
10348
10349 2005-09-05  Bruno Haible  <bruno@clisp.org>
10350
10351         * gnulib-tool (func_import): Fix comparison in handling of symbolic
10352         links.
10353
10354 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
10355
10356         * modules/size_max (Makefile.am): Add size_max.h
10357
10358 2005-09-04  Derek Price  <derek@ximbiot.com>
10359
10360         * gnulib-tool (func_import): Fix reversed $symbolic logic.
10361
10362 2005-09-03  Simon Josefsson  <jas@extundo.com>
10363
10364         * gnulib-tool: Fix typo.
10365
10366 2005-09-03  Simon Josefsson  <jas@extundo.com>
10367
10368         * config/srclist.txt: Add glibc bug 1293.
10369
10370 2005-09-03  Derek Price  <derek@ximbiot.com>
10371
10372         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
10373         From Larry Jones <lawrence.jones@ugs.com>.
10374
10375 2005-09-02  Simon Josefsson  <jas@extundo.com>
10376
10377         * modules/socklen: New file.
10378
10379 2005-09-02  Simon Josefsson  <jas@extundo.com>
10380
10381         * modules/havelib: New module.
10382
10383         * modules/gettext, modules/iconv, modules/lock, modules/readline:
10384         Use havelib.
10385
10386 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10387
10388         Check for arithmetic overflow when calculating sizes, to prevent
10389         some buffer-overflow issues.  These patches are conservative, in the
10390         sense that when I couldn't determine whether an overflow was possible,
10391         I inserted a run-time check.
10392         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
10393         macros.
10394         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
10395         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
10396         (re_xnrealloc, re_x2nrealloc): New inline functions.
10397         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
10398         parse_bracket_exp):
10399         (build_equiv_class, build_charclass): Check for arithmetic overflow
10400         in size expression calculations.
10401         * lib/regex_internal.c (re_string_realloc_buffers):
10402         (build_wcs_upper_buffer, re_node_set_add_intersect):
10403         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
10404         (re_dfa_add_node, register_state): Likewise.
10405         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
10406         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
10407         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
10408         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
10409
10410 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10411
10412         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
10413         m4/ulonglong.m4.  Problem reported by Martin Lambers.
10414
10415 2005-09-02  Bruno Haible  <bruno@clisp.org>
10416
10417         Support for lib vs. lib64 distinction on biarch platforms.
10418         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
10419         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
10420         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
10421
10422 2005-09-02  Bruno Haible  <bruno@clisp.org>
10423
10424         * gnulib-tool (import): In the other first-use case, provide defaults
10425         as well.
10426
10427 2005-09-02  Bruno Haible  <bruno@clisp.org>
10428
10429         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
10430         patches not yet found in the latest gettext release.
10431
10432 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10433
10434         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
10435         to avoid a collision with bits/local_lim.h in glibc.
10436         All uses changed.  Problem reported by Dmitry V. Levin in
10437         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
10438
10439         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
10440         bugs in int versus size_t comparisons.
10441         (re_string_context_at): Fix bug where the code assumed that
10442         Idx is signed.
10443
10444         Use bool where appropriate.
10445         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
10446         All callers changed.
10447         (calc_eclosure_iter): Likewise, for ROOT arg.
10448         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
10449         (build_charclass_op): Likewise, for NON_MATCH arg.
10450         * lib/regex_internal.c (re_string_allocate, re_string_construct):
10451         (re_string_construct_common): Likewise, for ICASE arg.
10452         * lib/regexec.c (re_search_2_stub, re_search_stub):
10453         Likewise, for RET_LEN arg.
10454         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
10455         (set_regs): Likewise, for FL_BACKTRACK arg.
10456         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
10457         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
10458         (calc_eclosure_iter, parse_bracket_exp):
10459         Use bool for internal variables that are booleans.
10460         * lib/regexec.c (re_search_internal, check_matching,
10461         proceed_next_node):
10462         (set_regs, build_sifted_states, sift_states_bkref):
10463         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
10464         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
10465         (find_collation_sequence_value):
10466         Likewise.
10467         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
10468         (re_node_set_compare):
10469         Return bool, not int. All callers changed.
10470         * lib/regexec.c (check_halt_node_context, check_dst_limits):
10471         (build_trtable, check_node_accept): Likewise.
10472         * lib/regex_internal.h: Include stdbool.h.
10473
10474         Fix bugs uncovered when converting to bool.
10475         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
10476         failure instead of charging ahead blindly.
10477         * lib/regex_internal.c (register_state): Likewise.
10478         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
10479         for freeing internal storage.
10480         (group_nodes_into_DFA_states): Use unsigned int, not int, for
10481         bitset pieces used as boolean, to avoid undefined behavior
10482         on hosts that do int overflow checking.
10483
10484 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10485
10486         * config/srclist.txt: Add glibc bugs 1285-1287.
10487
10488 2005-09-01  Jim Meyering  <jim@meyering.net>
10489
10490         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
10491         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
10492         Require gl_STAT_MACROS, too.
10493
10494 2005-09-01  Bruno Haible  <bruno@clisp.org>
10495
10496         * gnulib-tool (import): In the first-use case, provide defaults.
10497
10498 2005-09-01  Bruno Haible  <bruno@clisp.org>
10499
10500         * gnulib-tool (func_import): Remove the .tmp files.
10501
10502 2005-09-01  Bruno Haible  <bruno@clisp.org>
10503
10504         * gnulib-tool (func_import): Fix handling of symbolic links.
10505
10506 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10507
10508         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
10509         old glibc regex code mishandles strings longer than 2**31 bytes.
10510         This patch fixes this when the regex code is used in gnulib
10511         (i.e., outside glibc).
10512
10513         This patch should not affect the use of the regex code inside
10514         glibc.  No doubt this problem also needs to be handled for glibc
10515         as well, but the result will be an incompatible change to the
10516         glibc ABI, and the old ABI will have to be supported too.  That
10517         can be the the subject for another patch.
10518
10519         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
10520         governing whether the rest of this patch is active.  By default,
10521         the macro is disabled and the patch has no effect.
10522         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
10523         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
10524         (struct re_pattern_buffer, re_search, re_search_2, re_match):
10525         (re_match_2, re_set_registers): Use the new types.
10526         * lib/regex_internal.h (Idx, re_hashval_t): New types.
10527         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
10528         New macros.
10529         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
10530         (re_string_context_at, bin_tree_t, re_dfastate_t):
10531         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
10532         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
10533         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
10534         (re_string_char_size_at, re_string_wchar_at):
10535         (re_string_elem_size_at):
10536         Use the new types and macros to port to 64-bit hosts.
10537         Use unsigned types for internal values, so that the code
10538         mostly works even for arrays larger than SSIZE_MAX.
10539         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
10540         (search_duplicated_node, calc_eclosure_iter, fetch_number):
10541         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
10542         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
10543         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
10544         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
10545         (calc_inveclosure, parse_dup_op, build_range_exp):
10546         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
10547         (fetch_number, create_token_tree, mark_opt_subexp):
10548         Likewise.
10549         * lib/regex_internal.c (re_string_construct_common,
10550         create_ci_newstate):
10551         (create_cd_newstate, re_string_allocate, re_string_construct):
10552         (re_string_realloc_buffers, build_wcs_upper_buffer):
10553         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
10554         (re_string_reconstruct, re_string_peek_byte_case):
10555         (re_string_fetch_byte_case, re_string_context_at):
10556         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
10557         (re_node_set_init_copy, re_node_set_add_intersect):
10558         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10559         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10560         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
10561         (re_acquire_state, re_acquire_state_context, register_state):
10562         Likewise.
10563         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
10564         search_cur_bkref_entry):
10565         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
10566         (re_search_internal, re_search_2_stub, re_search_stub)
10567         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
10568         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
10569         (update_cur_sifted_state, check_dst_limits):
10570         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10571         (check_subexp_limits, sift_states_bkref, merge_state_array):
10572         (check_subexp_matching_top, get_subexp, get_subexp_sub):
10573         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
10574         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
10575         (expand_bkref_cache, check_node_accept_bytes):
10576         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
10577         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
10578         (acquire_init_state_context, check_halt_node_context):
10579         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
10580         (sift_states_backward, clean_state_log_if_needed):
10581         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
10582         (find_recover_state, transit_state_sb, transit_state_mb):
10583         (transit_state_bkref, build_trtable, match_ctx_clean):
10584         Likewise.
10585         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
10586         to work around an assumption that REG_MISSING is negative.
10587
10588         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
10589         (seek_collating_symbol_entry) [defined _LIBC]:
10590         (lookup_collation_sequence_value) [defined _LIBC]:
10591         (build_range_exp, build_collating_symbol) [defined _LIBC]:
10592         Use prototypes rather than old-style function definitions.
10593         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
10594         (transit_state_sb) [0]:
10595         (find_collation_sequence_value) [defined _LIBC]: Likewise.
10596
10597         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
10598         rm_eo.
10599
10600         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
10601         (optimize_subexps, lower_subexp):
10602         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
10603         since the signed shift might overflow.  Use 1u<<31 instead.
10604         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10605         Likewise.
10606         * lib/regexec.c (check_dst_limits_calc_pos_1,
10607         check_subexp_matching_top): Likewise.
10608
10609         * lib/regcomp.c (optimize_subexps, lower_subexp):
10610         Use CHAR_BIT rather than 8, for clarity.
10611         * lib/regexec.c (check_dst_limits_calc_pos_1):
10612         (check_subexp_matching_top): Likewise.
10613         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
10614         have to worry about portability issues when shifting it left.
10615         Remove no-longer-needed test for table_size > 0.
10616         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
10617         in a word, as the resulting behavior is undefined.
10618         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
10619         in one case, a <= should have been an <, and in another case the
10620         whole test was missing.
10621         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
10622         the standard name CHAR_BIT.
10623         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
10624         this is not true on one's complement and signed-magnitude hosts.
10625
10626         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
10627         next_last_offset.
10628         (struct re_dfa_t): Remove unused member states_alloc.
10629         * lib/regcomp.c (init_dfa): Don't initialize unused members.
10630
10631 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10632
10633         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
10634         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
10635         and large-file glibc and in 32-bit large-file Solaris.
10636
10637 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10638
10639         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
10640         lengths fit in regoff_t; this isn't true if regoff_t is the same
10641         width as size_t.
10642         * lib/regex.c (re_search_internal): 5th arg is LAST_START
10643         (= START + RANGE) instead of RANGE.  This avoids overflow
10644         problems when regoff_t is the same width as size_t.
10645         All callers changed.
10646         (re_search_2_stub): Check for overflow when adding the
10647         sizes of the two strings.
10648         (re_search_stub): Check for overflow when adding START
10649         to RANGE; if it occurs, substitute the extreme value.
10650
10651 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10652
10653         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
10654
10655 2005-08-31  Jim Meyering  <jim@meyering.net>
10656
10657         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
10658         a pointer-to-const.
10659         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
10660         (register_state): Likewise.
10661         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
10662         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10663         (group_nodes_into_DFAstates): Likewise.
10664
10665 2005-08-31  Jim Meyering  <jim@meyering.net>
10666
10667         * check-module: Add a FIXME comment.
10668
10669 2005-08-31  Eric Blake  <ebb9@byu.net>
10670
10671         * modules/unistd-safer (Files): Add unistd--.h.
10672         * modules/stdio-safer (Files): Add stdio--.h.
10673
10674 2005-08-31  Derek Price  <derek@ximbiot.com>
10675
10676         * lib/getdelim.c (getdelim): Return EOF on EOF.
10677         Reported by Larry Jones <lawrence.jones@ugs.com>.
10678
10679 2005-08-31  Bruno Haible  <bruno@clisp.org>
10680
10681         Avoid unnecessary diffs in the generated lib/Makefile.am.
10682         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
10683         the generated files.
10684         (func_import): Don't set cmd.
10685
10686 2005-08-31  Bruno Haible  <bruno@clisp.org>
10687
10688         * lib/strstr.c: Include <stddef.h>, for NULL.
10689         * lib/strcasestr.c: Likewise.
10690         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10691
10692 2005-08-31  Bruno Haible  <bruno@clisp.org>
10693
10694         * gnulib-tool: New option --macro-prefix.
10695         (func_import): Use macro_prefix.
10696         (import): Handle option --macro-prefix.
10697
10698 2005-08-31  Bruno Haible  <bruno@clisp.org>
10699
10700         * gnulib-tool (import): Rename most ac_* variables to cached_*.
10701         Also use new variables cached_lgpl, cached_libtool.
10702
10703 2005-08-31  Bruno Haible  <bruno@clisp.org>
10704
10705         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
10706         always instantiating them.
10707
10708 2005-08-31  Bruno Haible  <bruno@clisp.org>
10709
10710         * gnulib-tool (func_import): Read the previous cached settings
10711         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
10712         earlier added by gnulib but are now dropped. Warn when a gnulib file
10713         overwrites a non-gnulib file.
10714
10715 2005-08-31  Bruno Haible  <bruno@clisp.org>
10716
10717         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
10718         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
10719         projects that don't keep autogenerated files in CVS. Put into
10720         actioncmd only the specified modules, not the transitive closure.
10721
10722 2005-08-31  Bruno Haible  <bruno@clisp.org>
10723
10724         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
10725         Create directories that shall be filled.
10726         (import): Don't look for gl_* macros in configure.ac. Recurse across
10727         all directories containing a gnulib-cache.m4 files, if meaningful.
10728
10729 2005-08-31  Bruno Haible  <bruno@clisp.org>
10730
10731         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
10732         (import): Set seen_libtool when we see gl_LIBTOOL.
10733
10734 2005-08-31  Bruno Haible  <bruno@clisp.org>
10735
10736         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
10737         declaration macro definitions from generated gnulib.m4.
10738
10739 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
10740
10741         * lib/iconvme.h: Add prototype for iconv_alloc.
10742
10743 2005-08-29  Simon Josefsson  <jas@extundo.com>
10744
10745         * lib/iconvme.c: Fix errno.
10746
10747 2005-08-29  Bruno Haible  <bruno@clisp.org>
10748
10749         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
10750         that it works when the directory contains spaces.
10751
10752 2005-08-29  Bruno Haible  <bruno@clisp.org>
10753
10754         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
10755
10756 2005-08-29  Bruno Haible  <bruno@clisp.org>
10757
10758         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
10759         Emit more advice.
10760
10761 2005-08-29  Bruno Haible  <bruno@clisp.org>
10762         and Stepan Kasal  <kasal@ucw.cz>
10763
10764         * check-module: If more parameters are given, check each of them
10765         separately; add more exceptions, as noted by Jim Meyering.
10766         (check_module): New procedure.
10767         (%exempt_header): Now contains all exceptions.
10768
10769 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
10770
10771         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
10772
10773 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
10774
10775         * lib/iconvme.c: Split iconv_string into iconv_alloc.
10776
10777 2005-08-28  Bruno Haible  <bruno@clisp.org>
10778
10779         * m4/gnulib-tool.m4: New file.
10780
10781 2005-08-27  Jim Meyering  <jim@meyering.net>
10782
10783         * modules/unistd-safer (Files): Add pipe-safer.c.
10784         * modules/fcntl-safer (Files): Add creat-safer.c.
10785
10786 2005-08-27  Jim Meyering  <jim@meyering.net>
10787
10788         * m4/stdlib-safer.m4: New file.  From coreutils.
10789         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
10790         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
10791         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
10792         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
10793         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
10794
10795 2005-08-27  Jim Meyering  <jim@meyering.net>
10796
10797         * lib/fopen-safer.c: Merge minor changes from coreutils.
10798         * lib/dup-safer.c: Likewise.
10799         * lib/fd-safer.c: Likewise.
10800
10801         Merge from coreutils.
10802         * lib/stdio--.h: New file.
10803         * lib/stdlib--.h: New file.
10804         * lib/mkstemp-safer.c: New file.
10805
10806         GNU tar needs these.
10807         * lib/pipe-safer.c: New file.
10808         * lib/creat-safer.c: New file.
10809         * lib/fcntl--.h (creat): Define to creat_safer.
10810         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
10811         * lib/unistd--.h (pipe): Define to pipe_safer.
10812         * lib/unistd-safer.h: Declare pipe_safer.
10813
10814 2005-08-26  Simon Josefsson  <jas@extundo.com>
10815
10816         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
10817         Haible <bruno@clisp.org>.
10818
10819 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
10820
10821         * lib/regex_internal.h: Remove all references to
10822         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
10823         or better.
10824         (bitset_not, bitset_merge, bitset_not_merge):
10825         (bitset_mask, re_string_allocate, re_string_construct):
10826         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
10827         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
10828         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
10829         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
10830         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10831         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10832         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
10833         (re_acquire_state_context):
10834         Remove unnecessary forward decls.
10835         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
10836         Put __attribute at function definition,
10837         now that the function decl has been removed.
10838         * lib/regex_internal.c (re_string_peek_byte_case):
10839         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
10840         Likewise.
10841
10842 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
10843
10844         * m4/regex.m4: Add AC_PREREQ(2.50).
10845         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
10846
10847 2005-08-25  Simon Josefsson  <jas@extundo.com>
10848
10849         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
10850         __fsetlocking.
10851
10852 2005-08-25  Simon Josefsson  <jas@extundo.com>
10853
10854         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
10855         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
10856         GLIBC specific code.
10857
10858 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10859
10860         Make regex safe for g++.  This fixes one real bug (an "err"
10861         that should have been "*err").  g++ problem reported by
10862         Sam Steingold.
10863         * lib/regex_internal.h (re_calloc): New macro, consistent with
10864         re_malloc etc.  All callers of calloc changed to use re_calloc.
10865         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
10866         not int.  All callers changed.
10867         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
10868         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
10869         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
10870         (find_recover_state): Change "err" to "*err"; this fixes what
10871         appears to be a real bug.
10872         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
10873         versus int.
10874
10875 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10876
10877         * modules/regex (Depends-on): Add malloc, since the code
10878         assumes that !malloc(0) means failure.
10879
10880 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10881
10882         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
10883
10884         alloca modernization/simplification for regex.
10885         * lib/regex.c: Remove portability cruft for alloca.  This no longer
10886         needs to be at the start of the file, and can be moved into
10887         regex_internal.h and simplified.
10888         * lib/regex_internal.h: Include <alloca.h>.
10889         (__libc_use_alloca) [!defined _LIBC]: New macro.
10890         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
10891         now works outside glibc.
10892
10893 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10894
10895         * config/srclist.txt: Add glibc bugs 1241, 1245.
10896
10897 2005-08-25  Jim Meyering  <jim@meyering.net>
10898
10899         * lib/open-safer.c: Include <config.h>.
10900         Otherwise, we'd lose LARGEFILE support in any file using
10901         e.g. "fcntl--.h"
10902
10903 2005-08-25  Bruno Haible  <bruno@clisp.org>
10904
10905         * m4/minmax.m4: Require autoconf 2.52.
10906         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
10907         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
10908         alternatives of translit over the alphabet.
10909         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
10910
10911 2005-08-24  Simon Josefsson  <jas@extundo.com>
10912
10913         * tests/test-getpass.c: New file.
10914
10915 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10916
10917         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
10918         for GNU regex features.
10919
10920 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10921
10922         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
10923         * lib/regex.h (regerror): Likewise.
10924
10925         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
10926         requires this.  (The code never needed it.)
10927
10928         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
10929         All uses of recently-renamed identifiers changed to use the new,
10930         POSIX-compliant names.  The code will build and run just fine
10931         without these changes, but it's better to eat our own dog food
10932         and use the standard-conforming names.
10933
10934         * lib/regex.h: Fix a multitude of POSIX name space violations.
10935         These changes have an effect only for programs that define
10936         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
10937         do not change anything for programs compiled in the normal way.
10938         Also, there is no effect on the ABI.
10939
10940         (_REGEX_SOURCE): New macro.
10941         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
10942         defined and _GNU_SOURCE is not; this fixes a name space violation.
10943
10944         Rename the following macros to obey POSIX requirements.
10945         The old names are still visible as macros if _REGEX_SOURCE is defined.
10946         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
10947         RE_BACKSLASH_ESCAPE_IN_LISTS.
10948         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
10949         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
10950         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
10951         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
10952         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
10953         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
10954         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
10955         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
10956         (REG_INTERVALS): renamed from RE_INTERVALS.
10957         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
10958         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
10959         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
10960         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
10961         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
10962         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
10963         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
10964         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
10965         RE_UNMATCHED_RIGHT_PAREN_ORD.
10966         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
10967         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
10968         (REG_DEBUG): renamed from RE_DEBUG.
10969         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
10970         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
10971         unusual, since we can't clash with the POSIX REG_ICASE.
10972         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
10973         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
10974         (REG_NO_SUB): renamed from RE_NO_SUB.
10975         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
10976         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
10977         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
10978         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
10979         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
10980         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
10981         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
10982         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
10983         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
10984         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
10985         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
10986         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
10987         RE_SYNTAX_POSIX_MINIMAL_BASIC.
10988         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
10989         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
10990         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
10991         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
10992         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
10993         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
10994         (REG_FIXED): Renamed from REGS_FIXED.
10995         (REG_NREGS): Renamed from RE_NREGS.
10996
10997         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
10998         of other REG_* macros, since POSIX says the user is allowed to
10999         #undef these macros selectively.
11000
11001         (reg_errcode_t): Update comment stating what other tables need
11002         to be consistent.
11003
11004         Rename the following enum values to obey POSIX requirements.
11005         The old names are still visible as macros.
11006         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
11007         is not defined, since GNU is supposed to be a superset of POSIX as
11008         much as possible, and since we want reg_errcode_t to be a signed
11009         type for implementation consistency.
11010         (_REG_NOERROR): Renamed from REG_NOERROR.
11011         (_REG_NOMATCH): Renamed from REG_NOMATCH.
11012         (_REG_BADPAT): Renamed from REG_BADPAT.
11013         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
11014         (_REG_ECTYPE): Renamed from REG_ECTYPE.
11015         (_REG_EESCAPE): Renamed from REG_EESCAPE.
11016         (_REG_ESUBREG): Renamed from REG_ESUBREG.
11017         (_REG_EBRACK): Renamed from REG_EBRACK.
11018         (_REG_EPAREN): Renamed from REG_EPAREN.
11019         (_REG_EBRACE): Renamed from REG_EBRACE.
11020         (_REG_BADBR): Renamed from REG_BADBR.
11021         (_REG_ERANGE): Renamed from REG_ERANGE.
11022         (_REG_ESPACE): Renamed from REG_ESPACE.
11023         (_REG_BADRPT): Renamed from REG_BADRPT.
11024         (_REG_EEND): Renamed from REG_EEND.
11025         (_REG_ESIZE): Renamed from REG_ESIZE.
11026         (_REG_ERPAREN): Renamed from REG_ERPAREN.
11027         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
11028         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
11029         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
11030         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
11031
11032         (_REG_RE_NAME, _REG_RM_NAME): New macros.
11033         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
11034         changed.  But support the old name if the new one is not defined
11035         and if _REGEX_SOURCE.
11036
11037         Change the following member names in struct re_pattern_buffer.
11038         The old names are still supported if !_REGEX_SOURCE.
11039         The new names are always supported, regardless of _REGEX_SOURCE.
11040         (re_buffer): Renamed from buffer.
11041         (re_allocated): Renamed from allocated.
11042         (re_used): Renamed from used.
11043         (re_syntax): Renamed from syntax.
11044         (re_fastmap): Renamed from fastmap.
11045         (re_translate): Renamed from translate.
11046         (re_can_be_null): Renamed from can_be_null.
11047         (re_regs_allocated): Renamed from regs_allocated.
11048         (re_fastmap_accurate): Renamed from fastmap_accurate.
11049         (re_no_sub): Renamed from no_sub.
11050         (re_not_bol): Renamed from not_bol.
11051         (re_not_eol): Renamed from not_eol.
11052         (re_newline_anchor): Renamed from newline_anchor.
11053
11054         Change the following member names in struct re_registers.
11055         The old names are still supported if !_REGEX_SOURCE.
11056         The new names are always supported, regardless of _REGEX_SOURCE.
11057         (rm_num_regs): Renamed from num_regs.
11058         (rm_start): Renamed from start.
11059         (rm_end): Renamed from end.
11060
11061         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
11062         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
11063         Prepend __ to parameter names.
11064
11065         Undo yesterday's changes.
11066
11067 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11068
11069         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
11070         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
11071         lib/regex.c.
11072
11073 2005-08-24  Jim Meyering  <jim@meyering.net>
11074
11075         Sync from coreutils.
11076         * m4/fcntl-safer.m4: New file.
11077
11078         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
11079         and object files for this module.
11080
11081 2005-08-24  Jim Meyering  <jim@meyering.net>
11082
11083         Sync from coreutils.
11084         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
11085
11086 2005-08-24  Jim Meyering  <jim@meyering.net>
11087
11088         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
11089         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
11090
11091 2005-08-24  Jim Meyering  <jim@meyering.net>
11092
11093         * modules/fcntl-safer: New module.
11094         * modules/fts (Depends-on): Add fcntl-safer.
11095         * MODULES.html.sh (File descriptor based Input/Output):
11096         Add fcntl-safer.
11097
11098 2005-08-24  Bruno Haible  <bruno@clisp.org>
11099
11100         Support for unit test modules.
11101         * modules/README: Mention tests modules.
11102         * modules/TEMPLATE-TESTS: New file.
11103         * gnulib-tool: New options --extract-tests-module, --with-tests and
11104         --tests-base (unused for the moment).
11105         (testsbase, inctests): New variables.
11106         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
11107         (func_verify_module): Exclude TEMPLATE-TESTS.
11108         (func_verify_nontests_module, func_verify_tests_module): New functions.
11109         (func_get_dependencies): Add implicit dependency for tests modules.
11110         (func_get_tests_module): New function.
11111         (func_modules_transitive_closure): When --with-tests was specified,
11112         include the unit tests as well, unless explicitly avoided.
11113         (func_emit_lib_Makefile_am): Ignore the tests modules here.
11114         (func_emit_tests_Makefile_am): New function.
11115         (func_create_testdir): When --with-tests was specified, emit a
11116         tests/ directory.
11117         * MODULES.html.sh (Future developments): Update.
11118
11119 2005-08-24  Bruno Haible  <bruno@clisp.org>
11120
11121         * modules/tls-tests: New file.
11122         * tests/test-tls.c: New file, from GNU gettext.
11123
11124 2005-08-24  Bruno Haible  <bruno@clisp.org>
11125
11126         * modules/lock-tests: New file.
11127         * tests/test-lock.c: New file, from GNU gettext.
11128
11129 2005-08-24  Bruno Haible  <bruno@clisp.org>
11130
11131         * lib/lock.h: Add multiple inclusion guard.
11132         * lib/tls.h: Add multiple inclusion guard.
11133
11134 2005-08-24  Bruno Haible  <bruno@clisp.org>
11135
11136         * gnulib-tool: Add support for the --aux-dir option to
11137         --create-testdir, --create-megatestdir, --test, --megatest.
11138         (func_create_testdir, func_create_megatestdir): Optionally emit a
11139         AC_CONFIG_AUX_DIR directive.
11140         (create-testdir, create-megatestdir, test, megatest): Provide a
11141         default value for $auxdir.
11142
11143 2005-08-24  Bruno Haible  <bruno@clisp.org>
11144
11145         * gnulib-tool (import): Use compound statement instead of subshell
11146         where possible.
11147
11148 2005-08-24  Bruno Haible  <bruno@clisp.org>
11149
11150         * gnulib-tool (import): Change --aux-dir default to "build-aux".
11151
11152 2005-08-24  Bruno Haible  <bruno@clisp.org>
11153
11154         * gnulib-tool (func_version): Update.
11155
11156 2005-08-24  Bruno Haible  <bruno@clisp.org>
11157
11158         * gnulib-tool (func_import, func_create_testdir,
11159         func_create_megatestdir): Quote all autoconf macro arguments.
11160
11161 2005-08-24  Bruno Haible  <bruno@clisp.org>
11162
11163         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
11164         option --force, because --force causes the aclocal.m4 of each
11165         subdirectory to be newer than the corresponding config.h.in.
11166
11167 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11168
11169         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
11170         All contents moved to gl_REGEX.
11171         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
11172         assume that it does.
11173
11174 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11175
11176         * lib/regex.h (REG_NOSYS)
11177         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
11178         Define, since POSIX requires it as of 2001.
11179         (_REG_ENOSYS)
11180         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
11181         New private symbol, used to keep the enum signed in all cases.
11182         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
11183         Youngman in
11184         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
11185
11186         * lib/regex_internal.c (re_string_skip_chars, register_state):
11187         (calc_state_hash):
11188         Remove forward decls; no longer needed now that we use prototypes.
11189         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
11190         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
11191         (clean_state_log_if_needed): Likewise.
11192
11193 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11194
11195         * config/srclist.txt: Add glibc bugs 1231-1233.
11196
11197 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11198
11199         Fix problems reported by Sam Steingold in
11200         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
11201         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
11202         assumed that reg_errcode_t is a signed type, which is not
11203         necessarily true if _XOPEN_SOURCE is not defined.
11204         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
11205         since some compilers warn about it otherwise.
11206
11207 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11208
11209         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
11210         (init_word_char, create_initial_state, duplicate_node_closure):
11211         (fetch_token, peek_token_bracket, build_range_exp):
11212         (build_collating_symbol): Remove forward decls; no longer needed
11213         now that we use prototypes.
11214
11215         * lib/regcomp.c:
11216         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
11217         (re_compile_fastmap_iter, regcomp, regerror, regfree):
11218         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
11219         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
11220         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
11221         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
11222         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
11223         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
11224         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
11225         (build_range_exp, build_collating_symbol, parse_bracket_exp):
11226         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
11227         (build_charclass, build_charclass_op, fetch_number, create_tree):
11228         (create_token_tree, mark_opt_subexp, duplicate_tree):
11229         Use prototypes rather than old-style definitions.
11230
11231         * lib/regex_internal.c:
11232         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
11233         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
11234         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11235         (re_string_reconstruct, re_string_peek_byte_case):
11236         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
11237         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11238         (re_node_set_init_copy, re_node_set_add_intersect):
11239         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11240         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11241         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11242         (re_acquire_state, re_acquire_state_context, register_state):
11243         (create_ci_newstate, create_cd_newstate, free_state):
11244         Likewise.
11245         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
11246         re_search_2):
11247         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
11248         (re_search_internal, prune_impossible_nodes):
11249         (acquire_init_state_context, check_matching, static):
11250         (check_halt_node_context, check_halt_state_context, proceed_next_node):
11251         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
11252         (update_regs, sift_states_backward, build_sifted_states):
11253         (clean_state_log_if_needed, merge_state_array):
11254         (update_cur_sifted_state, add_epsilon_src_nodes):
11255         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
11256         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
11257         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
11258         (find_recover_state, check_subexp_matching_top, transit_state_mb):
11259         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
11260         (check_arrival, check_arrival_add_next_nodes):
11261         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11262         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11263         (check_node_accept_bytes, check_node_accept, extend_buffers):
11264         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
11265         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
11266         (sift_ctx_init):
11267         Likewise.
11268
11269         * lib/regex_internal.h:
11270         (re_string_allocate, re_string_construct, re_string_reconstruct):
11271         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
11272         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
11273         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
11274         (re_string_context_at, re_string_peek_byte_case):
11275         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
11276         is defined, since we now use prototypes always.
11277
11278         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
11279         C89 or better.  All uses removed.
11280
11281 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11282
11283         * config/srclist.txt: Add glibc bugs 1220-1227.
11284
11285 2005-08-20  Jim Meyering  <jim@meyering.net>
11286
11287         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
11288         of unused local, dfa.
11289
11290 2005-08-20  Bruno Haible  <bruno@clisp.org>
11291
11292         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
11293
11294 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11295
11296         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
11297         (re_node_set_insert_last, re_dfa_add_node):
11298         Rename local variables to avoid GCC shadowing warnings.
11299
11300 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11301
11302         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
11303         [defined lint]: Suppress bogus uninitialized-variable warnings.
11304
11305         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
11306         and let the caller return REG_ESPACE if out of space.  This
11307         removes an uninitialied-variable warning with GCC 4.0.1, and also
11308         avoids taking the address of a local variable.  All callers
11309         changed.
11310
11311 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11312
11313         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
11314         $LIBCSRC/posix/regexec.c.
11315         Add glibc bug 1217 for regcomp.c.
11316
11317 2005-08-19  Jim Meyering  <jim@meyering.net>
11318
11319         * lib/regexec.c (proceed_next_node): Redo local variables to
11320         avoid GCC shadowing warnings.
11321
11322 2005-08-18  Bruno Haible  <bruno@clisp.org>
11323
11324         * lib/strstr.c (strstr): Fix return value in multibyte case.
11325         * lib/strcasestr.c (strcasestr): Likewise.
11326
11327 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11328
11329         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
11330
11331 2005-08-17  Jim Meyering  <jim@meyering.net>
11332
11333         Make the %s format (seconds since the epoch) work for a negative
11334         number and when used with a zero-padded field width, e.g. %015s.
11335
11336         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
11337         label so that it precedes the code to set `digits'.  Otherwise,
11338         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
11339         print `00-22'.  Now, it prints `-0022', as it should.
11340
11341 2005-08-17  Bruno Haible  <bruno@clisp.org>
11342
11343         * modules/strstr (Files): Add m4/mbrtowc.m4.
11344         (Depends-on): Add mbuiter.
11345
11346 2005-08-17  Bruno Haible  <bruno@clisp.org>
11347
11348         * modules/strcasestr: New file.
11349         * MODULES.html.sh (String handling, based on ANSI C 89): Add
11350         strcasestr.
11351
11352 2005-08-17  Bruno Haible  <bruno@clisp.org>
11353
11354         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
11355
11356 2005-08-17  Bruno Haible  <bruno@clisp.org>
11357
11358         * modules/mbuiter: New file.
11359         * MODULES.html.sh (Extended multibyte and wide character utilities):
11360         Add mbuiter.
11361
11362 2005-08-17  Bruno Haible  <bruno@clisp.org>
11363
11364         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
11365         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
11366
11367 2005-08-17  Bruno Haible  <bruno@clisp.org>
11368
11369         * m4/strcasestr.m4: New file.
11370
11371 2005-08-17  Bruno Haible  <bruno@clisp.org>
11372
11373         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
11374         * lib/strstr.c: Completely rewritten, with multibyte locale support.
11375
11376 2005-08-17  Bruno Haible  <bruno@clisp.org>
11377
11378         * lib/strcasestr.h: New file.
11379         * lib/strcasestr.c: New file.
11380
11381 2005-08-17  Bruno Haible  <bruno@clisp.org>
11382
11383         * lib/strcasecmp.c: Use mbuiter.h.
11384
11385 2005-08-17  Bruno Haible  <bruno@clisp.org>
11386
11387         * lib/mbuiter.h: New file.
11388
11389 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11390
11391         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
11392         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
11393         and gl_GETOPT are both invoked via different paths (as happens
11394         with GNU tar CVS because it uses both argp and getopt), the former
11395         wins.
11396
11397 2005-08-16  Bruno Haible  <bruno@clisp.org>
11398
11399         * modules/tls: New file.
11400         * MODULES.html.sh (Multithreading): Add tls.
11401
11402 2005-08-16  Bruno Haible  <bruno@clisp.org>
11403
11404         * modules/strnlen1: New file.
11405         * MODULES.html.sh (String handling): Add strnlen1.
11406
11407 2005-08-16  Bruno Haible  <bruno@clisp.org>
11408
11409         * modules/strcase (Files): Add m4/mbrtowc.m4.
11410         (Depends-on): Add strnlen1, mbchar.
11411
11412 2005-08-16  Bruno Haible  <bruno@clisp.org>
11413
11414         * modules/mbiter: New file.
11415         * MODULES.html.sh (Extended multibyte and wide character utilities):
11416         Add mbiter.
11417
11418 2005-08-16  Bruno Haible  <bruno@clisp.org>
11419
11420         * modules/mbfile: New file.
11421         * MODULES.html.sh (Extended multibyte and wide character utilities):
11422         Add mbfile.
11423
11424 2005-08-16  Bruno Haible  <bruno@clisp.org>
11425
11426         * modules/mbchar: New file.
11427         * MODULES.html.sh (Extended multibyte and wide character utilities):
11428         New section.
11429
11430 2005-08-16  Bruno Haible  <bruno@clisp.org>
11431
11432         * m4/tls.m4: New file, from GNU gettext.
11433
11434 2005-08-16  Bruno Haible  <bruno@clisp.org>
11435
11436         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
11437         always.
11438         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
11439
11440 2005-08-16  Bruno Haible  <bruno@clisp.org>
11441
11442         * m4/mbiter.m4: New file.
11443
11444 2005-08-16  Bruno Haible  <bruno@clisp.org>
11445
11446         * m4/mbfile.m4: New file.
11447
11448 2005-08-16  Bruno Haible  <bruno@clisp.org>
11449
11450         * m4/mbchar.m4: New file.
11451
11452 2005-08-16  Bruno Haible  <bruno@clisp.org>
11453
11454         * lib/tls.h: New file, from GNU gettext.
11455         * lib/tls.c: New file, from GNU gettext.
11456
11457 2005-08-16  Bruno Haible  <bruno@clisp.org>
11458
11459         * lib/strnlen1.h: New file.
11460         * lib/strnlen1.c: New file.
11461
11462 2005-08-16  Bruno Haible  <bruno@clisp.org>
11463
11464         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
11465         (mbi_init): Update.
11466         (mbi_avail, mbi_advance): Let the iteration end before the terminating
11467         NUL byte, not after it.
11468
11469 2005-08-16  Bruno Haible  <bruno@clisp.org>
11470
11471         * lib/strcase.h (strcasecmp): Add note in comments.
11472         * lib/strncasecmp.c: Use code from strcasecmp.c.
11473         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
11474         (strcasecmp): Work correctly in multibyte locales.
11475
11476 2005-08-16  Bruno Haible  <bruno@clisp.org>
11477
11478         * lib/mbiter.h: New file.
11479
11480 2005-08-16  Bruno Haible  <bruno@clisp.org>
11481
11482         * lib/mbfile.h: New file.
11483
11484 2005-08-16  Bruno Haible  <bruno@clisp.org>
11485
11486         * lib/mbchar.h: New file.
11487         * lib/mbchar.c: New file.
11488
11489 2005-08-16  Bruno Haible  <bruno@clisp.org>
11490
11491         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
11492         the valid ones. Makes the comparison operations transitive:
11493         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
11494         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
11495
11496 2005-08-15  Simon Josefsson  <jas@extundo.com>
11497
11498         * modules/ssize_t (License): Change to 'unlimited'.
11499
11500         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
11501
11502 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11503
11504         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
11505         Add comments for each pending glibc patch.
11506
11507 2005-08-15  Bruno Haible  <bruno@clisp.org>
11508
11509         * lib/regex.h (__restrict_arr): Don't define to __restrict if
11510         __cplusplus is defined.
11511
11512 2005-08-14  Jim Meyering  <jim@meyering.net>
11513
11514         Sync from coreutils.
11515
11516         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
11517         Use the hash-table-based cycle-detection code not just when
11518         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
11519         Reported by James Youngman in
11520         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
11521         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
11522         FTS_TIGHT_CYCLE_CHECK.
11523         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
11524         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
11525         once again.
11526         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
11527         * lib/fts.c (fd_safer): Remove decl.
11528         Include fcntl--.h rather than unistd-safer.h
11529         (fts_safe_changedir): Don't call fd_safer; no longer needed
11530         now that we include fcntl--.h.
11531
11532 2005-08-12  Simon Josefsson  <jas@extundo.com>
11533
11534         * modules/getndelim2: Use ssize_t module.
11535         * modules/getnline: Likewise.
11536         * modules/safe-read: Likewise.
11537         * modules/xreadlink: Likewise.
11538
11539         * modules/ssize_t: New file.
11540
11541 2005-08-12  Simon Josefsson  <jas@extundo.com>
11542
11543         * m4/readline.m4: Look for termcap, curses or ncurses if required.
11544
11545 2005-08-12  Simon Josefsson  <jas@extundo.com>
11546
11547         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11548         ssize_t.
11549
11550 2005-08-12  Simon Josefsson  <jas@extundo.com>
11551
11552         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
11553         readline, getdelim and check_version.
11554         (Support for systems lacking ISO C 99: Sizes of integer types):
11555         Add size_max.
11556
11557 2005-08-12  Bruno Haible  <bruno@clisp.org>
11558
11559         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
11560
11561 2005-08-11  Simon Josefsson  <jas@extundo.com>
11562
11563         * modules/readline: New file.
11564
11565         * modules/strnlen (Files): Add strnlen.h.
11566
11567 2005-08-11  Simon Josefsson  <jas@extundo.com>
11568
11569         * m4/readline.m4: New file.
11570
11571 2005-08-11  Simon Josefsson  <jas@extundo.com>
11572
11573         * lib/readline.h, readline.c: New file.
11574
11575 2005-08-11  Simon Josefsson  <jas@extundo.com>
11576
11577         * doc/gnulib.texi (Initial import, Finishing touches): Mention
11578         gl_AVOID.
11579
11580 2005-08-11  Bruno Haible  <bruno@clisp.org>
11581
11582         * lib/strnlen.h (strnlen): Change parameter name to match comment.
11583
11584 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
11585
11586         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
11587
11588 2005-08-10  Simon Josefsson  <jas@extundo.com>
11589
11590         * tests/test-iconvme.c: New file.
11591
11592 2005-08-10  Simon Josefsson  <jas@extundo.com>
11593
11594         * m4/strnlen.m4: New file.
11595
11596         * m4/strndup.m4: Don't check for strnlen declaration, done in
11597         strnlen.m4.
11598
11599 2005-08-10  Simon Josefsson  <jas@extundo.com>
11600
11601         * lib/strndup.c: Use strnlen.h.
11602
11603         * lib/strnlen.h: New file.
11604
11605 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11606
11607         * README: Typos.
11608
11609 2005-08-02  Simon Josefsson  <jas@extundo.com>
11610
11611         * modules/readline: New file.
11612
11613 2005-08-02  Simon Josefsson  <jas@extundo.com>
11614
11615         * modules/getdelim: New file.
11616
11617         * modules/getline: Rewrite, don't use getndelim2.
11618
11619 2005-08-02  Simon Josefsson  <jas@extundo.com>
11620
11621         * m4/getline.m4: Separate out getdelim stuff into separate module.
11622
11623         * m4/getdelim.m4: New file.
11624
11625 2005-08-02  Simon Josefsson  <jas@extundo.com>
11626
11627         * lib/getline.h, getline.c: Rewrite.
11628
11629         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
11630
11631 2005-07-31  Bruno Haible  <bruno@clisp.org>
11632
11633         * lib/lock.h (gl_lock_initializer): New macro.
11634         (gl_lock_define_initialized): Use it.
11635         (gl_rwlock_initializer): New macro.
11636         (gl_rwlock_define_initialized): Use it.
11637         (gl_recursive_lock_initializer): New macro.
11638         (gl_recursive_lock_define_initialized): Use it.
11639
11640 2005-07-30  Karl Berry  <karl@gnu.org>
11641
11642         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
11643         Report from Ben Pfaff, regarding getopt.
11644
11645 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
11646
11647         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
11648         normal way.
11649         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
11650         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
11651         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
11652         (gl_GETOPT): Use the new macros.  Most of the implementation
11653         is moved to the new macros.  This is for programs like Emacs
11654         that don't want all the functionality of gl_GETOPT.
11655
11656 2005-07-26  Bruno Haible  <bruno@clisp.org>
11657
11658         * m4/lock.m4: Update from GNU gettext.
11659
11660 2005-07-26  Bruno Haible  <bruno@clisp.org>
11661
11662         * lib/lock.h: Update from GNU gettext.
11663         * lib/lock.c: Update from GNU gettext.
11664
11665 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
11666
11667         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
11668         obsolescent AC_TRY_RUN.  Include the default includes files, for
11669         'exit'.
11670
11671 2005-07-24  Bruno Haible  <bruno@clisp.org>
11672
11673         * modules/visibility: New file.
11674         * MODULES.html.sh (Misc): Add visibility.
11675
11676 2005-07-24  Bruno Haible  <bruno@clisp.org>
11677
11678         * m4/visibility.m4: New file.
11679
11680 2005-07-24  Bruno Haible  <bruno@clisp.org>
11681
11682         * doc/visibility.texi: New file.
11683
11684 2005-07-22  Bruno Haible  <bruno@clisp.org>
11685
11686         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
11687         $(ALLOCA_H), redundant through BUILT_SOURCES.
11688         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
11689         redundant through BUILT_SOURCES.
11690         * modules/byteswap (Makefile.am): Remove explicit dependency on
11691         $(BYTESWAP_H), redundant through BUILT_SOURCES.
11692         * modules/fnmatch (Makefile.am): Remove explicit dependency on
11693         $(FNMATCH_H), redundant through BUILT_SOURCES.
11694         * modules/getopt (Makefile.am): Remove explicit dependency on
11695         $(GETOPT_H), redundant through BUILT_SOURCES.
11696         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
11697         redundant through BUILT_SOURCES.
11698         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
11699         redundant through BUILT_SOURCES.
11700         * modules/stdbool (Makefile.am): Remove explicit dependency on
11701         $(STDBOOL_H), redundant through BUILT_SOURCES.
11702         * modules/stdint (Makefile.am): Remove explicit dependency on
11703         $(STDINT_H), redundant through BUILT_SOURCES.
11704         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
11705         Remove explicit dependency on $(SYSEXITS_H).
11706         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
11707
11708 2005-07-18  Simon Josefsson  <jas@extundo.com>
11709
11710         * lib/check-version.c (check_version): Accept identical versions too.
11711
11712 2005-07-18  Bruno Haible  <bruno@clisp.org>
11713
11714         * modules/lock: New file.
11715         * MODULES.html.sh (Multithreading): New section.
11716
11717 2005-07-18  Bruno Haible  <bruno@clisp.org>
11718
11719         * m4/lock.m4: New file, from GNU gettext.
11720
11721 2005-07-18  Bruno Haible  <bruno@clisp.org>
11722
11723         * lib/lock.h: New file, from GNU gettext.
11724         * lib/lock.c: New file, from GNU gettext.
11725
11726 2005-07-18  Bruno Haible  <bruno@clisp.org>
11727
11728         * lib/lock.h (gl_once_t): New type.
11729         (gl_once_define, gl_once): New macros.
11730         * lib/lock.c (fresh_once): New variable.
11731         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
11732         functions.
11733
11734 2005-07-16  Simon Josefsson  <jas@extundo.com>
11735
11736         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
11737         workaround, suggested by Bruno.
11738
11739 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11740
11741         * modules/xalloc (Depends-on): Add xalloc-die.
11742         * modules/xvasprintf (Depends-on): Add xalloc-die.
11743
11744 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11745
11746         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
11747         with a minor change.
11748
11749 2005-07-15  Bruno Haible  <bruno@clisp.org>
11750
11751         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
11752         When using lib/poll.c, define poll as rpl_poll.
11753
11754 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
11755
11756         * modules/argp (Depends-on): Remove unlocked-io.
11757
11758 2005-07-14  Derek Price  <derek@ximbiot.com>
11759
11760         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
11761         for glob symlink bug.
11762
11763 2005-07-14  Bruno Haible  <bruno@clisp.org>
11764
11765         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
11766         Instead, test for *_unlocked function declarations directly.
11767
11768 2005-07-11  Simon Josefsson  <jas@extundo.com>
11769
11770         * modules/size_max: New file.
11771
11772         * modules/xsize: Depend on size_max module for size_max.m4.
11773
11774 2005-07-11  Simon Josefsson  <jas@extundo.com>
11775
11776         * lib/size_max.h: New file.
11777
11778 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
11779
11780         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
11781         copyright symbol and the year.
11782         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
11783         (version_etc_va): Use parameterized copyright notice.
11784         Reword to conform to the current GNU coding standards.
11785
11786 2005-07-11  Karl Berry  <karl@gnu.org>
11787
11788         * doc/gnulib.texi (Quoting): new node.
11789         (Initial import): more info, from Patrice.
11790
11791 2005-07-11  Bruno Haible  <bruno@clisp.org>
11792
11793         * gnulib-tool (func_usage): Document option --avoid.
11794         (Command line options): Handle --avoid.
11795         (func_acceptable): New function.
11796         (func_modules_transitive_closure): Use it.
11797
11798 2005-07-11  Bruno Haible  <bruno@clisp.org>
11799
11800         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
11801         Reported by Jim Meyering.
11802
11803 2005-07-10  Bruno Haible  <bruno@clisp.org>
11804
11805         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
11806         Needed when size_t is smaller than 'unsigned int'.
11807         Reported by Paul Eggert.
11808
11809 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11810
11811         * modules/argp (Depends-on): Add unlocked-io
11812
11813 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11814
11815         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
11816         block of defines.
11817
11818 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11819
11820         * config/srclist.txt: Comment out regcomp.c, since we have a porting
11821         fix now.
11822
11823 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
11824         and Paul Eggert  <eggert@cs.ucla.edu>
11825
11826         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
11827         in wint_t, not wchar_t.  Remove now-unnecessary cast.
11828
11829 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11830
11831         * modules/regex (Files): Add lib/regex_internal.c,
11832         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
11833         (Depends-on): Add extensions.
11834         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
11835
11836 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11837
11838         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
11839         pathconf.
11840         * m4/same.m4 (gl_SAME): Likewise.
11841         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
11842
11843         * m4/regex.m4: Adjust to new libc regex implementation.
11844         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
11845         all the .c and .h parts of (the new) regex.
11846         Quote the m4 stuff better.
11847         Check for RE_ICASE bug of old gnulib.
11848         Check for REG_STARTEND of recent libc.
11849         Rename local variables from jm_* to gl_*.
11850         Quote operand of "test -f".
11851         Say "recent enough" version of libc, not "version 2".
11852         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
11853         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
11854         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
11855         Remove check for btowc, isascii.
11856         Require AM_LANGINFO_CODESET.
11857
11858 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11859
11860         * lib/regex.c, regex.h: Sync from libc.
11861         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
11862         * lib/regexec.c:
11863         New files, synced from libc, except that regex_internal.h
11864         currently has a small porting fix.
11865
11866 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11867
11868         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
11869         regex_internal.c, regexec.c.
11870         Add regex_internal.h too, but as a comment, since the libc version
11871         is currently broken in gnulib mode.
11872
11873 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11874
11875         Support programs like Emacs that use gnulib but not gettext.
11876         * MODULES.html.sh (Internationalization functions): Add gettext-h.
11877         * modules/gettext-h: New file.
11878         * modules/gettext (Files): Remove lib/gettext.h.
11879         (Depends-on): Add gettext-h.
11880         (Makefile.am): Remove lib_SOURCES.
11881         * modules/argmatch, modules/c-stack, modules/closeout:
11882         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
11883         * modules/execute, modules/file-type, modules/getaddrinfo:
11884         * modules/getopt, modules/human, modules/javacomp:
11885         * modules/javaexec, modules/mkdir-p, modules/obstack:
11886         * modules/openat, modules/pagealign_alloc, modules/pipe:
11887         * modules/quotearg, modules/regex, modules/rpmatch:
11888         * modules/unicodeio, modules/userspec, modules/version-etc:
11889         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
11890         * modules/xsetenv:
11891         Depend on gettext-h, not gettext.
11892
11893 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11894
11895         * gnulib-tool (func_import): Add support for 'public domain' license.
11896         * modules/alloca, modules/atexit, modules/memmove:
11897         Now public domain, not GPL.
11898         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
11899         * modules/realloc, modules/strerror, modules/strtod:
11900         Now LGPL, not GPL.
11901
11902 2005-07-05  Bruno Haible  <bruno@clisp.org>
11903
11904         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
11905         autoconf CVS. Needed for mingw.
11906
11907 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11908
11909         Remove the dependency of the strftime module on the tzset module.
11910         * modules/strftime (Depends-on): Remove dependency on tzset.
11911
11912 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11913
11914         Remove the dependency of the strftime module on the tzset module.
11915         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
11916         gl_FUNC_TZSET_CLOBBER.
11917
11918 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11919
11920         Remove the dependency of the strftime module on the tzset module.
11921         * lib/strftime.c (my_strftime)
11922         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
11923         Copy the input structure, to work around some of the bug with
11924         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
11925         Solaris releases, you should also use the tzset module, but we won't
11926         require it as a dependency any more since we don't want LGPLed code
11927         to depend on GPLed code.
11928
11929 2005-07-02  Jim Meyering  <jim@meyering.net>
11930
11931         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
11932         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
11933         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
11934         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
11935
11936 2005-07-02  Jim Meyering  <jim@meyering.net>
11937
11938         * lib/backupfile.c (backup_args): Change a `0' to NULL.
11939
11940 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11941
11942         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
11943         declares only 'struct timespec;' (!).
11944
11945 2005-07-01  Jim Meyering  <jim@meyering.net>
11946
11947         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
11948         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
11949         * lib/save-cwd.c, tempname.c:
11950         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
11951         and don't include <sys/file.h>).
11952
11953 2005-06-29  Jim Meyering  <jim@meyering.net>
11954
11955         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
11956         type name.  Use the variable name instead.
11957         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
11958         Likewise.
11959
11960 2005-06-28  Simon Josefsson  <jas@extundo.com>
11961
11962         * modules/check-version (Files): Add check-version.m4.
11963
11964 2005-06-28  Simon Josefsson  <jas@extundo.com>
11965
11966         * m4/check-version.m4: New file, suggested by Jim Meyering
11967         <jim@meyering.net>.
11968
11969 2005-06-28  Simon Josefsson  <jas@extundo.com>
11970
11971         * lib/check-version.h, lib/check-version.c: New files.
11972
11973 2005-06-28  Simon Josefsson  <jas@extundo.com>
11974
11975         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
11976         collision with global variable.  Better indentation.  Don't
11977         increment buffer pointer beyond buffer end.  Based on comments
11978         from Paul Eggert <eggert@cs.ucla.edu>.
11979
11980         * lib/base64.h: Indent.
11981
11982 2005-06-28  Simon Josefsson  <jas@extundo.com>
11983
11984         * doc/gnulib.texi (Library version handling): New section.
11985
11986 2005-06-28  Jim Meyering  <jim@meyering.net>
11987
11988         * check-module (find_included_lib_files): Hard-code another
11989         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
11990         but modules/fts-lgpl (correctly) does not list those files.
11991
11992         * modules/canonicalize (Files): Add lib/pathmax.h.
11993
11994 2005-06-25  Simon Josefsson  <jas@extundo.com>
11995
11996         * modules/check-version: New file.
11997
11998 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
11999
12000         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
12001         initializer of struct addrinfo, as an indication that we don't
12002         care how many members the structure has.
12003
12004 2005-06-24  Derek Price  <derek@ximbiot.com>
12005         and Bruno Haible  <bruno@clisp.org>
12006
12007         Remove stat module & update lstat.
12008         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
12009         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
12010         * m4/stat.m4: Remove this file.
12011
12012 2005-06-24  Derek Price  <derek@ximbiot.com>
12013         and Bruno Haible  <bruno@clisp.org>
12014
12015         Remove stat module & update lstat.
12016         * lib/stat.c: Remove this file...
12017         (slash_aware_lstat): ...moving this content and its support...
12018         * lib/lstat.c (rpl_lstat): ...into here.
12019         * lib/lstat.h: New file.
12020
12021 2005-06-24  Derek Price  <derek@ximbiot.com>
12022         and Bruno Haible  <bruno@clisp.org>
12023
12024         Remove stat module & update lstat.
12025         * config/srclist.txt (libc sources): Remove stat.
12026
12027 2005-06-24  Derek Price  <derek@ximbiot.com>
12028         and Bruno Haible  <bruno@clisp.org>
12029
12030         Remove stat module & update lstat.
12031         * MODULES.html.sh (stat): Remove.
12032         * MODULES.html: Regenerated.
12033         * modules/lstat (Description): Correct function name.
12034         (Files): Add "lstat.h".
12035         (Depends-on): Remove stat, add xalloc, stat-macros.
12036         * modules/stat: Remove this file.
12037         (Include): Add "lstat.h", remove <sys/stat.h>.
12038
12039 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
12040
12041         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
12042         (ranged_convert): Don't save conversion in a temporary struct.
12043         This causes a warning with GCC 4.0.0, and anyway in the typical
12044         case it's not worth the extra 100 bytes or so of code.
12045         (ranged_convert, __mktime_internal): When calling a function via a
12046         pointer P, use P () rather than (*P) (), as we now assume C89 or
12047         better.
12048
12049 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12050
12051         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
12052         "who -r" failed to give output.  Problem reported by Tim Waugh.
12053
12054         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
12055         (xcalloc): Use it to avoid needless tests.
12056         Problem reported by Jim Meyering.
12057
12058 2005-06-20  Derek Price  <derek@ximbiot.com>
12059
12060         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
12061         unnecessary for Autoconfs > 2.59c.
12062
12063 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12064
12065         * lib/argp.h (__option_is_short): Check upper limit of
12066         __key. Isprint() requires its argument to have the value
12067         of an unsigned char or EOF.
12068
12069 2005-06-16  Jim Meyering  <jim@meyering.net>
12070
12071         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
12072         when either N or S is zero.
12073
12074 2005-06-16  Derek Price  <derek@ximbiot.com>
12075
12076         * m4/bison.m4: Declare YACC & YFLAGS precious.
12077
12078 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
12079
12080         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
12081         multibyte string or pattern, fall back on unibyte matching.
12082         Problem reported by James Youngman.
12083
12084 2005-06-08  Bruno Haible  <bruno@clisp.org>
12085
12086         * modules/csharpcomp: New file.
12087         * MODULES.html.sh (C#): Add csharpcomp.
12088
12089 2005-06-08  Bruno Haible  <bruno@clisp.org>
12090
12091         * m4/csharpcomp.m4: New file, from GNU gettext.
12092
12093 2005-06-08  Bruno Haible  <bruno@clisp.org>
12094
12095         * lib/csharpcomp.h: New file, from GNU gettext.
12096         * lib/csharpcomp.c: New file, from GNU gettext.
12097         * lib/csharpcomp.sh.in: New file, from GNU gettext.
12098
12099 2005-06-08  Bruno Haible  <bruno@clisp.org>
12100
12101         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
12102         warning on mingw.
12103
12104 2005-06-07  Derek Price  <derek@ximbiot.com>
12105
12106         Sync from CVS.
12107         * lib/glob_.h: Indent nested #ifdef.
12108
12109 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12110
12111         Sync from coreutils.
12112         Use "file name" when talking about file names, instead of "filename"
12113         or "path", as per the GNU coding standards.
12114         * lib/mkdir-p.c: Renamed from makepath.c.
12115         (make_dir_parents): Renamed from make_path.  All callers changed.
12116         * lib/mkdir-p.h: Likewise.  All includers changed.
12117         * lib/filenamecat.c: Renamed from path-concat.c.
12118         (file_name_concat): Renamed from path_concat.  All callers changed.
12119         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
12120         * lib/filenamecat.h: Likewise.  All includers changed.
12121         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
12122         in comments or local variable names.
12123         * lib/basename.c: Likewise.
12124         * lib/canonicalize.c, canonicalize.h: Likewise.
12125         * lib/dirname.c, dirname.h: Likewise.
12126         * lib/euidaccess.c: Likewise.
12127         * lib/exclude.c: Likewise
12128         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
12129         * lib/fsusage.c, fsuage.h: Likewise.
12130         * lib/fts.c, fts_.h: Likewise.
12131         * lib/getcwd.c: Likewise.
12132         * lib/getloadavg.c: Likewise.
12133         * lib/mkstemp.c: Likewise.
12134         * lib/mountlist.c, mountlist.h: Likewise.
12135         * lib/openat.c, openat.h: Likewise.
12136         * lib/readlink-stub.c: Likewise.
12137         * lib/readutmp.c, readutmp.h: Likewise.
12138         * lib/rename.c: Likewise.
12139         * lib/rmdir.c: Likewise.
12140         * lib/same.c: Likewise.
12141         * lib/savedir.c: Likewise.
12142         * lib/stripslash.c: Likewise.
12143         * lib/tempname.c: Likewise.
12144         * lib/xreadlink.c: Likewise.
12145         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
12146         All uses changed.
12147         * lib/exclude.h: Likewise.
12148
12149         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
12150         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12151         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
12152         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12153         * lib/pathmax.h: Include <limits.h> unconditionally, since other
12154         files have been getting away with it for years (MORE/BSD 4.3
12155         is extinct now).
12156         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
12157         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12158
12159         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
12160         Define to 256, not 255, as per modern POSIX.
12161
12162 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12163
12164         Sync from coreutils.
12165         Use "file name" when talking about file names, instead of "filename"
12166         or "path", as per the GNU coding standards.
12167         * MODULES.html.sh: mkdir-p renamed from makepath.
12168         filenamecat renamed from path-concat.
12169         * modules/filenamecat: Renamed from modules/path-concat.
12170         (Files): filenamecat.h and filenamecat.c renamed from
12171         path-concat.h and path-concat.c.
12172         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
12173         (Include): filenamecat.h, not path-concat.h.
12174         * modules/mkdir-p: Renamed from modules/makepath.
12175         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
12176         makepath.c.
12177         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
12178         (Include): mkdir-p.h, not makepath.h.
12179
12180 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12181
12182         Sync from coreutils.
12183         * m4/mkdir-p.m4: Renamed from makepath.m4.
12184         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
12185         Rename files from makepath.c to mkdir-p.c, and from
12186         makepath.h to mkdir-p.h.
12187         * m4/filenamecat.m4: Renamed from path-concat.m4.
12188         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
12189         Rename files from path-concat.c to filenamecat.c,
12190         and from path-concat.h to filenamecat.h.
12191         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
12192         "file name" in local variables or comments.
12193         * m4/rename.m4: Likewise.
12194
12195 2005-06-01  Bruno Haible  <bruno@clisp.org>
12196
12197         * modules/csharpexec: New file.
12198         * MODULES.html.sh (C#): New section.
12199
12200 2005-06-01  Bruno Haible  <bruno@clisp.org>
12201
12202         * m4/csharp.m4: New file, from GNU gettext.
12203         * m4/csharpexec.m4: New file, from GNU gettext.
12204
12205 2005-06-01  Bruno Haible  <bruno@clisp.org>
12206
12207         * lib/csharpexec.h: New file, from GNU gettext.
12208         * lib/csharpexec.c: New file, from GNU gettext.
12209         * lib/csharpexec.sh.in: New file, from GNU gettext.
12210
12211 2005-05-31  Derek Price  <derek@ximbiot.com>
12212             Paul Eggert  <eggert@cs.ucla.edu>
12213
12214         Sync from cvs.
12215         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12216
12217 2005-05-31  Derek Price  <derek@ximbiot.com>
12218             Paul Eggert  <eggert@cs.ucla.edu>
12219
12220         Sync from cvs.
12221         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12222
12223 2005-05-29  Derek Price  <derek@ximbiot.com>
12224
12225         * config/srclist.txt (glob_.h, glob.c): Add these files.
12226
12227 2005-05-29  Derek Price  <derek@ximbiot.com>
12228
12229         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
12230         * modules/glob: New file.
12231         * modules/getlogin_r: Add link to POSIX spec in description.
12232
12233 2005-05-29  Derek Price  <derek@ximbiot.com>
12234             Paul Eggert  <eggert@cs.ucla.edu>
12235
12236         * m4/glob.m4: New file.
12237
12238 2005-05-29  Derek Price  <derek@ximbiot.com>
12239             Paul Eggert  <eggert@cs.ucla.edu>
12240
12241         * lib/glob_.h, lib/glob.c: New files.
12242
12243 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12244
12245         * modules/fts (Files): Remove m4/inttypes-pri.m4.
12246         * modules/fts-lgpl (Depends-on): Remove gettext.
12247
12248 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12249
12250         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
12251         and don't require gt_INTTYPES_PRI.
12252
12253 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12254
12255         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
12256
12257         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
12258         the configuration hassle isn't worth it.
12259         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
12260         (LONGEST_MODIFIER, PRIuMAX): Remove.
12261
12262 2005-05-27  Bruno Haible  <bruno@clisp.org>
12263
12264         * lib/getlogin_r.h: Remove second include of <stddef.h>.
12265
12266 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
12267
12268         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
12269         _POSIX_PTHREAD_SEMANTICS for Solaris.
12270
12271 2005-05-25  Derek Price  <derek@ximbiot.com>
12272
12273         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
12274
12275 2005-05-25  Derek Price  <derek@ximbiot.com>
12276             Paul Eggert  <eggert@cs.ucla.edu>
12277
12278         * modules/getlogin_r, m4/getlogin_r.m4: New files.
12279         * lib/getlogin_r.c, getlogin_r.h: New files.
12280
12281 2005-05-25  Bruno Haible  <bruno@clisp.org>
12282             Derek Price  <derek@ximbiot.com>
12283
12284         * lib/getlogin_r.h: Simplify API documentation.
12285
12286 2005-05-23  Derek Price  <derek@ximbiot.com>
12287
12288         * modules/minmax (Files): Add m4/minmax.m4.
12289         (configure.ac): Add gl_MINMAX.
12290
12291 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
12292
12293         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
12294         so that unistd-safer.h (GPL'ed code) need not be included.
12295
12296 2005-05-22  Bruno Haible  <bruno@clisp.org>
12297
12298         * m4/minmax.m4: New file.
12299         Based on a patch by Derek Price <derek@ximbiot.com>.
12300
12301 2005-05-22  Bruno Haible  <bruno@clisp.org>
12302
12303         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
12304         (INT64_MIN): Fix definition.
12305         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
12306
12307         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
12308         NEED_SIGNED_INT_TYPES.
12309
12310         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
12311         HAVE_SYSTEM_INTTYPES.
12312
12313 2005-05-22  Bruno Haible  <bruno@clisp.org>
12314
12315         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
12316         Also include <sys/param.h> if it defines MIN, MAX.
12317         Based on a patch by Derek Price <derek@ximbiot.com>.
12318
12319 2005-05-21  Jim Meyering  <jim@meyering.net>
12320
12321         * modules/fts (Files): Add m4/inttypes-pri.m4.
12322         (Depends-on): Add lstat and remove gettext.  Alphabetize.
12323
12324 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12325
12326         New fts module.
12327         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
12328         (setup_dir, free_dir): New functions.
12329         (enter_dir, leave_dir): Define trivial
12330         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
12331         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
12332         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
12333         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
12334         Move to fts-cycle.c.
12335         (fts_open): Use setup_dir.
12336         (fts_close): Use free_dir.
12337         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
12338         This adds a label and some gotos, but the alternatives were messier.
12339         Check for memory allocation failure when entering a dir.
12340         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
12341         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
12342         (FTS): New member fts_cycle, that is a union that contains the
12343         old active_dir_ht and cycle_state.  All uses changed to mention
12344         fts_cycle.ht and fts_cycle.state.
12345         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
12346         fts.c, with the following changes:
12347         (setup_dir, free_dir): New functions.
12348         (enter_dir): Now returns bool.  Return true if successful, false
12349         if memory exhausted.  All callers changed.
12350         Do not bother partly cleaning up on
12351         memory allocation failure; that is free_dir's job.
12352         However, free ad if hash_insert fails, to avoid memory leak.
12353         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
12354         fts->fts_options to see which union member to use.
12355
12356 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12357
12358         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
12359         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
12360
12361 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12362
12363         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
12364
12365 2005-05-20  Jim Meyering  <jim@meyering.net>
12366
12367         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
12368         Now a macro, to pacify GCC.
12369
12370 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12371
12372         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
12373         of -1.
12374
12375 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12376
12377         * lib/chown.c (rpl_chown): Return -1 on failure.
12378
12379 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12380
12381         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
12382         Don't check for stddef.h.
12383         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
12384         don't use its results.
12385         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
12386         since we include them unconditionally.  Don't require
12387         AM_STDBOOL_H, since stdbool is a prerequisite.
12388         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
12389         since we assume C89 or better.
12390         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
12391         as we don't use their results.
12392         Don't check for fchdir, memmove, memset, strrchr, as we use
12393         them unconditionally.
12394         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
12395         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
12396
12397 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12398
12399         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
12400         Include <stddef.h> unconditionally, since we assume C89 now.
12401         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
12402         * lib/fts.c: Include fts_.h first, to check interface.
12403         Do not include intprops.h; no longer needed.
12404         Include cycle-check.h and hash.h, since fts_.h no longer does.
12405         Remove unnecessary casts of closedir to void.
12406         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
12407         decide whether to decrement nlinks.
12408         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
12409         (FTS): Use struct hash_table * instead of Hash_table, so that
12410         we no longer need to include hash.h here.
12411
12412 2005-05-18  Jim Meyering  <jim@meyering.net>
12413
12414         * modules/dirfd (License): Change to LGPL.  Most of the code
12415         is already in the public domain.
12416
12417 2005-05-18  Jim Meyering  <jim@meyering.net>
12418
12419         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
12420         Reported by Yoann Vandoorselaere.
12421
12422 2005-05-17  Jim Meyering  <jim@meyering.net>
12423
12424         * m4/fts.m4: New file, from coreutils.
12425
12426 2005-05-17  Jim Meyering  <jim@meyering.net>
12427
12428         * lib/fts.c, lib/fts_.h: New files, from coreutils.
12429
12430 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12431
12432         Sync from coreutils.
12433         * m4/unlinkdir.m4: New file.
12434
12435 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12436
12437         Sync from coreutils.
12438         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
12439         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
12440         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
12441         White space changes only.
12442         * lib/makepath.c (make_path): Port to hosts where leading "//" is
12443         special.
12444         * lib/yesno.c: Include getline.h, not ctype.h.
12445         (yesno): Don't remove leading white space; POSIX doesn't allow it.
12446         Use getline to remove arbitrary restriction on response length.
12447
12448 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12449
12450         * config/srclist-update: Spell out "Street" in FSF postal
12451         mail address; this is the style the FSF seems to prefer.
12452
12453         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
12454         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
12455         this updates FSF postal mail address.
12456
12457         Sync from coreutils.
12458         * modules/unlinkdir: New file.
12459         * modules/yesno (Depends-on): Add getline.
12460         * MODULES.html.sh (File system functions): Add unlinkdir.
12461
12462 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12463
12464         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
12465         lib/strsep.h:
12466         Change the initial comment to refer to GPL, not LGPL.
12467         gnulib-tool will change it to LGPL as needed.
12468
12469         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
12470         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
12471         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
12472         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
12473         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
12474         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
12475         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
12476         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
12477         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
12478         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
12479         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
12480         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
12481         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
12482         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
12483         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
12484         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
12485         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
12486         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
12487         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
12488         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
12489         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
12490         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
12491         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
12492         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
12493         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
12494         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
12495         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
12496         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
12497         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
12498         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
12499         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
12500         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
12501         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
12502         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
12503         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
12504         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
12505         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
12506         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
12507         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
12508         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
12509         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
12510         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
12511         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
12512         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
12513         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
12514         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
12515         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
12516         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
12517         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
12518         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
12519         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12520         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
12521         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
12522         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
12523         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
12524         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
12525         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
12526         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
12527         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
12528         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
12529         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
12530         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
12531         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
12532         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
12533         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
12534         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
12535         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
12536         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
12537         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
12538         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
12539         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
12540         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
12541         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
12542         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
12543         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
12544         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
12545         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
12546         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
12547         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
12548         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
12549         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
12550         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
12551         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
12552         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
12553         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
12554         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
12555         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
12556         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
12557         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
12558         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
12559         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
12560         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
12561         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
12562         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
12563         lib/yesno.c, lib/yesno.h:
12564         Update FSF postal mail address.
12565
12566 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12567
12568         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
12569         tests/test-memmem.c, tests/test-stpncpy.c:
12570         Update FSF postal mail address.
12571
12572 2005-05-13  Bruno Haible  <bruno@clisp.org>
12573
12574         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
12575         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
12576         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
12577         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
12578         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
12579         Add support for 64-bit integers in the MSVC compiler.
12580
12581 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12582
12583         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
12584
12585 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
12586
12587         * gnulib-tool (func_import): Sort and uniquify recommended includes.
12588
12589 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
12590
12591         * doc/getdate.texi (General date syntax): Don't say that date
12592         date --iso-8601=ns generates acceptable dates; it doesn't yet.
12593         Problem reported by Nic Ferrier.
12594
12595 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12596
12597         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
12598         specified in ai_socktype. Fix invalid ai_protocol
12599         check. ai_protocol is usually set to 0 or depending on
12600         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
12601         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
12602         ai_socktype / ai_protocol in the returned addrinfo structure.
12603
12604 2005-05-10  Simon Josefsson  <jas@extundo.com>
12605
12606         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
12607         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12608
12609 2005-05-10  Karl Berry  <karl@gnu.org>
12610
12611         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
12612         (from http://www.gnu.org/licenses).
12613         * doc/COPYING.LIB: also rename to COPYING.LESSER.
12614         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
12615         fdl.texi suffices.
12616
12617 2005-05-10  Karl Berry  <karl@gnu.org>
12618
12619         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
12620         (COPYING.DOC): remove.
12621
12622         * config/srclist-update: new FSF address.
12623
12624 2005-05-10  Derek Price  <derek@ximbiot.com>
12625
12626         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
12627         possible.
12628
12629 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12630             Bruno Haible  <bruno@clisp.org>
12631
12632         * modules/inet_ntop: New file.
12633         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12634         inet_ntop.
12635
12636 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12637             Bruno Haible  <bruno@clisp.org>
12638
12639         * m4/inet_ntop.m4: New file.
12640
12641 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12642             Bruno Haible  <bruno@clisp.org>
12643
12644         * lib/inet_ntop.h: New file.
12645         * lib/inet_ntop.c: New file, from glibc with modifications.
12646
12647 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
12648
12649         * modules/time_r (License): Change to LGPL.
12650         * modules/extensions (License): Change to LGPL.  Actually,
12651         the license is more permissive than that, but currently gnulib-tool
12652         doesn't know how to handle more-permissive licenses.
12653
12654         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
12655         Problem reported by Dave Love.
12656
12657 2005-05-08  Jim Meyering  <jim@meyering.net>
12658
12659         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
12660         blank.
12661
12662 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12663
12664         * modules/argmatch (Depends-on): Add stdbool.
12665         * modules/backupfile (Depends-on): Likewise.
12666         * modules/chdir-long (Depends-on): Likewise.
12667         * modules/closeout (Depends-on): Likewise.
12668         * modules/cycle-check (Depends-on): Likewise.
12669         * modules/dirname (Depends-on): Likewise.
12670         * modules/fnmatch (Depends-on): Likewise.
12671         * modules/fsusage (Depends-on): Likewise.
12672         * modules/fwriteerror (Depends-on): Likewise.
12673         * modules/getcwd (Depends-on): Likewise.
12674         * modules/getloadavg (Depends-on): Likewise.
12675         * modules/hard-locale (Depends-on): Likewise.
12676         * modules/makepath (Depends-on): Likewise.
12677         * modules/mountlist (Depends-on): Likewise.
12678         * modules/nanosleep (Depends-on): Likewise.
12679         * modules/posixtm (Depends-on): Likewise.
12680         * modules/quotearg (Depends-on): Likewise.
12681         * modules/readtokens (Depends-on): Likewise.
12682         * modules/readtokens0 (Depends-on): Likewise.
12683         * modules/readutmp (Depends-on): Likewise.
12684         * modules/save-cwd (Depends-on): Likewise.
12685         * modules/strftime (Depends-on): Likewise.
12686         * modules/userspec (Depends-on): Likewise.
12687         * modules/utimecmp (Depends-on): Likewise.
12688         * modules/xgetcwd (Depends-on): Likewise.
12689         * modules/xnanosleep (Depends-on): Likewise.
12690         * modules/xstrtod (Depends-on): Likewise.
12691         * modules/yesno (Depends-on): Likewise.
12692
12693 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
12694
12695         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
12696         needless checks.
12697
12698 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12699
12700         Merge from coreutils.  Among other things,
12701         add bulletproofing for cases where stdin, stdout, or stderr are closed.
12702         * lib/fd-safer.c: New file.
12703         * lib/fcntl-safer.h, open-safer.c: Remove.
12704         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
12705         * lib/dup-safer.c: Include unistd-safer.h first.
12706         Don't include errno.h.
12707         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
12708         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
12709         * lib/file-type.c: Rely on file-type.h change.
12710         * lib/getloadavg.c: Include unistd-safer.h.
12711         (getloadavg): Use safer open.
12712         * lib/getusershell.c: Include "stdio-safer.h".
12713         (getusershell): Use safer fopen.
12714         * lib/long-options.c (long_options): Use NULL rather than 0.
12715         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
12716         'free'.
12717         * lib/modechange.c: Likewise.
12718         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
12719         (MODE_DONE): New constant.
12720         (struct mode_change): Remove 'next' member.
12721         (make_node_op_equals): New function; like the old one of the
12722         same name, except it allocates an array.
12723         (mode_compile, mode_create_from_ref): Use it.
12724         (mode_compile): Allocate result as an array, not a linked list.
12725         Parse octal string ourself, so that we catch mistakes like "+0".
12726         (mode_adjust): Arg is an array, not a linked list.
12727         * lib/modechange.c: Include stat-macros.h, xalloc.h.
12728         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
12729         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
12730         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
12731         Remove.  This is now stat-macros.h's job.
12732         (talloc): Remove.  All callers replaced by xalloc, so that
12733         our invokers don't have to worry about reporting memory failures.
12734         (make_node_op_equals): Remove.
12735         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12736         New constants.
12737         (struct mode_change): Moved here from modechange.h.
12738         (mode_append_entry): Remove.
12739         (mode_compile): Remove MASKED_OPS arg, since it encouraged
12740         apps to have incorrect behavior.  Use simpler algorithm for head
12741         and tail.  Don't futz with umask; that's now the job of mode_adjust.
12742         Detect more invalid usages rather than having somewhat-random behavior.
12743         Don't insert an "a=" action, as that leads to incorrect behavior.
12744         (mode_compile, mode_create_from_ref): Return NULL on error instead
12745         of an enum, since now there's only one way to have an error.  All
12746         callers changed.
12747         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
12748         at the correct time.  Simplify calculation of "+u" and its ilk.
12749         Don't mishandle "+X".
12750         (mode_free): Remove "register" and localize decls.
12751         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12752         (struct mode_change): Move to modechange.c; callers don't
12753         need to see this stuff.
12754         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
12755         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
12756         (mode_change, mode_adjust): Reflect the new signatures noted above.
12757         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
12758         that might redefine system include files.
12759         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
12760         (my_usleep): Use NULL rather than (void *) 0.
12761         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
12762         Use siginterrupt to specify that system calls should be interrupted.
12763         (rpl_nanosleep): Move initialization of suspended closer to call of
12764         my_usleep.
12765         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
12766         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
12767         (desirable_utmp_entry): New function.
12768         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
12769         using x2nrealloc, to simplify logic.
12770         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
12771         size calculation.  Do not assume utmp file is a regular file.
12772         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
12773         (READ_UTMP_CHECK_PIDS): New constant.
12774         * lib/save-cwd.c: Include unistd-safer.h.
12775         (save_cwd): Use fd_safer.
12776         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
12777         [!_LIBC] Include "stat-macros.h" instead.
12778         * lib/unistd-safer.h (fd_safer): New decl.
12779
12780 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12781
12782         * modules/getloadavg (Depends-on): Add unistd-safer.
12783         * modules/getusershell (Depends-on): Add stdio-safer.
12784         * modules/lstat (Depends-on): Remove xalloc.
12785         * modules/mkstemp (Depends-on): Add stat-macros.
12786         * modules/modechange (Depends-on): Remove xstrtol.
12787         Add stat-macros, xalloc.
12788         * modules/save-cwd (Depends-on): Add unistd-safer.
12789         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
12790         * modules/unistd-safer (Files): Add lib/fd-safer.c
12791         (Makefile.am): Remove lib_SOURCES.
12792
12793         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
12794         Remove fcntl-safer; unistd-safer supersedes it.
12795
12796 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12797
12798         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
12799         AC_HEADER_STAT.
12800         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
12801         (gl_PREREQ_CHOWN): Remove.
12802         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
12803         it.  Don't require AC_HEADER_STAT.
12804         (gl_PREREQ_LSTAT): Remove.
12805         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
12806         Don't require AC_HEADER_STAT.
12807         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
12808         (gl_PREREQ_RMDIR): Remove.
12809         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
12810         mention stat-macros.h or AC_HEADER_STAT, since we'll make
12811         the stat-macros module a prerequisite.
12812         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
12813         * m4/filemode.m4 (gl_FILEMODE): Likewise.
12814         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
12815         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
12816         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
12817         variable names.
12818         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
12819         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
12820         variable prefixes.
12821         * m4/fcntl-safer.m4: Remove.
12822         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
12823         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
12824         Invoke gl_PREREQ_FD_SAFER.
12825         (gl_PREREQ_FD_SAFER): New macro.
12826         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
12827         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
12828         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
12829         Remove duplicate call to AC_LIBOBJ(readutmp).
12830         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
12831
12832         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
12833         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
12834
12835 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12836
12837         * MODULES.html.sh (Misc): Add byteswap.
12838
12839 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12840
12841         * modules/getcwd (Depends-on): Add extensions.
12842         * modules/openat (Depends-on): Likewise.
12843
12844 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12845
12846         * modules/byteswap: New file.
12847
12848 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12849
12850         * m4/byteswap.m4: New file.
12851
12852 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12853
12854         * lib/byteswap_.h: New file.
12855
12856 2005-04-25  Karl Berry  <karl@gnu.org>
12857
12858         * m4/gettext.m4: Update from GNU gettext 0.14.4.
12859
12860 2005-04-25  Albert Chin  <china@thewrittenword.com>
12861
12862         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
12863         Toolkit C bug.
12864
12865 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
12866
12867         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
12868         (func_ln_if_changed) Remove forcibly for no error message
12869         in case file does not exist.
12870
12871 2005-04-19  Simon Josefsson  <jas@extundo.com>
12872
12873         * gnulib-tool (Options): Make --symlink mean --symbolic.
12874
12875 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
12876
12877         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
12878
12879 2005-04-16  Simon Josefsson  <jas@extundo.com>
12880
12881         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
12882
12883 2005-04-15  Simon Josefsson  <jas@extundo.com>
12884
12885         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
12886
12887 2005-04-15  Simon Josefsson  <jas@extundo.com>
12888
12889         * gnulib-tool: Rename --symlink to --symbolic.
12890
12891 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
12892
12893         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
12894         symbolic links to files instead of copying/moving.  Add --aux-dir,
12895         specifying directory relative --dir where auxiliary build tools
12896         are placed.
12897
12898 2005-04-14  Bruno Haible  <bruno@clisp.org>
12899
12900         * modules/allocsa (License): Change to LGPL.
12901         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
12902
12903 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12904
12905         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
12906         that "UTC +1 second" continues to work.  Problem reported
12907         by Dmitry V. Levin.
12908         (relunit_snumber): New rule.
12909         (relunit): Use it.
12910
12911 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
12912
12913         * lib/getdate.y (universal_time_zone_table): New constant.
12914         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
12915         universal_time_zone_table.
12916         (lookup_zone): Prefer universal_time_zone_table to
12917         local_time_zone_table, so that "GMT" time stamps are allowed in
12918         London during the summer.  Problem reported by Ian Abbott.
12919
12920 2005-04-12  Jim Meyering  <jim@meyering.net>
12921
12922         * lib/human.c (humblock): Set *options even when returning due to
12923         xstrtoumax conversion failure.  Thanks to a used-uninitialized
12924         warning from gcc-4.
12925
12926 2005-04-09  Jim Meyering  <jim@meyering.net>
12927
12928         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
12929         -Wuninitialized: initialize tm0.tm_year.
12930
12931 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
12932
12933         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
12934         count, since there's no maximum.  All uses changed.
12935         Add member dsts_seen.
12936         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
12937         not being INT_MAX.
12938         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
12939         Use pc_rels_seen to decide whther a date is absolute.
12940
12941         * lib/getdate.y (number): Don't overwrite year.
12942         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
12943         check.
12944
12945 2005-04-02  Simon Josefsson  <jas@extundo.com>
12946
12947         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
12948         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
12949
12950 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
12951
12952         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
12953         where no absolute path name can be longer than PATH_MAX.
12954
12955 2005-03-27  Jim Meyering  <jim@meyering.net>
12956
12957         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
12958
12959 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
12960
12961         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
12962         "one's complement" -> "ones' complement" in comment, as per Knuth.
12963         "value of type" -> "type or expression" in comment.
12964         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
12965
12966 2005-03-26  Jim Meyering  <jim@meyering.net>
12967
12968         Comment nits.
12969         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
12970         Correct typos: s/or/of/.
12971
12972 2005-03-26  Jim Meyering  <jim@meyering.net>
12973
12974         * modules/check-include-files: Move to ../ and rename to...
12975         * check-module: ...this.
12976
12977 2005-03-25  Jim Meyering  <jim@meyering.net>
12978
12979         * modules/xvasprintf (Files): Add xalloc.h.
12980
12981 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
12982
12983         * modules/gettext (Files): config/config.rpath ->
12984         build-aux/config.rpath
12985         * modules/iconv (Files): Likewise.
12986         Problem reported by Oskar Liljeblad.
12987
12988 2005-03-23  Jim Meyering  <jim@meyering.net>
12989
12990         * modules/check-include-files: New script to check for
12991         missing dependencies, multiple includes, etc.
12992
12993         * modules/c-strtold (Depends-on): Add xalloc.
12994         * modules/c-strtod (Depends-on): Add xalloc.
12995         * modules/hash (Depends-on): Add xalloc.
12996         (Files): Remove lib/xalloc.h.
12997
12998         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
12999         * modules/userspec (Files): Add lib/inttostr.h.
13000
13001 2005-03-23  Jim Meyering  <jim@meyering.net>
13002
13003         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
13004
13005 2005-03-22  Jim Meyering  <jim@meyering.net>
13006
13007         * modules/stat-macros: New module.
13008         * modules/canonicalize, modules/euidaccess, modules/file-type,
13009         * modules/filemode, modules/lchown, modules/makepath,
13010         * modules/rmdir, modules/stat: Depend on new stat-macros module
13011         rather than listing lib/stat-macros.h manually.
13012         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
13013
13014 2005-03-22  Jim Meyering  <jim@meyering.net>
13015
13016         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
13017
13018 2005-03-22  Bruno Haible  <bruno@clisp.org>
13019
13020         * config/srclist.txt: Replace target directory 'config' with
13021         'build-aux'.
13022         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
13023         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
13024         ../build-aux/.
13025
13026 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
13027
13028         * modules/chdir-long (Depends-on): Add mempcpy.
13029
13030         * modules/acl, modules/backupfile, modules/c-strtod,
13031         modules/c-strtold, modules/canon-host, modules/canonicalize,
13032         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
13033         modules/exclude, modules/exitfail, modules/file-type,
13034         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
13035         modules/getdate, modules/getline, modules/getpagesize,
13036         modules/getpass, modules/getugroups, modules/group-member,
13037         modules/hard-locale, modules/hash, modules/human, modules/idcache,
13038         modules/inttostr, modules/long-options, modules/makepath,
13039         modules/md5, modules/memcasecmp, modules/memcoll,
13040         modules/modechange, modules/mountlist, modules/path-concat,
13041         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
13042         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
13043         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
13044         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
13045         modules/strftime, modules/strndup, modules/strverscmp,
13046         modules/timespec, modules/unlocked-io, modules/userspec,
13047         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
13048         modules/yesno:
13049         Remove lib_SOURCES line from Makefile.am section, as this is now
13050         done automatically by the corresponding Autoconf macro.
13051
13052 2005-03-21  Jim Meyering  <jim@meyering.net>
13053
13054         Changes imported from coreutils.
13055
13056         * lib/cycle-check.c: Don't include xalloc.h.
13057
13058         * lib/path-concat.c: Don't include assert.h.
13059         (path_concat): Remove assertion that would have triggered
13060         for ABASE starting with more than one slash.
13061         Reported by Andreas Schwab.
13062
13063         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
13064         properly when ABASE is an absolute file name.
13065         Correct the description of this function.
13066         Include <assert.h>.
13067         Add an assertion and a test driver.
13068         This fixes a bug introduced on 2004-07-02.
13069         Andreas Schwab reported the resulting failure of cp --parents:
13070         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
13071
13072 2005-03-21  Jim Meyering  <jim@meyering.net>
13073
13074         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
13075         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
13076
13077 2005-03-21  Jim Meyering  <jim@meyering.net>
13078         and  Paul Eggert  <eggert@cs.ucla.edu>
13079
13080         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
13081         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
13082         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
13083         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
13084         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
13085         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
13086         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
13087         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
13088         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
13089         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
13090         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
13091         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
13092         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
13093         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
13094         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
13095         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
13096         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
13097         for these modules.
13098
13099 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
13100
13101         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
13102         (which shouldn't happen), generate nothing instead of returning 0
13103         immediately, so that nstrftime (NULL, ...) doesn't return 0.
13104
13105 2005-03-16  Bruno Haible  <bruno@clisp.org>
13106
13107         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
13108         HAVE_LONGLONG_64BIT.
13109
13110 2005-03-16  Bruno Haible  <bruno@clisp.org>
13111
13112         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
13113         HAVE_LONGLONG_64BIT.
13114
13115 2005-03-16  Bruno Haible  <bruno@clisp.org>
13116
13117         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
13118         HAVE_LONGLONG_64BIT.
13119
13120 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13121
13122         * lib/strftime.c (my_strftime): Prepend space to format so that we can
13123         reliably distinguish strftime failure from empty output on POSIX
13124         hosts.
13125
13126 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13127
13128         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
13129         (iconv_string): Don't guess a size-zero buffer, as that might cause
13130         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
13131         result would be 'too large', where 'too large' is (heuristically)
13132         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
13133         overflow concerns.  This will prevent some unwanted malloc failures
13134         when the inputs are very large.
13135
13136 2005-03-15  Karl Berry  <karl@gnu.org>
13137
13138         * config/srclist.txt (config.rpath): from gettext.
13139         * config/config.rpath: update.
13140
13141 2005-03-15  Bruno Haible  <bruno@clisp.org>
13142
13143         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
13144         to 'negate'.
13145
13146         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
13147         variable.
13148
13149         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
13150         results.
13151
13152 2005-03-14  Simon Josefsson  <jas@extundo.com>
13153
13154         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
13155         <fx@gnu.org>.
13156
13157 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
13158
13159         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
13160         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
13161         intprops.h.
13162         * lib/strtol.c: Likewise.
13163
13164 2005-03-14  Jim Meyering  <jim@meyering.net>
13165
13166         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
13167         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
13168         to be nonzero so that we (and caller) can detect the difference
13169         between a valid zero-length expansion and an error return, even
13170         when the underlying strftime fails before writing anything into
13171         that location.
13172
13173 2005-03-14  Bruno Haible  <bruno@clisp.org>
13174
13175         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
13176         Update from GNU gettext 0.14.3.
13177
13178 2005-03-10  Jim Meyering  <jim@meyering.net>
13179
13180         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
13181
13182 2005-03-10  Jim Meyering  <jim@meyering.net>
13183
13184         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
13185         so that this module works on systems without fchdir.
13186
13187 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
13188
13189         Factor int-properties macros into a single file, except for
13190         glibc-related files.
13191         * lib/intprops.h: New file.
13192         * lib/getloadavg.c: Include it instead of limits.h.
13193         (INT_STRLEN_BOUND): Remove.
13194         * lib/human.c: Include intprops.h.
13195         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
13196         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
13197         302/1000.
13198         * lib/inttostr.h: Include intprops.h instead of limits.h.
13199         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
13200         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
13201         for consistency with intprops.h.
13202         (time_t_is_integer, twos_complement_arithmetic): Use them.
13203         * lib/sig2str.h: Include <signal.h>, intprops.h.
13204         (INT_STRLEN_BOUND): Remove.
13205         * lib/strftime.c (TYPE_SIGNED): Remove.
13206         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
13207         * lib/strtol.c: Adjust comments to match intprops.h.
13208         * lib/userspec.c: Include intprops.h.
13209         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
13210         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
13211         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
13212         instead of rolling our own expressions.
13213         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
13214
13215         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
13216         instead of int.
13217         (my_strftime): Do not mishandle years close to INT_MAX, by doing
13218         the right thing even if adding 1900 would overflow.  Similarly
13219         for tm_mon + 1 and tm_yday + 1.
13220         Make %Y always equivalent to %C%y, and similarly for %G and %g.
13221         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
13222         (DO_SIGNED_NUMBER): New macro.
13223         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
13224
13225 2005-03-07  Bruno Haible  <bruno@clisp.org>
13226
13227         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
13228
13229 2005-03-07  Bruno Haible  <bruno@clisp.org>
13230
13231         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
13232
13233 2005-03-04  Derek R. Price  <derek@ximbiot.com>
13234
13235         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
13236         (func_import): Only replace files via --import when they have actually
13237         changed.
13238
13239 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13240
13241         * m4/mmap-anon.m4: New file.
13242         * m4/pagealign_alloc.m4: New file.
13243
13244 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13245             Bruno Haible  <bruno@clisp.org>
13246
13247         * modules/pagealign_alloc: New file.
13248         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
13249
13250 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13251             Bruno Haible  <bruno@clisp.org>
13252
13253         * lib/pagealign_alloc.h: New file.
13254         * lib/pagealign_alloc.c: New file.
13255
13256 2005-03-03  Bruno Haible  <bruno@clisp.org>
13257
13258         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
13259         Use an all-permissive copyright notice, recommended by RMS.
13260
13261 2005-03-02  Bruno Haible  <bruno@clisp.org>
13262
13263         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
13264         of AIX, the replacement has to be done only after <string.h> is
13265         included, therefore not in config.h. stpncpy.h does the replacement,
13266         and stpncpy.c uses it.
13267
13268 2005-03-02  Bruno Haible  <bruno@clisp.org>
13269
13270         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
13271         stpncpy.c uses it.
13272
13273 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13274
13275         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
13276         The workaround isn't strictly needed for POSIX conformance, and
13277         it's too much of a pain to configure and maintain.  We'll ask
13278         people to fix their kernels instead.
13279         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
13280         (NANOSLEEP_BUG_WORKAROUND): Remove.
13281         (xnanosleep): Remove the workaround.
13282
13283 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13284
13285         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
13286         Reported by Derek Price.
13287         (Include): Add "timespec.h".
13288
13289         * modules/xnanosleep (Depends-on): Remove gethrxtime.
13290
13291 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13292
13293         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
13294         to detect nanosleep bug.
13295
13296 2005-03-01  Bruno Haible  <bruno@clisp.org>
13297
13298         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
13299
13300 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13301
13302         * modules/gethrxtime: New file.
13303         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
13304         (Depends-on): Add gethrxtime.
13305         (configure.ac): Add gl_XNANOSLEEP.
13306         (Makefile.am): Remove lib_SOURCES line.
13307
13308 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13309
13310         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
13311         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
13312
13313 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13314
13315         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
13316         * lib/timespec.h (gettime): Return void, since it always
13317         succeeds now.  All uses changed.
13318         * lib/gettime.c (gettime) Likewise.
13319         [HAVE_NANOTIME]: Prefer nanotime.
13320         Assume gettimeofday succeeds, as POSIX requires.
13321         Assime time () succeeds, since other code already does.
13322         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
13323         (timespec_subtract): Remove.
13324         (NANOSLEEP_BUG_WORKAROUND): New constant.
13325         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
13326         things considerably.  Use it only on GNU/Linux hosts, since the
13327         workaround shouldn't be needed elsewhere.
13328
13329 2005-02-24  Bruno Haible  <bruno@clisp.org>
13330
13331         * modules/gettext (Files): Add m4/glibc2.m4.
13332
13333 2005-02-24  Bruno Haible  <bruno@clisp.org>
13334
13335         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
13336         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
13337         * m4/progtest.m4:
13338         Update from GNU gettext 0.14.2.
13339         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
13340
13341 2005-02-24  Bruno Haible  <bruno@clisp.org>
13342
13343         * lib/localcharset.c: Update from GNU gettext 0.14.2.
13344         * lib/config.charset: Update from GNU gettext 0.14.2.
13345
13346 2005-02-24  Bruno Haible  <bruno@clisp.org>
13347
13348         * lib/gettext.h: Update from GNU gettext 0.14.2.
13349
13350 2005-02-23  Simon Josefsson  <jas@extundo.com>
13351
13352         * m4/iconvme.m4: New file.
13353
13354 2005-02-23  Jim Meyering  <jim@meyering.net>
13355
13356         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
13357         change.
13358         Thanks to Bruno Haible for catching it.
13359
13360 2005-02-22  Simon Josefsson  <jas@extundo.com>
13361
13362         * modules/iconvme: New file.
13363
13364         * MODULES.html.sh: Add iconvme.
13365
13366 2005-02-22  Simon Josefsson  <jas@extundo.com>
13367
13368         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
13369
13370 2005-02-22  Simon Josefsson  <jas@extundo.com>
13371
13372         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
13373
13374 2005-02-22  Jim Meyering  <jim@meyering.net>
13375
13376         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
13377         s/ifndef/ifdef/.
13378
13379 2005-02-20  Neil Conway  <neilc@samurai.com>
13380
13381         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
13382         returned by OSX/Darwin if the specified buffer is not large
13383         enough for the hostname.
13384
13385 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13386
13387         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
13388         pass it to _help, otherwise the latter coredumps trying to
13389         dereference state.root_argp.
13390
13391 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13392
13393         * modules/chdir-long (Depends-on): Add memrchr.
13394         * modules/memrchr (Files): Add lib/memrchr.h.
13395         (Include): "memrchr.h".
13396
13397 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13398
13399         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
13400
13401 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13402
13403         * lib/memrchr.h: New file.
13404         * lib/chdir-long.c: Include it.
13405         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
13406         Don't bother including stddef.h.
13407
13408 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
13409
13410         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
13411         inclusion.
13412         Include <sys/types.h>, for dev_t.
13413         (ME_DUMMY, ME_REMOTE): Move from here....
13414         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
13415         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
13416         Dmitry V. Levin.
13417         Include mountlist.h first, to test the interface.
13418
13419 2005-01-29  Bruno Haible  <bruno@clisp.org>
13420
13421         * lib/progname.c (program_name): Initialize.
13422         Needed when linking statically on MacOS X.
13423
13424 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13425
13426         Sync from coreutils.
13427         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
13428         (Depends-on): Add c-strtod.
13429         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
13430
13431 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13432
13433         Sync from coreutils.
13434         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
13435
13436         Remove files that are specific to coreutils.
13437         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
13438
13439 2005-01-28  Bruno Haible  <bruno@clisp.org>
13440
13441         * modules/javacomp: New file.
13442         * MODULES.html.sh (Java): Add javacomp.
13443
13444 2005-01-28  Bruno Haible  <bruno@clisp.org>
13445
13446         * m4/javacomp.m4: New file, from GNU gettext.
13447
13448 2005-01-28  Bruno Haible  <bruno@clisp.org>
13449
13450         * lib/javacomp.sh.in: New file, from GNU gettext.
13451         * lib/javacomp.h: New file, from GNU gettext.
13452         * lib/javacomp.c: New file, from GNU gettext.
13453
13454 2005-01-26  Simon Josefsson  <jas@extundo.com>
13455
13456         * lib/gai_strerror.c: Use GPL in header.
13457
13458 2005-01-26  Bruno Haible  <bruno@clisp.org>
13459
13460         * modules/javaexec: New file.
13461         * MODULES.html.sh (Java): Add javaexec.
13462
13463 2005-01-26  Bruno Haible  <bruno@clisp.org>
13464
13465         * m4/javaexec.m4: New file, from GNU gettext.
13466
13467 2005-01-26  Bruno Haible  <bruno@clisp.org>
13468
13469         * lib/javaexec.sh.in: New file, from GNU gettext.
13470         * lib/javaexec.h: New file, from GNU gettext.
13471         * lib/javaexec.c: New file, from GNU gettext.
13472
13473 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13474
13475         * modules/lchown (Depends-on): Remove lchown.h
13476
13477 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13478
13479         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
13480         must be defined if the header file was not found, in order
13481         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
13482
13483 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13484
13485         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
13486         initializers for struct pentry_state.
13487         (__argp_error): Check return value of __asprintf
13488         (__argp_failure): Translate error message
13489
13490         * lib/argp-parse.c: Removed braces around the expansion of N_()
13491
13492 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13493
13494         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
13495         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
13496         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
13497         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
13498         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
13499         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
13500         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
13501         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
13502         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
13503         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
13504         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
13505         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
13506         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
13507         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
13508         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
13509         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
13510         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
13511         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
13512         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
13513         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
13514         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
13515         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
13516         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
13517         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
13518         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
13519         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
13520         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
13521         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
13522         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
13523         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
13524         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
13525         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
13526         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
13527         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
13528         xstrtol.m4, xstrtoumax.m4, yesno.m4:
13529         Use an all-permissive copyright notice, recommended by RMS.
13530
13531 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
13532
13533         * modules/chdir-long (Depends-on): Remove mempcpy.
13534
13535 2005-01-21  Jim Meyering  <jim@meyering.net>
13536
13537         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
13538         same value as for Solaris 9.
13539
13540         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
13541         component length.  This included changing the parameter to be
13542         of type `char *' rather than `char const *'.
13543         * lib/chdir-long.h (chdir_long): Update prototype.
13544
13545         * lib/openat.c (fdopendir, fstatat): New functions.
13546         * lib/openat.h: Include headers required for use of DIR and struct
13547         stat.
13548         [AT_SYMLINK_NOFOLLOW]: Define.
13549         (fdopendir, fstatat): Add prototypes.
13550
13551 2005-01-21  Bruno Haible  <bruno@clisp.org>
13552
13553         * modules/classpath: New file.
13554         * MODULES.html.sh (Java): Add classpath.
13555
13556 2005-01-21  Bruno Haible  <bruno@clisp.org>
13557
13558         * lib/classpath.h: New file, from GNU gettext.
13559         * lib/classpath.c: New file, from GNU gettext.
13560
13561 2005-01-20  Simon Josefsson  <jas@extundo.com>
13562
13563         * modules/version-etc-fsf: New file.
13564
13565 2005-01-20  Simon Josefsson  <jas@extundo.com>
13566
13567         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
13568         * lib/version-etc.c: Remove version_etc_copyright.
13569         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
13570         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
13571
13572 2005-01-20  Simon Josefsson  <jas@extundo.com>
13573
13574         * lib/base64.h (isbase64): Add.
13575
13576         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
13577         using a unsigned prototype, don't inline.
13578         (base64_decode): Use it.
13579
13580 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13581
13582         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
13583         it.
13584
13585 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13586
13587         * lib/save-cwd.c (save_cwd): Remove code to support the case
13588         where fchdir is missing or flaky.
13589
13590 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13591
13592         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
13593
13594 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
13595
13596         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
13597         AC_LIBSOURCES now does this.
13598         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
13599         with new ullong_max module.
13600
13601 2005-01-19  Bruno Haible  <bruno@clisp.org>
13602
13603         * modules/sh-quote: New file.
13604         * MODULES.html.sh (Executing programs): Add sh-quote.
13605
13606 2005-01-19  Bruno Haible  <bruno@clisp.org>
13607
13608         * lib/sh-quote.h: New file, from GNU gettext.
13609         * lib/sh-quote.c: New file, from GNU gettext.
13610
13611 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13612
13613         Merge from coreutils.
13614         * m4/ullong_max.m4: New file.
13615         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
13616         (gl_MACROS): Assume localeconv exists.
13617
13618 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13619
13620         Merge changes from coreutils, as described below in several
13621         changelogs dated today.
13622
13623         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
13624         (O_DIRECTORY): Remove; not needed here, since "." must be
13625         a directory.  All uses removed.
13626         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
13627         universal on Suns, and we also need to test for IRIX.
13628         Revamp code to use 'if' rather than '#if'.
13629         Avoid unnecessary comparison of cwd->desc to 0.
13630
13631         * lib/utimens.c (futimens): Robustify the previous patch, by checking
13632         for known valid error numbers rather than observed invalid ones.
13633
13634 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13635
13636         * modules/ullong_max: New file.
13637
13638         * modules/chdir-long, modules/openat: New files.
13639         * modules/save-cwd (Depends-on): Depend on chdir-long.
13640         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
13641
13642 2005-01-18  Jim Meyering  <jim@meyering.net>
13643
13644         Merge from coreutils.
13645         * m4/chdir-long.m4, m4/openat.m4: New files.
13646         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
13647         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
13648         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
13649         is sane and DOES follow symlinks.  Besides, testing 20 different
13650         systems found no broken chown implementations.
13651         Prompted by a change in rsync's copy of this macro.
13652         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
13653
13654         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
13655
13656         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
13657         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
13658         NULL-means-set-to-current-time semantics.
13659         Remove temporary file immediately, rather than waiting
13660         for configure's at-exit trap code to do it.
13661
13662 2005-01-18  Jim Meyering  <jim@meyering.net>
13663
13664         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13665
13666         * lib/utimens.c (futimens): Account for the fact that futimes
13667         can also fail with errno == ENOSYS or errno == ENOENT.
13668         Patch from Dmitry V. Levin.
13669
13670         Change the name of the robust chdir function from chdir to chdir_long.
13671         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
13672         (restore_cwd): Use chdir_long, not chdir.
13673         * lib/chdir-long.c: Renamed from chdir.c.
13674         * lib/chdir-long.h: Renamed from chdir.h.
13675         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
13676         Hurd.
13677
13678 2005-01-18  Bruno Haible  <bruno@clisp.org>
13679
13680         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
13681         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
13682         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
13683         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
13684         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
13685         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
13686         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
13687         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
13688         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
13689         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
13690         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
13691         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
13692         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
13693         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
13694         Use an all-permissive copyright notice, recommended by RMS.
13695
13696 2005-01-18  Bob Proulx  <bob@proulx.com>
13697
13698         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
13699         simplify offsetof() macro construct to avoid compile failure with
13700         native HP-UX 11.0 ANSI C compiler.
13701
13702 2005-01-17  Bruno Haible  <bruno@clisp.org>
13703
13704         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
13705         redundant because stpncpy.m4 takes care of it.
13706
13707 2005-01-17  Bruno Haible  <bruno@clisp.org>
13708
13709         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
13710
13711 2005-01-17  Bruno Haible  <bruno@clisp.org>
13712
13713         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
13714         used.
13715
13716 2005-01-17  Bruno Haible  <bruno@clisp.org>
13717
13718         * lib/fwriteerror.h (fwriteerror): Change specification to include
13719         fclose.
13720         * lib/fwriteerror.c: Include <stdbool.h>.
13721         (fwriteerror): At the end, close the file stream. Record whether
13722         stdout was already closed.
13723
13724 2005-01-17  Bruno Haible  <bruno@clisp.org>
13725
13726         * lib/execute.c (environ): Declare if needed.
13727         * lib/pipe.c (environ): Likewise.
13728         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
13729
13730 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13731
13732         * modules/argp: Depend on vsnprintf
13733
13734 2005-01-10  Jim Meyering  <jim@meyering.net>
13735
13736         * modules/closeout (Depends-on): Add atexit.
13737
13738 2005-01-06  Bruno Haible  <bruno@clisp.org>
13739
13740         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
13741
13742 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13743
13744         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
13745         definitions to be after all include files, to avoid collisions.
13746         Problem reported by Bob Proulx.
13747
13748 2005-01-04  Jim Meyering  <jim@meyering.net>
13749
13750         Changes imported from coreutils.
13751         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
13752         as the mkstemp template, use a temporary directory and an
13753         8.3-friendly template to avoid trouble on systems like DJGPP.
13754         Reported by Juan M. Guerrero via Stepan Kasal.
13755         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
13756         close. Remove the temporary directory right away, rather than waiting
13757         for configure's at-exit trap code to do it.
13758         Suggestion from Stepan Kasal.
13759
13760 2005-01-01  Simon Josefsson  <jas@extundo.com>
13761
13762         * gnulib-tool: Print #include directives when --import'ing.
13763
13764 2004-12-28  Simon Josefsson  <jas@extundo.com>
13765
13766         * tests/test-base64.c: Include required header files.  Remove
13767         unused variables.
13768
13769 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13770
13771         * modules/error (Depends-on): Remove gettext.
13772
13773 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13774
13775         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
13776         not needed.  This removes a dependency on the gettext module.
13777         [defined _LIBC]: Do not include <libintl.h>; not needed.
13778
13779 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13780
13781         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
13782         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
13783
13784 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13785
13786         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
13787         HAVE_DECL_STRTOLD.
13788
13789 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13790
13791         * modules/getdate (Depends-on): Remove alloca-opt.
13792
13793 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13794
13795         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
13796
13797 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13798
13799         * lib/argp-parse.c: Include <stddef.h>.
13800         (alignof, alignto): New macros.
13801         (parser_init): Don't assume that void * is aligned sufficiently
13802         for struct option.
13803
13804         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
13805         need to extend the stack.
13806         (YYINITDEPTH): New macro, so that the initial stack isn't overly
13807         large.
13808
13809 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13810
13811         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
13812
13813 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13814
13815         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
13816         (2004-10-24) change.  Apparently this was a false alarm.
13817
13818         * modules/getdate: Depend on alloca-opt, not alloca.
13819
13820 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13821
13822         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
13823         Remove now-obsolete comment about AIX.
13824         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
13825         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
13826         (YYMAXDEPTH): New macro.
13827
13828 2004-12-18  Simon Josefsson  <jas@extundo.com>
13829
13830         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
13831
13832 2004-12-18  Bruno Haible  <bruno@clisp.org>
13833
13834         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
13835
13836 2004-12-18  Bruno Haible  <bruno@clisp.org>
13837
13838         * lib/fatal-signal.c (fatal_signals): Make non-const.
13839         (init_fatal_signals): New function.
13840         (uninstall_handlers, install_handlers): Ignore signals that were set to
13841         SIG_IGN.
13842         (at_fatal_signal): Call init_fatal_signals.
13843         (init_fatal_signal_set): Likewise. Ignore signals that were set to
13844         SIG_IGN.
13845         Reported by Paul Eggert.
13846
13847 2004-12-18  Bruno Haible  <bruno@clisp.org>
13848
13849         * doc/alloca.texi: New file.
13850         * doc/alloca-opt.texi: New file.
13851
13852 2004-12-17  Jim Meyering  <jim@meyering.net>
13853
13854         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
13855         Otherwise, install-sh could exit with improper exit status when
13856         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
13857
13858 2004-12-16  Simon Josefsson  <jas@extundo.com>
13859
13860         * tests/test-base64.c: Add license.
13861
13862 2004-12-15  Stepan Kasal  <address@hidden>
13863
13864         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
13865
13866 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
13867
13868         * modules/getcwd (Files): Add m4/d-ino.m4.
13869         Suggested by Mark D. Baushke.
13870
13871 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13872
13873         * lib/getdate.y (textint): New member "negative".
13874         (time_zone_hhmm): New function.
13875         Expect 14 shift-reduce conflicts, not 13.
13876         (o_colon_minutes): New rule.
13877         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
13878         (yylex): Set the "negative" member of signed numbers.
13879
13880 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13881
13882         * doc/getdate.texi (Time of day items, Time zone items):
13883         Describe new formats +00:00, UTC+00:00.
13884
13885 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13886
13887         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
13888         spurious "-l"s.  Problem reported by Stepan Kasal.
13889
13890 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
13891
13892         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
13893         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
13894
13895 2004-12-04  Simon Josefsson  <jas@extundo.com>
13896
13897         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
13898         Vandoorselaere <yoann@prelude-ids.org>.
13899
13900 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13901
13902         Changes imported from coreutils.
13903         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
13904         exist.
13905         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
13906
13907 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13908
13909         Changes imported from coreutils.
13910         * lib/hard-locale.c: Assume <locale.h> exists.
13911         Include "strdup.h".
13912         (GLIBC_VERSION): New macro.
13913         (hard_locale): Assume setlocale exists.
13914         Rewrite to avoid #ifdef.
13915         Use strdup rather than malloc + strcpy.
13916         * lib/human.c: Assume <locale.h> exists.
13917         (human_readable): Assume localeconv exists.
13918
13919 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13920
13921         * modules/hard-locale (Depends-on): Add strdup.
13922
13923 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
13924
13925         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
13926         convert T2, not T.  (Imported from libc.)
13927
13928 2004-11-30  Simon Josefsson  <jas@extundo.com>
13929
13930         * modules/restrict (License): Change to LGPL.
13931
13932 2004-11-30  Simon Josefsson  <jas@extundo.com>
13933
13934         * m4/restrict.m4: Add copyright and copying conditions.
13935
13936 2004-11-30  Simon Josefsson  <jas@extundo.com>
13937
13938         * m4/base64.m4: New file.
13939
13940 2004-11-30  Simon Josefsson  <jas@extundo.com>
13941
13942         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
13943         base64.
13944
13945         * tests/test-base64.c: New file.
13946
13947         * modules/base64: New file.
13948
13949 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13950
13951         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
13952         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
13953
13954         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
13955
13956 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13957
13958         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
13959         (__getcwd.c): Don't restore errno; glibc doesn't.
13960         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
13961         first, falling back to our code only if its results look suspicious.
13962         Ensure that the resulting buffer is only as large as necessary.
13963
13964         * lib/readutmp.c: Include readutmp.h first.
13965         Include <errno.h>, since readutmp.h no longer does that.
13966         * lib/readutmp.h: Don't include <errno.h>,
13967         <sys/param.h>, <time.h>; not needed to establish interface.
13968         (errno): Remove decl.
13969         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
13970         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
13971         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
13972
13973 2004-11-28  Simon Josefsson  <jas@extundo.com>
13974
13975         * lib/base64.h, base64.c: New file.
13976
13977 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
13978
13979         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
13980
13981 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
13982
13983         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
13984         (Depends-on): Remove pathmax, same.  Add mempcpy.
13985         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
13986         (Makefile.am): Append getcwd.h to lib_SOURCES.
13987         (Include): Add getcwd.h.
13988         (Maintainer): Change from Jim Meyering to "all, glibc",
13989         since getdate now uses intended-for-glibc code.
13990         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
13991         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
13992
13993 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13994
13995         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
13996         HP's ANSI C compiler.
13997         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
13998         Declaring int functions causes warnings on some modern systems and
13999         shouldn't be needed to compile on ancient ones.
14000         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
14001         defined.
14002
14003         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
14004         with the following changes.
14005         (__set_errno): Parenthesize properly.
14006         Include <stdbool.h>.
14007         (MIN, MAX, MATCHING_INO): New macros.
14008         (__getcwd): Define with prototype, not K&R form.
14009         Use heuristics to allocate default buffer on stack if possible.
14010         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
14011         behavior, and to avoid the PATH_MAX limit when computing
14012         ../../../../...
14013         Use MATCHING_INO to compare inode number to file.
14014         Check for arithmetic overflow in size calculations.
14015         Fix bug in reallocation of dot array that caused getcwd to fail
14016         on directories nested deeper than 75.
14017         Be more careful about saving errno on error.
14018         Do not use realloc; use only free+malloc, as this is a bit
14019         more flexible and avoids a needless copy operation.
14020         Do not inspect st_dev and st_ino for symbolic links; POSIX
14021         doesn't specify the latter.
14022         Check for closedir errors.
14023         Avoid needless casts.
14024         Use "#ifdef weak_alias" around weak_alias, to be like other
14025         glibc code.
14026         The following changes to getcwd.c have effect only when used in
14027         gnulib; they have no effect inside glibc proper.
14028         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
14029         as alloca isn't used.
14030         (alloca, __alloca): Likewise.
14031         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
14032         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
14033         unconditionally, as gnulib assumes C89 or better.
14034         Do not include <sys/param.h>.
14035         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
14036         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
14037         better.
14038         (NULL) [!defined NULL]: Remove; we assume C89 or better.
14039         Include <dirent.h> in a way that is compatible with modern Autoconf.
14040         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
14041         New macros, if not already defined.
14042         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
14043         Use "_LIBC", not "defined _LIBC", for consistency.
14044         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
14045         a mempcpy module.
14046         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
14047         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
14048         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
14049         credit only to Jim Meyering and adjust the copyright dates.
14050         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
14051         <stdlib.h>, <unistd.h>, "pathmax.h".
14052         Instead, include "xgetcwd.h" (first) and "getcwd.h".
14053         (INITIAL_BUFFER_SIZE): Remove.
14054         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
14055
14056 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
14057
14058         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
14059         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
14060         Use the _ONCE methods, for efficiency.
14061         Check for fcntl.h.  In test program, include <errno.h>
14062         and <fcntl.h> if available.  Remove old K&R cruft from
14063         test program.  Check for common errors in GNU/Linux,
14064         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
14065         don't do AC_LIBOBJ, as that's getcwd.m4's job.
14066         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
14067         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
14068         name accordingly.
14069         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
14070         accommodate new getcwd.c.
14071         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
14072         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
14073         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
14074         that's all we need now.
14075
14076 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14077
14078         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
14079         argp-parse.c depends on getopt internals, that means we should
14080         always use our getopt, to be on the safe side.
14081         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
14082         order not to spoil the result of an eventual previous invocation
14083         of gl_GETOPT_SUBSTITUTE.
14084
14085 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14086
14087         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
14088         redefinition warnings. To avoid them, include the defines
14089         in `#if !defined __need_getopt ... #endif'. The only place
14090         where __getopt_argv_const is used is in definitions
14091         of getopt_long and getopt_long_only below, which are as well
14092         protected by `#ifndef __need_getopt'.
14093         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
14094         __need_getopt after including <stdio.h> and <unistd.h> These
14095         headers might have defined it.
14096
14097 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
14098
14099         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
14100
14101 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
14102
14103         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
14104         (futimens): New function, which uses futimes if available.
14105         (futimens, utimens): Support timespec==NULL, with same semantics
14106         as utime and utimens.
14107         * lib/utimens.h (futimens): New decl.
14108
14109 2004-11-23  Jim Meyering  <jim@meyering.net>
14110
14111         * lib/getopt_.h: Remove trailing blanks.
14112
14113 2004-11-23  Jim Meyering  <jim@meyering.net>
14114
14115         * lib/__fpending.c: Add comment.
14116
14117 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
14118
14119         * modules/canonicalize (Depends-on): Add xreadlink.
14120         Problem reported by James Youngman.
14121
14122 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
14123
14124         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
14125         New macros.
14126         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
14127         optopt): Use them instead of invoking ## directly; otherwise, the
14128         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
14129
14130 2004-11-19  Bruno Haible  <bruno@clisp.org>
14131
14132         * lib/strtok_r.c: Move comments from here...
14133         * lib/strtok_r.h: ... to here.
14134
14135 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14136
14137         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
14138         implementations that mishandle size_t overflow.
14139
14140 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14141
14142         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
14143         might fail.  Problem reported by Yoann Vandoorselaere.
14144         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
14145         implementations that mishandle size_t overflow.
14146
14147 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14148
14149         * modules/canon-host (Depends-on): Add strdup.
14150
14151 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14152
14153         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
14154
14155 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14156
14157         * lib/canon-host.c: Include "strdup.h".
14158         (canon_host): Use getaddrinfo if available, so that IPv6 works.
14159         Use strdup instead of malloc/strcpy to duplicate strings.
14160
14161         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
14162         (human_space_before_unit): New constant.
14163         * lib/human.c (human_readable): Support it.
14164
14165         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
14166         (xgetcwd): Set errno correctly when failing.
14167         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
14168         the failure is actually due to a PATH_MAX problem.
14169
14170         Further getopt changes to make it more likely that glibc will
14171         buy the changes back.
14172         * lib/getopt.c (POSIXLY_CORRECT): New constant.
14173         (getopt): Use it, so to preserve glibc semantic
14174         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
14175         when compiling for libc.
14176         * lib/getopt_.h (__getopt_argv_const): Bring it back.
14177         (getopt_long, getopt_long_only): Use it.
14178
14179         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14180         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
14181         (getopt): Argv is now char * const *, as per standard.
14182         (_getopt_internal_r, _getopt_internal): Argv is now char **,
14183         not char *__getopt_argv_const *.
14184         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14185         _getopt_long_only_r): Likewise.
14186         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
14187         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14188         _getopt_long_r, _getopt_long_only_r): Likewise.
14189         * lib/getopt_.h (__getopt_argv_const): Remove.
14190         (getopt): Argv is now char * const *, as per standard.
14191
14192         * lib/getdate.y (tORDINAL): New token.
14193         (day, relunit): Allow it for relative times.
14194         (relative_time_table): Use tORDINAL for ordinals.
14195
14196 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14197
14198         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
14199         Document that "second" isn't allowed as an ordinal number.
14200
14201 2004-11-16  Jim Meyering  <jim@meyering.net>
14202
14203         * modules/closeout (Depends-on): Add fpending.
14204
14205 2004-11-15  Jim Meyering  <jim@meyering.net>
14206
14207         * lib/closeout.c: Include "__fpending.h" once again.
14208         Include <stdbool.h>.
14209         (close_stdout): Don't fail just because stdout was closed initially,
14210         since some programs don't write to stdout in the normal course of
14211         operation (other than --version and --help), and we don't want this
14212         function to make e.g. `touch file >&-' fail.
14213         But do fail if it was closed and someone has tried to write to it.
14214         E.g., `printf foo >&-' must fail.
14215
14216 2004-11-13  Jim Meyering  <jim@meyering.net>
14217
14218         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
14219
14220 2004-11-12  Simon Josefsson  <jas@extundo.com>
14221
14222         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
14223         small doc fix is still pending.
14224
14225 2004-11-11  Simon Josefsson  <jas@extundo.com>
14226
14227         * modules/strtok_r: New file.
14228
14229         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14230         strtok_r.
14231
14232 2004-11-11  Simon Josefsson  <jas@extundo.com>
14233
14234         * m4/strtok_r.m4: New file.
14235
14236         * m4/getopt.m4: Replace opterr.
14237
14238 2004-11-11  Simon Josefsson  <jas@extundo.com>
14239
14240         * lib/strtok_r.h, strtok_r.c: New file.
14241
14242 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14243
14244         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
14245         of replacing opterr, getopt, etc.  This should handle the
14246         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
14247
14248 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14249
14250         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
14251         we can stop lying to compilers about the constness of argv when we
14252         are compiled outside glibc.
14253         (getopt, getopt_long, getopt_long_only): Use it.
14254         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14255         _getopt_internal, getopt): Likewise.
14256         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14257         _getopt_long_only_r): Likewise.
14258         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14259         _getopt_long_r, _getopt_long_only_r): Likewise.
14260
14261         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
14262         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
14263         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
14264         the other external symbols.
14265         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
14266         declaration, since the above renaming now works around collisions.
14267
14268 2004-11-11  Jim Meyering  <jim@meyering.net>
14269
14270         * lib/linebreak.c: Remove trailing blanks.
14271         * lib/alloca_.h: Likewise.
14272         * lib/acosl.c: Likewise.
14273         * lib/euidaccess.c: Likewise.
14274         * lib/allocsa.h: Likewise.
14275
14276 2004-11-10  Simon Josefsson  <jas@extundo.com>
14277
14278         * m4/getaddrinfo.m4: New file.
14279
14280 2004-11-10  Simon Josefsson  <jas@extundo.com>
14281
14282         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
14283
14284 2004-11-10  Simon Josefsson  <jas@extundo.com>
14285
14286         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14287         getaddrinfo.
14288
14289         * modules/getaddrinfo: New file.
14290
14291 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14292
14293         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
14294
14295 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14296
14297         * lib/mktime.c (SHR): New macro, which is a portable
14298         substitute for >> that should work even on Crays.
14299         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
14300         Problem reported by Mark D. Baushke in
14301         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
14302         * lib/getdate.y (SHR): Likewise.
14303         (tm_diff): Use it.
14304         * lib/strftime.c (SHR): Likewise.
14305         (tm_diff): Use it.
14306         * lib/quotearg.c (struct quoting_options): Use unsigned int for
14307         quote_these_too, so that right shifts are well defined.  All uses
14308         changed.
14309
14310 2004-11-10  Jim Meyering  <jim@meyering.net>
14311
14312         Ensure that no close failure goes unreported.
14313         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
14314         return early when it seems there's nothing to flush.
14315         Don't include __fpending.h.
14316
14317 2004-11-10  Jim Meyering  <jim@meyering.net>
14318
14319         * modules/closeout (Depends-on): Remove fpending.
14320
14321 2004-11-10  Jim Meyering  <jim@meyering.net>
14322
14323         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
14324
14325 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14326
14327         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
14328         gl_FUNC_STRFTIME.
14329         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
14330         and AC_REQUIRE when possible, to avoid duplicate checks.
14331         Check for <wchar.h>.
14332
14333 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14334
14335         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
14336
14337 2004-11-09  Bruno Haible  <bruno@clisp.org>
14338
14339         * m4/sockpfaf.m4: New file.
14340
14341 2004-11-05  Bruno Haible  <bruno@clisp.org>
14342
14343         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
14344         Reported by Mark D. Baushke <mdb@cvshome.org>.
14345
14346 2004-11-04  Bruno Haible  <bruno@clisp.org>
14347
14348         2004-09-11  Bruno Haible  <bruno@clisp.org>
14349                 * allocsa.valgrind: New file.
14350         2004-02-06  Bruno Haible  <bruno@clisp.org>
14351                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
14352                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
14353                 Reported by Christopher Seip <chris.seip@hp.com>.
14354
14355 2004-11-04  Bruno Haible  <bruno@clisp.org>
14356
14357         * modules/allocsa (Files): Add lib/allocsa.valgrind.
14358         (Makefile.am): Distribute it.
14359
14360 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
14361
14362         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
14363         with errno == ERANGE if the buffer is too small.
14364         Problem reported by Mark D. Baushke.
14365
14366 2004-11-03  Albert Chin  <china@thewrittenword.com>
14367             Paul Eggert  <eggert@cs.ucla.edu>
14368
14369         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
14370         equivalent, substitute $ac_type for equivalent type rather than
14371         blindly using uint32_t *always* which won't work if uint32_t is not
14372         available.  Define _UINT32_T to work around typedef of uint32_t if
14373         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
14374         2.5.1.
14375
14376 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14377
14378         * m4/jm-macros.m4: Sync from coreutils.
14379         (gl_MACROS): Check for mbrlen, for pathchk.
14380         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
14381
14382 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14383
14384         * lib/xreadlink.c (MAXSIZE): New macro.
14385         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
14386         size does not exceed MAXSIZE.  Avoid cast.
14387         As suggested by Mark D. Baushke in
14388         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
14389         if readlink fails with buffer size just under MAXSIZE, try again
14390         with MAXSIZE.
14391
14392 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14393
14394         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
14395
14396 2004-11-02  Derek R. Price  <derek@ximbiot.com>
14397         and  Paul Eggert  <eggert@cs.ucla.edu>
14398
14399         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
14400         (get_date): Overparenthesize to avoid GCC warning.
14401
14402 2004-11-02  Bruno Haible  <bruno@clisp.org>
14403
14404         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
14405         returns void.
14406
14407 2004-11-02  Bruno Haible  <bruno@clisp.org>
14408
14409         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
14410         function returns void.
14411
14412 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14413
14414         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
14415         fflush_unlocked, flockfile, funlockfile, funlockfile,
14416         fputs_unlocked, putc_unlocked.
14417
14418 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14419
14420         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14421         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
14422         already declared.
14423
14424 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14425
14426         * modules/getdate (Files): Add doc/getdate.texi.
14427         (Depends-on): Add setenv, xalloc.
14428
14429 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14430
14431         * lib/getdate.y: Add support for TZ="foo" within a date string.
14432         Fix some bugs near time_t boundaries.  Reject dates with
14433         out-of-range components, e.g., "Sept 31".
14434         Include <stdlib.h>, "setenv.h", "xalloc.h".
14435         (ISDIGIT_LOCALE): Remove; unused.
14436         Note that the TZ and time functions used here are not reentrant.
14437         (mktime_ok, get_tz): New functions.
14438         (TZBUFSIZE): New constant.
14439         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
14440         This requires that we sometimes generate our own TZ="XXX..." setting.
14441
14442 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14443
14444         * doc/getdate.texi: New file, from coreutils with modifications for
14445         the new TZ parsing.
14446
14447 2004-10-27  Derek R. Price  <derek@ximbiot.com>
14448
14449         * lib/mktime.c (not_equal_tm): Remove redundant check.
14450
14451 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14452
14453         * modules/regex (lib_SOURCES): Add regex.c.
14454         Reported by James Youngman in
14455         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
14456
14457 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14458
14459         * lib/getdate.y: Use Bison 1.875 features, and some minor
14460         code cleanups.  This change does not affect semantics.
14461         Don't include <stdlib.h>; no longer needed.
14462         Don't include unlocked-io.h; only the "#if TEST" code uses
14463         stdio, and performance isn't crucial there.
14464         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
14465         Bison 1.875 features as described below.
14466         All uses of "PC." replaced by "pc->".
14467         (YYSTYPE): Add a forward declaration.
14468         (yylex, yyerror): Use full prototypes in forward decls.
14469         Use "%pure-parser" rather than obsolescent "%pure_parser".
14470         Use %parse-param and %lex-param instead of obsolescent
14471         YYPARSE_PARAM and YYLEX_PARAM.
14472         (meridian_table, month_and_day_table, time_units_table,
14473         relative_time_table, time_zone_table, military_table,
14474         lookup_zone, lookup_word, get_date):
14475         Use NULL instead of 0 where appropriate.
14476         (to_hour): Avoid abort (), to avoid a dependency on
14477         stdlib.h.
14478         (yyerror, yylex): Now accepts parser_control * arg.
14479         (main) [TEST]: Use '\0' rather than 0 for char.
14480
14481 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14482
14483         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
14484
14485 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14486
14487         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
14488         It's now the caller's responsibility to handle the case where
14489         !HAVE_GETPAGESIZE && !defined getpagesize.
14490
14491         * lib/mktime.c (leapyear): Arg is long int, not int.
14492
14493 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
14494
14495         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
14496
14497 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
14498
14499         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
14500         missing.  Problem reported by James Youngman.
14501
14502 2004-10-16  Simon Josefsson  <jas@extundo.com>
14503
14504         * gnulib-tool: Fix comments.  Fix parse problem.
14505         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
14506
14507 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
14508
14509         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
14510         implementation of getopt_long.  Problem reported by Alexander Taler in:
14511         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
14512
14513 2004-10-15  Bruno Haible  <bruno@clisp.org>
14514
14515         * gnulib-tool: Untabify. Initialize supplied_libname.
14516         (func_usage): More homogenous output.
14517         (func_modules_transitive_closure, func_modules_to_filelist,
14518         func_emit_lib_Makefile_am): New functions.
14519         (func_import): New function, extracted from big case statement. Use
14520         func_get_license, func_modules_transitive_closure,
14521         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
14522         opt_lgpl. Don't use test -a, as it's not portable.
14523         (func_create_testdir): Use func_modules_transitive_closure,
14524         func_modules_to_filelist, func_emit_lib_Makefile_am.
14525
14526 2004-10-15  Bruno Haible  <bruno@clisp.org>
14527
14528         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
14529
14530 2004-10-15  Bruno Haible  <bruno@clisp.org>
14531
14532         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
14533         the portions belonging to each module.
14534         Suggested by Derek Robert Price <derek@ximbiot.com>.
14535
14536 2004-10-12  Simon Josefsson  <jas@extundo.com>
14537
14538         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14539         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
14540         to real functions.
14541
14542 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14543
14544         * modules/vsnprintf: New file.
14545
14546 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14547
14548         * m4/vsnprintf.m4: New file.
14549
14550 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14551
14552         * lib/vsnprintf.h: New file.
14553         * lib/vsnprintf.c: New file.
14554
14555 2004-10-11  Bruno Haible  <bruno@clisp.org>
14556
14557         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
14558         vsnprintf.
14559
14560 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14561
14562         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
14563
14564 2004-10-07  Bruno Haible  <bruno@clisp.org>
14565
14566         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
14567         fits into the provided buffer.
14568
14569 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14570
14571         * lib/diacrit.c, diacrit.h: Add GPL notice.
14572
14573         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
14574         notice.
14575         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
14576         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
14577         This avoids a potential constant-folding bug.
14578
14579 2004-10-05  Bruno Haible  <bruno@clisp.org>
14580
14581         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
14582         for the declaration of strsep.
14583
14584 2004-10-05  Bruno Haible  <bruno@clisp.org>
14585
14586         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
14587
14588 2004-10-04  Simon Josefsson  <jas@extundo.com>
14589
14590         * modules/memmem: New file.
14591         * tests/test-memmem.c: New file.
14592         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
14593
14594 2004-10-04  Simon Josefsson  <jas@extundo.com>
14595
14596         * m4/memmem.m4: New file.
14597
14598 2004-10-04  Simon Josefsson  <jas@extundo.com>
14599
14600         * lib/memmem.h: New file.
14601         * lib/memmem.c: New file, taken from glibc.
14602
14603 2004-10-04  Simon Josefsson  <jas@extundo.com>
14604
14605         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
14606         '#ifdef USE_UNLOCKED_IO'.
14607
14608 2004-10-04  Simon Josefsson  <jas@extundo.com>
14609
14610         * config/srclist.txt: Add memmem from glibc.
14611
14612 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14613
14614         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
14615
14616         * modules/argmatch, modules/argp, modules/closeout, modules/error,
14617         modules/exclude, modules/getdate, modules/getline,
14618         modules/getndelim2, modules/getpass, modules/getpass-gnu,
14619         modules/getusershell, modules/linebuffer, modules/md5,
14620         modules/mountlist, modules/posixtm, modules/readtokens,
14621         modules/readutmp, modules/regex, modules/sha1,
14622         modules/version-etc, modules/yesno:
14623         Remove dependency on unlocked-io.
14624
14625 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14626
14627         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
14628
14629         * m4/unlocked-io.m4: Add copyright notice.
14630         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
14631
14632 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14633
14634         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
14635         * lib/xmalloc.c (xmemdup): Likewise.
14636         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
14637         XFREE): Remove these long-obsolescent macros.
14638         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
14639         * lib/xstrdup.c: Remove.
14640
14641         * lib/regex.c (re_comp): Cast gettext return value to char *,
14642         Problem reported by Martin Neitzel via Mark D. Baushke.
14643
14644 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14645
14646         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
14647         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
14648         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
14649         regex.c, sha1.c, version-etc.c, yesno.c:
14650         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
14651         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
14652         the includer's responsibility.
14653
14654         Sync from coreutils.
14655
14656         * lib/modechange.c (mode_compile): Don't decrement a pointer that
14657         points to the start of a string, as the C Standard says the
14658         resulting behavior is undefined.
14659
14660         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
14661         simple -> simple_backups, numbered_existing ->
14662         numbered_existing_backups, numbered -> numbered_backups
14663         to avoid shadowing problems.  All uses changed.
14664         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
14665         * lib/backupfile.c (check_extension, numbered_backup):
14666         Rename locals to avoid shadowing 'basename'.
14667         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
14668         once.
14669
14670         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
14671         * lib/.cvsignore: Add getopt.h.
14672
14673 2004-10-04  Bruno Haible  <bruno@clisp.org>
14674
14675         * modules/README: New file.
14676         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
14677         not a module.
14678
14679 2004-10-02  Jim Meyering  <jim@meyering.net>
14680
14681         * lib/dirfd.h, getpagesize.h: Add copyright notice.
14682
14683 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14684
14685         * modules/strsep: New file.
14686
14687 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14688
14689         * m4/strsep.m4: New file.
14690
14691 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14692
14693         * lib/strsep.h: New file.
14694         * lib/strsep.c: New file.
14695
14696 2004-10-01  Simon Josefsson  <jas@extundo.com>
14697
14698         * lib/snprintf.c (snprintf): Handle size==0.
14699
14700 2004-10-01  Simon Josefsson  <jas@extundo.com>
14701             Bruno Haible  <bruno@clisp.org>
14702
14703         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
14704         (snprintf): Declare 'args'.
14705
14706 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
14707
14708         * lib/snprintf.c: Remove comments as to why each header is needed.
14709
14710 2004-10-01  Bruno Haible  <bruno@clisp.org>
14711
14712         * MODULES.html.sh: Add strsep.
14713
14714 2004-09-30  Simon Josefsson  <jas@extundo.com>
14715
14716         * modules/snprintf: New file.
14717
14718 2004-09-30  Simon Josefsson  <jas@extundo.com>
14719
14720         * m4/snprintf.m4: New file.
14721
14722 2004-09-30  Simon Josefsson  <jas@extundo.com>
14723
14724         * lib/snprintf.h, lib/snprintf.c: New files.
14725
14726 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14727
14728         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
14729         (hol_entry_help): Never translate an empty string.
14730         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
14731         * lib/argp.h (OPTION_NO_TRANS): New option.
14732
14733 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14734
14735         * modules/argp (Maintainer): Replace Simon Josefsson
14736         by Sergey Poznyakoff.
14737
14738 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14739
14740         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
14741         changes merged back into glibc.
14742
14743 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14744
14745         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
14746
14747 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14748
14749         * lib/xvasprintf.c: Include xalloc.h.
14750         (xvasprintf): Use xalloc_die, not xmalloc_die.
14751
14752 2004-09-29  Bruno Haible  <bruno@clisp.org>
14753
14754         * modules/alloca-opt: New file, derived from modules/alloca.
14755         * modules/allocsa: Depend on alloca-opt instead of alloca.
14756         * modules/setenv: Likewise.
14757         * modules/vasnprintf: Likewise.
14758         * MODULES.html.sh: Add alloca-opt.
14759
14760 2004-09-28  Simon Josefsson  <jas@extundo.com>
14761
14762         * gnulib-tool: New parameter --lgpl, to asseert that modules are
14763         LGPL, and to replace license template from GPL to LGPL.
14764
14765 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14766
14767         * modules/dummy: Change license to LGPL.
14768
14769 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14770
14771         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
14772
14773 2004-09-24  Simon Josefsson  <jas@extundo.com>
14774
14775         * modules/minmax (License): Change from GPL to LGPL.
14776
14777 2004-09-23  Simon Josefsson  <jas@extundo.com>
14778
14779         * gnulib-tool (--import): Typo.
14780
14781 2004-09-23  Simon Josefsson  <jas@extundo.com>
14782
14783         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
14784
14785 2004-09-22  Bruno Haible  <bruno@clisp.org>
14786
14787         * modules/*: Add 'License' field.
14788         * gnulib-tool: Accept --extract-license option.
14789         (func_get_license): New function.
14790
14791 2004-09-21  Bruno Haible  <bruno@clisp.org>
14792
14793         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
14794         Reported by Simon Josefsson.
14795
14796 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14797
14798         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
14799         gl_AC_TYPE_LONG_LONG.
14800
14801 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14802
14803         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
14804
14805 2004-09-18  Simon Josefsson  <jas@extundo.com>
14806         and  Paul Eggert  <eggert@cs.ucla.edu>
14807
14808         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
14809         calls with autoreconf.  Define GL_LIB.
14810
14811 2004-09-14  Karl Berry  <karl@gnu.org>
14812
14813         * config/srclist.txt: unsync setenv.c, sigh.
14814
14815 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14816
14817         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
14818         Problem reported by Bruno Haible in:
14819         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
14820
14821 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14822
14823         * config/srclist.txt: Comment out argp-pvh.c.
14824
14825 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
14826
14827         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
14828         in case some system header has #define'd it.  Problem reported by
14829         Soeren D. Schulze in
14830         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
14831
14832 2004-09-09  Karl Berry  <karl@gnu.org>
14833
14834         * regex.[ch]: delete from the root.  These were supposed to be
14835                 synced with emacs cvs, but this has not happened for about
14836                 a year, and anyway nothing else uses emacs regex.[ch].
14837                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
14838                 lib/regex[.ch] is untouched.
14839
14840 2004-09-09  Bruno Haible  <bruno@clisp.org>
14841
14842         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
14843
14844 2004-09-09  Bruno Haible  <bruno@clisp.org>
14845
14846         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
14847         modifications.
14848         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
14849
14850 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14851
14852         * modules/xvasprintf: New file.
14853         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
14854
14855 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14856
14857         * lib/xvasprintf.h: New file.
14858         * lib/xvasprintf.c: New file.
14859         * lib/xasprintf.c: New file.
14860
14861 2004-09-08  Bruno Haible  <bruno@clisp.org>
14862
14863         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
14864
14865 2004-09-08  Bruno Haible  <bruno@clisp.org>
14866
14867         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
14868         length is > INT_MAX.
14869         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
14870         more.
14871
14872 2004-09-08  Bruno Haible  <bruno@clisp.org>
14873
14874         * lib/stdint_.h: New file, taken from GNU clisp.
14875
14876 2004-09-08  Bruno Haible  <bruno@clisp.org>
14877             Oskar Liljeblad  <oskar@osk.mine.nu>
14878
14879         * modules/stdint: New file.
14880         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
14881
14882 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14883
14884         Import from coreutils.
14885         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
14886         strings on unbounded length.  alloca's performance benefits aren't
14887         that important here.
14888         (V_STRDUP): Remove.
14889         (parse_with_separator): New function, with most of the internals
14890         of the old parse_user_spec.  Allow user to omit both user and group,
14891         for compatibility with FreeBSD.
14892         Clone only the user name, not the entire spec.
14893         Do not set *uid, *gid unless entirely successful.
14894         Avoid memory leak in some failing cases.
14895         Fix regression for USER.GROUP reported by Dmitry V. Levin in
14896         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
14897         (parse_user_spec): Rewrite to use parse_with_separator.
14898
14899 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14900
14901         * modules/userspec: Don't depend on alloca.
14902
14903 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14904
14905         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
14906
14907 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
14908
14909         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
14910         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
14911         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
14912
14913 2004-08-16  Simon Josefsson  <jas@extundo.com>
14914
14915         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
14916         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
14917         Add --dry-run for --import.
14918         Let user provided command line parameters override configure.ac
14919         settings.
14920
14921 2004-08-12  Simon Josefsson  <jas@extundo.com>
14922
14923         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
14924         as discussed with Paul Eggert in threads rooted at
14925         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
14926         and
14927         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
14928         Before, the test was empty, and relied on ELIDE_CODE in source
14929         code.)
14930         (gl_PREREQ_GETOPT): New macro.
14931         (gl_GETOPT): Use them.
14932
14933 2004-08-12  Simon Josefsson  <jas@extundo.com>
14934
14935         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
14936         * lib/getopt_.h: Renamed from getopt.h.
14937
14938 2004-08-12  Simon Josefsson  <jas@extundo.com>
14939
14940         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
14941         Change default library name from libfoo to libgnu.
14942         Now, if you have a configure.ac that says:
14943                 gl_SOURCE_BASE(gl)
14944                 gl_M4_BASE(gl/m4)
14945                 gl_MODULES(error getopt etcetera)
14946                 gl_INIT
14947         you can import all you need by running:
14948                 ../gnulib/gnulib-tool --import
14949
14950         * modules/getopt (Files): Rename getopt.h to getopt_.h.
14951         (Makefile.am): Rewrite, use logic from argz.
14952         (Include): Use <getopt.h> instead of "getopt.h".
14953
14954 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14955
14956         * modules/argp (Files): Add m4/unlocked-io.m4.
14957         (Depends-on): Add extensions.
14958
14959 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14960
14961         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
14962         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
14963         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
14964         Check for program_invocation_name, program_invocation_short_name,
14965         flockfile, funlockfile, features.h, _getopt_long_only_r.
14966
14967 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14968
14969         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
14970         its complicated substitute.
14971         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
14972         and program_invocation_name.
14973         (__argp_basename) [!_LIBC]: Remove; the only use was
14974         replaced by its body.
14975         (__argp_short_program_name): Change condition from
14976         !defined __argp_short_program_name to
14977         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
14978         to match argp-namefrob.h.
14979         (__argp_failure): Don't assume strerror_r returns char *.
14980         * lib/argp-parse.c (N_): Define unconditionally.
14981         (argp_default_options): Fill out initializers with 0 to avoid
14982         gcc warnings.
14983
14984 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14985
14986         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
14987         getopt1.c.
14988
14989 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14990
14991         Merge from coreutils.
14992
14993         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
14994
14995         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
14996         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
14997
14998 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14999
15000         Merge from coreutils.
15001
15002         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
15003         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
15004         for Reliant Unix 5.43.
15005
15006         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
15007         (union fooround): Use uintmax_t, not long int.
15008         The rest is a merge from libc:
15009         [defined _LIBC]: Include <shlib-compat.h>.
15010         (_obstack) [defined _LIBC]: Remove after 2.3.4.
15011
15012         * lib/settime.c (settime): Recode to avoid warning with
15013         Sun Forte C 6U2.
15014
15015         * lib/strverscmp.c: Convert to UTF-8.
15016
15017 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15018
15019         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
15020         m4/uintmax_t.m4.
15021
15022 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15023
15024         * modules/xalloc-die: New file.
15025         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
15026
15027         * modules/md5 (Files): Add m4/uint32_t.m4.
15028         * modules/sha1: Renamed from modules/sha.
15029         (Files):
15030         Rename lib/sha.h to lib/sha1.h.
15031         Rename lib/sha.c to lib/sha1.c.
15032         Rename m4/sha.m4 to m4/sha1.m4.
15033         (lib_SOURCES): Likewise.
15034         (configure.ac): Rename gl_SHA to gl_SHA1.
15035         (Include): sha.h -> sha1.h.
15036
15037 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15038
15039         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
15040         * m4/sha1.m4: Renamed from sha.m4.
15041         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
15042
15043 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15044
15045         * lib/obstack.h (obstack_empty_p):
15046         Don't assume that chunk->contents is suitably aligned.
15047         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
15048         Likewise. Problem reported by Benno in
15049         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
15050
15051         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
15052         readable.  This could be improved further but it'd take some work.
15053
15054 2004-08-08  Simon Josefsson  <jas@extundo.com>
15055
15056         * modules/xgethostname (Depends-on): Remove exit and error (not
15057         used).
15058
15059         * modules/getpass-gnu: Add getpass.h.
15060         (Depends-on): Add stdbool.
15061         * modules/getpass: Add getpass.h.
15062
15063 2004-08-08  Simon Josefsson  <jas@extundo.com>
15064
15065         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
15066         Check getpass declaration.
15067
15068 2004-08-08  Simon Josefsson  <jas@extundo.com>
15069
15070         * lib/xgethostname.c: Don't include error.h (not used).
15071
15072         * lib/getpass.h: Add.
15073         * lib/getpass.c: Include getpass.h first.
15074
15075 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
15076
15077         * lib/xalloc-die.c: New file.
15078         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
15079         All uses removed.
15080         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
15081         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
15082         xalloc-die.c.
15083         (_, N_, xalloc_die): Move to xalloc-die.c.
15084         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
15085         so that we needn't mess with xalloc_msg_memory_exhausted.
15086
15087         * lib/sha1.h: Renamed from sha.h.
15088         (SHA1_H): Renamed from _SHA_H.
15089         (sha1_ctx): Renamed from sha_ctx.
15090         (sha1_init_ctx): Renamed from sha_init_ctx.
15091         (sha1_process_block): Renamed from sha_process_block.
15092         (sha1_process_bytes): Renamed from sha_process_bytes.
15093         (sha1_finish_ctx): Renamed from sha_finish_ctx.
15094         (sha1_read_ctx): Renamed from sha_read_ctx.
15095         (sha1_stream): Renamed from sha_stream.
15096         (sha1_buffer): Renamed from sha_buffer.
15097         * lib/sha1.c: Likewise; renamed from sha.c.
15098         Do not include <sys/types.h>.
15099         Include <stddef.h> rather than <stdlib.h>.
15100
15101 2004-08-08  Bruno Haible  <bruno@clisp.org>
15102
15103         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
15104         FILESYSTEM_PREFIX_LEN.
15105         * lib/progreloc.c: Likewise.
15106         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
15107
15108 2004-08-06  Simon Josefsson  <jas@extundo.com>
15109
15110         * modules/progname (Depends-on): Don't depend on stdbool.
15111
15112 2004-08-06  Simon Josefsson  <jas@extundo.com>
15113
15114         * modules/getsubopt: New file.
15115         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15116         getsubopt.
15117
15118 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15119
15120         More merge from coreutils.
15121
15122         * m4/utimens.m4, m4/utimecmp.m4: New files.
15123         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
15124         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
15125         prereq.m4, sha.m4: Import changes from coreutils.
15126
15127 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15128
15129         More merge from coreutils.
15130         * modules/raise, modules/readtokens0, modules/utimens:
15131         * modules/utimecmp, module/xnanosleep: New files.
15132         * modules/strftime: Add lib/strftime.h.
15133         Change include from <time.h> to "strftime.h".
15134         * modules/yesno: Add lib/yesno.h.
15135         * modules/backupfile: Remove lib/addext.c.
15136         * modules/euidaccess: Add stat-macros.h.
15137         * modules/canonicalize, modules/euidaccess,
15138         modules/filemode, modules/lchown, modules/makepath,
15139         modules/rmdir, modules/stat: Likewise.
15140
15141 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15142
15143         Merge from tar.
15144         * lib/argp-help.c (make_hol, hol_append): Don't assume that
15145         SIZE_MAX is a valid preprocessor constant.
15146         (__argp_basename): Change from "#ifndef _LIBC"
15147         to "#ifndef __argp_short_program_name", so that
15148         we don't compile these functions for tar.
15149
15150         More merges from coreutils.
15151         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
15152         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
15153         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
15154         * lib/addext.c: Remove; no longer needed.
15155         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
15156         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
15157         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
15158         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
15159         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
15160         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
15161         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
15162         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
15163         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
15164         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15165         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
15166         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
15167         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
15168         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
15169         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
15170         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
15171         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
15172         Import changes from coreutils.
15173
15174 2004-08-05  Simon Josefsson  <jas@extundo.com>
15175
15176         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
15177
15178 2004-08-05  Simon Josefsson  <jas@extundo.com>
15179
15180         * m4/getsubopt.m4: New file.
15181
15182 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15183
15184         Merge from coreutils.
15185
15186         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
15187         * m4/getcwd-path-max.m4: New files.
15188
15189         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
15190         FILESYSTEM_PREFIX_LEN ->
15191         FILE_SYSTEM_PREFIX_LEN.
15192         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
15193         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
15194         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
15195         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
15196
15197         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
15198         prerequisite modules now handle the DOS stuff.
15199         Don't check for unistd.h.
15200
15201 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15202
15203         Merge from coreutils.
15204
15205         * lib/.gdb-history: Remove; this doesn't belong here.
15206
15207         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
15208         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
15209         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
15210         * lib/getcwd.c: New files.
15211
15212         * lib/dirname.h: Include <stdbool.h>.
15213         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
15214         for consistency with POSIX terminology.  All uses changed.
15215         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
15216         (strip_trailing_slashes): Use bool for booleans.
15217         * lib/stripslash.c (strip_trailing_slashes): Likewise.
15218
15219         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
15220         sometimes returns a positive errno value even when it succeeds.
15221         (print_errno_message) [!LIBC]: Fall back on strerror if
15222         __strerror_r fails.
15223
15224         * lib/path-concat.c (mempcpy): Don't define if a system header defines
15225         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
15226         (longest_relative_suffix): New function.
15227         (path_concat): Use it.  Assume first argument is not NULL.
15228         Port to DOS.  Omit redundant separators.
15229         Report an error instead of returning NULL.
15230         Use mempcpy instead of memcpy.
15231         (xpath_concat): Remove: not declared or used.
15232
15233         * lib/same.h: Include <stdbool.h>
15234         (same_name): Return bool, not int.
15235         * lib/same.c (same_name): Likewise.
15236         (errno): Don't declare; we assume C89 or better now.
15237
15238         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
15239         if not already defined.
15240
15241         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
15242         * lib/dup-safer.c (errno): Likewise.
15243
15244 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15245
15246         Merge from coreutils.
15247         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
15248         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
15249         * modules/path-concat: Don't depend on strdup.
15250
15251 2004-08-03  Simon Josefsson  <jas@extundo.com>
15252
15253         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
15254         * lib/progname.h: Don't include stdbool.h.
15255
15256 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15257
15258         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
15259         * MODULES.html.sh (func_all_modules): Remove fatal.
15260
15261 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15262
15263         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
15264
15265 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15266
15267         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
15268         working.
15269
15270 2004-08-02  Simon Josefsson  <jas@extundo.com>
15271
15272         * lib/getsubopt.h: New file, with comments from Bruno Haible.
15273         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
15274         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
15275
15276 2004-08-01  Simon Josefsson  <jas@extundo.com>
15277
15278         * lib/xgetdomainname.c: Include stdlib.h, for free().
15279
15280 2004-07-19  Bruno Haible  <bruno@clisp.org>
15281
15282         * MODULES.html.sh (func_all_modules): Add dummy.
15283
15284 2004-07-16  Simon Josefsson  <jas@extundo.com>
15285
15286         * modules/dummy: New file.
15287
15288 2004-07-16  Simon Josefsson  <jas@extundo.com>
15289
15290         * lib/dummy.c: New file.
15291
15292 2004-07-16  Bruno Haible  <bruno@clisp.org>
15293
15294         * lib/backupfile.h: Add extern "C" for C++.
15295         * lib/closeout.h: Likewise.
15296         * lib/copy-file.h: Likewise.
15297         * lib/findprog.h: Likewise.
15298         * lib/full-write.h: Likewise.
15299         * lib/pathname.h: Likewise.
15300         * lib/progname.h: Likewise.
15301         * lib/stpcpy.h: Likewise.
15302         * lib/stpncpy.h: Likewise.
15303         * lib/strcase.h: Likewise.
15304         * lib/strstr.h: Likewise.
15305         * lib/xalloc.h: Likewise.
15306
15307         * lib/mbswidth.h: Add extern "C" for C++.
15308         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
15309
15310 2004-07-13  Robert Millan  <robertmh@gnu.org>
15311
15312         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
15313
15314 2004-07-09  Simon Josefsson  <jas@extundo.com>
15315
15316         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
15317         failed without this.)
15318
15319 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15320
15321         * modules/chown (Files): Add lib/fchown-stub.c, since
15322         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
15323
15324 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15325
15326         * lib/fchown-stub.c: New file.
15327
15328 2004-06-24  Jim Meyering  <jim@meyering.net>
15329
15330         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
15331
15332 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15333
15334         * modules/argz: Omit "#include".
15335
15336         * MODULES.html.sh (func_all_modules): Add calloc, to match
15337         2004-06-01 addition of calloc module.
15338
15339 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15340
15341         * m4/argz.m4: New file, which is autoupdated from libtool.
15342
15343 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15344
15345         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
15346         libtool.
15347
15348 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15349
15350         * config/srclist-update: Don't insist on "USA." before the
15351         close-comment, as libtool omits the period and puts the */ on a
15352         separate line.
15353         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
15354         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
15355
15356 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
15357
15358         * modules/argz: New file.
15359         * MODULES.html.sh (func_all_modules): Add argz.
15360
15361 2004-06-12  Jim Meyering  <jim@meyering.net>
15362         and  Paul Eggert  <eggert@cs.ucla.edu>
15363
15364         * modules/hash (Files): Add lib/xalloc.h.
15365         * modules/pipe (Depends-on): Add wait-process.
15366         * modules/stat (Depends-on): Add xalloc.
15367         * modules/userspec (Files): Add lib/userspec.h.
15368         * modules/xstrto
15369
15370         Upgrade from gettext-0.13.
15371         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
15372         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
15373         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
15374
15375 2004-06-10  Jim Meyering  <jim@meyering.net>
15376
15377         * lib/calloc.c: New file.
15378
15379 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
15380
15381         * lib/getdate.y (yylex): Allow space between sign and number.
15382         Problem reported by Dan Jacobson.
15383
15384 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15385
15386         Merge from coreutils CVS.
15387
15388         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
15389         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
15390         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
15391         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
15392         xstrtol.m4: Fix copyright date and/or serial number.
15393
15394         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
15395         See if we need an fchown replacement.
15396         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
15397         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
15398         and use the replacement function if we detect either defect.
15399
15400         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
15401         gl_UTIMECMP.
15402
15403 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15404         and  Jim Meyering  <jim@meyering.net>
15405
15406         Merge from coreutils CVS.
15407
15408         * lib/stat-macros.h: New file, with contents from file-type.h
15409         and coreutils' system.h.
15410         * lib/file-type.c: Include "stat-macros.h".
15411         * lib/file-type.h (file_type): Move all macro definitions to new file,
15412         stat-macros.h.
15413
15414         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
15415         Wrap old code with this conditional.
15416         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
15417         function that does not dereference symlinks.
15418         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
15419
15420         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
15421         dependency problems.
15422         (xreadlink): Accept new arg SIZE, for efficiency.
15423         All decls and uses changed.
15424         * lib/xreadlink.h: Include <stddef.h>, for size_t.
15425
15426         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
15427         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
15428
15429         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
15430         sysexits.h.
15431
15432 2004-06-01  Jim Meyering  <jim@meyering.net>
15433
15434         * m4/calloc.m4: New file.
15435
15436 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
15437
15438         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
15439         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
15440         Also, fix a typo in a diagnostic.
15441
15442 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15443
15444         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
15445         or AC_FUNC_REALLOC.
15446
15447 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15448
15449         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
15450         macros to be defined.
15451         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
15452         the allocator returns NULL because the requested size is zero.
15453
15454 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15455
15456         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
15457         var.  Add comment explaining why libc still defines it.  This
15458         merges the following patch from glibc:
15459         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
15460
15461 2004-05-20  Andreas Schwab  <schwab@suse.de>
15462
15463         * m4/free.m4: Replace free if it not known to work, not the other
15464         way round.
15465
15466 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
15467
15468         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
15469         present in glibc since revision 1.1 of this file.
15470         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
15471         obstack_alignment_mask, obstack_alloc, obstack_base,
15472         obstack_blank, obstack_blank_fast, obstack_chunk_size,
15473         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
15474         obstack_grow0, obstack_init, obstack_int_grow,
15475         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
15476         obstack_next_free, obstack_object_size, obstack_ptr_grow,
15477         obstack_ptr_grow_fast, obstack_room): Remove declarations of
15478         nonexistent functions.
15479
15480 2004-05-18  Karl Berry  <karl@gnu.org>
15481
15482         * config/srclist.txt: break link for vasnprintf.c.
15483
15484 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15485
15486         Port obstack to the AS/400, where pointers are 16 bytes wide and
15487         you cannot cast an integer to a valid pointer.  This patch is
15488         currently waiting to be integrated into glibc; see
15489         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
15490
15491         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
15492         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
15493         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
15494         (struct obstack): temp member is now a union of a pointer and
15495         an integer, instead of an integer.  All integer uses changed.
15496         This does not affect the physical layout of struct obstack,
15497         except on hosts (like the AS/400) where the size or alignment of
15498         void * is greater than that of ptrdiff_t.
15499         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
15500         __STDC__)]: Store temporary in pointer member of union, not
15501         integer member.
15502         * lib/obstack.c: Include <stddef.h>, for offsetof.
15503         (struct fooalign): Remove; it doesn't need a name.
15504         (union fooround): Change double to long double, and add void *.
15505         (DEFAULT_ALIGNMENT): Use offsetof to compute.
15506         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
15507         not a macro.  Hence the values are always int; so remove all
15508         casts-to-int in uses.
15509
15510 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15511
15512         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
15513         we can get this patch merged into glibc.
15514
15515 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15516             Paul Eggert  <eggert@cs.ucla.edu>
15517
15518         * m4/argp: Depend on alloca.
15519
15520 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15521             Paul Eggert  <eggert@cs.ucla.edu>
15522
15523         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
15524         freecoding.
15525
15526 2004-05-17  Bruno Haible  <bruno@clisp.org>
15527
15528         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
15529         precision that consists of a '.' followed by an empty digit string.
15530         Patch by Tor Lillqvist <tml@iki.fi>.
15531
15532 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15533
15534         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
15535         for backward compatibility with older code.  We need our own
15536         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
15537         it under some other name, and our alloca.h will define it.
15538
15539 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15540             Derek Price  <derek@ximbiot.com>
15541
15542         * lib/alloca.c: Include <alloca.h>, to get our interface.
15543         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
15544         include <alloca.h> first.  Use C89 prototype for alloca; this
15545         requires including <stddef.h> for size_t.  Use extern "C" if C++.
15546         Use #elif for simplicity, since we can assume C89 now.
15547         Don't try to source the system alloca.h since it will not be found
15548         and to prevent recursively including its replacement.
15549         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
15550         * lib/regex.c: Likewise.
15551
15552 2004-05-16  Derek Price  <derek@ximbiot.com>
15553             Paul Eggert  <eggert@cs.ucla.edu>
15554
15555         getline cleanup.  This changes the getndelim2 API: both order of
15556         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
15557         no delimiter).
15558
15559         * lib/getline.c: Don't include stddef.h or stdio.h, since our
15560         interface does that.
15561         (getline): Always use getdelim, so that we don't have two
15562         copies of this code.
15563         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
15564         if available.
15565         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
15566         (GETNDELIM2_MAXIMUM): New macro.
15567         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
15568         instead of the old practice of delim2==0.  All callers changed.
15569         Return -1 on overflow, instead of returning junk.
15570         Do not set *linesize unless allocation succeeds.
15571         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
15572         that we include sys/types.h.
15573         * lib/getnline.h: Likewise.
15574         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
15575         (getndelim2): Reorder arguments.
15576         * lib/getnline.c (getnline, getndelim):
15577         Don't discard the NMAX argument.
15578         (getnline): Invoke getndelim, to avoid code duplication.
15579         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
15580         of (size_t) -1 by callers of the getnline family.
15581
15582 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15583
15584         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
15585         Check for gettimeofday.
15586         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
15587         Check for settimeofday, stime.
15588
15589 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15590
15591         * lib/nanosleep.c (suspended): Change its type from int to
15592         sig_atomic_t volatile.
15593         (first_call): Make it private to rpl_nanosleep, and have it
15594         be zero initially as that's a bit faster.
15595         (my_usleep): Round up fractional times instead of truncating them,
15596         as this is the usual meaning for 'sleep'.
15597
15598         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
15599         doesn't work.
15600         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
15601         (ENOSYS): Define if not defined.
15602         (settime): Fall back on stime if it exists and settimeofday fails.
15603         But don't bother with fallbacks if a method fails with errno == EPERM.
15604
15605 2004-05-11  Jim Meyering  <jim@meyering.net>
15606
15607         Prior to this change, the save_cwd caller required read access to the
15608         current directory on most systems (ones with the fchdir function).
15609
15610         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
15611         fails, try write-only, and finally, resort to using xgetcwd.
15612
15613 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15614
15615         * lib/obstack.c, obstack.h: Import changes from libc.
15616
15617 2004-04-28  Bruno Haible  <bruno@clisp.org>
15618
15619         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
15620         also implicitly appends .exe to executables.
15621         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
15622         accepts Windows pathnames.
15623         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15624         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15625         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15626         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15627         Reported by Derek Robert Price <derek@ximbiot.com>.
15628
15629 2004-04-21  Karl Berry  <karl@gnu.org>
15630
15631         * config/srclist.txt (localcharset.c): break sync.
15632
15633 2004-04-20  Paul Eggert  <eggert@twinsun.com>
15634
15635         * m4/host-os.m4: Add a copyright notice.
15636
15637 2004-04-20  Jim Meyering  <jim@meyering.net>
15638
15639         Change UTILS_ to gl_ in AC_DEFINE'd names.
15640         Change utils_- and jm_-prefixed variables, too.
15641         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
15642         UTILS_FUNC_MKDIR_TRAILING_SLASH.
15643         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
15644
15645         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
15646         Don't emit trailing blanks.
15647         Also rename jm_-prefixed variables to have gl_ prefix.
15648
15649         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
15650         Also rename jm_-prefixed variables to have gl_ prefix.
15651
15652         * m4/jm-macros.m4: Reflect the renamings.
15653         * m4/prereq.m4: Likewise.
15654
15655 2004-04-20  Jim Meyering  <jim@meyering.net>
15656
15657         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
15658         memory.
15659
15660 2004-04-20  Jim Meyering  <jim@meyering.net>
15661             Bruno Haible  <bruno@clisp.org>
15662
15663         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
15664         memory when realloc fails.
15665
15666 2004-04-19  Jim Meyering  <jim@meyering.net>
15667
15668         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
15669         now that readutmp.c may call `free (0)'.
15670
15671 2004-04-19  Bruno Haible  <bruno@clisp.org>
15672
15673         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
15674         * m4/inttypes_h.m4: Likewise.
15675         * m4/stdint_h.m4: Likewise.
15676         * m4/intmax_t.m4: Likewise.
15677         * m4/uintmax_t.m4: Likewise.
15678
15679 2004-04-18  Jim Meyering  <jim@meyering.net>
15680
15681         * m4/prereq.m4: Don't forbid jm_ prefix.
15682
15683         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
15684         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
15685         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
15686         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
15687         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
15688         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
15689         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
15690         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
15691         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
15692         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
15693         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
15694         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
15695         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
15696         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
15697         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
15698         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
15699         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
15700         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
15701         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
15702
15703 2004-04-18  Jim Meyering  <jim@meyering.net>
15704
15705         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
15706         failure, don't leak memory and do call END_UTMP_ENT.
15707
15708 2004-04-16  Jim Meyering  <jim@meyering.net>
15709
15710         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
15711         coreutils' stat program.
15712         (gl_PREREQ): Don't require jm_PREREQ_STAT.
15713
15714 2004-04-11  Paul Eggert  <eggert@twinsun.com>
15715
15716         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
15717         C89.
15718         (CHAR_BIT): Remove, since we assume C89.
15719         Include <stdint.h> if available, as per current Autoconf CVS advice.
15720
15721 2004-03-31  Jim Meyering  <jim@meyering.net>
15722
15723         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
15724         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
15725         * m4/xalloc.m4: Likewise.
15726
15727 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15728
15729         Merge from coreutils.
15730
15731         * m4/inttostr.m4: New file.
15732         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
15733         Require AM_STDBOOL_H and gl_TIMESPEC instead.
15734         Require gl_CLOCK_TIME.
15735         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
15736
15737 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15738
15739         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
15740         not bool, to be more consistent with Unix conventions.
15741         Suggested by Bruno Haible.
15742
15743         Merge from coreutils.
15744
15745         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
15746         * lib/umaxtostr.c: New files.
15747
15748         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
15749         the usual <time.h> dance.
15750         (get_date): Change signature to support fractional time stamps.
15751         All callers changed.
15752         * lib/getdate.y: Include "getdate.h" first, as we can now
15753         assume C89 and don't need to worry about 'const'.
15754         Similarly, include "unlocked-io.h" near start, not in middle.
15755         Include <limits.h>.
15756         (textint.value): Use long int rather than int.
15757         (textint.digits): Use size_t rather than int.
15758         (BILLION, LOG10_BILLION): New constants.
15759         (parser_control): New member rel_ns.  Members day_ordinal,
15760         time_zone, month, day, hour, minutes, rel_year, rel_month,
15761         rel_day, rel_hour, rel_minutes, rel_seconds
15762         are now long int, not int.  Member seconds is now struct timespec,
15763         not int.  New member timespec_seen.  Members dates_seen, days_seen,
15764         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
15765         not int.
15766         (%union.intval): Now long int, not int.
15767         New member timespec.
15768         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
15769         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
15770         (spec): Now is a timespec or an item list.
15771         (timespec, items): New nonterminals.
15772         (time, rel, relunit, number, get_date):
15773         Add support for fractional seconds.
15774         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
15775         (gmtime, localtime, mktime): Remove decls; not needed with C89.
15776         (to_hour): First arg is now long int, not int.
15777         (to_year): Returns long int, not int.
15778         Don't treat year -70 like 70.
15779         (tm_diff): Returns long int, not int.
15780         (lookup_word): Use bool instead of int when appropriate.
15781         (yylex): Use size_t for count, not int.
15782         Detect overflow when parsing large integer constants.
15783         Add support for fractions.
15784         (get_date): Make pointers 'const' if possible.
15785         Use more-portable code to detect integer overflow.
15786         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
15787         Don't use ctime; it's not reliable if the year has >4 digits.
15788
15789         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
15790         This is for compatibility with BSD.
15791
15792         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
15793         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
15794         From coreutils' system.h.
15795
15796         * lib/userspec.c: Don't include "posixver.h".
15797         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
15798         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
15799         compatible extension.  Simplify code by removing a boolean int
15800         that was always nonzero if a string was nonnull.
15801
15802 2004-03-30  Jim Meyering  <jim@meyering.net>
15803
15804         Merge from coreutils.
15805
15806         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
15807         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
15808         on some systems one must include <grp.h> before it.
15809         Reported by Christian Krackowizer.
15810
15811 2004-03-30  Jim Meyering  <jim@meyering.net>
15812
15813         Merge from coreutils.
15814
15815         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
15816
15817         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
15818         an empty input stream.
15819
15820         * lib/readtokens.c: Include <stdbool.h>.
15821         (readtoken): Use `size_t' rather than int/long.
15822         All callers adjusted.
15823         Use `bool' rather than `int' where appropriate.
15824         Use memset rather than an explicit loop.
15825         Use x2nrealloc rather than xrealloc.
15826         Allow the use of `\0' as a delimiter.
15827         (readtokens): Likewise.
15828         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
15829
15830 2004-03-30  Jim Meyering  <jim@meyering.net>
15831
15832         * m4/realloc.m4: Remove file, since now it does no more than
15833         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
15834         the `configure.ac' section of module/realloc.
15835         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
15836
15837 2004-03-30  Bruno Haible  <bruno@clisp.org>
15838
15839         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
15840         nonnull.
15841
15842 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15843
15844         Merge changes to getloadavg.c from coreutils and Emacs.
15845
15846         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
15847         Define to an expression, not to the empty string.
15848         Include cloexec.h and xalloc.h.
15849         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
15850         Use set_cloexec_flag rather than rolling our own.
15851         * lib/cloexec.c, lib/cloexec.h: New files.
15852
15853 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15854
15855         * m4/cloexec.m4: New file.
15856
15857 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15858
15859         * lib/getopt.h: Sync with libc CVS.
15860
15861 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15862             Bruno Haible  <bruno@clisp.org>
15863
15864         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
15865         mbswidth.
15866
15867 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15868             Bruno Haible  <bruno@clisp.org>
15869
15870         * lib/mbswidth.h: Include <wchar.h> only if
15871         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
15872         <wchar.h>.
15873         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
15874
15875 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15876
15877         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
15878         Sync with libc CVS.
15879         * lib/getopt_int.h: New file, also synced from libc.
15880
15881 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15882
15883         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
15884         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
15885         Bring back getopt.c, getopt.h, getopt1.c.
15886
15887 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15888
15889         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
15890         All uses changed.  Check for sa_sigaction member; this fixes
15891         a bug first reported by Jason Andrade in
15892         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15893
15894 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15895
15896         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
15897         '#if' expressions.  Unlike the code it replaces, it does not
15898         depend on (defined _SC_PAGESIZE).  However, it does depend on
15899         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
15900         first reported by Jason Andrade in
15901         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15902
15903 2004-02-25  Simon Josefsson  <jas@extundo.com>
15904
15905         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
15906
15907 2004-02-25  Simon Josefsson  <jas@extundo.com>
15908
15909         * lib/strdup.h: New file.
15910         * lib/strdup.c: Include it.
15911         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
15912         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
15913
15914 2004-02-23  Karl Berry  <karl@gnu.org>
15915
15916         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
15917         (from fencepost.gnu.org:/gd/gnuorg).
15918
15919 2004-02-23  Karl Berry  <karl@gnu.org>
15920
15921         * config/srclistvars.sh (GNUORG) [karl]: redefine.
15922         * config/srclist.txt: add maintain/standards documents.
15923
15924 2004-02-18  Bruno Haible  <bruno@clisp.org>
15925
15926         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
15927         Reported by Derek Robert Price <derek@ximbiot.com>.
15928
15929 2004-02-16  Karl Berry  <karl@gnu.org>
15930
15931         * config/mkinstalldirs, install-sh: update from automake.
15932
15933 2004-02-06  Karl Berry  <karl@gnu.org>
15934
15935         * m4/po.m4: update from gettext 0.14.1.
15936
15937 2004-02-06  Karl Berry  <karl@gnu.org>
15938
15939         * lib/config.charset: update from gettext 0.14.1.
15940
15941 2004-02-05  Paul Eggert  <eggert@twinsun.com>
15942
15943         Add comments and code, prompted by suggestions from Bruno Haible
15944         for sh-quote.
15945         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
15946         describing the enum quoting_style values.
15947         * lib/quotearg.c (quotearg_alloc): New function.
15948         (quotearg_buffer_restyled): Treat lone { and } as special.
15949         Treat = as special.  Work around bug with older shells
15950         that "see" a '\' that is really the 2nd byte of a multibyte char.
15951         Quote empty string with shell_quoting_style.
15952
15953 2004-02-03  Bruno Haible  <bruno@clisp.org>
15954
15955         * m4/pipe.m4: New file, from GNU gettext.
15956
15957 2004-02-03  Bruno Haible  <bruno@clisp.org>
15958
15959         * lib/pipe.h: New file, from GNU gettext.
15960         * lib/pipe.c: New file, from GNU gettext.
15961
15962 2004-01-27  Bruno Haible  <bruno@clisp.org>
15963
15964         * m4/execute.m4: New file, from GNU gettext.
15965
15966 2004-01-27  Bruno Haible  <bruno@clisp.org>
15967
15968         * lib/execute.h: New file, from GNU gettext.
15969         * lib/execute.c: New file, from GNU gettext.
15970         * lib/w32spawn.h: New file, from GNU gettext.
15971
15972 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15973
15974         Merge from diffutils.
15975
15976         * lib/file-type.c (file_type): Add typed memory objects.
15977         * lib/file-type.h (S_TYPEISTMO): New macro.
15978
15979         * lib/c-stack.h (c_stack_action): Remove argv argument.
15980         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
15981         (die): Don't calculate message unless segv_action returns.
15982         (get_stack_location, min_address_from_argv, max_address_from_argv,
15983         volatile stack_base, volatile_stack_size): Remove.
15984         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
15985         that every segmentation violation is a stack overflow.  (Ouch!)
15986         See Debian bug 136249 (still outstanding) for more info about why
15987         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
15988
15989 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15990
15991         Exit-status fix from coreutils.
15992
15993         Use exit_failure consistently in place of EXIT_FAILURE,
15994         so that program exit statuses are consistent on failure.
15995
15996         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
15997         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
15998         * lib/argmatch.h: Comment fix to match the above.
15999         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
16000         Now a macro referring to exit_failure, instead of a separate
16001         variable.  Include "exitfail.h" to get it.
16002         * lib/xstrtol.h: Include "exitfail.h".
16003         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
16004
16005         * lib/long-options.c (parse_long_options): Use prototype
16006         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
16007         for clarity.
16008
16009 2004-01-21  Jim Meyering  <jim@meyering.net>
16010
16011         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
16012         so as not to conflict with a different-sized __mktime_internal
16013         function in GNU libc.
16014         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
16015         Problem building statically-linked `ls' reported by Michael Brunnbauer.
16016
16017 2004-01-20  Karl Berry  <karl@gnu.org>
16018
16019         * config/config.guess: update from config.
16020
16021         * config/srclistvars.sh: GNUWWWLICENSES for karl.
16022
16023 2004-01-20  Bruno Haible  <bruno@clisp.org>
16024
16025         Safer stack allocation.
16026         * lib/setenv.c: Include allocsa.h.
16027         (alloca): Remove fallback definition.
16028         (freea): Remove macro.
16029         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
16030         instead of freea.
16031
16032 2004-01-20  Bruno Haible  <bruno@clisp.org>
16033
16034         * m4/eealloc.m4: New file, from GNU gettext.
16035
16036 2004-01-20  Bruno Haible  <bruno@clisp.org>
16037
16038         * m4/allocsa.m4: New file, from GNU gettext.
16039
16040 2004-01-20  Bruno Haible  <bruno@clisp.org>
16041
16042         * lib/xallocsa.h: New file, from GNU gettext.
16043         * lib/xallocsa.c: New file, from GNU gettext.
16044
16045 2004-01-20  Bruno Haible  <bruno@clisp.org>
16046
16047         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
16048
16049 2004-01-20  Bruno Haible  <bruno@clisp.org>
16050
16051         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
16052         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
16053         specially.
16054
16055 2004-01-20  Bruno Haible  <bruno@clisp.org>
16056
16057         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
16058         patch.
16059
16060 2004-01-20  Bruno Haible  <bruno@clisp.org>
16061
16062         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
16063
16064 2004-01-20  Bruno Haible  <bruno@clisp.org>
16065
16066         * lib/eealloc.h: New file.
16067
16068 2004-01-20  Bruno Haible  <bruno@clisp.org>
16069
16070         * lib/binary-io.h: Avoid warnings on Cygwin.
16071
16072 2004-01-20  Bruno Haible  <bruno@clisp.org>
16073
16074         * lib/allocsa.h: New file, from GNU gettext.
16075         * lib/allocsa.c: New file, from GNU gettext.
16076
16077 2004-01-18  Karl Berry  <karl@gnu.org>
16078
16079         * doc/gpl.texi, doc/lgpl.texi: new files.
16080
16081 2004-01-18  Karl Berry  <karl@gnu.org>
16082
16083         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
16084         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
16085
16086 2004-01-15  Paul Eggert  <eggert@twinsun.com>
16087
16088         Merge from coreutils.
16089
16090         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
16091         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
16092         (gl_DEFAULT_POSIX2_VERSION): Move
16093         the documentation from 'configure' into 'config.hin',
16094         so that 'configure --help' isn't burdened by it and
16095         we don't have to worry about its formatting there.
16096         Reword the documentation so that it's more succinct
16097         and can be run together into a single paragraph.
16098         * m4/same.m4 (gl_SAME): Check for pathconf.
16099
16100 2004-01-15  Paul Eggert  <eggert@twinsun.com>
16101
16102         Merge from coreutils.
16103
16104         * lib/posixver.c: Include posixver.h.
16105
16106         * lib/same.c: Include <stdbool.h>, <limits.h>.
16107         (_POSIX_NAME_MAX): Define if not defined.
16108         (MIN): New macro.
16109         (same_name): If file names are silently truncated, report
16110         that the file names are the same if they are the same after
16111         the silent truncation.
16112
16113         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
16114         conversion function.
16115         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
16116         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
16117         longer needed.
16118
16119 2004-01-15  Jim Meyering  <jim@meyering.net>
16120
16121         Merge from coreutils.
16122
16123         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
16124         if no library is required.
16125         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
16126         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
16127         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
16128         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
16129         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
16130         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
16131         value, $ac_cv_search_crypt, if it's "none required".
16132         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
16133         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
16134         not gl_FUNC_GETLOADAVG.
16135         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
16136         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
16137
16138 2004-01-15  Jim Meyering  <jim@meyering.net>
16139
16140         Merge from coreutils.
16141
16142         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
16143         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
16144         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
16145
16146         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
16147         optional configure-time default.
16148
16149         * lib/version-etc.c (version_etc_copyright): Update copyright date.
16150
16151         * lib/xreadlink.c (xreadlink): Correct outdated comment.
16152
16153 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
16154
16155         Merge from coreutils.
16156
16157         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
16158         value, $ac_cv_search_nanosleep, if it's "none required".
16159
16160 2004-01-14  Paul Eggert  <eggert@twinsun.com>
16161
16162         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
16163         with like-named macro in fnmatch.c.
16164         (EXT): Use an internal constant instead.
16165
16166         Merge fnmatch patches from glibc.
16167         * lib/fnmatch.c (mbsinit): Remove define.
16168         Add libc_hidden_ver (__fnmatch, fnmatch).
16169         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
16170         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
16171
16172 2004-01-14  Karl Berry  <karl@gnu.org>
16173
16174         * config/install-sh: update from automake.
16175
16176 2004-01-13  Karl Berry  <karl@gnu.org>
16177
16178         * config/install-sh: update from automake.
16179
16180 2004-01-09  Karl Berry  <karl@gnu.org>
16181
16182         * config/install-sh: update from automake.
16183
16184 2004-01-05  Karl Berry  <karl@gnu.org>
16185
16186         * config/config.{sub,guess}: update from config.
16187
16188 2003-12-31  Karl Berry  <karl@gnu.org>
16189
16190         * config/depcomp: update from automake.
16191
16192 2003-12-14  Karl Berry  <karl@gnu.org>
16193
16194         * lib/config.charset: update from gettext-runtime.
16195
16196 2003-12-03  Paul Eggert  <eggert@twinsun.com>
16197
16198         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
16199         Bug reported by Alfred M. Szmidt.
16200
16201 2003-12-03  Bruno Haible  <bruno@clisp.org>
16202
16203         * m4/gettext.m4: Upgrade from gettext-0.13.
16204         * m4/po.m4: Upgrade from gettext-0.13.
16205         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
16206         * m4/intmax.m4: New file, from gettext-0.13.
16207         * m4/printf-posix.m4: New file, from gettext-0.13.
16208
16209 2003-11-29  Karl Berry  <karl@gnu.org>
16210
16211         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
16212
16213 2003-11-25  Paul Eggert  <eggert@twinsun.com>
16214             Bruno Haible  <bruno@clisp.org>
16215
16216         * lib/printf-parse.h: Don't include sys/types.h.
16217         (ARG_NONE): New macro.
16218         (char_directive): Change type of *arg_index fields to size_t.
16219         * lib/printf-parse.c: Don't include sys/types.h.
16220         (SSIZE_MAX): Remove macro.
16221         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
16222         Remove unnecessary overflow check.
16223         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
16224         fields.
16225
16226 2003-11-25  Bruno Haible  <bruno@clisp.org>
16227
16228         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
16229
16230 2003-11-25  Bruno Haible  <bruno@clisp.org>
16231
16232         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
16233         gt_TYPE_SSIZE_T.
16234
16235 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16236
16237         * modules/alloca: Remove dependency on xalloc.
16238
16239 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16240
16241         * lib/alloca.c: Remove dependency on xalloc module.
16242         (xalloc_die): Remove.
16243         (memory_full) [!defined emacs]: New macro.
16244         [!defined emacs]: Don't include xalloc.h.
16245         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
16246         address arithmetic overflows.  Change datatypes a bit to avoid
16247         unnecessary casts.
16248
16249 2003-11-22  Jim Meyering  <jim@meyering.net>
16250
16251         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
16252         s/size/size_t/.
16253
16254 2003-11-21  Karl Berry  <karl@gnu.org>
16255
16256         * config/config.{sub,guess}: update from config.
16257
16258 2003-11-18  Karl Berry  <karl@gnu.org>
16259
16260         * config/config.{sub,guess}: update from config.
16261
16262         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
16263
16264 2003-11-17  Paul Eggert  <eggert@twinsun.com>
16265
16266         * README: Mention that S+T cannot overflow if S is the size of
16267         an existing object and T is sufficiently small.
16268
16269 2003-11-17  Jim Meyering  <jim@meyering.net>
16270
16271         On systems without utime and without a utimes function capable of
16272         dealing with a NULL struct utimbuf* argument, this utime replacement
16273         could -- in unusual circumstances -- leak a file descriptor.
16274         * lib/utime.c: Include <unistd.h> and <errno.h>.
16275         (utime_null): Be sure to close `fd' and to preserve errno.
16276         Reported by Geoff Collyer via Arnold Robbins.
16277
16278 2003-11-17  Bruno Haible  <bruno@clisp.org>
16279
16280         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
16281         (Depends-on): Add xsize.
16282
16283 2003-11-17  Bruno Haible  <bruno@clisp.org>
16284
16285         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
16286
16287 2003-11-17  Bruno Haible  <bruno@clisp.org>
16288
16289         * lib/vasnprintf.c (alloca): Remove fallback definition.
16290         (freea): Remove definition.
16291         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
16292         Reported by Paul Eggert.
16293
16294 2003-11-16  Paul Eggert  <eggert@twinsun.com>
16295             Bruno Haible  <bruno@clisp.org>
16296
16297         Protect against address arithmetic overflow.
16298         * lib/printf-args.h: Include stddef.h.
16299         (arguments): Change type of field 'count' to size_t.
16300         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
16301         'unsigned int' where appropriate.
16302         * lib/printf-parse.h: Include sys/types.h.
16303         (char_directive): Change type of *arg_index fields to ssize_t.
16304         (char_directives): Change type of fields 'count', max_*_length to
16305         size_t.
16306         * lib/printf-parse.c: Include sys/types.h and xsize.h.
16307         (SSIZE_MAX): Define fallback value.
16308         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
16309         instead of 'int' where appropriate. Check a_allocated, d_allocated
16310         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
16311         * lib/vasnprintf.c: Include xsize.h.
16312         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
16313         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
16314         overflow. Avoid wraparound when converting a width or precision from
16315         decimal to binary.
16316
16317 2003-11-16  Bruno Haible  <bruno@clisp.org>
16318
16319         Update from GNU gettext.
16320         * lib/printf-parse.c: Generalize to it can be compiled for wide
16321         strings.
16322         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
16323         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
16324         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
16325         SNPRINTF): New macros.
16326         Don't include <alloca.h> if the file is used inside libintl.
16327         (local_wcslen): New function, for Solaris 2.5.1.
16328         (VASNPRINTF): Use it instead of wcslen.
16329
16330 2003-11-16  Bruno Haible  <bruno@clisp.org>
16331
16332         * lib/xsize.h (xmax): New function.
16333         (xsum, xsum3, xsum4): Declare as "pure" functions.
16334
16335 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16336
16337         * modules/xalloc (Files): Undo latest change, since xalloc.h
16338         no longer needs SIZE_MAX or PTRDIFF_MAX.
16339
16340 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16341
16342         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
16343         gl_PTRDIFF_MAX.
16344
16345 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16346
16347         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
16348         "return", to pacify some unknown compiler.  Problem reported
16349         by Joerg Schilling.
16350
16351 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16352
16353         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
16354         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
16355         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
16356         heuristic is just as accurate as far as we know, and it removes a
16357         dependency on size_max.m4 and ptrdiff_max.m4.
16358
16359 2003-11-11  Bruno Haible  <bruno@clisp.org>
16360
16361         * modules/xsize (Files): Add m4/size_max.m4.
16362         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
16363
16364 2003-11-11  Bruno Haible  <bruno@clisp.org>
16365
16366         * m4/size_max.m4: New file.
16367         * m4/ptrdiff_max.m4: New file.
16368         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
16369         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
16370         (gl_XALLOC): Invoke it.
16371
16372 2003-11-11  Bruno Haible  <bruno@clisp.org>
16373
16374         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
16375         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
16376         defined.
16377
16378 2003-11-10  Paul Eggert  <eggert@twinsun.com>
16379
16380         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
16381         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
16382         rejected some allocations of exactly SIZE_MAX - 2 bytes.
16383         From Bruno Haible.
16384         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
16385         not (size_t) -1, since it's defined here.
16386
16387 2003-11-09  Karl Berry  <karl@gnu.org>
16388
16389         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
16390
16391 2003-11-06  Paul Eggert  <eggert@twinsun.com>
16392
16393         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
16394         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
16395         Reject sizes of exactly SIZE_MAX bytes.
16396         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
16397         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
16398
16399 2003-11-05  Bruno Haible  <bruno@clisp.org>
16400
16401         * lib/xsize.h: Include limits.h, to avoid a possible collision with
16402         SIZE_MAX defined in <limits.h> on Solaris.
16403
16404 2003-11-04  Jim Meyering  <jim@meyering.net>
16405
16406         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
16407         variable names, rather than @VAR@.
16408         * modules/poll: Likewise.
16409
16410 2003-11-04  Bruno Haible  <bruno@clisp.org>
16411
16412         * modules/xsize: New file.
16413         * modules/linebreak: Depend on xsize.
16414         * MODULES.html.sh (func_all_modules): Add xsize.
16415
16416 2003-11-04  Bruno Haible  <bruno@clisp.org>
16417
16418         * m4/xsize.m4: New file.
16419
16420 2003-11-04  Bruno Haible  <bruno@clisp.org>
16421
16422         * lib/xsize.h: New file.
16423         * lib/linebreak.c: Include xsize.h.
16424         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
16425         argument for overflow.
16426         Suggested by Paul Eggert.
16427
16428 2003-11-03  Karl Berry  <karl@gnu.org>
16429
16430         * config/config.{guess,sub}: update from config.
16431
16432 2003-11-03  Jim Meyering  <jim@meyering.net>
16433
16434         * modules/userspec (lib_SOURCES): Add userspec.h.
16435         (Include): Add "userspec.h".
16436         Improve description.
16437
16438 2003-11-03  Jim Meyering  <jim@meyering.net>
16439
16440         * lib/userspec.c: Include "userspec.h".
16441         * lib/userspec.h: New file.
16442
16443 2003-11-03  Bruno Haible  <bruno@clisp.org>
16444
16445         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
16446
16447 2003-11-03  Bruno Haible  <bruno@clisp.org>
16448
16449         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
16450         available, to avoid (extremely rare) race condition.
16451         Suggested by Paul Eggert.
16452
16453 2003-11-02  Karl Berry  <karl@gnu.org>
16454
16455         * config/srclist.txt (vasprintf.c): sync broken, sigh.
16456
16457 2003-10-31  Paul Eggert  <eggert@twinsun.com>
16458
16459         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
16460         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
16461         (read_filesystem_list): Set and use me_type_malloced.
16462         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
16463         whatever the type happens to be), for brevity and consistency.
16464         Check for size calculation overflow on Alphas running OSF/1.
16465
16466 2003-10-31  Jim Meyering  <jim@meyering.net>
16467
16468         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
16469
16470         * lib/linebuffer.c: Include <string.h> for declaration of memset.
16471
16472 2003-10-30  Paul Eggert  <eggert@twinsun.com>
16473             Bruno Haible  <bruno@clisp.org>
16474
16475         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
16476         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
16477
16478 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16479
16480         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
16481         netbsd*-gnu*.  Suggested by Robert Millan.
16482
16483 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16484
16485         * modules/group-member: Depend on stdbool.
16486
16487 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16488
16489         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
16490
16491 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16492
16493         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
16494         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
16495         after the 'gnu' in these cases.  This fixes some bugs in the
16496         previous change, and is based on suggestions by Robert Millan.
16497
16498 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16499
16500         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
16501         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
16502         no longer needed.
16503         * lib/quotearg.c (quotearg_n_options): Use it.
16504         * lib/group-member.c: Include <stdbool.h>.
16505         (free_group_info): Arg is now const *; don't free arg.
16506         (get_group_info): Now returns bool and accepts struct group_info *,
16507         rather than returning a malloc'ed struct group_info *.
16508         All uses changed.  Check for overflow in internal size calculation.
16509
16510         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
16511         rather than xmalloc/xrealloc.
16512         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
16513         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
16514         conformance bug: the old code used a pointer after freeing the
16515         storage that it addressed.
16516         * lib/hash.c (hash_initialize): Simplify the code by using
16517         xalloc_oversized rather than doing it by hand.
16518         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
16519         the buffer preserved.  Use free and xmalloc instead.
16520         * lib/quotearg.c (quotearg_n_options): Likewise.
16521         Use a simpler test for size overflow.  Don't use xalloc_oversized
16522         because unsigned int might be wider than size_t (!); this suggests
16523         that we should switch from unsigned int to size_t for slot numbers.
16524
16525 2003-10-28  Paul Eggert  <eggert@twinsun.com>
16526
16527         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
16528         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
16529         NetBSD kernels.  Requested by Richard Stallman.
16530
16531 2003-10-27  Paul Eggert  <eggert@twinsun.com>
16532
16533         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
16534         to allocate the returned structure.  Do not allocate a subarray,
16535         as x2nrealloc will do that.
16536         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
16537         instead of xnrealloc.
16538         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
16539
16540 2003-10-27  Bruno Haible  <bruno@clisp.org>
16541
16542         * lib/stdbool_.h: Better support for BeOS.
16543
16544 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16545
16546         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
16547         now uses inline.
16548
16549 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16550
16551         * lib/xalloc.h (xalloc_oversized): New static inline function, for
16552         callers that want to do their own size-overflow checking.  Include
16553         <stdbool.h>, since xalloc_oversized returns bool.
16554         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
16555         to use xalloc_oversized.
16556
16557         Add two functions x2realloc, x2nrealloc, for programs that grow
16558         arrays dynamically by doubling their sizes.
16559         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
16560         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
16561         New functions.
16562
16563         Port to C99 semantics for 'inline' of external functions.
16564         Bug reported by Bruno Haible.
16565         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
16566         with the old contents of xnmalloc.
16567         (xnmalloc, xmalloc): Use it.
16568         (xnrealloc_inline): New static inline function,
16569         with the old contents of xnrealloc.
16570         (xnrealloc, xrealloc): Use it.
16571
16572         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
16573         that.
16574
16575 2003-10-26  Karl Berry  <karl@gnu.org>
16576
16577         * config/srclist.txt (COPYING.DOC): no longer available from
16578         /gd/gnuorg; don't know where the ultimate source is.
16579
16580 2003-10-25  Paul Eggert  <eggert@twinsun.com>
16581
16582         Fix several address-calculation bugs in the hash modules,
16583         plus some minor code cleanup.
16584
16585         * lib/hash.h: Include <stdbool.h>, for bool.
16586         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
16587         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
16588         hash_get_n_entries, hash_get_max_bucket_length,
16589         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
16590         hash_rehash): Use size_t rather than unsigned.
16591         * lib/hash.c (struct hash_table, hash_get_n_buckets,
16592         hash_get_n_buckets_used, hash_get_n_entries,
16593         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
16594         hash_get_entries, hash_do_for_each, hash_string, is_prime,
16595         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
16596         Likewise.
16597         (SIZE_MAX): Define if not defined.
16598         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
16599         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
16600         hash_print):
16601         Use const * when possible.
16602         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
16603         (check_tuning): Fix bug: if tuning parameters were very close to
16604         0 or 1, rounding errors could have caused subscript violations.
16605         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
16606         (hash_initialize): Add 'fail:' label
16607         to free table and return NULL, and use it to simplify code.
16608         Use calloc rather than clearing the storage ourself.
16609         (hash_initialize, hash_rehash): Check for arithmetic overflow in
16610         buffer size calculations.
16611         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
16612         Include <stddef.h>, for size_t.
16613         * lib/hash-pjw.c (hash_pjw): Likewise.
16614         Switch to method described by Bruno Haible.
16615         Include <limits.h>, for CHAR_BIT.
16616         (SIZE_BITS): New macro.
16617
16618 2003-10-23  Paul Eggert  <eggert@twinsun.com>
16619
16620         * m4/getline.m4 (AM_FUNC_GETLINE):
16621         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
16622         hosts.  Problem reported by Derek Robert Price in
16623         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
16624         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
16625         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
16626
16627 2003-10-21  Paul Eggert  <eggert@twinsun.com>
16628
16629         * lib/getndelim2.c (getndelim2): When size calculation overflows,
16630         ceiling the allocation at NMAX bytes rather than silently
16631         discarding input bytes before NMAX is reached.  This makes
16632         a difference only if NMAX exceeds SIZE_MAX / 2.
16633
16634         * lib/obstack.c: Merge from glibc.
16635         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
16636         Add libc_hidden_def (_obstack_newchunk).
16637         (_obstack_free) [! defined _LIBC]: Remove.
16638         [defined _LIBC]: Make a strong alias from obstack_free, rather than
16639         a clone of the function body.
16640         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
16641         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
16642
16643         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
16644         glibc.
16645         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
16646         arg to memcpy.
16647
16648         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
16649         (obstack_ptr_grow_fast, obstack_int_grow_fast):
16650         Don't use lvalue casts, as GCC plans to remove support for them
16651         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
16652         was also present in the non-GCC version, indicating that this
16653         code had always been buggy and had never been widely used.
16654         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
16655         Use the fast variant of each macro, rather than copying the
16656         definiens of the fast variant; that way, we'll be more likely to
16657         catch future bugs in the fast variants.
16658
16659 2003-10-20  Bruno Haible  <bruno@clisp.org>
16660
16661         * modules/wait-process: New file.
16662         * MODULES.html.sh (func_all_modules): Add wait-process.
16663
16664 2003-10-20  Bruno Haible  <bruno@clisp.org>
16665
16666         * m4/wait-process.m4: New file.
16667
16668 2003-10-20  Bruno Haible  <bruno@clisp.org>
16669
16670         * lib/wait-process.h: New file, from GNU gettext.
16671         * lib/wait-process.c: New file, from GNU gettext.
16672
16673 2003-10-19  Jim Meyering  <jim@meyering.net>
16674
16675         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
16676         HPUX 10.20.
16677
16678 2003-10-18  Karl Berry  <karl@gnu.org>
16679
16680         * config/config.guess: update from config.
16681
16682 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16683
16684         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
16685         (getgroups): First arg is int, not size_t.
16686         Don't let 'free' mangle errno.
16687
16688 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16689
16690         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
16691
16692 2003-10-16  Karl Berry  <karl@gnu.org>
16693
16694         * config/config.{guess,sub}: update from config.
16695
16696 2003-10-16  Jim Meyering  <jim@meyering.net>
16697
16698         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
16699         memcpy.
16700
16701 2003-10-15  Paul Eggert  <eggert@twinsun.com>
16702
16703         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
16704         (SIZE_MAX): Remove.
16705         (new_exclude, add_exclude_file): Initial size no longer needs to
16706         be a power of 2.
16707         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
16708         our own address arithmetic overflow checking.
16709
16710         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
16711         (fnmatch): Do not alloca more than 2000 wide characters;
16712         instead, use malloc for large buffers.
16713         Check for address arithmetic overflow, and return -1
16714         with errno set to ENOMEM in that case.
16715         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
16716         (NEW_PATTERN): Do not alloca more than 8000 bytes;
16717         instead, return -1.  Check for address arithmetic overflow.
16718
16719 2003-10-14  Paul Eggert  <eggert@twinsun.com>
16720
16721         Handle invalid suffixes and overflow independently, so that
16722         callers can treat them independently as needed.  Fix some bugs in
16723         suffix handling, e.g., "100k@" was not diagnosed as an invalid
16724         suffix for a human-readable blocksize.  The major caller-visible
16725         change is the addition of a new
16726         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
16727         that both overflow and suffix chars were found.
16728
16729         * lib/human.c (humblock): Don't check separately for invalid suffix
16730         char; that is xstrtoumax's job (now that its bug is fixed).
16731         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
16732         INTMAX_MAX]: New macros.
16733         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
16734         TYPE_MAXIMUM): New macros.
16735         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
16736         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
16737         if overflow occurs, as it's what __strtol does and it's more useful
16738         in practice.
16739         (__xstrtol): If __strtol reports some error other than ERANGE,
16740         reflect it to the caller as LONGINT_INVALID.  If it reports
16741         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
16742         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
16743         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
16744         value.
16745         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
16746         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
16747         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
16748         [defined UINTMAX_MAX]: New macros.
16749
16750 2003-10-14  Bruno Haible  <bruno@clisp.org>
16751
16752         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
16753
16754 2003-10-14  Bruno Haible  <bruno@clisp.org>
16755
16756         * m4/sig_atomic_t: New file, from GNU gettext.
16757         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
16758
16759 2003-10-14  Bruno Haible  <bruno@clisp.org>
16760
16761         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
16762         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
16763         Also use volatile where needed.
16764
16765 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16766
16767         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
16768         Change maintainer from Bruno Haible to 'all'.
16769
16770 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16771
16772         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
16773
16774 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16775
16776         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
16777         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
16778         and define in terms of the other primitives.
16779         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
16780         (SIZE_MAX): Define if not already defined.
16781         (array_size_overflow): New function.
16782         (xalloc_die): Abort instead of exiting if 'error' returns.
16783         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
16784         (xmalloc, xrealloc): Use them.
16785         (xcalloc): Check for address arithmetic overflow.
16786         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
16787         a bit faster than strcpy.
16788
16789 2003-10-10  Simon Josefsson  <jas@extundo.com>
16790
16791         * modules/argp (Depends-on): Add restrict and strcase.
16792
16793 2003-10-10  Simon Josefsson  <jas@extundo.com>
16794
16795         * m4/argp.m4: Add AC_C_INLINE.
16796
16797 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16798
16799         Merge getpass from libc, plus a few fixes.
16800
16801         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
16802         Include <stdbool.h>.
16803         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
16804         __fsetlocking to empty.
16805         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
16806         do include <bits/libc-lock.h>.
16807         Do not include <fcntl.h>; not needed.
16808         [_LIBC]: Include <wchar.h>.
16809         (NOTCANCEL_MODE): New macro.
16810         (flockfile, funlockfile) [_LIBC]: New macros.
16811         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
16812         [!_LIBC]: New macros.
16813         (call_fclose): New function.
16814         (getpass): Use it.  Save tty stream separately; this simplifies the
16815         code and makes it more reliable if stdin happens to equal stdout.
16816         Invoke __fsetlocking on tty.
16817         Handle thread cancellation if needed.
16818         Namespace cleanup (use __tcgetattr, __getline).
16819         Use bool for Booleans.
16820         [USE_IN_LIBIO]: Handle wide streams.
16821         [!_LIBC]: Unconditionally do the fseek, since we don't know what
16822         stream might go where.
16823
16824         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
16825         doesn't have to include <stdio.h> before us.
16826         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
16827         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
16828         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
16829         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
16830         if not declared, so that we can use getpass.c code from libc without
16831         rewriting it.
16832         (flockfile, ftrylockfile, funlockfile): New macros.
16833
16834 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16835
16836         * modules/getpass: Depend on stdbool.
16837
16838 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16839
16840         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
16841
16842 2003-10-07  Karl Berry  <karl@gnu.org>
16843
16844         * config/config.{guess,sub}: update from config.
16845
16846 2003-10-06  Jim Meyering  <jim@meyering.net>
16847             Bruno Haible  <bruno@clisp.org>
16848
16849         This lets translators provide better translations for the
16850         "Written by ..." part of --version output.
16851         * lib/version-etc.h: Include stdarg.h.
16852         (version_etc_copyright): Declare as readonly.
16853         (version_etc): Make this function variadic with a NULL-terminated list
16854         of author name strings.
16855         (version_etc_va): New declaration.
16856         * lib/version-etc.c: Include stdarg.h, stdlib.h.
16857         (version_etc_copyright): Declare as readonly.
16858         (version_etc_va): New function. Provide a different translatable string
16859         for each possible number of authors < 10. Abbreviate when there are 10
16860         authors or more.
16861         (version_etc): Make this function variadic. Call version_etc_va.
16862         Suggestion from Gary V. Vaughan.
16863
16864         * lib/long-options.h (parse_long_options): Change prototype: the
16865         authors string is moved to the end and becomes variadic.
16866         * lib/long-options.c: Include stdarg.h.
16867         (parse_long_options): Make this function variadic, too.
16868         Call version_etc_va, not version_etc.
16869
16870 2003-10-06  Bruno Haible  <bruno@clisp.org>
16871
16872         * modules/version-etc-2: Remove file.
16873         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
16874
16875 2003-10-06  Bruno Haible  <bruno@clisp.org>
16876
16877         * modules/fatal-signal: New file.
16878         * MODULES.html.sh (func_all_modules): Add fatal-signal.
16879
16880 2003-10-06  Bruno Haible  <bruno@clisp.org>
16881
16882         * m4/fatal-signal.m4: New file.
16883         * m4/signalblocking.m4: New file, from GNU gettext.
16884
16885 2003-10-06  Bruno Haible  <bruno@clisp.org>
16886
16887         * lib/version-etc-2.h: Remove file.
16888         * lib/version-etc-2.c: Remove file.
16889
16890 2003-10-06  Bruno Haible  <bruno@clisp.org>
16891
16892         * lib/fatal-signal.h: New file, from GNU gettext.
16893         * lib/fatal-signal.c: New file, from GNU gettext.
16894
16895 2003-10-05  Paul Eggert  <eggert@twinsun.com>
16896
16897         * README: Rework advice for preventing empty .o files.
16898         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
16899         not <sys/types.h>.
16900
16901 2003-10-04  Karl Berry  <karl@gnu.org>
16902
16903         * lib/argp*: update from libc.
16904
16905 2003-10-04  Karl Berry  <karl@gnu.org>
16906
16907         * config/config.{guess,sub}: update from config.
16908
16909 2003-10-02  Bruno Haible  <bruno@clisp.org>
16910
16911         * modules/lchown (Include): Add lchown.h.
16912         * modules/time_r (Include): Use "..." syntax.
16913         * modules/xgetdomainname (Include): Add xgetdomainname.h.
16914
16915 2003-10-01  Simon Josefsson  <jas@extundo.com>
16916
16917         * MODULES.html.sh (func_all_modules): Move gethostname from section
16918         'based on' to section 'lacking' POSIX:2001.
16919
16920 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
16921
16922         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
16923         to output mode on the same stream.
16924
16925 2003-09-29  Paul Eggert  <eggert@twinsun.com>
16926
16927         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
16928         Fix arg typo in previous patch.
16929
16930 2003-09-28  Jim Meyering  <jim@meyering.net>
16931
16932         * lib/error.c: Correct cpp indentation.
16933
16934 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16935
16936         * modules/free: New file.
16937
16938 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16939
16940         * m4/free.m4: New file.
16941
16942 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16943
16944         * lib/minmax.h (MIN, MAX)
16945         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
16946         Omit the special code that used __typeof__, since we worry that
16947         it could be more trouble than it's worth.  See:
16948         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
16949         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
16950
16951         * lib/free.c: New file.
16952
16953 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
16954
16955         Trivial fixes to Makefile.am parts of module listings.
16956         * modules/strstr: Append strstr.h to lib_SOURCES.
16957         * modules/strcase: Likewise, for strcase.h.
16958
16959 2003-09-27  Karl Berry  <karl@gnu.org>
16960
16961         * config/mkinstalldirs: update from automake.
16962
16963 2003-09-26  Paul Eggert  <eggert@twinsun.com>
16964
16965         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
16966         (error_tail): Do not loop, reallocating temporary buffer, since
16967         the output cannot contain more wide characters than the input
16968         contains bytes, the size must be big enough already.  This avoids
16969         one potential size overflow calculation.  Check for size overflow
16970         when calculating temporary buffer size.  Free temporary buffer
16971         when done, if it was allocated with malloc; this plugs a memory
16972         leak.  Remove casts from void * to pointers, that are no longer
16973         needed now that we're assuming C89 or better.
16974
16975         Merge error changes from glibc.
16976
16977         * lib/error.c, error.h: Update copyright notice header to match glibc.
16978         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
16979         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
16980         Disable cancellation while printing error.
16981         * lib/error.h: Prepend __ to parameter names.
16982
16983 2003-09-26  Jim Meyering  <jim@meyering.net>
16984
16985         * lib/error.c (error_tail): Move some declarations
16986         into inner scope where the local variables are used.
16987
16988 2003-09-26  Bruno Haible  <bruno@clisp.org>
16989
16990         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
16991         stpncpy().
16992         Don't define stpncpy through config.h; it's now done through stpncpy.h.
16993
16994 2003-09-26  Bruno Haible  <bruno@clisp.org>
16995
16996         * lib/stpncpy.h (gnu_stpncpy): New declaration.
16997         (stpncpy): Define as alias for gnu_stpncpy.
16998         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
16999
17000 2003-09-25  Simon Josefsson  <jas@extundo.com>
17001
17002         * lib/xgetdomainname.h: New file.
17003         * lib/xgetdomainname.c: New file.
17004
17005 2003-09-25  Simon Josefsson  <jas@extundo.com>
17006             Bruno Haible  <bruno@clisp.org>
17007
17008         * modules/getdomainname: New file.
17009         * modules/xgetdomainname: New file.
17010         * MODULES.html.sh (func_all_modules): Add getdomainname,
17011         xgetdomainname.
17012
17013 2003-09-25  Simon Josefsson  <jas@extundo.com>
17014             Bruno Haible  <bruno@clisp.org>
17015
17016         * m4/getdomainname.m4: New file.
17017
17018 2003-09-25  Simon Josefsson  <jas@extundo.com>
17019             Bruno Haible  <bruno@clisp.org>
17020
17021         * lib/getdomainname.h: New file.
17022         * lib/getdomainname.c: New file.
17023
17024 2003-09-25  Karl Berry  <karl@gnu.org>
17025
17026         * lib/argp-fmtstream.c, argp-help.c: update from libc.
17027
17028 2003-09-25  Karl Berry  <karl@gnu.org>
17029
17030         * config/install-sh: update from automake.
17031
17032 2003-09-25  Bruno Haible  <bruno@clisp.org>
17033
17034         * modules/version-etc-2: New file, from modules/version-etc with
17035         modifications.
17036         * MODULES.html.sh (func_all_modules): Add version-etc-2.
17037
17038 2003-09-25  Bruno Haible  <bruno@clisp.org>
17039
17040         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
17041         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
17042
17043 2003-09-24  Simon Josefsson  <jas@extundo.com>
17044
17045         * modules/xgethostname: Add xgethostname.h.
17046
17047 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17048
17049         * lib/linebuffer.c (freebuffer): Don't free the argument, just
17050         the buffer associated with the argument.  Bug reported by
17051         Simon Josefsson.
17052
17053 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17054
17055         * README: Document assumptions that 'int' is at least 32 bits
17056         wide, that integer arithmetic is 2's complement without overflow,
17057         that there are no holes in integer values, that adding sizes of
17058         two nonoverlapping objects can't overflow, and that all-bits-zero
17059         yields scalar zero.  Fix spelling and capitalization typos.
17060
17061 2003-09-19  Karl Berry  <karl@gnu.org>
17062
17063         * lib/argp.h: update from libc.
17064
17065 2003-09-17  Paul Eggert  <eggert@twinsun.com>
17066
17067         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
17068         to avoid spurious warnings like "AC_RUN_IFELSE was called before
17069         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
17070
17071 2003-09-17  Paul Eggert  <eggert@twinsun.com>
17072
17073         * gnulib-tool: Use "test -h", not "test -L", for portability
17074         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
17075         (tags_regexp): Remove, since \| doesn't conform to POSIX.
17076         (sed_extract_prog): Issue s commands one-by-one, rather than
17077         using \| in one s command.
17078
17079 2003-09-16  Paul Eggert  <eggert@twinsun.com>
17080
17081         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
17082         input error, instead of returning NULL the next time we are called
17083         (and therefore losing track of errno).
17084
17085 2003-09-16  Bruno Haible  <bruno@clisp.org>
17086
17087         * gnulib-tool (func_create_testdir): Warn about duplicated
17088         dependencies.
17089
17090 2003-09-15  Paul Eggert  <eggert@twinsun.com>
17091
17092         * modules/argmatch, modules/fatal, modules/obstack,
17093         modules/xalloc, modules/xgethostname: Sort dependencies by
17094         importance, not alphabetically.
17095
17096 2003-09-15  Paul Eggert  <eggert@twinsun.com>
17097
17098         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
17099         fails, so that the caller gets the proper errno.
17100
17101         * lib/readutmp.c (read_utmp): Likewise.
17102         Check for fstat error.  Close stream and free storage
17103         when failing.
17104
17105 2003-09-14  Karl Berry  <karl@gnu.org>
17106
17107         * config/srclist.txt (strdup.c): disable for c89 changes.
17108
17109 2003-09-14  Jim Meyering  <jim@meyering.net>
17110
17111         * lib/getloadavg.c: Correct cpp indentation.
17112         * lib/strdup.c: Likewise.
17113         * lib/vasnprintf.c: Likewise.
17114
17115 2003-09-14  Bruno Haible  <bruno@clisp.org>
17116
17117         * modules/fwriteerror: New file.
17118         * MODULES.html.sh (func_all_modules): Add fwriteerror.
17119
17120 2003-09-14  Bruno Haible  <bruno@clisp.org>
17121
17122         * lib/fwriteerror.h: New file.
17123         * lib/fwriteerror.c: New file.
17124
17125 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17126
17127         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
17128         modules/xgethostname, modules/xalloc: Depend on exit.
17129
17130 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17131
17132         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
17133
17134         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
17135         and AC_MINIX, too, so that their extensions are available.
17136
17137         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
17138         This macro has been superseded by gl_BACKUPFILE.
17139
17140         More patches to assume C89 or better.
17141
17142         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
17143
17144         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
17145         unconditionally.
17146         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
17147         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
17148         Include <string.h>, <stdlib.h> unconditionally.
17149         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
17150         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
17151         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
17152         headers or for string.h.
17153         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
17154         or strtoul.
17155
17156         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
17157         headers.
17158         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
17159         * m4/userspec.m4 (gl_USERSPEC): Likewise.
17160         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
17161         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
17162         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
17163         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
17164         memcpy, memset.
17165         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
17166         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
17167         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
17168         strtol.
17169         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
17170         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
17171         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
17172         strtoul.
17173
17174 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17175
17176         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
17177         * lib/obstack.c [!defined _LIBC]: Likewise.
17178         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
17179         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
17180         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
17181
17182         More changes to assume C89 or better.
17183
17184         * lib/error.c (error_tail): Assume vprintf.
17185
17186         * lib/argmatch.c (getenv): Remove decl.
17187         * lib/progreloc.c (get_full_program_name): Define via prototype.
17188         * lib/setenv.c (clearenv): Likewise.
17189         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
17190         needed.
17191         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
17192         (malloc, memcpy): Remove decls.
17193         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
17194         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
17195         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17196         (memcpy): Remove macro.
17197         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
17198         (__P): Remove.  All uses removed.
17199         (PTR): Remove.  All uses changed to void *.
17200         (CHAR_BIT, NULL): Remove.
17201         (spaces, zeros, memset_space, memset_zero)
17202         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
17203         Remove.
17204         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
17205         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
17206         Define with prototype.
17207         Remove now-unnecessary prototype decl.
17208         (extra_args_spec): Assume ANSI C.  All uses changed.
17209         (extra_args_spec_iso): Remove.
17210         (my_strftime, emacs_strftimeu): Define via prototype.
17211         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
17212         unconditionally.
17213         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
17214         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
17215         (strtoul, strtol): Remove decls.
17216         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
17217         LONG_MAX): Remove.
17218         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17219         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
17220         (LOCALE_PARAM_PROTO): New macro.
17221         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
17222         (INTERNAL (strtol), strtol): Define with a prototype.
17223         (PARAMS): Remove.  All uses removed.
17224         * lib/tempname.c: Include <string.h> unconditionally.
17225         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
17226         * lib/xgethostname.c (main): Define with a prototype.
17227         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
17228         Include <stdlib.h> unconditionally.
17229         (calloc, malloc, realloc, free): Remove decls.
17230         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
17231         Include <stdlib.h> unconditionally.  Sort include file names.
17232         (strtod): Remove.
17233         (xstrtod): Define with a prototype.
17234         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
17235         (strtol, strtoul): Remove decls.
17236
17237 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17238
17239         More patches to assume C89 or better.
17240         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
17241         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
17242         string.h, memchr, STDC_HEADERS.
17243
17244 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17245
17246         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
17247         Include <stdlib.h>, <string.h> unconditionally.
17248         Remove now-unnecessary cast to char *.
17249         * lib/strnlen.c: Include <string.h> unconditionally.
17250         * lib/yesno.c (yesno): Define with a prototype.
17251
17252 2003-09-11  Bruno Haible  <bruno@clisp.org>
17253
17254         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
17255
17256 2003-09-10  Jim Meyering  <jim@meyering.net>
17257
17258         * lib/error.c: Correct indentation of cpp directives.
17259
17260 2003-09-10  Bruno Haible  <bruno@clisp.org>
17261
17262         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
17263         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
17264         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
17265         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
17266         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
17267         <stdlib.h> and <string.h> checks.
17268         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
17269         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
17270
17271 2003-09-10  Bruno Haible  <bruno@clisp.org>
17272
17273         * lib/strcspn.c: Include <string.h> unconditionally.
17274         * lib/strpbrk.c: Include <string.h> unconditionally.
17275         * lib/strstr.c: Include <string.h> unconditionally.
17276         * lib/unicodeio.c: Include <string.h> unconditionally.
17277         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
17278         * lib/unsetenv.c: Likewise.
17279         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
17280         * lib/yesno.c: Include <stdlib.h> unconditionally.
17281         (rpmatch): Add prototype.
17282
17283 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17284
17285         More patches to assume C89 or better.
17286         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
17287         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
17288         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
17289         or for string.h.
17290         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
17291         stdlib.h.
17292         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
17293         C headers.
17294         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
17295         string.h.
17296         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
17297         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
17298         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
17299         or for string.h.
17300         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
17301         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
17302         C headers.
17303         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
17304         memcpy.
17305         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
17306         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
17307         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
17308         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
17309         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
17310         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
17311         string.h, free.
17312         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
17313         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
17314         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
17315         C headers, or for string.h.
17316         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
17317         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
17318         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
17319         headers, memory.h, stdlib.h, string.h, strings.h.
17320         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
17321         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
17322         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
17323         strchr.
17324         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
17325         headers, memory.h, string.h.
17326         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
17327         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
17328         free.
17329         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
17330         headers.
17331         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
17332         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
17333         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
17334         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
17335         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
17336
17337 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17338
17339         More K&R removal.
17340
17341         * lib/acosl.c (main): Use a prototype.
17342         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
17343         tanl.c: Likewise.
17344
17345         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
17346
17347         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
17348         (getopt, etopt_long, getopt_long_only, _getopt_internal)
17349         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
17350         with a prototype.
17351         * lib/getopt.c (const): Remove macro.
17352         Include <string.h> unconditionally.
17353         (my_index): Remove; all uses changed to strchr.
17354         (strlen): Remove decl.
17355         (exchange): Remove forward decl; no longer needed.
17356         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
17357         Define with prototype.
17358         * lib/getopt1.c (const): Remove macro.
17359         (getopt_long, getopt_long_only, main): Define with prototype.
17360
17361         * lib/getugroups.c: Include <string.h> unconditionally.
17362
17363         * lib/getusershell.c: Include <stdlib.h> unconditionally.
17364         (getusershell, setusershell, endusershell, readname, main):
17365         Define with prototypes.
17366
17367         * lib/group-member.c: Include group-member.h first.
17368         Include <stdlib.h> unconditionally.
17369
17370         * lib/hard-locale.c: Include hard-locale.h first.
17371         Include <stdlib.h>, <string.h> unconditionally.
17372
17373         * lib/hash.c (free, malloc): Remove decls.
17374         Include <stdlib.h> unconditionally.
17375
17376         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
17377         (getenv): Do not declare.
17378
17379         * lib/idcache.c: Include <string.h> unconditionally.
17380
17381         * lib/long-options.c: Include long-options.h first, to test interface.
17382         Include <stdlib.h> unconditionally.
17383
17384         * lib/makepath.c: Include makepath.h first, to test interface.
17385         Include <stdlib.h> and <string.h> unconditionally.
17386
17387         * lib/linebuffer.c: Include <stdlib.h>.
17388         (free): Remove decl.
17389
17390         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
17391         stddef.h. rpl_malloc returns void *, not char *.
17392         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
17393         prototype.
17394
17395         * lib/md5.h: Include <limits.h> unconditionally.
17396         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
17397         (__P): Remove; all uses removed.
17398         * lib/md5.c: Include "md5.h" first.
17399         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
17400         md5_buffer, md5_process_bytes, md5_process_block):
17401         Define with prototypes.
17402         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
17403         * lib/sha.c: Include "sha.h" first.
17404         Include <stdlib.h>, <string.h> unconditionally.
17405
17406         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
17407         * lib/memcmp.c (__ptr_t): Likewise.
17408         * lib/memrchr.c (__ptr_t): Likewise.
17409         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
17410         Include <string.h> unconditionally.
17411         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
17412         * lib/memchr.c: Include <stdlib.h> unconditionally.
17413         * lib/memchr.c (LONG_MAX): Remove.
17414         * lib/memrchr.c (LONG_MAX): Likewise.
17415         * lib/memchr.c (__memchr): Define via a prototype.
17416         * lib/memrchr.c (__memrchr): Likewise.
17417         * lib/memcmp.c (__P): Remove, and remove all uses.
17418         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
17419         Remove forward decls; no longer needed.
17420         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
17421         Use types required by C89 in prototype.
17422
17423         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
17424         * lib/savedir.c: Likewise.
17425         * lib/mkdir.c (free): Remove decl.
17426         * lib/rmdir.c (rmdir): Define with a prototype.
17427         * lib/savedir.c: Include savedir.h first, to test interface.
17428
17429         * lib/mktime.c (STDC_HEADERS): Remove.
17430         Include <stdlib.h>, <string.h> unconditionally.
17431
17432         * lib/modechange.c: Include <stdlib.h> unconditionally.
17433         (malloc): Remove decl.
17434
17435         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
17436         (free): Remove decl.
17437
17438         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
17439         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
17440         (This type really should be intptr_t, but that's a C99ism.)
17441         (_obstack_memcpy): Remove: all uses changed to memcpy.
17442         Include <string.h> unconditionally.
17443         (struct obstack): Assume __STDC__ for types of members
17444         chunkfun, freefun, extra_arg.
17445         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
17446         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
17447         obstack_begin, obstack_specify_allocation,
17448         obstack_specify_allocation_with_arg, obstack_chunkfun,
17449         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
17450         Remove unprototyped decls and the macros that use them.
17451         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
17452         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
17453         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
17454         (defined __STDC__ && __STDC__)]:
17455         Remove nonprototyped code.
17456         Include <stdlib.h> unconditionally.
17457         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
17458         _obstack_allocated_p, _obstack_free, obstack_free,
17459         _obstack_memory_used, print_and_abort):
17460         Define using prototypes.
17461         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
17462         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
17463         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
17464         obstack_next_free, obstack_object_size, obstack_room) [0]:
17465         Remove unused, unprototyped code.
17466
17467         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
17468
17469         * lib/physmem.c (physmem_total, physmem_available, main): Define
17470         with prototypes.
17471
17472         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
17473         (main): Define with a prototype.
17474
17475         * lib/posixver.c (getenv): Remove decl.
17476
17477         * lib/putenv.c (malloc): Returns void *, not char *.
17478         Include <string.h> unconditionally.
17479         (strchr, memcpy, NULL): Do not define.
17480
17481         * lib/readtokens.c: Include readtokens.h first, to test interface.
17482         Include <stdlib.h>, <string.h> unconditionally.
17483         (init_tokenbuffer): Define with a prototype.
17484
17485         * lib/regex.c (PARAMS): Remove.  All uses removed.
17486         All uses of _RE_ARGS removed, too.
17487         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17488         unconditionally.
17489         (bzero): Assume memset exists.
17490         (memcmp, memcpy, NULL): Remove.
17491         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
17492         char, or assignments to local vars of type signed char.
17493         (init_syntax_once, PREFIX(extract_number_and_incr),
17494         PREFIX(print_partial_compiled_pattern),
17495         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
17496         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
17497         PREFIX(regex_grow_registers), PREFIX(regex_compile),
17498         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
17499         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
17500         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
17501         wcs_compile_range, byte_compile_range, truncate_wchar,
17502         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
17503         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
17504         count_mbs_length, wcs_re_match_2_internal,
17505         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
17506         PREFIX(alt_match_null_string_p),
17507         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
17508         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
17509         regfree, PREFIX(extract_number)): Define with prototype.  Remove
17510         now-unnecessary declaration, if any.
17511         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
17512         regcomp, regexec):
17513         Remove now-unnecessary casts among pointer types.
17514         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
17515
17516         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
17517         (free): Remove decl.
17518
17519         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
17520
17521         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
17522         (free): Remove decl.
17523
17524         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
17525         * lib/xgetcwd.c: Likewise.
17526
17527         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
17528         (free): Remove decl.
17529
17530         * lib/strchrnul.c (strchrnul): Define with a prototype.
17531         Fix bug: c_in was not converted to char before searching.
17532
17533         The following changes are not K&R related:
17534
17535         * lib/group-member.h: Include <sys/types.h>, so that this file is
17536         self-contained.
17537         * lib/makepath.h: Likewise.
17538
17539         * lib/getusershell.c (readname, default_index, line_size, readname):
17540         Use size_t, not int, for sizes.
17541         (readname): If the size overflows, report an error instead of
17542         looping forever.
17543
17544 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17545
17546         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
17547         libc.
17548
17549 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17550
17551         * README: New section: portability guidelines.
17552
17553 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17554
17555         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
17556         C89 spec.
17557
17558 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17559
17560         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
17561
17562 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17563
17564         Assume C89 or better; remove K&R cruft.
17565         A few of these changes were first proposed by Derek Robert Price
17566         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
17567
17568         * lib/addext.c: Include <string.h> unconditionally.
17569         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
17570         Don't declare getenv or malloc.
17571
17572         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
17573         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
17574         (NULL): Remove.
17575         (find_stack_direction, alloca): Use prototypes.
17576
17577         * lib/atexit.c (atexit): Define using a prototype.
17578
17579         * lib/basename.c, dirname.c, stripslash.c:
17580         Include <string.h> unconditionally.
17581
17582         * lib/bcopy.c: Include <stddef.h>.
17583         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
17584
17585         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
17586
17587         * lib/error.h (error, error_at_line, error_print_progname)
17588         [! (defined (__STDC__) && __STDC__)]: Remove decls.
17589         * lib/error.c: Include error.h first, to check interface.
17590         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17591         (VA_START): Remove; all uses changeed to va_start.
17592         (exit, strerror): Remove decls.
17593         (error_print_progname): Prototype uncondionally.
17594         Don't include <errno.h>; no longer needed.
17595         (private_strerror): Remove.
17596         (error_tail): Always define.
17597         (error, error_at_line): Assume C89 or better; always use prototypes.
17598         * lib/fatal.c: Include "fatal.h" first, to test interface.
17599         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17600         (VA_START): Remove; all uses changed to va_start.
17601         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
17602         this case.
17603         (exit): Remove decl.
17604         (fatal): Prototype unconditionally.  Assume va_start works.
17605         Abort at end, to pacify gcc.
17606
17607         * lib/euidaccess.c (main): Define with a prototype.
17608
17609         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
17610
17611         * lib/exitfail.c: Include <stdlib.h> unconditionally.
17612
17613         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
17614         prototypes.
17615         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
17616         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
17617         (getenv): Remove decl.
17618         (fnmatch): Define using a prototype.
17619         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
17620         (FCT): Define using a prototype.
17621
17622         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
17623
17624         * lib/gethostname.c: Include <stddef.h>.
17625         (gethostname): Define with prototype.  Length is size_t, not int.
17626
17627 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17628
17629         Assume C89 or better; remove K&R cruft.
17630         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
17631         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
17632         string.h, getenv, malloc.
17633         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
17634         headers.
17635         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
17636         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
17637         do not check for strerror.
17638         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
17639         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
17640         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
17641         do not check for doprnt or vprintf.
17642         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
17643         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
17644
17645 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17646
17647         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
17648         getversion.c should have been removed then, but was accidentally
17649         preserved.
17650
17651         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
17652         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
17653
17654 2003-09-08  Karl Berry  <karl@gnu.org>
17655
17656         * config/config.sub, config.guess, srclistvars.sh: update from savannah
17657                 config, forget about prep.
17658
17659         * config/depcomp, missing: update from automake.
17660
17661 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17662
17663         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
17664         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17665
17666 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17667
17668         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
17669         copy_tm_result.  Bug reported by Simon Josefsson in
17670         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17671
17672 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17673
17674         * m4/time_r.m4: New file.
17675         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
17676         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
17677         is. Check for timegm declaration.
17678         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
17679         Do not check for gmtime_r.
17680         Replace mktime if __mktime_internal does not exist and if mktime
17681         hasn't been replaced already.
17682
17683 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17684
17685         * lib/time_r.c, lib/time_r.h: New files.
17686
17687         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
17688         __localtime_r.
17689         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
17690         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
17691
17692         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
17693         __gmtime_r.
17694         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
17695         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
17696         Include <time_r.h>.
17697
17698         * lib/timegm.c: Switch to glibc implementation, with the following
17699         changes:
17700         [defined HAVE_CONFIG_H]: Include <config.h>.
17701         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
17702         (__mktime_internal) [!defined _LIBC]: New decl.
17703         (__gmtime_r) [!defined _LIBC]: New macro and function.
17704         (timegm): Use a prototype, since gnulib assumes C89.
17705         Do not bother declaring tmp to be const, as it's not really usefu.
17706         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
17707         (timegm): Declare only if HAVE_DECL_TIMEGM.
17708
17709 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17710
17711         * MODULES.html.sh (func_all_modules): Add time_r.
17712         * modules/time_r: New file.
17713         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
17714         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
17715
17716 2003-09-03  Paul Eggert  <eggert@twinsun.com>
17717
17718         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
17719         Bug reported by Lute Kamstra in
17720         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
17721
17722         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
17723         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
17724         course with correspondingly smaller numbers for tomorrow and
17725         yesterday.  From Tadayoshi Funaba.  Originally installed into
17726         sh-utils on 1999-08-07, but the patch got lost (I guess during the
17727         coreutils merge?).
17728
17729 2003-08-31  Simon Josefsson  <jas@extundo.com>
17730
17731         * modules/timegm: New file.
17732         * MODULES.html.sh (func_all_modules): Add timegm.
17733
17734 2003-08-31  Simon Josefsson  <jas@extundo.com>
17735
17736         * m4/timegm.m4: New file.
17737
17738 2003-08-31  Simon Josefsson  <jas@extundo.com>
17739
17740         * lib/timegm.h: New file.
17741         * lib/timegm.c: New file.  Based on
17742         wget-1.8.2/src/http.c:mktime_from_utc.
17743
17744 2003-08-31  Karl Berry  <karl@gnu.org>
17745
17746         * lib/argp.h: update from libc.
17747
17748 2003-08-28  Bruno Haible  <bruno@clisp.org>
17749
17750         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
17751         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
17752         followed by '#define fnmatch fnmatch_posix' gives an error.
17753
17754 2003-08-28  Bruno Haible  <bruno@clisp.org>
17755
17756         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
17757         warning on QNX, which defines O_BINARY to 000000.
17758
17759 2003-08-27  Jim Meyering  <jim@meyering.net>
17760
17761         * m4/mkstemp.m4: Require that the system mkstemp be able to create
17762         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
17763         would fail after 32.  Reported by Danny Levinson.  Details here:
17764         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
17765
17766 2003-08-24  Bruno Haible  <bruno@clisp.org>
17767
17768         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
17769         MSVC7 <stdio.h> is included later.
17770
17771 2003-08-22  Simon Josefsson  <jas@extundo.com>
17772
17773         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
17774
17775 2003-08-20  Karl Berry  <karl@gnu.org>
17776
17777         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
17778
17779 2003-08-20  Bruno Haible  <bruno@clisp.org>
17780
17781         * modules/progname: New file.
17782         * MODULES.html.sh (func_all_modules): Add progname.
17783
17784 2003-08-20  Bruno Haible  <bruno@clisp.org>
17785
17786         * lib/progname.h: New file, from GNU gettext.
17787         * lib/progname.c: New file, from GNU gettext.
17788         * lib/progreloc.c: New file, from GNU gettext.
17789
17790 2003-08-19  Jim Meyering  <jim@meyering.net>
17791
17792         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
17793         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
17794
17795 2003-08-19  Bruno Haible  <bruno@clisp.org>
17796
17797         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
17798         more.
17799
17800 2003-08-19  Bruno Haible  <bruno@clisp.org>
17801
17802         * lib/xstrdup.c: Assume <string.h> exists.
17803
17804 2003-08-18  Paul Eggert  <eggert@twinsun.com>
17805
17806         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
17807         in makefile rules.
17808
17809 2003-08-18  Jim Meyering  <jim@meyering.net>
17810
17811         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
17812         * m4/lib-ld.m4: Likewise.
17813
17814 2003-08-18  Jim Meyering  <jim@meyering.net>
17815
17816         * lib/setenv.h: Indent nested cpp directive.
17817         * lib/vasnprintf.c: Remove trailing blanks.
17818
17819 2003-08-17  Simon Josefsson  <jas@extundo.com>
17820
17821         * modules/xstrndup: New file.
17822         * MODULES.html.sh (func_all_modules): Add xstrndup.
17823
17824 2003-08-17  Simon Josefsson  <jas@extundo.com>
17825
17826         * modules/argp: Fix autoconf macro name. Add more dependencies.
17827
17828 2003-08-17  Simon Josefsson  <jas@extundo.com>
17829
17830         * m4/xstrndup.m4: New file.
17831
17832 2003-08-17  Simon Josefsson  <jas@extundo.com>
17833
17834         * m4/argp.m4: New file.
17835
17836 2003-08-17  Simon Josefsson  <jas@extundo.com>
17837             Bruno Haible  <bruno@clisp.org>
17838
17839         * lib/xstrndup.h: New file.
17840         * lib/xstrndup.c: New file.
17841
17842 2003-08-17  Bruno Haible  <bruno@clisp.org>
17843
17844         * modules/strndup (Files, Include): Add lib/strndup.h.
17845
17846 2003-08-17  Bruno Haible  <bruno@clisp.org>
17847
17848         * modules/euidaccess (Files): Add lib/euidaccess.h.
17849
17850 2003-08-17  Bruno Haible  <bruno@clisp.org>
17851
17852         * lib/strndup.h: New file.
17853
17854 2003-08-17  Bruno Haible  <bruno@clisp.org>
17855
17856         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
17857         like AC_GNU_SOURCE.
17858         * modules/extensions (configure.ac): Comment out the invocation of
17859         gl_USE_SYSTEM_EXTENSIONS.
17860
17861 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17862
17863         Merges from coreutils, etc.
17864         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
17865         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
17866         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
17867         fixing a typo.
17868         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
17869         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
17870
17871 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17872
17873         Document merge from coreutils.
17874         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
17875         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
17876         * modules/utime: Add m4/utimes-null.m4.
17877
17878 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17879
17880         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
17881         space, undoing this 2003-08-12 change:
17882         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17883
17884 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17885
17886         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
17887         strtoul.c from libc, undoing this 2003-08-12 change:
17888         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17889
17890 2003-08-16  Jim Meyering  <jim@meyering.net>
17891
17892         Merges from coreutils.
17893         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
17894         prefix.  Adjust cache variables similarly.  Create 500 rather than
17895         just 300 files, to exercise bug on Darwin6.5, too.
17896         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
17897         $missing_dir.
17898         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
17899         AM_SYS_POSIX_TERMIOS.
17900         Reported by mkc@mathdogs.com.
17901         Also change use of $am_cv_sys_posix_termios
17902         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
17903         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
17904         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
17905         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
17906         in /proc/mounts until it finds one with matching device number.  This
17907         is unnecessary when the FILE argument *is* a mount point.  No stat call
17908         is necessary in that case.  So, disable the statvfs-testing code on
17909         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
17910         as RedHat bug# 84846.
17911         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17912         to 1MB, so as not to render systems with no stack size limit (e.g.,
17913         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17914         Include <unistd.h>.  On some systems,
17915         it is required for the definition of _SC_PAGESIZE.
17916
17917 2003-08-16  Jim Meyering  <jim@meyering.net>
17918
17919         Merge from coreutils.
17920         * lib/xstrtoimax.c: #else #if -> #elif.
17921         * lib/xstrtoumax.c: Likewise.
17922
17923 2003-08-16  Jim Meyering  <jim@meyering.net>
17924
17925         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
17926         * m4/utimes.m4: Removed.
17927         * m4/utimes-null.m4: Renamed from utimes.m4.
17928
17929         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17930         to 1MB, so as not to render systems with no stack size limit (e.g.,
17931         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17932         Include <unistd.h>.  On some systems,
17933         it is required for the definition of _SC_PAGESIZE.
17934
17935 2003-08-16  Jim Meyering  <jim@meyering.net>
17936         and Paul Eggert  <eggert@cs.ucla.edu>
17937
17938         Merges from coreutils, etc.
17939
17940         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
17941         using the latest version from cvs.  This avoids problems with #line
17942         directives using a vendor (Sun) compiler.
17943         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
17944         Don't set GETGROUPS_LIB here; now it's
17945         done via getgroups.m4's wrapper function.
17946         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
17947         rather than just in sh-util/configure.in, so that the
17948         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
17949         same.
17950         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
17951         AC_FUNC_GETLOADAVG where to find getloadavg.c.
17952         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
17953         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
17954         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
17955         Remove code that is now done by the newly-required macros.
17956         Append $(EXEEXT) to DF_PROG.
17957         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
17958         Do not invoke or require the following here,
17959         since prereq.m4 or some gnulib .m4 now does this for us:
17960         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
17961         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
17962         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
17963         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
17964         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
17965         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
17966         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
17967         AC_FUNC_OBSTACK.
17968         Do not replace the following functions, as this is now the job
17969         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
17970         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
17971         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
17972         atexit getpass, strdup, getpagesize.
17973         Replace 'raise'.
17974         Do not check for the following functions, as this is now the job
17975         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
17976         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
17977         setregid.
17978         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
17979         Check for sys/sysctl.h.
17980         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
17981         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
17982         of checking for ssize_t ourselves.
17983
17984         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
17985         Require every macro that gnulib/modules/* suggests for us.
17986         (jm_PREREQ_ADDEXT): New macro.
17987         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
17988         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
17989
17990         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
17991         (gl_PHYSMEM): Use it.
17992         Also check for `table' function.
17993         Check for new headers and functions.
17994         Add check for sys/sysmp.h.
17995         With suggestions from Kaveh Ghazi.
17996         Ignore headers that are present but cannot be compiled.  This
17997         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
17998         C 5.4.
17999
18000 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18001
18002         Document merge from coreutils.
18003         * modules/userspec: Depend on posixver.
18004         * modules/strftime: Depend on tzset.
18005
18006 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18007
18008         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
18009         rather than tab, after '#' in shell-script copyright notices.
18010         Suggested by Bruno Haible.
18011
18012 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18013
18014         * config/srclist-update: Use three spaces, rather than tab, after '#'
18015         in shell-script copyright notices.  Suggested by Bruno Haible.
18016         Remove unnecessary parenthesization in regular expression.
18017
18018 2003-08-15  Jim Meyering  <jim@meyering.net>
18019
18020         Merge from coreutils.
18021         * lib/xgethostname.c: Include <stdlib.h>.
18022         (xghostname): Don't exit for anything other than memory-related
18023         failure; just return NULL.
18024         * lib/userspec.c: Include "posixver.h".
18025         (parse_user_spec): Accept `.' as a separator only
18026         in pre-POSIX-200112 mode.
18027         * lib/strtoimax.c: Use #elif rather than #else #if.
18028         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
18029         Remove function, now that we can rely on a working tzset function.
18030         [!_LIBC]: Ensure that the required autoconf test has been run.
18031         [!defined _NL_CURRENT && HAVE_STRFTIME]:
18032         Use underlying_strftime for %r.
18033         * lib/sha.c: Merge in some clean-up and optimization changes from
18034         glibc.
18035         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
18036         Ensure that it is a multiple of 64.
18037         Rearrange loop exit tests so as to avoid performing an
18038         additional fread after encountering an error or EOF.
18039         * lib/realloc.c: Update copyright date.
18040
18041 2003-08-15  Jim Meyering  <jim@meyering.net>
18042         and Paul Eggert  <eggert@twinsun.com>
18043
18044         Merge from coreutils.
18045         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
18046         member but strut utmpx does not.  Needed for AIX 4.3.3.
18047         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
18048
18049 2003-08-15  Jim Meyering  <jim@meyering.net>
18050         and Paul Eggert  <eggert@cs.ucla.edu>
18051
18052         Merges from coreutils, etc.
18053         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
18054         Require gl_FUNC_TZSET_CLOBBER.
18055         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
18056         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
18057         members.
18058
18059 2003-08-14  Paul Eggert  <eggert@twinsun.com>
18060
18061         Help the merge from coreutils.
18062         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
18063         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
18064         * m4/tzset.m4: Use it too.
18065
18066 2003-08-14  Paul Eggert  <eggert@twinsun.com>
18067
18068         * modules/tzset: New file.
18069
18070 2003-08-14  Jim Meyering  <jim@meyering.net>
18071
18072         Merges from coreutils.
18073         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
18074         variable names, rather than @FNMATCH_H@.
18075         * modules/alloca: Likewise for $(ALLOCA_H).
18076
18077         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
18078         the three copies of the literal target, `fnmatch.h'.
18079         * modules/alloca (alloca.h): Likewise.
18080
18081 2003-08-14  Jim Meyering  <jim@meyering.net>
18082
18083         Merge from coreutils.
18084         * m4/tzset.m4: New file.
18085         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
18086         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
18087         otherwise, AIX 5.1 systems would end up using the latter.
18088         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
18089         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
18090         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
18091         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
18092
18093 2003-08-14  Jim Meyering  <jim@meyering.net>
18094
18095         Merge from coreutils.
18096         * lib/obstack.h: Whitespace changes.
18097         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
18098         and xcalloc return values.
18099         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
18100         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
18101         hang on OSF/1 5.1 for DIR on both local and remote file systems.
18102         Reported by (and fix confirmed by) Nelson H. F. Beebe.
18103         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
18104         error from mntctl.
18105         Use mntctl's return value to drive the entry-processing loop, since
18106         we can't rely on the value of the vmt_length member in the last
18107         entry.  On some systems doing so could result in exhausting
18108         virtual memory.  Based in part on a patch from Mike Jetzer.
18109
18110 2003-08-14  Jim Meyering  <jim@meyering.net>
18111         and Paul Eggert  <eggert@twinsun.com>
18112
18113         Merges from coreutils, plus other fixes.
18114         * lib/physmem.c: Merge in portability changes from gcc/libiberty
18115         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
18116         for credits and details.  Thanks to Kaveh Ghazi for helping
18117         to keep these files in sync.
18118         (ARRAY_SIZE): Define it.
18119         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
18120         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
18121         (memcasecmp): Don't assume size_t fits in unsigned int.
18122         Remove casts and duplicate code.
18123         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
18124         (memcpy): Remove definition.
18125         Merge in some clean-up and optimization changes from glibc.
18126         [BLOCKSIZE]: Move definition to top of file.
18127         Ensure that it is a multiple of 64.
18128         Rearrange loop exit tests so as to avoid performing an
18129         additional fread after encountering an error or EOF.
18130         * lib/md5.h (md5_uintptr): Define.
18131         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
18132         return to the initial working directory.  Preserve errno
18133         for caller.
18134         * lib/idcache.c: Include "xalloc.h".
18135         (xmalloc, xrealloc): Remove decls.
18136         (getuser): Remove casts no longer required in C89.
18137         * lib/human.c: Include stdio.h, for sprintf.
18138         * lib/group-member.c: Include "xalloc.h".
18139         (xmalloc, xrealloc): Remove decls.
18140         (get_group_info): Remove casts no longer required in C89.
18141         * lib/getusershell.c (readname): Remove casts no longer required in
18142         C89.
18143         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
18144         * lib/getline.c: Whitespace fix, from coreutils.
18145
18146 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18147
18148         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
18149         Check for isascii.
18150
18151         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18152         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18153         Undo previous (whitespace-only) change.
18154
18155 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18156
18157         * lib/exclude.c: Include <ctype.h>
18158         (IN_CTYPE_DOMAIN): New macro.
18159         (is_space): New fn.
18160         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
18161         and empty lines.
18162
18163         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18164         Undo previous (whitespace-only) change.
18165
18166 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18167
18168         * config/srclist-update: Change update back to the old behavior,
18169         leaving whitespace alone.  Use one 'sed' command rather than a
18170         pipeline.
18171         (fixlicense): Now a variable, not a function.
18172         (remove_trailing_blanks): Remove.
18173         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
18174         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18175         Undo previous (whitespace-only) change.
18176
18177 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18178
18179         Merge from coreutils.
18180         * modules/euidaccess: Add lib_SOURCES, include for new
18181         file euidaccess.h
18182
18183 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18184
18185         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18186         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18187         Normalize leading white space and remove trailing white space.
18188
18189         Merge from coreutils
18190         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
18191
18192         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
18193         0.12.1.  These files are now being upgraded automatically by
18194         ../config/srclist-update.
18195
18196 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18197
18198         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18199         Normalize leading white space and remove trailing white space.
18200         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
18201         notice, as per ../config/srclist-update.
18202
18203         Merge from coreutils.
18204         * lib/euidaccess.h: New file.
18205         * lib/euidaccess.c: Include it.
18206         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
18207         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
18208         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
18209
18210 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18211
18212         * config/srclist-update: Add copyright notice.
18213         (remove_id_lines, remove_trailing_blanks): New constants.
18214         (fixfile): Use them to normalize spacing a bit in copied files.
18215         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18216         Normalize leading white space and remove trailing white space.
18217
18218         * config/texinfo.tex: Sync with texinfo.
18219
18220         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
18221         strtoul.c from libc, to merge coreutils whitespace changes.
18222
18223         * config/srclist.txt: Get the following m4 files from gettext:
18224         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
18225         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
18226         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
18227         wint_t.m4.
18228
18229 2003-08-12  Karl Berry  <karl@gnu.org>
18230
18231         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
18232         been made.
18233
18234 2003-08-11  Paul Eggert  <eggert@twinsun.com>
18235
18236         * modules/gnu-source, m4/gnu-source.m4:
18237         Remove; we're assuming Autoconf 2.54 or later now.
18238         Suggested by Bruno Haible.
18239         * MODULES.html.sh (func_all_modules): Remove gnu-source.
18240
18241 2003-08-11  Bruno Haible  <bruno@clisp.org>
18242
18243         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
18244
18245 2003-08-11  Bruno Haible  <bruno@clisp.org>
18246
18247         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
18248         (vasnprintf): Use it instead of wcslen.
18249
18250 2003-08-11  Bruno Haible  <bruno@clisp.org>
18251
18252         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
18253         value to ensure that _Bool promotes to int. Use #define for _Bool when
18254         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
18255
18256 2003-08-10  Karl Berry  <karl@gnu.org>
18257
18258         * lib/regex.h: update from libc (whitespace fix).
18259
18260 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18261
18262         Merge some files from coreutils.  These changes were
18263         originally made by Jim Meyering.
18264         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
18265         many older Unixes require this.
18266         * lib/alloca.c (alloca): Remove cast to argument of free;
18267         no longer needed in C89.
18268         * lib/alloca_.h, regex.h: Fix white space to match
18269         what GNU indent does.
18270
18271 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18272
18273         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
18274         apparently Emacs's Unicode mode got confused before my 2003-08-05
18275         checkin.
18276
18277 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18278
18279         * m4/extensions.m4: New file.
18280         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
18281         Require gl_USE_SYSTEM_EXTENSIONS.
18282         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
18283         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
18284
18285 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18286
18287         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
18288         * modules/extensions, modules/gnu-source: New files.
18289         * modules/timespec, modules/unlocked-io: Depend on extensions.
18290
18291 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18292
18293         * modules/restrict: New file.
18294         * MODULES.html.sh (func_all_modules): Add restrict.
18295         * modules/regex: Depend on restrict.
18296
18297 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18298
18299         * m4/restrict.m4: New file.
18300         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
18301
18302 2003-08-07  Bruno Haible  <bruno@clisp.org>
18303
18304         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
18305         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
18306
18307 2003-08-07  Bruno Haible  <bruno@clisp.org>
18308
18309         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
18310         makes the module 'getndelim2' compatible with the module 'getline'.
18311
18312 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18313
18314         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
18315         byte with "\201" to avoid glitches when editing that source file
18316         with multi-gnome-terminal.
18317
18318 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18319
18320         * lib/bumpalloc.h: Remove.
18321
18322 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18323
18324         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
18325         * modules/bumpalloc: Remove.
18326
18327 2003-08-04  Paul Eggert  <eggert@twinsun.com>
18328
18329         * lib/getloadavg.c: Change copyright notice and spacing to conform to
18330         GNU coding style.
18331
18332         Merge from coreutils.
18333         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
18334         1. From glibc.
18335         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
18336         from Karl Berry, implemented by Jim Meyering.
18337         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
18338         from Dmitry V. Levin.
18339         Remove anachronistic cast of xrealloc.
18340         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
18341         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
18342         type. Otherwise, it wouldn't compile with at least /bin/cc on
18343         ymp-cray-unicos9.0.2.X.
18344         Combine two mostly-identical uses of alloca into one.
18345         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
18346
18347 2003-08-04  Dave Love  <d.love@dl.ac.uk>
18348
18349         [From Emacs.]
18350
18351         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
18352         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
18353         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
18354         obsolete NLIST_NAME_UNION.
18355         [__GNU__]: Undef BSD and FSCALE.
18356         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
18357
18358 2003-08-03  Paul Eggert  <eggert@twinsun.com>
18359
18360         * lib/stdbool_.h (_Bool): Make it signed char, instead of
18361         an enum type, so that it's guaranteed to promote to int.  See:
18362         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
18363
18364 2003-08-03  Karl Berry  <karl@gnu.org>
18365
18366         * config/depcomp: update from automake.
18367
18368 2003-07-31  Paul Eggert  <eggert@twinsun.com>
18369
18370         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
18371         (strerror): Don't assume that a printable int fits in 14 bytes.
18372
18373 2003-07-31  Bruno Haible  <bruno@clisp.org>
18374
18375         * modules/getpass-gnu: New file.
18376         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
18377
18378 2003-07-31  Bruno Haible  <bruno@clisp.org>
18379
18380         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
18381
18382 2003-07-24  Karl Berry  <karl@gnu.org>
18383
18384         * config/missing: update from automake.
18385
18386 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
18387             Bruno Haible  <bruno@clisp.org>
18388
18389         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
18390         * lib/getline.c (getline, getdelim): Likewise.
18391         Remove _GNU_SOURCE define; now it's defined in config.h through
18392         m4/getline.m4.
18393
18394 2003-07-23  Karl Berry  <karl@gnu.org>
18395
18396         * config/config.sub: update from prep.
18397
18398 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18399
18400         * modules/xalloc (Depends-on): Add exitfail.
18401         * modules/xmemcoll: Likewise.
18402
18403 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18404
18405         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
18406         over-parenthesization in macros.
18407
18408         Sync with coreutils.
18409
18410         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
18411         required by C99.
18412
18413         Use `exit_failure' for xalloc and xmemcoll instead of their own
18414         private exit-failure variables.
18415         * lib/xalloc.h (xalloc_exit_failure): Remove.
18416         * lib/xmalloc.c: Likewise.  Include exitfail.h.
18417         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
18418         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
18419         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
18420         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
18421
18422 2003-07-20  Jim Meyering  <jim@meyering.net>
18423
18424         * modules/closeout (Depends-on): Add exitfail.
18425         Suggestion from Bruno Haible.
18426
18427 2003-07-19  Karl Berry  <karl@gnu.org>
18428
18429         * config/config.sub: update from prep.
18430
18431 2003-07-18  Paul Eggert  <eggert@twinsun.com>
18432
18433         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
18434         Remove.
18435         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
18436         to test that it can stand by itself.  Include "exitfail.h".
18437         Clients should set exit_failure instead.
18438         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
18439
18440 2003-07-18  Bruno Haible  <bruno@clisp.org>
18441
18442         * modules/getndelim2: New file.
18443         * modules/getline: Share files with module getndelim2.
18444         * modules/getnline: Depend on getndelim2 instead of sharing files with
18445         it. Add getnline.c to lib_SOURCES.
18446         * MODULES.html.sh (func_all_modules): Add getndelim2.
18447
18448 2003-07-18  Bruno Haible  <bruno@clisp.org>
18449
18450         * m4/getndelim2.m4: New file.
18451         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
18452         invoke gl_PREREQ_GETNDELIM2.
18453         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
18454         gl_PREREQ_GETNDELIM2.
18455         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
18456         gl_GETNDELIM2.
18457
18458 2003-07-18  Bruno Haible  <bruno@clisp.org>
18459
18460         * lib/getndelim2.h: New file.
18461         * lib/getndelim2.c: Make into a module of its own. Include config.h,
18462         getndelim2.h.
18463         (getndelim2): Make non-static. Change return type to ssize_t.
18464         * lib/getline.h: Change argument names.
18465         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
18466         * lib/getnline.c: Include getndelim2.h.
18467
18468 2003-07-18  Andreas Schwab  <schwab@suse.de>
18469
18470         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
18471
18472 2003-07-17  Karl Berry  <karl@gnu.org>
18473
18474         * config/config.sub: update from prep.
18475
18476 2003-07-17  Bruno Haible  <bruno@clisp.org>
18477
18478         * modules/getnline: New file.
18479         * modules/getline: Add lib/getndelim2.c to source file list.
18480         * MODULES.html.sh (func_all_modules): Add getnline.
18481
18482 2003-07-17  Bruno Haible  <bruno@clisp.org>
18483
18484         * m4/getnline.m4: New file.
18485
18486 2003-07-17  Bruno Haible  <bruno@clisp.org>
18487
18488         * m4/Makefile.am.in: Remove file.
18489         * m4/Makefile.am: Remove file.
18490         * m4/Makefile.in: Remove file.
18491
18492 2003-07-17  Bruno Haible  <bruno@clisp.org>
18493
18494         * lib/getnline.h: New file.
18495         * lib/getnline.c: New file.
18496         * lib/getndelim2.c: New file, extracted from getline.c.
18497         (getndelim2): Renamed from getdelim2, with added nmax argument.
18498         * lib/getline.c: Include getndelim2.c.
18499         (getdelim2): Moved out to getndelim2.c.
18500         (getline, getdelim): Update.
18501
18502 2003-07-17  Bruno Haible  <bruno@clisp.org>
18503
18504         * lib/Makefile.am: Remove file.
18505         * lib/Makefile.in: Remove file.
18506
18507 2003-07-17  Bruno Haible  <bruno@clisp.org>
18508
18509         * configure.in: Remove file.
18510         * Makefile.in: Remove file.
18511
18512 2003-07-17  Bruno Haible  <bruno@clisp.org>
18513
18514         * MODULES.html.sh: Put the </BODY> right before </HTML>.
18515
18516 2003-07-16  Karl Berry  <karl@gnu.org>
18517
18518         * config/srclist-update: was running fixlicense twice, which caused
18519                 texinfo.tex to be nullified for some reason.  Simplify,
18520                 $gplsrc is no longer needed as far as I can see?
18521
18522 2003-07-16  Jim Meyering  <jim@meyering.net>
18523
18524         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
18525
18526 2003-07-15  Paul Eggert  <eggert@twinsun.com>
18527
18528         * config/srclist.txt: Get the following files from gettext-runtime/intl
18529         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
18530         ref-del.sin.  From Bruno Haible.
18531         * config/srclist-update (fixfile): Change grep pattern again, since the
18532         previous fix didn't work (there was another trailing $).  Use
18533         '[$]' to escape the $s.
18534
18535 2003-07-15  Karl Berry  <karl@gnu.org>
18536
18537         * lib/vasnprintf.c: update from gettext.
18538
18539 2003-07-15  Karl Berry  <karl@gnu.org>
18540
18541         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
18542         gets expanded when surrounded by '$'.
18543
18544 2003-07-15  Jim Meyering  <jim@meyering.net>
18545
18546         * modules/save-cwd: Don't depend on error.  From Derek Price.
18547
18548 2003-07-15  Jim Meyering  <jim@meyering.net>
18549
18550         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
18551
18552 2003-07-14  Simon Josefsson  <jas@extundo.com>
18553
18554         * modules/mempcpy: New file.
18555         * MODULES.html.sh (func_all_modules): Add mempcpy.
18556
18557 2003-07-14  Simon Josefsson  <jas@extundo.com>
18558
18559         * m4/mempcpy.m4: New file.
18560
18561 2003-07-14  Simon Josefsson  <jas@extundo.com>
18562
18563         * lib/mempcpy.h: New file.
18564         * lib/mempcpy.c: New file.
18565
18566 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18567
18568         * modules/getdate, modules/posixtm: Depend on mktime.
18569
18570 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18571
18572         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
18573         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
18574         unicodeio.c, unicodeio.h, unlocked-io.h:
18575         Switch from LGPL to GPL.
18576
18577 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18578
18579         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
18580         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
18581         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
18582         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
18583         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
18584         updated automatically by ../config/srclist-update.  This changes
18585         their license from LPGL to GPL.
18586
18587 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18588
18589         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
18590         assumed to refer to the root of the most recent stable gettext version.
18591         * config/srclistvars.sh: Add defaults for eggert.
18592         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
18593         Match "This program" as well as "The program".  This is needed
18594         for gettext.
18595
18596 2003-07-14  Jim Meyering  <jim@meyering.net>
18597
18598         Don't emit diagnostics.  Let callers do that.
18599         * lib/save-cwd.c: Don't include "error.h".
18600         (save_cwd): Don't call error.  Ensure that errno is valid
18601         when returning nonzero.
18602
18603         * lib/save-cwd.h (restore_cwd): Update prototype.
18604         * lib/save-cwd.c (restore_cwd): Remove two parameters.
18605         Simplify.  Don't call error upon failure.  Let callers do that.
18606         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
18607         when auditing is enabled.  But don't bother updating the #if.
18608
18609 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
18610
18611         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
18612         it breaks C++ compilation.
18613         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
18614
18615 2003-07-10  Simon Josefsson  <jas@extundo.com>
18616
18617         * modules/strchrnul (Makefile.am): Add strchrnul.h.
18618
18619 2003-07-10  Jim Meyering  <jim@meyering.net>
18620
18621         * m4/clock_time.m4: Remove trailing blank.
18622         * m4/intmax_t.m4: Likewise.
18623
18624 2003-07-10  Jim Meyering  <jim@meyering.net>
18625
18626         * lib/vasnprintf.c: Remove trailing blanks.
18627         Make cpp indentation consistent.
18628
18629 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18630
18631         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
18632         posixver.c, strftime.c, strnlen.c, strverscmp.c:
18633         Switch from LGPL to GPL.
18634
18635 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18636
18637         * config/srclist.txt: Sort sublists.  Add
18638         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
18639         that differ from gnulib for one reason or another; we'd like this list
18640         to be smaller but for now let's document what we have.
18641
18642 2003-07-08  Paul Eggert  <eggert@twinsun.com>
18643
18644         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
18645         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
18646         and sweeter "eval x=$x".
18647         * config/srclist.txt: Get lib/argp* from glibc.
18648
18649 2003-07-07  Paul Eggert  <eggert@twinsun.com>
18650
18651         * lib/mktime.c: Fix some boundary cases and remove need for floating
18652         point.
18653
18654         Issue a compile-time diagnostic if time_t is floating point, or if
18655         two's complement arithmetic is not in effect, or if arithmetic
18656         right shift does not propagate the sign.  These assumptions were
18657         all in the original code but they weren't checked.
18658
18659         (TIME_T_MIDPOINT, verify): New macros.
18660         (__isleap): Remove; it has integer overflow problems.
18661         (leapyear): New function, without those problems.
18662         (ydhms_tm_diff): Remove; splitting into two parts.
18663         (ydhms_diff): New function, containing the arithmetic part of
18664         the old ydhms_tm_diff function.  Issue a compile-time
18665         diagnostic if we are not using C99 integer division.
18666         Avoid casts when possible.
18667         (guess_time_tm): New function, containing the checking part of
18668         the old ydhms_tm_diff function.  Return the new value, rather than
18669         the difference between it and the old.  Accept a new argument T
18670         so that *T specifies the old value.  Check for overflow in the result.
18671
18672         (__mktime_internal): Use a time_t offset, not a long int offset.
18673         This undoes the 2003-06-04 change, which is no longer needed now
18674         that we have better overflow checking.
18675         (localtime_offset): Likewise.
18676
18677         (__mktime_internal): Avoid harmful overflow on hosts where time_t
18678         and long are 64-bit but int is only 32-bit.
18679         (ydhms_diff): Use long int to store year1 and yday1.
18680         Issue a compile-time diagnostic if long int is not wide enough.
18681
18682         (__mktime_internal): Use long int to store adjusted year and yday.
18683         Use plain C rather than preprocessor commands, if that doesn't
18684         affect efficiency.
18685         Check for overflow (and try to repair) after each probe
18686         rather than checking only at the very end.  This avoids some bugs
18687         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
18688         does not equal GMT offset at maximum time).
18689         Use integer to check for overflow rather than floating point; this
18690         is more portable to non-IEEE hosts, and is a tad faster.
18691         When we detect that we are oscillating between two values,
18692         don't check whether tm_isdst has the requested value, since
18693         we already know the answer.  When tm_isdst has the wrong value,
18694         use a different heuristic to find the right one, based on the
18695         extreme values actually observed in practice in tz2003a,
18696         rather than the (overly optimistic) "previous 3 calendar quarters".
18697
18698         (not_equal_tm, print_tm, check_result): Use "const T" rather than
18699         "T const" to accommodate glibc style.
18700         (check_result): Use less-confusing report format.  "long" -> "long int.
18701         (main): Likewise.
18702         Don't loop if the iteration overflows time_t.
18703         Allow a negative step in the iteration.
18704
18705 2003-07-06  Karl Berry  <karl@gnu.org>
18706
18707         * config/depcomp: update from automake.
18708         * config/config.sub: update from prep.
18709
18710 2003-07-03  Karl Berry  <karl@gnu.org>
18711
18712         * config/config.guess: update from prep.
18713
18714 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18715
18716         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
18717         xreadlink.c now includes it unconditionally.
18718
18719 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18720
18721         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
18722         having it depend on HAVE_SYS_TYPES_H.
18723
18724 2003-07-01  Bruno Haible  <bruno@clisp.org>
18725
18726         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
18727         <sys/types.h> should be sufficient.
18728         Reported by Paul Eggert.
18729
18730 2003-06-26  Karl Berry  <karl@gnu.org>
18731
18732         * config/depcomp: update from automake.
18733
18734 2003-06-26  Bruno Haible  <bruno@clisp.org>
18735
18736         * modules/human: Depend on module stdbool.
18737
18738 2003-06-25  Bruno Haible  <bruno@clisp.org>
18739
18740         * modules/readlink: New file.
18741         * modules/xreadlink: Depend on it.
18742         * MODULES.html.sh (func_all_modules): Add readlink.
18743
18744 2003-06-25  Bruno Haible  <bruno@clisp.org>
18745
18746         * m4/readlink.m4: New file.
18747
18748 2003-06-25  Bruno Haible  <bruno@clisp.org>
18749
18750         * lib/readlink.c: New file.
18751
18752 2003-06-22  Karl Berry  <karl@gnu.org>
18753
18754         * config/srclist.txt: update mkinstalldirs from automake.
18755         * config/mkinstalldirs: update.
18756
18757 2003-06-22  Bruno Haible  <bruno@clisp.org>
18758
18759         Portability to mingw32.
18760         * m4/ssize_t.m4: New file, from GNU gettext.
18761         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
18762         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
18763
18764 2003-06-22  Bruno Haible  <bruno@clisp.org>
18765
18766         * modules/safe-read: Add m4/ssize_t.m4.
18767         * modules/xreadlink: Add m4/ssize_t.m4.
18768
18769 2003-06-20  Bruno Haible  <bruno@clisp.org>
18770
18771         Assume C89, so PARAMS isn't needed.
18772         * lib/unicodeio.h (PARAMS): Remove.
18773         * lib/unicodeio.c: Don't use PARAMS.
18774
18775 2003-06-18  Karl Berry  <karl@gnu.org>
18776
18777         * config/config.{guess,sub}: update from prep.
18778
18779 2003-06-18  Jim Meyering  <jim@meyering.net>
18780
18781         Merge changes from coreutils.
18782         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
18783         Remove explicit declarations of xmalloc and realloc.
18784         Include xalloc.h.
18785         (read_utmp): Remove anachronistic cast of xmalloc.
18786
18787 2003-06-17  Paul Eggert  <eggert@twinsun.com>
18788
18789         Assume C89, so PARAMS isn't needed.
18790         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
18791         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
18792         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
18793         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
18794         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
18795         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
18796         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
18797         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
18798         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
18799         lib/xstrtod.h, lib/xstrtol.h: Likewise.
18800         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
18801         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
18802         no longer needed. Anyway, config.h should always be included before any
18803         other file.
18804
18805 2003-06-11  Simon Josefsson  <jas@extundo.com>
18806
18807         * modules/sysexits: New file.
18808         * MODULES.html.sh (func_all_modules): Add sysexits.
18809
18810 2003-06-11  Simon Josefsson  <jas@extundo.com>
18811
18812         * lib/sysexit_.h: New file.
18813
18814 2003-06-11  Derek Price  <derek@ximbiot.com>
18815
18816         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
18817         necessary.
18818
18819 2003-06-11  Bruno Haible  <bruno@clisp.org>
18820
18821         * m4/sysexits.m4: New file.
18822
18823 2003-06-10  Simon Josefsson  <jas@extundo.com>
18824
18825         * lib/argp.h: New file, from glibc.
18826         * lib/argp-ba.c: New file, from glibc.
18827         * lib/argp-eexst.c: New file, from glibc.
18828         * lib/argp-fmtstream.c: New file, from glibc.
18829         * lib/argp-fmtstream.h: New file, from glibc.
18830         * lib/argp-fs-xinl.c: New file, from glibc.
18831         * lib/argp-help.c: New file, from glibc.
18832         * lib/argp-namefrob.h: New file, from glibc.
18833         * lib/argp-parse.c: New file, from glibc.
18834         * lib/argp-pv.c: New file, from glibc.
18835         * lib/argp-pvh.c: New file, from glibc.
18836         * lib/argp-xinl.c: New file, from glibc.
18837
18838 2003-06-10  Simon Josefsson  <jas@extundo.com>
18839
18840         * modules/strchrnul: New file.
18841
18842 2003-06-10  Simon Josefsson  <jas@extundo.com>
18843
18844         * modules/argp: New file.
18845
18846 2003-06-10  Simon Josefsson  <jas@extundo.com>
18847
18848         * m4/strchrnul.m4: New file.
18849
18850 2003-06-10  Simon Josefsson  <jas@extundo.com>
18851
18852         * lib/strchrnul.h: New file.
18853         * lib/strchrnul.c: New file.
18854
18855 2003-06-10  Bruno Haible  <bruno@clisp.org>
18856
18857         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
18858
18859 2003-06-07  Karl Berry  <karl@gnu.org>
18860
18861         * config/config.{guess,sub}: update from prep.
18862
18863 2003-06-07  Jim Meyering  <jim@meyering.net>
18864
18865         * modules/strtod: Use $(...) notation, not @...@ for
18866         AC_REPLACE'd variables.
18867         * modules/localcharset: Likewise.
18868
18869 2003-06-07  Jim Meyering  <jim@meyering.net>
18870
18871         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
18872         in place of my name in the copyright comment.
18873         Remove definition and uses of __P.
18874
18875         From coreutils.
18876         * lib/stat.c: Don't declare xmalloc explicitly.
18877         Instead, include "xalloc.h".
18878         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
18879         xrealloc, and xcalloc return values.
18880         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
18881         Improve comment.
18882         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
18883
18884 2003-06-07  Bruno Haible  <bruno@clisp.org>
18885
18886         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
18887         avoid AC_CONFIG_LINKS.
18888         * modules/fnmatch (Makefile.am): Use explicit creation rule for
18889         fnmatch.h, to avoid AC_CONFIG_LINKS.
18890         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
18891
18892 2003-06-07  Bruno Haible  <bruno@clisp.org>
18893
18894         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
18895         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
18896         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18897         directory.
18898         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
18899         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18900         directory.
18901
18902 2003-06-06  Jim Meyering  <jim@meyering.net>
18903
18904         Merge from coreutils.
18905         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
18906         Consolidate declarations and initializations of *_base* locals.
18907
18908         Merge from coreutils.
18909         This avoids a core dump on systems without GNU putenv,
18910         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
18911         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
18912         (unsetenv): New static function, from GNU libc.
18913         (rpl_putenv): Use it.
18914
18915         * lib/modechange.c: Remove trailing blanks.
18916
18917         Merge from coreutils.
18918         * lib/fsusage.c: Remove declaration of statfs.
18919         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
18920
18921         * lib/posixtm.c: Include <stdbool.h> unconditionally.
18922
18923 2003-06-06  Jim Meyering  <jim@meyering.net>
18924
18925         * lib/stdbool_.h: Renamed from stdbool.h.in.
18926
18927 2003-06-06  Jim Meyering  <jim@meyering.net>
18928             Bruno Haible  <bruno@clisp.org>
18929
18930         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
18931         Adjust Makefile.am snippet not to redirect directly to target.
18932         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
18933
18934 2003-06-05  Paul Eggert  <eggert@twinsun.com>
18935
18936         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
18937         mismatch, look in future quarters as well as past.  This fixes a
18938         bug when processing fall-backwards gaps immediately after a long
18939         period of daylight-saving time.
18940
18941         * lib/mktime.c: Assume freestanding C89 or better.
18942         (HAVE_LIMITS_H): Remove.  Assume it's 1.
18943         (__P): Remove; not used.
18944         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
18945         (mktime, not_equal_tm, print_tm, check_result,
18946         main): Use prototypes.  Use const * where appropriate.
18947         (main): Fix typo in testing code that uncovered by above changes.
18948         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
18949
18950 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18951
18952         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
18953         locale.h, localeconv.  This merges changes from coreutils.
18954
18955         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
18956         It can be removed after the next Autoconf is released.
18957         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
18958         needed.
18959
18960 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18961
18962         * lib/mktime.c: Fix Debian bug 177940
18963         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
18964         (localtime_offset): Now long int, not time_t, because we want it
18965         to be guaranteed to be signed.  All uses changed.
18966         (__mktime_internal): If overflow would occur when adding offset,
18967         don't add it.
18968
18969         Merge 'human' changes from coreutils.  Rewrite to support
18970         locale-specific notations like thousands separators.
18971         * lib/human.c: Simplify authorship notice.
18972         Include human.h immediately after config.h.
18973         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
18974         <limits.h>: Do not include, since human.h does.
18975         (SIZE_MAX, UINTMAX_MAX): New macros.
18976         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
18977         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
18978         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
18979         (power_letter): Renamed from suffixes.
18980         (generate_suffix_backwards): Remove.
18981         (adjust_value): Now takes int style (because of human.h changes)
18982         and long double value (for greater precision on some platforms).
18983         (group_number): New function.
18984         (human_readable): Use it.  Use integer options, not enum.
18985         Put the options before the sizes in the arg list.
18986         Support all the new options.
18987         The old human_readable function has been removed;
18988         use inttostr.h instead.
18989         (human_readable, default_block_size, humblock):
18990         Use uintmax_t, not int, for block sizes.
18991         (human_readable_inexact, block_size_types): Remove.
18992         (block_size_opts): New constant.
18993         (human_options): Renamed from human_block_size, with new signature
18994         that allows block sizes up to UINTMAX_MAX.  All callers changed.
18995         * lib/human.h: Add copyright and authorship notice.
18996         Include <limits.h> and <stdbool.h> unconditionally.
18997         (PARAMS): Remove.  All uses removed.
18998         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
18999         (enum human_inexact_style): Remove tag; now a nameless enum.
19000         (human_floor, human_ceiling, human_round_to_even): Now have
19001         values 2, 0, 1 rather than -1, 1, 0.
19002         (human_group_digits, human_suppress_point_zero, human_autoscale,
19003         human_base_1024, human_SI, human_B): New constants.
19004         (human_readable_inexact, human_block_size): Remove.
19005         (human_readable): Size args are now uintmax_t, not int.
19006         (human_options): New decl.
19007
19008         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
19009         unnecessary now that we assume C89 or better.  This change
19010         imported from coreutils.
19011
19012         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19013         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
19014         in the 2003-05-30 sync from glibc.
19015
19016         .h files should stand alone, but we shouldn't include <sys/types.h>
19017         if we can get away with just <stddef.h>.
19018
19019         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
19020         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
19021         rather than <sys/types.h>, as we merely need size_t.
19022         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
19023         to get size_t.
19024         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
19025         Include <stdio.h>, to get FILE.
19026         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
19027         memcasecmp.h has included <stddef.h> and all we need is size_t.
19028         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
19029         our interface, instead of including <sys/types.h>
19030
19031 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19032
19033         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
19034         now, as glibc mktime is buggy on non-glibc systems.
19035
19036 2003-06-03  Karl Berry  <karl@gnu.org>
19037
19038         * config/config.sub: update from prep.
19039
19040 2003-06-02  Paul Eggert  <eggert@twinsun.com>
19041
19042         [from coreutils]
19043         Fix some minor time-related bugs with POSIX time arguments.
19044         Some valid time stamps were being rejected (notably -1, and
19045         time stamps before 1900 on 64-bit hosts).  And some invalid
19046         time stamps were being accepted, e.g. September 31.
19047
19048         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
19049         that we can return (time_t) -1 successfully.
19050         * lib/posixtm.c: Likewise.
19051         [HAVE_STDBOOL_H]: Include <stdbool.h>.
19052         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
19053         (t): Remove static var.
19054         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
19055         of static var.  All uses changed.
19056         (year): Do not reject years before 1900; they can occur with
19057         64-bit time_t.
19058         (posix_time_parse): Do not check for out-of-range components;
19059         that is now the caller's responsibility, since our checks were
19060         only approximations.
19061         (posixtime): Use mktime to check for out-of-range components,
19062         since it knows them exactly.
19063         If mktime returns (time_t) -1, check whether an error actually occurred
19064         by invoking localtime on -1.
19065         (main) [TEST_POSIXTIME]: Check for input data errors, and report
19066         posixtime failures better.
19067         Improve the test data (in comments only).
19068
19069 2003-06-02  Karl Berry  <karl@gnu.org>
19070
19071         * config/mkinstalldirs (version): new variable.
19072         (--version): new option.
19073         (usage): improve message.
19074
19075 2003-05-30  Karl Berry  <karl@gnu.org>
19076
19077         * lib/mktime.c: update from libc.
19078
19079 2003-05-30  Bruno Haible  <bruno@clisp.org>
19080
19081         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
19082         * config/config.rpath: Upgrade to gettext-0.12.1.
19083
19084 2003-05-30  Bruno Haible  <bruno@clisp.org>
19085
19086         * m4/gettext.m4: Upgrade to gettext-0.12.1.
19087         * m4/nls.m4: New file, from gettext-0.12.1.
19088         * m4/po.m4: New file, from gettext-0.12.1.
19089         * m4/progtest.m4: Upgrade to gettext-0.12.1.
19090
19091 2003-05-30  Bruno Haible  <bruno@clisp.org>
19092
19093         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
19094         * lib/localcharset.h: Likewise.
19095         * lib/localcharset.c: Likewise.
19096
19097 2003-05-29  Karl Berry  <karl@gnu.org>
19098
19099         * config/config.rpath: update from gettext.
19100
19101 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19102
19103         Assume the headers required for C89 freestanding compilers.
19104         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
19105         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
19106         * m4/human.m4 (gl_HUMAN): Likewise.
19107         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
19108         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
19109         * m4/userspec.m4 (gl_USERSPEC): Likewise.
19110         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
19111         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
19112         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
19113
19114 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19115
19116         Assume the headers required for C89 freestanding compilers.
19117         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
19118         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
19119         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
19120         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
19121         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
19122         define, since <limits.h> is guaranteed to do that.
19123         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
19124         * lib/exclude.c: Include <stdbool.h> unconditionally.
19125         * lib/tempname.c: Include <stddef.h> unconditionally.
19126         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
19127         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
19128         <stddef.h> does that.
19129         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
19130         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
19131         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
19132         needed.
19133         * lib/xstrtol.c: Likewise.
19134         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
19135         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
19136
19137         * lib/addext.c (addext): Use assignment rather than cast, to avoid
19138         warnings on some platforms.
19139
19140         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19141         arbitrarily.
19142
19143 2003-05-26  Jim Meyering  <jim@meyering.net>
19144
19145         Merge in a change from coreutils:
19146         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
19147         that is guaranteed to be `no'.  Use `no_such_member' to indicate
19148         that condition, rather than `-1' which is slightly misleading.
19149         Change the name of the cache variable to have the gl_ prefix.
19150         Prompted by a patch from Richard Dawe for DJGPP.
19151
19152 2003-05-24  Karl Berry  <karl@gnu.org>
19153
19154         * config/config.guess: update from prep.
19155
19156 2003-05-22  Karl Berry  <karl@gnu.org>
19157
19158         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
19159
19160 2003-05-20  Karl Berry  <karl@gnu.org>
19161
19162         * config/config.guess: update from prep.
19163
19164 2003-05-18  Karl Berry  <karl@gnu.org>
19165
19166         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
19167         might actually be set by the user.
19168
19169         * config/depcomp, install-sh, mdate-sh: update from automake.
19170
19171 2003-05-17  Bruno Haible  <bruno@clisp.org>
19172
19173         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
19174         invalid expansion for AC_EGREP_CPP.
19175         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
19176         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
19177         Suggested by Akim Demaille <akim@epita.fr> in
19178         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
19179
19180 2003-05-12  Jim Meyering  <jim@meyering.net>
19181
19182         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
19183         the space-padded-by-default conversion specifiers, %e, %k, %l.
19184
19185 2003-05-12  Bruno Haible  <bruno@clisp.org>
19186
19187         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
19188         the string is longer than 4 KB.
19189
19190 2003-05-11  Karl Berry  <karl@gnu.org>
19191
19192         * config/config.{guess,sub}: update from prep.
19193
19194 2003-05-09  Bruno Haible  <bruno@clisp.org>
19195
19196         * modules/error: Add m4/strerror_r.m4 to file list.
19197
19198 2003-05-03  Bruno Haible  <bruno@clisp.org>
19199
19200         Upgrade to Unicode-4.0.
19201         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
19202         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
19203         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
19204         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
19205         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
19206         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
19207         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
19208         Change width of U+E0100..U+E01EF from 1 to 0.
19209
19210 2003-04-25  Jim Meyering  <jim@meyering.net>
19211
19212         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
19213         of type size_t, not int.
19214
19215 2003-04-25  Bruno Haible  <bruno@clisp.org>
19216
19217         * lib/copy-file.c: Include <stddef.h>, for size_t.
19218
19219 2003-04-21  Paul Eggert  <eggert@twinsun.com>
19220
19221         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
19222         code which expansion is under static control.  Patch imported from
19223         Akim Demaille's patch to Bison; see
19224         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
19225
19226 2003-04-14  Bruno Haible  <bruno@clisp.org>
19227
19228         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
19229
19230 2003-04-11  Jim Meyering  <jim@meyering.net>
19231
19232         Merge changes from Coreutils.
19233
19234         2003-03-22  Jim Meyering  <jim@meyering.net>
19235
19236         * lib/strftime.c (widen): Cast alloca return value to proper type.
19237
19238         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
19239
19240         From GNU libc.
19241         * lib/strftime.c (my_strftime): Handle very large width
19242         specifications for numeric values correctly.  Improve checks for
19243         overflow.
19244
19245         2003-01-19  Jim Meyering  <jim@meyering.net>
19246
19247         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
19248         definitions.
19249         (nl_get_alt_digit) [! defined my_strftime]: Define.
19250         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
19251         _nl_get_alt_digit and _nl_get_walt_digit.
19252
19253         * lib/strftime.c (my_strftime): Merge in locale-related changes from
19254         libc. These changes have no effect outside of _LIBC.
19255
19256 2003-04-10  Bruno Haible  <bruno@clisp.org>
19257
19258         * modules/findprog: New file.
19259         * MODULES.html.sh (func_all_modules): Add it.
19260
19261 2003-04-10  Bruno Haible  <bruno@clisp.org>
19262
19263         * m4/findprog.m4: New file.
19264         * m4/eaccess.m4: New file.
19265
19266 2003-04-10  Bruno Haible  <bruno@clisp.org>
19267
19268         * lib/findprog.h: New file, from GNU gettext.
19269         * lib/findprog.c: New file, from GNU gettext.
19270
19271 2003-04-05  Jim Meyering  <jim@meyering.net>
19272
19273         Merge changes from Coreutils.
19274
19275         * lib/exclude.h (PARAMS): Remove definition and uses.
19276         * lib/exclude.c: Remove uses of `PARAMS'.
19277
19278         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
19279         Add test-cases for DOS filenames. Declare program_name.
19280         (main): Set up program_name.  Patch by Rich Dawe.
19281
19282         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19283         error from mntctl.
19284         Use mntctl's return value to drive the entry-processing loop, since
19285         we can't rely on the value of the vmt_length member in the last
19286         entry.  On some systems doing so could result in exhausting
19287         virtual memory.  Based in part on a patch from Mike Jetzer.
19288
19289 2003-04-04  Bruno Haible  <bruno@clisp.org>
19290
19291         * modules/linebreak: New file.
19292         * MODULES.html.sh (func_all_modules): Add it.
19293
19294 2003-04-04  Bruno Haible  <bruno@clisp.org>
19295
19296         * m4/linebreak.m4: New file.
19297
19298 2003-04-04  Bruno Haible  <bruno@clisp.org>
19299
19300         * lib/linebreak.h: New file, from GNU gettext.
19301         * lib/linebreak.c: New file, from GNU gettext with slight
19302         modifications.
19303         * lib/lbrkprop.h: New file, from GNU gettext.
19304
19305 2003-04-03  Bruno Haible  <bruno@clisp.org>
19306
19307         * modules/utf8-ucs4: New file.
19308         * modules/utf16-ucs4: New file.
19309         * modules/ucs4-utf8: New file.
19310         * modules/ucs4-utf16: New file.
19311         * MODULES.html.sh (func_all_modules): Add them.
19312
19313 2003-04-03  Bruno Haible  <bruno@clisp.org>
19314
19315         * m4/utf-ucs4.m4: New file.
19316         * m4/ucs4-utf.m4: New file.
19317
19318 2003-04-03  Bruno Haible  <bruno@clisp.org>
19319
19320         * lib/utf8-ucs4.h: New file, from GNU gettext.
19321         * lib/utf16-ucs4.h: New file, from GNU gettext.
19322         * lib/ucs4-utf8.h: New file, from GNU gettext.
19323         * lib/ucs4-utf16.h: New file, from GNU gettext.
19324
19325 2003-04-02  Bruno Haible  <bruno@clisp.org>
19326
19327         * modules/binary-io: New file.
19328         * MODULES.html.sh (func_all_modules): Add it.
19329
19330 2003-04-02  Bruno Haible  <bruno@clisp.org>
19331
19332         * lib/binary-io.h: New file, from GNU gettext.
19333
19334 2003-04-01  Bruno Haible  <bruno@clisp.org>
19335
19336         * modules/pathname: New file.
19337         * MODULES.html.sh (func_all_modules): Add it.
19338
19339 2003-04-01  Bruno Haible  <bruno@clisp.org>
19340
19341         * lib/pathname.h: New file, from GNU gettext.
19342         * lib/concatpath.c: New file, from GNU gettext.
19343
19344 2003-03-30  Bruno Haible  <bruno@clisp.org>
19345
19346         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
19347
19348 2003-03-30  Bruno Haible  <bruno@clisp.org>
19349
19350         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
19351         function chown() doesn't exist.
19352
19353 2003-03-28  Bruno Haible  <bruno@clisp.org>
19354
19355         * modules/copy-file: New file.
19356         * MODULES.html.sh (func_all_modules): Add it.
19357
19358 2003-03-28  Bruno Haible  <bruno@clisp.org>
19359
19360         * m4/copy-file.m4: New file.
19361
19362 2003-03-28  Bruno Haible  <bruno@clisp.org>
19363
19364         * lib/copy-file.h: New file, from GNU gettext.
19365         * lib/copy-file.c: New file, from GNU gettext.
19366
19367 2003-03-18  Jim Meyering  <jim@meyering.net>
19368
19369         * lib/quote.c (quote_n): Fix typo in comment.
19370
19371 2003-03-18  Bruno Haible  <bruno@clisp.org>
19372
19373         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
19374         checking.
19375         * m4/onceonly_2_57.m4: Likewise.
19376
19377 2003-03-17  Bruno Haible  <bruno@clisp.org>
19378
19379         * m4/onceonly.m4: Require autoconf 2.54 or newer.
19380         (m4_quote): Remove macro.
19381         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
19382
19383 2003-03-14  Jim Meyering  <jim@meyering.net>
19384
19385         Merge changes from Coreutils.
19386         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
19387         to be const, in order to avoid warnings.
19388         (obstack_room): Likewise.
19389         (obstack_empty_p): Likewise.
19390
19391 2003-03-14  Bruno Haible  <bruno@clisp.org>
19392
19393         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
19394         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
19395
19396 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19397
19398         Merge changes from Bison.
19399         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
19400         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
19401         when compiling Bison 1.875's `bitset bset = obstack_alloc
19402         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
19403         * lib/hash.c: Include <stdbool.h> unconditionally.
19404
19405 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19406
19407         * m4/onceonly.m4 (m4_quote): New macro.
19408         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
19409         Quote AC_FOREACH variable-expansions properly.
19410
19411 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19412
19413         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
19414
19415 2003-03-09  Paul Eggert  <eggert@twinsun.com>
19416
19417         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
19418         Reported by Bruce Becker; see:
19419         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
19420
19421 2003-03-03  Paul Eggert  <eggert@twinsun.com>
19422             Bruno Haible  <bruno@clisp.org>
19423
19424         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
19425         Reported by John Hughes, see
19426         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
19427
19428 2003-02-20  Bruno Haible  <bruno@clisp.org>
19429
19430         * MODULES.html.sh (func_all_modules): Add poll.
19431
19432 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19433
19434         * modules/poll: New file.
19435
19436 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19437
19438         * lib/poll_.h: New file.
19439         * lib/poll.c: New file.
19440
19441 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19442
19443         * m4/poll.m4: New file.
19444
19445 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19446
19447         * modules/mathl: New file.
19448
19449 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19450
19451         * lib/mathl.h: New file.
19452         * lib/acosl.c: New file.
19453         * lib/asinl.c: New file.
19454         * lib/atanl.c: New file.
19455         * lib/ceill.c: New file.
19456         * lib/cosl.c: New file.
19457         * lib/expl.c: New file.
19458         * lib/floorl.c: New file.
19459         * lib/frexpl.c: New file.
19460         * lib/ldexpl.c: New file.
19461         * lib/logl.c: New file.
19462         * lib/sincosl.c: New file.
19463         * lib/sinl.c: New file.
19464         * lib/sqrtl.c: New file.
19465         * lib/tanl.c: New file.
19466         * lib/trigl.c: New file.
19467         * lib/trigl.h: New file.
19468
19469 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19470
19471         * m4/mathl.m4: New file.
19472
19473 2003-02-18  Bruno Haible  <bruno@clisp.org>
19474
19475         * MODULES.html.sh (func_all_modules): Add mathl.
19476
19477 2003-02-17  Bruno Haible  <bruno@clisp.org>
19478
19479         * modules/mkdtemp: New module.
19480         * MODULES.html.sh (func_all_modules): Add it.
19481
19482 2003-02-17  Bruno Haible  <bruno@clisp.org>
19483
19484         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
19485
19486 2003-02-17  Bruno Haible  <bruno@clisp.org>
19487
19488         * lib/mkdtemp.h: New file, from GNU gettext.
19489         * lib/mkdtemp.c: New file, from GNU gettext.
19490
19491 2003-02-02  Jim Meyering  <jim@meyering.net>
19492
19493         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
19494         e.g. glibc-2.2.93.
19495
19496 2003-01-31  Bruno Haible  <bruno@clisp.org>
19497
19498         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
19499         'rpl_rename'.
19500         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
19501         'rpl_strnlen'.
19502         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
19503         'rpl_strtod'.
19504         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
19505         'rpl_utime'.
19506
19507 2003-01-31  Bruno Haible  <bruno@clisp.org>
19508
19509         * lib/rename.c: #undef rename before defining rpl_rename.
19510         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
19511
19512 2003-01-30  Bruno Haible  <bruno@clisp.org>
19513
19514         * modules/vasnprintf, modules/vasprintf: New modules.
19515         * MODULES.html.sh (func_all_modules): Add them.
19516
19517 2003-01-30  Bruno Haible  <bruno@clisp.org>
19518
19519         * m4/signed.m4: New file, from GNU gettext.
19520         * m4/longdouble.m4: New file, from GNU gettext.
19521         * m4/wchar_t.m4: New file, from GNU gettext.
19522         * m4/wint_t.m4: New file, from GNU gettext.
19523         * m4/vasnprintf.m4: New file.
19524         * m4/vasprintf.m4: New file.
19525
19526 2003-01-30  Bruno Haible  <bruno@clisp.org>
19527
19528         * lib/printf-args.h: New file, from GNU gettext.
19529         * lib/printf-args.c: New file, from GNU gettext.
19530         * lib/printf-parse.h: New file, from GNU gettext.
19531         * lib/printf-parse.c: New file, from GNU gettext.
19532         * lib/vasnprintf.h: New file, from GNU gettext.
19533         * lib/vasnprintf.c: New file, from GNU gettext.
19534         * lib/asnprintf.c: New file, from GNU gettext.
19535         * lib/vasprintf.h: New file, from GNU gettext with modifications.
19536         * lib/vasprintf.c: New file, from GNU gettext.
19537         * lib/asprintf.c: New file, from GNU gettext.
19538
19539 2003-01-29  Bruno Haible  <bruno@clisp.org>
19540
19541         * modules/stpncpy: New module.
19542         * MODULES.html.sh (func_all_modules): Add it.
19543
19544 2003-01-29  Bruno Haible  <bruno@clisp.org>
19545
19546         * m4/stpncpy.m4: New file.
19547
19548 2003-01-29  Bruno Haible  <bruno@clisp.org>
19549
19550         * lib/stpncpy.h: New file, from GNU gettext with modifications.
19551         * lib/stpncpy.c: New file, from GNU gettext with modifications.
19552
19553 2003-01-28  Bruno Haible  <bruno@clisp.org>
19554
19555         * modules/c-ctype: New module.
19556         * MODULES.html.sh (func_all_modules): Add it.
19557
19558 2003-01-28  Bruno Haible  <bruno@clisp.org>
19559
19560         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
19561         Paul Eggert.
19562         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
19563         Paul Eggert.
19564
19565 2003-01-27  Bruno Haible  <bruno@clisp.org>
19566
19567         * modules/xsetenv: New module.
19568         * MODULES.html.sh (func_all_modules): Add it.
19569
19570 2003-01-27  Bruno Haible  <bruno@clisp.org>
19571
19572         * lib/xsetenv.h: New file, from GNU gettext.
19573         * lib/xsetenv.c: New file, from GNU gettext.
19574
19575 2003-01-23  Jim Meyering  <jim@meyering.net>
19576
19577         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
19578         from working on systems without dirfd (at least Irix and OSF1/Tru64).
19579
19580 2003-01-23  Bruno Haible  <bruno@clisp.org>
19581
19582         * modules/minmax: New module.
19583         * MODULES.html.sh (func_all_modules): Add it.
19584
19585 2003-01-23  Bruno Haible  <bruno@clisp.org>
19586
19587         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
19588         Eggert.
19589
19590 2003-01-22  Bruno Haible  <bruno@clisp.org>
19591
19592         * modules/exit: New module.
19593         * MODULES.html.sh (func_all_modules): Add it.
19594
19595 2003-01-22  Bruno Haible  <bruno@clisp.org>
19596
19597         * lib/exit.h: New file, from GNU gettext.
19598
19599 2003-01-19  Bruno Haible  <bruno@clisp.org>
19600
19601         * gnulib-tool: Recognize option --extract-maintainer.
19602         (func_get_maintainer): New function.
19603         * modules/*: Add Maintainer entry.
19604
19605 2003-01-16  Jim Meyering  <jim@meyering.net>
19606
19607         * m4/regex.m4: The `regex' struct is both input and output.
19608         Initialize it before each use.  Patch by Tim Waugh.
19609
19610 2003-01-16  Bruno Haible  <bruno@clisp.org>
19611
19612         * MODULES.html.sh: Add a table of contents. Add the module name as
19613         leftmost column. Add hyperlinks.
19614
19615 2003-01-15  Bruno Haible  <bruno@clisp.org>
19616
19617         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
19618
19619 2003-01-15  Bruno Haible  <bruno@clisp.org>
19620
19621         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
19622         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
19623         suffix.
19624
19625 2003-01-15  Bruno Haible  <bruno@clisp.org>
19626
19627         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
19628
19629 2003-01-15  Bruno Haible  <bruno@clisp.org>
19630
19631         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
19632         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
19633
19634 2003-01-14  Jim Meyering  <jim@meyering.net>
19635
19636         * lib/same.c (same_name): Tweak a comment.
19637
19638 2003-01-14  Bruno Haible  <bruno@clisp.org>
19639
19640         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
19641         when a string comparison is sufficient.
19642
19643 2003-01-14  Bruno Haible  <bruno@clisp.org>
19644
19645         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
19646         'unsigned int'.
19647
19648 2003-01-14  Bruno Haible  <bruno@clisp.org>
19649
19650         * lib/hash-pjw.c: Add comment about low quality of this function.
19651
19652 2003-01-13  Bruno Haible  <bruno@clisp.org>
19653
19654         * modules/stpcpy: Distribute lib/stpcpy.h.
19655         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
19656
19657 2003-01-13  Bruno Haible  <bruno@clisp.org>
19658
19659         * modules/*: Add a description.
19660         * modules/strpbrk: Fix Makefile.am snippet.
19661         * modules/strtoimax: Fix dependencies.
19662         * modules/strtoumax: Likewise.
19663
19664 2003-01-13  Bruno Haible  <bruno@clisp.org>
19665
19666         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
19667         * modules/alloca (Makefile.am): All object files depend on alloca.h.
19668         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
19669
19670 2003-01-13  Bruno Haible  <bruno@clisp.org>
19671
19672         * gnulib-tool (func_create_testdir): Store config/* files in the main
19673         directory.
19674         * config.rpath: Move to ...
19675         * config/config.rpath: ... here.
19676         * modules/gettext: Contains config/config.rpath, not config.rpath.
19677         * modules/iconv: Likewise.
19678
19679 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19680
19681         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19682         to avoid collisions with libcurses and libreadline.
19683
19684         * m4/getstr.m4: Remove.
19685         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
19686
19687 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19688
19689         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19690         to avoid collisions with libcurses and libreadline.
19691
19692         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
19693         * lib/getstr.h, getstr.c: Remove.
19694         * lib/getline.c: Include "getline.h", to check interface.
19695         Move body of old getstr.c here: this defines MIN_CHUNK and
19696         declares getdelim2, which is renamed from getstr.
19697         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
19698
19699         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
19700         All uses changed.
19701         * lib/linebuffer.h: Likewise.
19702         (readline): Remove backward-compatibility macro.
19703
19704 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19705
19706         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19707         to avoid collisions with libcurses and libreadline.
19708         * getstr: Remove.
19709         * MODULES.html.sh: Remove getstr.
19710         * modules/getline: Depend on unlocked-io, not getstr.
19711
19712 2003-01-12  Jim Meyering  <jim@meyering.net>
19713
19714         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
19715
19716 2003-01-10  Bruno Haible  <bruno@clisp.org>
19717
19718         * modules/alloca: Change Makefile.am requirements. Simplify Include
19719         requirements. Add lib/alloca_.h to file list.
19720
19721 2003-01-10  Bruno Haible  <bruno@clisp.org>
19722
19723         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
19724
19725 2003-01-10  Bruno Haible  <bruno@clisp.org>
19726
19727         * lib/alloca_.h: New file.
19728         * lib/getdate.y: Unconditionally include alloca.h.
19729         * lib/makepath.c: Likewise.
19730         * lib/setenv.c: Likewise.
19731         * lib/userspec.c: Likewise.
19732
19733 2003-01-09  Karl Berry  <karl@gnu.org>
19734
19735         * MODULES.html.sh: include `dirname $0` in PATH, to find
19736         gnulib-tool.
19737
19738 2003-01-09  Bruno Haible  <bruno@clisp.org>
19739
19740         * modules/stdbool: Change configure.ac, Makefile.am requirements.
19741         Simplify Include requirements. Add lib/stdbool.h.in to file list.
19742
19743 2003-01-09  Bruno Haible  <bruno@clisp.org>
19744
19745         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
19746
19747 2003-01-09  Bruno Haible  <bruno@clisp.org>
19748
19749         * lib/stdbool.h.in: New file.
19750
19751 2003-01-09  Bruno Haible  <bruno@clisp.org>
19752
19753         * gnulib-tool (func_all_modules): Ignore files ending in ~.
19754         * MODULES.html.sh: Likewise.
19755
19756 2003-01-08  Jim Meyering  <jim@meyering.net>
19757
19758         * lib/full-write.c: Undefine and define-away `const' after inclusion
19759         of errno.h, not before.  Suggestion from Bruno Haible.
19760
19761 2003-01-08  Bruno Haible  <bruno@clisp.org>
19762
19763         * modules/full-read: Depend on full-write.
19764
19765 2003-01-08  Bruno Haible  <bruno@clisp.org>
19766
19767         * lib/safe-read.c: Include specification header first, to ensure its
19768         selfcontainedness.
19769         * lib/full-write.c: Likewise.
19770
19771 2003-01-07  Jim Meyering  <jim@meyering.net>
19772
19773         * lib/full-write.c: Rework so that it may serve to define full_read,
19774         too.
19775         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
19776
19777 2003-01-07  Bruno Haible  <bruno@clisp.org>
19778
19779         * lib/strtoimax.c: Include <stdint.h> as an alternative to
19780         <inttypes.h>.
19781         * lib/xstrtol.h: Likewise.
19782         * lib/xstrtoimax.c: Likewise.
19783         * lib/xstrtoumax.c: Likewise.
19784         * lib/human.h: Likewise.
19785
19786         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
19787         on systems that have <inttypes.h> but not <stdint.h>.
19788
19789 2003-01-07  Bruno Haible  <bruno@clisp.org>
19790
19791         * MODULES.html.sh: Add copyright notice.
19792         (missed_files): Omit CVS directory entries.
19793         (func_module): Make it work with sed-3.02.
19794         * MODULES.txt: Remove file.
19795
19796 2003-01-06  Jim Meyering  <jim@meyering.net>
19797
19798         * lib/version-etc.c: Update year in translatable copyright string.
19799
19800 2003-01-03  Karl Berry  <karl@gnu.org>
19801
19802         * config/config.{guess,sub}: update from prep.
19803
19804 2003-01-02  Karl Berry  <karl@gnu.org>
19805
19806         * doc/COPYING.DOC: belatedly updated to 1.2.
19807
19808 2003-01-01  Karl Berry  <karl@gnu.org>
19809
19810         * gnulib-tool (func_verify_module): report module name $module in
19811         error message, not $1.
19812         * gnulib-tool (create-testdir): don't complain if destdir couldn't
19813         be created, only if it doesn't exist.
19814         * gnulib-tool (last_checkin_date): don't expand the $Date here.
19815
19816 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19817
19818         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
19819
19820 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19821
19822         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
19823         memcmp if strcoll doesn't work.
19824
19825 2002-12-31  Bruno Haible  <bruno@clisp.org>
19826
19827         * lib/utime.c (utime_null): No need to call ftruncate if the file was
19828         nonempty.
19829
19830 2002-12-31  Bruno Haible  <bruno@clisp.org>
19831
19832         * lib/memcoll.c (STRCOLL): New macro.
19833         (memcoll): Use it.
19834
19835 2002-12-31  Bruno Haible  <bruno@clisp.org>
19836
19837         * lib/localcharset.h: New file.
19838         * lib/localcharset.c: Include it.
19839         * lib/unicodeio.c: Likewise.
19840
19841 2002-12-31  Bruno Haible  <bruno@clisp.org>
19842
19843         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
19844         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
19845
19846 2002-12-31  Bruno Haible  <bruno@clisp.org>
19847
19848         * lib/getline.h: Include <stddef.h>, for size_t.
19849
19850         * lib/unicodeio.h: Include <stddef.h>, for size_t.
19851         * lib/unicodeio.c: Don't include <stddef.h>.
19852
19853 2002-12-31  Bruno Haible  <bruno@clisp.org>
19854
19855         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
19856         HAVE_TM_ZONE.
19857
19858 2002-12-24  Karl Berry  <karl@gnu.org>
19859
19860         * config/config.guess: update from prep.
19861
19862 2002-12-24  Bruno Haible  <bruno@clisp.org>
19863
19864         General infrasructure.
19865         * m4/README: Rewritten.
19866         * m4/onceonly.m4: New file.
19867         * m4/onceonly_2_57.m4: New file.
19868
19869         Module atexit.
19870         * m4/atexit.m4: New file.
19871
19872         Module strtod.
19873         * m4/strtod.m4: New file.
19874
19875         Module strtol.
19876         * m4/strtol.m4: New file.
19877
19878         Module strtoul.
19879         * m4/strtoul.m4: New file.
19880
19881         Module memchr.
19882         * m4/memchr.m4: New file.
19883
19884         Module memcmp.
19885         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
19886         (jm_FUNC_MEMCMP): Invoke it.
19887
19888         Module memcpy.
19889         * m4/memcpy.m4: New file.
19890
19891         Module memmove.
19892         * m4/memmove.m4: New file.
19893
19894         Module memset.
19895         * m4/memset.m4: New file.
19896
19897         Module strcspn.
19898         * m4/strcspn.m4: New file.
19899
19900         Module strpbrk.
19901         * m4/strpbrk.m4: New file.
19902
19903         Module strstr.
19904         * m4/strstr.m4: New file.
19905
19906         Module strerror.
19907         * m4/strerror.m4: New file.
19908
19909         Module mktime.
19910         * m4/mktime.m4: Renamed from jm-mktime.m4.
19911         (gl_PREREQ_MKTIME): New macro.
19912         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
19913
19914         Module malloc.
19915         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
19916         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
19917         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
19918
19919         Module realloc.
19920         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
19921         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
19922         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
19923
19924         Module strftime.
19925         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
19926         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
19927         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
19928         gl_TM_GMTOFF.
19929         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
19930
19931         Module xalloc.
19932         * m4/xalloc.m4: New file.
19933
19934         Module alloca.
19935         * m4/alloca.m4: New file.
19936
19937         Module putenv.
19938         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
19939         (jm_FUNC_PUTENV): Invoke it.
19940
19941         Module setenv.
19942         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
19943         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
19944         when invoked twice.
19945         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
19946         gt_FUNC_SETENV.
19947
19948         Module memrchr.
19949         * m4/memrchr.m4: New file.
19950
19951         Module stpcpy.
19952         * m4/stpcpy.m4: New file.
19953
19954         Module strcase.
19955         * m4/strcase.m4: New file.
19956
19957         Module strdup.
19958         * m4/strdup.m4: New file.
19959
19960         Module strnlen.
19961         * m4/strnlen.m4: New file.
19962
19963         Module strndup.
19964         * m4/strndup.m4: New file.
19965
19966         Module xstrtod.
19967         * m4/xstrtod.m4: New file.
19968
19969         Module xstrtol.
19970         * m4/xstrtol.m4: New file.
19971
19972         Module getdate.
19973         * m4/getdate.m4: New file.
19974
19975         Module unlocked-io.
19976         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
19977         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
19978         * m4/jm-glibc-io.m4n: Remove file.
19979
19980         Module long-options.
19981         * m4/long-options.m4: New file.
19982
19983         Module md5.
19984         * m4/md5.m4: New file.
19985
19986         Module sha.
19987         * m4/sha.m4: New file.
19988
19989         Module getstr.
19990         * m4/getstr.m4: New file.
19991
19992         Module getline.
19993         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
19994         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
19995         <sys/types.h>, for size_t. Use the function name gnu_getline, not
19996         simply getline. Infoke gl_PREREQ_GETLINE.
19997
19998         Module obstack.
19999         * m4/obstack.m4: New file.
20000
20001         Module hash.
20002         * m4/hash.m4: New file.
20003
20004         Module readtokens.
20005         * m4/readtokens.m4: New file.
20006
20007         Module strverscmp.
20008         * m4/strverscmp.m4: New file.
20009
20010         Module stdbool.
20011         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
20012         OSF/1.
20013
20014         Module strtoll.
20015         * m4/strtoll.m4: New file.
20016
20017         Module strtoull.
20018         * m4/strtoull.m4: New file.
20019
20020         Module strtoimax.
20021         * m4/strtoimax.m4: New file.
20022
20023         Module strtoumax.
20024         * m4/strtoumax.m4: New file.
20025
20026         Module xstrtoimax.
20027         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
20028         jm_AC_PREREQ_XSTRTOIMAX.
20029         Moved the strtol prerequisites to strtol.m4.
20030         Moved the strtoll prerequisites to strtoll.m4.
20031         Moved the strtoimax prerequisites to strtoimax.m4.
20032
20033         Module xstrtoumax.
20034         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
20035         jm_AC_PREREQ_XSTRTOUMAX.
20036         Moved the strtoul prerequisites to strtoul.m4.
20037         Moved the strtoull prerequisites to strtoull.m4.
20038         Moved the strtoumax prerequisites to strtoumax.m4.
20039
20040         Module chown.
20041         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
20042         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
20043
20044         Module dup2.
20045         * m4/dup2.m4: New file.
20046
20047         Module ftruncate.
20048         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
20049         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
20050
20051         Module getgroups.
20052         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
20053         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
20054
20055         Module gettimeofday.
20056         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
20057         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
20058         gl_PREREQ_GETTIMEOFDAY.
20059
20060         Module mkdir.
20061         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
20062         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
20063
20064         Module mkstemp.
20065         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
20066         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
20067         jm_AC_TYPE_UINTMAX_T.
20068         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
20069
20070         Module stat.
20071         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
20072         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
20073
20074         Module lstat.
20075         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
20076         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
20077
20078         Module timespec.
20079         * m4/timespec.m4 (gl_TIMESPEC): New macro.
20080         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
20081         * m4/st_mtim.m4: Indentation.
20082
20083         Module nanosleep.
20084         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
20085         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
20086         gl_PREREQ_NANOSLEEP.
20087
20088         Module regex.
20089         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
20090         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
20091         (gl_REGEX): New macro.
20092
20093         Module rename.
20094         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
20095         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
20096
20097         Module rmdir.
20098         * m4/rmdir.m4: New file.
20099
20100         Module utime.
20101         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
20102         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
20103         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
20104
20105         Module dirname.
20106         * m4/dirname.m4: New file.
20107
20108         Module getopt.
20109         * m4/getopt.m4: New file.
20110
20111         Module unistd-safer.
20112         * m4/unistd-safer.m4: New file.
20113
20114         Module fnmatch.
20115         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
20116         declaration.
20117         (gl_PREREQ_FNMATCH_EXTRA): New macro.
20118         (gl_FUNC_FNMATCH_POSIX): New macro.
20119         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
20120         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
20121         simply fnmatch.
20122
20123         Module exclude.
20124         * m4/exclude.m4: New file.
20125
20126         Module human.
20127         * m4/human.m4: New file.
20128
20129         Module acl.
20130         * m4/acl.m4: Nop.
20131
20132         Module backupfile.
20133         * m4/backupfile.m4: New file.
20134         * m4/d-ino.m4: Indentation.
20135
20136         Module fsusage.
20137         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
20138         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
20139         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
20140
20141         Module dirfd.
20142         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
20143         requirements.
20144
20145         Module euidaccess.
20146         * m4/euidaccess.m4: New file.
20147
20148         Module file-type.
20149         * m4/file-type.m4: New file.
20150
20151         Module fileblocks.
20152         * m4/fileblocks.m4: New file.
20153
20154         Module filemode.
20155         * m4/filemode.m4: New file.
20156
20157         Module isdir.
20158         * m4/isdir.m4: New file.
20159
20160         Module lchown.
20161         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
20162         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
20163
20164         Module makepath.
20165         * m4/makepath.m4: New file.
20166
20167         Module modechange.
20168         * m4/modechange.m4: New file.
20169
20170         Module mountlist.
20171         * m4/mountlist.m4: New file.
20172         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
20173         Indentation.
20174
20175         Module path-concat.
20176         * m4/path-concat.m4: New file.
20177
20178         Module pathmax.
20179         * m4/pathmax.m4: New file.
20180
20181         Module same.
20182         * m4/same.m4: New file.
20183
20184         Module save-cwd.
20185         * m4/save-cwd.m4: New file.
20186
20187         Module savedir.
20188         * m4/savedir.m4: New file.
20189
20190         Module xgetcwd.
20191         * m4/xgetcwd.m4: New file.
20192         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
20193
20194         Module xreadlink.
20195         * m4/xreadlink.m4: New file.
20196
20197         Module safe-read.
20198         * m4/safe-read.m4: New file.
20199
20200         Module safe-write.
20201         * m4/safe-write.m4: New file.
20202
20203         Module closeout.
20204         * m4/closeout.m4: New file.
20205
20206         Module stdio-safer.
20207         * m4/stdio-safer.m4: New file.
20208
20209         Module getpass.
20210         * m4/getpass.m4: New file.
20211
20212         Module getugroups.
20213         * m4/getugroups.m4: New file.
20214
20215         Module group-member.
20216         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
20217         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
20218
20219         Module idcache.
20220         * m4/idcache.m4: New file.
20221
20222         Module userspec.
20223         * m4/userspec.m4: New file.
20224
20225         Module gettime.
20226         * m4/clock_time.m4: New file.
20227         * m4/gettime.m4: New file.
20228
20229         Module settime.
20230         * m4/settime.m4: New file.
20231
20232         Module posixtm.
20233         * m4/posixtm.m4: New file.
20234
20235         Module gethostname.
20236         * m4/gethostname.m4: New file.
20237
20238         Module canon-host.
20239         * m4/canon-host.m4: New file.
20240
20241         Module gettext.
20242         * m4/codeset.m4: New file, from gettext-0.11.5.
20243         * m4/gettext.m4: New file, from gettext-0.11.5.
20244         * m4/glibc21.m4: New file, from gettext-0.11.5.
20245         * m4/iconv.m4: New file, from gettext-0.11.5.
20246         * m4/intdiv0.m4: New file, from gettext-0.11.5.
20247         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
20248         * m4/inttypes.m4: New file, from gettext-0.11.5.
20249         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
20250         * m4/isc-posix.m4: New file, from gettext-0.11.5.
20251         * m4/lcmessage.m4: New file, from gettext-0.11.5.
20252         * m4/lib-ld.m4: New file, from gettext-0.11.5.
20253         * m4/lib-link.m4: New file, from gettext-0.11.5.
20254         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
20255         * m4/progtest.m4: New file, from gettext-0.11.5.
20256         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
20257         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
20258         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
20259
20260         Module localcharset.
20261         * m4/localcharset.m4: New file.
20262
20263         Module hard-locale.
20264         * m4/hard-locale.m4: New file.
20265
20266         Module mbswidth.
20267         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
20268         onceonly macros.
20269         * m4/mbrtowc.m4: Add comment.
20270
20271         Module memcasecmp.
20272         * m4/memcasecmp.m4: New file.
20273
20274         Module memcoll.
20275         * m4/memcoll.m4: New file.
20276
20277         Module unicodeio.
20278         * m4/unicodeio.m4: New file.
20279
20280         Module rpmatch.
20281         * m4/rpmatch.m4: New file.
20282
20283         Module yesno.
20284         * m4/yesno.m4: New file.
20285
20286         Module exitfail.
20287         * m4/exitfail.m4: New file.
20288
20289         Module c-stack.
20290         * m4/c-stack.m4 (gl_C_STACK): New macro.
20291         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
20292
20293         Module error.
20294         * m4/error.m4 (gl_ERROR): New macro.
20295         (jm_PREREQ_ERROR): Use onceonly macros.
20296
20297         Module fatal.
20298         * m4/fatal.m4: New file.
20299
20300         Module getloadavg.
20301         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
20302         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
20303
20304         Module getpagesize.
20305         * m4/getpagesize.m4: New file.
20306
20307         Module getusershell.
20308         * m4/getusershell.m4: New file.
20309
20310         Module physmem.
20311         * m4/physmem.m4: New file.
20312
20313         Module posixver.
20314         * m4/posixver.m4: New file.
20315
20316         Module quotearg.
20317         * m4/quotearg.m4: New file.
20318
20319         Module quote.
20320         * m4/quote.m4: New file.
20321
20322         Module readutmp.
20323         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
20324
20325         Module sig2str.
20326         * m4/sig2str.m4: New file.
20327
20328         Other.
20329         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
20330         ulonglong.m4.
20331         * m4/intmax_t.m4: New file.
20332         * m4/d-type.m4: Indentation.
20333         * m4/jm-macros.m4: Update.
20334         * m4/prereq.m4 (jm_PREREQ): Update.
20335         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
20336         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
20337         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
20338         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
20339         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
20340         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
20341         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
20342         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
20343         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
20344         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
20345         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
20346         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
20347         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
20348         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
20349         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
20350         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
20351         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
20352         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
20353         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
20354
20355 2002-12-24  Bruno Haible  <bruno@clisp.org>
20356
20357         * MODULES.txt: Update according to m4/ changes.
20358
20359         Module gettext.
20360         * config.rpath: New file, from gettext-0.11.5.
20361
20362         * modules/*: New module descriptions.
20363         * gnulib-tool: New file.
20364         * MODULES.html.sh: New file.
20365
20366 2002-12-21  Karl Berry  <karl@gnu.org>
20367
20368         * doc/fdl.texi: update to version 1.2.
20369
20370 2002-12-19  Karl Berry  <karl@gnu.org>
20371
20372         * config/config.guess: update from prep.
20373
20374 2002-12-18  Bruno Haible  <bruno@clisp.org>
20375
20376         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
20377         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
20378
20379 2002-12-17  Bruno Haible  <bruno@clisp.org>
20380
20381         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
20382         stdlib.h, string.h.
20383
20384 2002-12-17  Bruno Haible  <bruno@clisp.org>
20385
20386         * lib/canon-host.c (strdup): Remove unused declaration.
20387
20388         * lib/fsusage.c: Include full_read.h.
20389         (get_fs_usage): Use full_read instead of safe_read.
20390
20391         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
20392
20393 2002-12-12  Karl Berry  <karl@gnu.org>
20394
20395         * config/config.guess: update from prep.
20396
20397 2002-12-11  Bruno Haible  <bruno@clisp.org>
20398
20399         * m4/setenv.m4: New file, from gettext-0.11.5.
20400
20401 2002-12-11  Bruno Haible  <bruno@clisp.org>
20402
20403         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
20404         not unsetenv().
20405         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
20406         modifications:
20407
20408         2002-12-11  Bruno Haible  <bruno@clisp.org>
20409
20410                 * setenv.c (alloca): Fall back to malloc.
20411                 (freea): New macro.
20412                 (setenv): Use freea() to free memory allocated with alloca().
20413
20414         2002-11-13  Bruno Haible  <bruno@clisp.org>
20415
20416                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
20417                 function declarations.
20418                 * unsetenv.c (unsetenv): Likewise.
20419
20420         2002-03-04  Bruno Haible  <bruno@clisp.org>
20421
20422                 Portability to AIX 4.3.3.
20423                 * unsetenv.c: New file, extracted from setenv.c.
20424                 * setenv.c: Move the unsetenv() function to unsetenv.c.
20425
20426         2001-12-20  Bruno Haible  <bruno@clisp.org>
20427
20428                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
20429                 use malloc instead. For SunOS 4.
20430
20431         2001-12-11  Bruno Haible  <bruno@clisp.org>
20432
20433                 * setenv.c: Declare alloca.
20434                 (compar_fn_t): New typedef.
20435                 (KNOWN_VALUE, STORE_VALUE): Use it.
20436
20437         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
20438         setenv.h.
20439
20440 2002-12-10  Paul Eggert  <eggert@twinsun.com>
20441
20442         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
20443         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
20444         Choose values that are less likely to collide with system fnmatch
20445         options.
20446         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
20447         defined (e.g., a pure POSIX system).
20448         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
20449         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
20450
20451 2002-12-06  Paul Eggert  <eggert@twinsun.com>
20452
20453         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
20454         a pain in practice to deal with generated m4 files.  This change
20455         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
20456
20457         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
20458         and jm-glibc-io.m4, as they are no longer a special case.
20459         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
20460         kludge and the auto-generation stuff.  Check only whether the
20461         functions are declared, not whether they exist, since older hosts
20462         that don't declare the functions can't use the optimization anyway.
20463
20464 2002-12-06  Jim Meyering  <jim@meyering.net>
20465
20466         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
20467
20468         Merge in changes from libc's misc/error.c, in preparation
20469         for the merge of gnulib's changes back into libc.
20470
20471         * lib/error.c (_): Define only if not already defined.
20472         Move definition to follow all #include directives.
20473         Include unlocked-io.h only if !_LIBC.
20474         [_LIBC]: Include <libio/libioP.h>.
20475         [USE_IN_LIBIO]: Include <libio/iolibio.h>
20476         (fflush): Tweak definition to use INTUSE.
20477         (putc): Define.
20478
20479 2002-12-05  Paul Eggert  <eggert@twinsun.com>
20480
20481         * lib/alloca.c [defined emacs]: Include "lisp.h".
20482         (xalloc_die) [defined emacs]: New macro.
20483         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
20484         [! defined emacs]: Include <xalloc.h>.
20485         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
20486         (pointer): Typedef to POINTER_TYPE *.
20487         (malloc): Remove decl; we now always use xmalloc.
20488         (alloca): Use old-style definition, since Emacs needs this.
20489         Check for arithmetic overflow when computing combined size.
20490
20491 2002-12-04  Paul Eggert  <eggert@twinsun.com>
20492
20493         Do not generate unlocked-io.h automatically, since it's easier to
20494         maintain it by hand.
20495
20496         * lib/unlocked-io.h: New file, from GNU diffutils,
20497         but with proper copyright notice and attribution.
20498         * lib/gen-uio: Remove.
20499         * lib/Makefile.am: Add copyright notice.
20500         (libfetish_a_SOURCES): Add unlocked-io.h.
20501         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
20502         (DISTCLEANFILES, io_functions): Remove macros.
20503         (EXTRA_DIST): Remove gen_uio.
20504         (unlocked-io.h): Remove rule.
20505
20506 2002-12-04  Jim Meyering  <jim@meyering.net>
20507
20508         Reflect the fact that stat.c and lstat.c are no longer generated.
20509         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
20510         (DISTCLEANFILES): Likewise.
20511         (EXTRA_DIST): Likewise.
20512         (all_local): Don't depend on stat.c or lstat.c.
20513         (stat.c, lstat.c): Remove rules.
20514         (EXTRA_DIST): Remove xstat.in.
20515
20516         * lib/xstat.in: Remove file.  Contents moved into stat.c.
20517         * lib/stat.c: New file.  Contents mostly from xstat.in.
20518         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
20519         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
20520
20521         * lib/safe-read.c: Rework so that it may serve to define safe_write,
20522         too.
20523         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
20524
20525 2002-12-03  Jim Meyering  <jim@meyering.net>
20526
20527         * lib/safe-read.c, safe-write.c: Change variable names and comments,
20528         but not semantics, to minimize the differences between these two files.
20529         (safe_read): Change comment to mention SAFE_READ_ERROR.
20530
20531         * lib/safe-read.c (IS_EINTR): Define.
20532         (safe_read): Use IS_EINTR in place of in-function cpp directives.
20533
20534 2002-12-02  Jim Meyering  <jim@meyering.net>
20535
20536         * lib/safe-read.c (EINTR): Define.
20537         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20538         (INT_MAX): Provide fallback.
20539         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
20540
20541         * lib/safe-read.h (SAFE_READ_ERROR): Define.
20542
20543 2002-12-02  Bruno Haible  <bruno@clisp.org>
20544
20545         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
20546         Define, taken from safe-read.c.
20547         (INT_MAX): Provide fallback.
20548         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
20549         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
20550
20551         * lib/safe-read.c (EINTR): Remove definition.
20552         (safe_read): Don't use EINTR if it is absent.
20553
20554 2002-12-01  Jim Meyering  <jim@meyering.net>
20555
20556         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
20557         zero.
20558         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
20559
20560 2002-11-27  Paul Eggert  <eggert@twinsun.com>
20561
20562         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
20563         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
20564         with `if (! (value < limit)) abort ();', for readability.
20565
20566 2002-11-26  Karl Berry  <karl@gnu.org>
20567
20568         * lib/strdup.c: copy from libc again, with jim's ok.
20569         * lib/.cppi-disable: re-add strdup.c
20570
20571 2002-11-25  Karl Berry  <karl@gnu.org>
20572
20573         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
20574         instead of "strtol.c".
20575
20576 2002-11-25  Karl Berry  <karl@gnu.org>
20577
20578         * config/install-sh: update from automake for variable quoting, $0 in
20579         error msgs, etc.
20580
20581         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
20582         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
20583         entry.
20584
20585 2002-11-25  Jim Meyering  <jim@meyering.net>
20586
20587         * lib/mktime.c: Sync from libc, now that it has the latest fix.
20588
20589 2002-11-24  Karl Berry  <karl@gnu.org>
20590
20591         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
20592         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
20593
20594 2002-11-24  Jim Meyering  <jim@meyering.net>
20595
20596         Update from coreutils:
20597
20598         * lib/mktime.c: Merge in changes from libc.
20599
20600         Avoid a link-time failure on some Linux systems.
20601         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
20602         (otherwise).
20603         (__mon_yday): Declare with the STATIC attribute.
20604         (__mktime_internal): Likewise.
20605         Based on a report from Greg Schafer.
20606
20607 2002-11-23  Jim Meyering  <jim@meyering.net>
20608
20609         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
20610         Use `unsigned', not `int', as type of index.
20611
20612         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
20613
20614         * lib/fsusage.c: Remove unneeded parentheses around operands of
20615         `defined'.
20616
20617 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20618
20619         * lib/quotearg.h: Allow multiple inclusion by surrounding with
20620         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
20621         so that we can be included first.
20622         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
20623         * lib/quotearg.c: Include quotearg.h immediately after config.h.
20624         No need to include stddef.h or sys/types.h any more.
20625         Surround local include files with "", not "<>".
20626         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
20627         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
20628         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
20629         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
20630         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
20631         (ISPRINT): Remove; no longer needed now that we assume C89.
20632
20633         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
20634         Preserve errno.
20635
20636         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
20637         quotearg_char): Use SIZE_MAX rather than
20638         (size_t) -1 when we are talking about "infinity".
20639
20640         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
20641
20642 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20643
20644         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
20645         hint that one should use `if (! x) abort ();' rather than `assert
20646         (x);', and anyway it's one less thing to worry about configuring.
20647         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
20648         hash_rehash, hash_insert): Use abort rather than assert.
20649
20650 2002-11-22  Bruno Haible  <bruno@clisp.org>
20651
20652         * lib/safe-read.h: Assume C89. Add comments.
20653         (safe_read): Change return type to size_t.
20654         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
20655         byte counts > SSIZE_MAX correctly.
20656         * lib/safe-write.h: New file.
20657         * lib/safe-write.c: New file.
20658         * lib/full-read.h: New file.
20659         * lib/full-read.c: New file.
20660         * lib/full-write.h: Assume C89. Add comments.
20661         * lib/full-write.c: Include safe-write.h.
20662         (full_write): Rewritten to use safe_write.
20663         Suggested by Jim Meyering and Paul Eggert.
20664
20665 2002-11-21  Jim Meyering  <jim@meyering.net>
20666
20667         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
20668
20669         Merge in changes from the coreutils.
20670
20671         2002-09-25  Paul Eggert  <eggert@twinsun.com>
20672         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
20673         <stdint.h>.
20674         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
20675         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
20676         int.  Work more efficiently if X is the same width as uintmax_t.
20677         Do not compare X to -1, to avoid bogus compiler warning.
20678         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
20679         Don't assume that f_frsize and f_bsize are the same type.
20680
20681         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
20682         warning on FreeBSD.
20683
20684         * lib/makepath.c (make_path): Restore umask *before* creating the final
20685         component.
20686         (make_path): Minor reformatting.
20687
20688         * lib/xmalloc.c: Adjust to work with new autoconf macros,
20689         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
20690         HAVE_MALLOC/HAVE_REALLOC.
20691
20692         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
20693         dummy ones.  At least on GNU/Linux systems, `auto' means something
20694         else.
20695         From Michael Stone.
20696
20697 2002-11-21  Bruno Haible  <bruno@clisp.org>
20698
20699         Remove case insensitive option matching.
20700         * lib/argmatch.h (argcasematch): Remove declaration.
20701         (ARGCASEMATCH): Remove macro.
20702         (__xargmatch_internal): Remove case_sensitive argument.
20703         (XARGMATCH): Update.
20704         (XARGCASEMATCH): Remove macro.
20705         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
20706         case_sensitive argument.
20707         (argcasematch): Remove function.
20708         (__xargmatch_internal): Remove case_sensitive argument.
20709         (main): Use XARGMATCH instead of XARGCASEMATCH.
20710
20711         * lib/xmalloc.c: Change compile-time error message. Add comment about
20712         required autoconf version.
20713
20714 2002-11-20  Paul Eggert  <eggert@twinsun.com>
20715
20716         Merge argmatch cleanups from Bison.  Assume C89.
20717
20718         * lib/argmatch.c: Include config.h here, not in argmatch.h.
20719         Include stdlib.h, for EXIT_FAILURE.
20720         Always include <string.h>, since we assume C89.
20721         (EXIT_FAILURE): Remove pre-C89 bug workaround.
20722         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
20723         Include <stddef.h> instead, since it's all we need for size_t.
20724         (PARAMS): Remove.  All uses removed.
20725         (ARRAY_CARDINALITY): Do not bother to #undef.
20726         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
20727         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20728         Remove unnecessary parentheses.
20729         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20730         Insert necessary parentheses.
20731         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
20732         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
20733
20734 2002-11-19  Bruno Haible  <bruno@clisp.org>
20735
20736         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
20737         * lib/mbswidth.h: Include <stddef.h>, for size_t.
20738
20739         * lib/mbswidth.h (PARAMS): Remove macro.
20740         (mbswidth, mbsnwidth): Use ANSI C function declarations.
20741         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
20742
20743         * lib/gcd.h (PARAMS): Remove macro.
20744         (gcd): Use ANSI C function declarations.
20745         * lib/gcd.c (gcd): Likewise.
20746
20747 2002-11-15  Bruno Haible  <bruno@clisp.org>
20748
20749         * lib/strcspn.c: Include <stddef.h>.
20750         (strcspn): Use ANSI C function declaration. Change return type to
20751         size_t. Use NULL.
20752         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
20753         (strpbrk): Use NULL.
20754         * lib/strpbrk.h (PARAMS): Remove macro.
20755         (strpbrk): Use ANSI C function declaration.
20756         * lib/strstr.c: Don't include <sys/types.h>.
20757         * lib/strstr.h (PARAMS): Remove macro.
20758         (strstr): Use ANSI C function declarations.
20759
20760 2002-11-14  Karl Berry  <karl@gnu.org>
20761
20762         * config/mkinstalldirs: `do' on separate line, instead of
20763         `for var; do'.
20764
20765 2002-11-06  Bruno Haible  <bruno@clisp.org>
20766
20767         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
20768         * lib/gcd.c (gcd): Likewise.
20769
20770 2002-11-05  Bruno Haible  <bruno@clisp.org>
20771
20772         * lib/gcd.h: New file, from gettext-0.11.5.
20773         * lib/gcd.c: New file, from gettext-0.11.5.
20774
20775 2002-11-05  Bruno Haible  <bruno@clisp.org>
20776
20777         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20778         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20779         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20780         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20781
20782         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
20783         <libintl.h>.
20784         * lib/makepath.c: Include gettext.h instead of <locale.h> and
20785         <libintl.h>.
20786
20787         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
20788         * lib/human.c: Include gettext.h instead of <libintl.h>.
20789         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
20790         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
20791         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
20792         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
20793         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
20794         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
20795         (textdomain): Remove definition.
20796         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
20797
20798         * lib/long-options.c: Remove include of <libintl.h> and definition of
20799         _.
20800         * lib/same.c: Remove include of <libintl.h> and definition of _.
20801
20802 2002-11-04  Owen Taylor  <otaylor@redhat.com>
20803
20804         * lib/config.charset: A few additions for Solaris.
20805
20806 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20807
20808         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
20809         * lib/localcharset.c (locale_charset): Declare as extern "C".
20810
20811 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20812
20813         * lib/config.charset: msdos in uk_UA uses CP1125.
20814
20815 2002-11-04  Bruno Haible  <bruno@clisp.org>
20816
20817         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
20818         * lib/strcase.h: New file, from GNU gettext-0.11.5.
20819         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
20820         * lib/strstr.h: New file, from GNU gettext-0.11.5.
20821         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
20822
20823 2002-11-04  Bruno Haible  <bruno@clisp.org>
20824
20825         * lib/localcharset.c (locale_charset): Don't return an empty string.
20826
20827 2002-11-04  Bruno Haible  <bruno@clisp.org>
20828
20829         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
20830         aliases.
20831
20832 2002-11-04  Bruno Haible  <bruno@clisp.org>
20833
20834         * lib/config.charset: Update for newest glibc. Add canonical names
20835         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
20836
20837 2002-11-04  Bruno Haible  <bruno@clisp.org>
20838
20839         * lib/config.charset: Add support for NetBSD.
20840
20841 2002-11-04  Bruno Haible  <bruno@clisp.org>
20842
20843         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
20844
20845 2002-11-01  Bruno Haible  <bruno@clisp.org>
20846
20847         * configure.in: Add AC_CONFIG_AUX_DIR call.
20848         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
20849         test/Makefile.
20850         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
20851
20852 2002-09-28  Karl Berry  <karl@gnu.org>
20853
20854         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
20855         installed automake until the next release, since changes have been
20856         made.
20857
20858 2002-09-25  Karl Berry  <karl@gnu.org>
20859
20860         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
20861         * lib/getopt*: copy from libc/posix.
20862         * lib/gettext.h: copy from gettext.
20863         * lib/.cppi-disable: add strdup.c, gettext.h.
20864
20865 2002-09-25  Karl Berry  <karl@gnu.org>
20866
20867         * config/srclist.txt: enable gettext.h check.
20868         * config/config.{guess,sub}: update from prep.
20869         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
20870                 from automake 1.6.3.
20871         See srclist*.
20872
20873 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
20874
20875         * regex.c (PATFETCH): Remove the translating fetch.
20876         (PATFETCH_RAW): Rename to PATFETCH.
20877         (set_image_of_range): New fun.
20878         (SET_RANGE_TABLE_WORK_AREA): Use it.
20879         (regex_compile): Don't translate the pattern chars so eagerly.
20880         Only do it when inserting an `exactn' bytecode or when handling
20881         a char-range.
20882         (mutually_exclusive_p): Avoid empty statement.
20883
20884 2002-07-06  Jim Meyering  <meyering@lucent.com>
20885
20886         * m4/README: Don't mention Makefile.am.in.
20887         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
20888
20889 2002-07-01  Jim Meyering  <meyering@lucent.com>
20890
20891         * lib/c-stack.c: Include sys/time.h.
20892         From Volker Borchert.
20893
20894 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20895
20896         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
20897
20898 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20899
20900         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
20901         New macro.  Use it uniformly instead of
20902         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
20903         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
20904         reported by Vin Shelton.
20905
20906 2002-06-22  Paul Eggert  <eggert@twinsun.com>
20907
20908         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
20909         Do not assume SA_SIGINFO behavior.
20910         Bug reported by Jim Meyering on NetBSD 1.5.2.
20911
20912 2002-06-22  Jim Meyering  <meyering@lucent.com>
20913
20914         * m4/c-stack.m4: New file, from diffutils-2.8.2.
20915         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
20916
20917         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
20918         now that configure.ac uses AC_GNU_SOURCE.
20919         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
20920         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
20921
20922         Update to latest tools.  Suggestions from Paul Eggert.
20923         * m4/stdbool.m4: New file, from diffutils-2.8.2.
20924         * m4/gnu-source.m4: Update from diffutils-2.8.2.
20925         * m4/fnmatch.m4: Likewise.
20926         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
20927         to AC_HEADER_STDBOOL
20928
20929 2002-06-22  Jim Meyering  <meyering@lucent.com>
20930
20931         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
20932         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
20933
20934 2002-06-22  Jim Meyering  <meyering@lucent.com>
20935
20936         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
20937
20938         * lib/exitfail.c, exitfail.h: Likewise.
20939         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
20940
20941         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
20942         of fnmatch.h.
20943         (EXTRA_DIST): Add fnmatch_loop.c.
20944         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
20945
20946         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
20947         * lib/fnmatch.c: Update from diffutils-2.8.2.
20948         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
20949         * lib/fnmatch.h: Remove file.
20950
20951 2002-06-21  Jim Meyering  <meyering@lucent.com>
20952
20953         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
20954         * m4/mbrtowc.m4: Likewise.
20955
20956         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
20957         * m4/mbswidth.m4: Reflect name change:
20958         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
20959         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
20960
20961         * m4/lib-link.m4: Update from gettext-0.11.2.
20962         * m4/gettext.m4: Likewise.
20963
20964         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
20965         From Alfred M. Szmidt.
20966
20967 2002-06-18  Paul Eggert  <eggert@twinsun.com>
20968
20969         * lib/file-type.h: Report an error if neither S_ISREG nor
20970         S_IFREG is defined, instead of using a test specific to glibc
20971         2.2.  This should be safe, since POSIX requires S_ISREG and
20972         Unix Version 7 had S_IFREG.  We don't need to check for
20973         <sys/types.h> since we don't use any symbols that it defines.
20974
20975 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
20976
20977         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
20978         $@-t, so that each temporary file name is unique and valid in the first
20979         8 characters, for operation under DOS.
20980
20981 2002-06-15  Paul Eggert  <eggert@twinsun.com>
20982
20983         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
20984
20985 2002-06-15  Jim Meyering  <meyering@lucent.com>
20986
20987         Work even with DJGPP 2.03, which lacks support for symlinks.
20988         From Richard Dawe.
20989         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
20990         is defined.
20991         * lib/lchown.c (S_ISLNK): Likewise.
20992
20993 2002-06-15  Jim Meyering  <meyering@lucent.com>
20994
20995         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
20996         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
20997         have been included before this file.
20998
20999 2002-06-14  Jim Meyering  <meyering@lucent.com>
21000
21001         * lib/file-type.h: Use the version from diffutils-2.8.2.
21002         * lib/file-type.c: Likewise.
21003
21004 2002-06-07  Jim Meyering  <meyering@lucent.com>
21005
21006         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
21007         They're needed at least for NetBSD 1.5.2.
21008         ($statxfs_includes): Include those same headers.
21009         ($statxfs_includes): Include sys/vfs.h if available.
21010         ($statxfs_includes): Likewise for sys/statvfs.h.
21011         Check for the following members in both structs statfs and statvfs:
21012         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
21013
21014 2002-06-01  Jim Meyering  <meyering@lucent.com>
21015
21016         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
21017         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
21018
21019 2002-05-28  Jim Meyering  <meyering@lucent.com>
21020
21021         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
21022         Reported by Volker Borchert.
21023
21024 2002-05-27  Jim Meyering  <meyering@lucent.com>
21025
21026         Fix a problem seen only on nonconforming systems whereby ls.c's
21027         use of localtime, and then of gettimeofday would cause trouble:
21028         the localtime call used to initialize rpl_gettimeofday's save
21029         mechanism would clobber ls's current local time information so
21030         that in any long listing the first file would always be listed
21031         with date 1970-01-01.  Analysis by Volker Borchert.
21032
21033         * lib/gettimeofday.c (localtime): Undefine.
21034         (rpl_localtime): New function.
21035
21036 2002-05-27  Jim Meyering  <meyering@lucent.com>
21037
21038         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
21039         localtime.
21040
21041         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
21042         use the replacement function; it wouldn't resolve at link time.
21043         Reported by Volker Borchert.
21044
21045 2002-05-22  Jim Meyering  <meyering@lucent.com>
21046
21047         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
21048         file-type.h.
21049         * lib/file-type.h: New file.
21050         * lib/file-type.c (file_type): New file/function.  Extracted from
21051         diffutils.
21052
21053 2002-04-30  Jim Meyering  <meyering@lucent.com>
21054
21055         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
21056
21057 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21058
21059         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
21060
21061 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21062
21063         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
21064         Do not check for alloca.h (no longer used) or stdbool.h (was never
21065         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
21066
21067 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21068
21069         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
21070
21071 2002-04-29  Jim Meyering  <meyering@lucent.com>
21072
21073         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
21074         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
21075         Use AC_FUNC_STRNLEN here instead.
21076
21077         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
21078         With autoconf-2.53a, it's part of AC_PROG_CC.
21079
21080 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21081
21082         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
21083         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
21084
21085 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21086
21087         * lib/sig2str.h, lib/sig2str.c: New files.
21088         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
21089
21090 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21091
21092         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
21093         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
21094         of 127, since 64 is the largest conceivable number for ancient
21095         nonstandard hosts.
21096         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
21097
21098 2002-04-28  Jim Meyering  <meyering@lucent.com>
21099
21100         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
21101
21102 2002-04-24  Jim Meyering  <meyering@lucent.com>
21103
21104         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
21105         (jm_PREREQ): Use it.
21106
21107         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
21108         mach/mach.h fcntl.h.
21109         Check for this function: setlocale.
21110
21111 2002-04-24  Jim Meyering  <meyering@lucent.com>
21112
21113         * lib/gettext.h: New file, from Gettext.
21114         * lib/Makefile.am (INCLUDES): Remove -I../intl.
21115         (libfetish_a_SOURCES): Add gettext.h.
21116
21117 2002-04-16  Jim Meyering  <meyering@lucent.com>
21118
21119         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
21120         ut_pid, ut_id, ut_exit.
21121
21122 2002-04-16  Jim Meyering  <meyering@lucent.com>
21123
21124         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
21125         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
21126         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
21127
21128 2002-04-12  Jim Meyering  <meyering@lucent.com>
21129
21130         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
21131         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
21132         existence of the getmntinfo function.  Needed for Darwin 5.3.
21133
21134         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
21135         This is necessary at least on Darwin 5.3.
21136
21137         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
21138         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
21139         strnlen.o in the library, and that makes some versions of ranlib
21140         object.
21141
21142 2002-04-12  Jim Meyering  <meyering@lucent.com>
21143
21144         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
21145
21146 2002-04-09  Jim Meyering  <meyering@lucent.com>
21147
21148         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
21149         to be more precise.  Rather than saying we're checking whether the
21150         function `works', say what we're testing.
21151         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
21152         Reported by Bruno Haible.
21153
21154 2002-03-10  Jim Meyering  <meyering@lucent.com>
21155
21156         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
21157         Suggestion from Santiago Vila.
21158
21159 2002-03-08  Jim Meyering  <meyering@lucent.com>
21160
21161         * lib/rename.c: Mention that this wrapper is needed also on
21162         mips-dec-ultrix4.4 systems.
21163
21164 2002-03-02  Jim Meyering  <meyering@lucent.com>
21165
21166         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
21167         not HAVE_CLOCK_SETTIME.
21168
21169 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21170
21171         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
21172         Check for clock_settime.
21173
21174 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21175
21176         * lib/nanosleep.h: Rename to....
21177         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
21178
21179         * lib/gettime.c: New file.
21180         * lib/settime.c: New file.
21181         * lib/stime.c: Remove.
21182
21183         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
21184         timespec.h.  Remove nanosleep.h.
21185
21186 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21187
21188         * m4/acl.m4: New file.
21189         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
21190         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
21191
21192 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21193
21194         * lib/acl.c, lib/acl.h: New files.
21195         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
21196
21197 2002-02-24  Jim Meyering  <meyering@lucent.com>
21198
21199         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
21200         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
21201         cause trouble.  Reported by Nelson Beebe.
21202
21203 2002-02-23  Paul Eggert  <eggert@twinsun.com>
21204
21205         * lib/path-concat.c (xpath_concat): Reorder code to pacify
21206         compilers that don't know that xalloc_die never returns.
21207
21208 2002-02-20  Jim Meyering  <meyering@lucent.com>
21209
21210         * lib/getdate.c: Regenerate using bison-1.33.
21211
21212 2002-02-17  Jim Meyering  <meyering@lucent.com>
21213
21214         * config/config.guess (main): Don't use `head -1'; it's no longer
21215         portable. Use `sed 1q' instead.
21216
21217 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
21218
21219         * m4/codeset.m4: Upgrade to gettext-0.11.
21220         * m4/gettext.m4: Upgrade to gettext-0.11.
21221         * m4/glibc21.m4: Upgrade to gettext-0.11.
21222         * m4/iconv.m4: Upgrade to gettext-0.11.
21223         * m4/isc-posix.m4: Upgrade to gettext-0.11.
21224         * m4/lcmessage.m4: Upgrade to gettext-0.11.
21225         * m4/lib-ld.m4: New file, from gettext-0.11.
21226         * m4/lib-link.m4: New file, from gettext-0.11.
21227         * m4/lib-prefix.m4: New file, from gettext-0.11.
21228         * m4/progtest.m4: Upgrade to gettext-0.11.
21229
21230 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21231
21232         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
21233         (jm_PREREQ): Use it.
21234
21235 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21236
21237         * lib/posixver.c, lib/posixver.h: New files.
21238         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21239
21240 2002-02-02  Paul Eggert  <eggert@twinsun.com>
21241             Bruno Haible  <bruno@clisp.org>
21242
21243         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
21244         (fwrite_success_callback): New declaration.
21245         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
21246         print_unicode_char. Call failure callback instead of error.
21247         (fwrite_success_callback): New function.
21248         (exit_failure_callback): New function.
21249         (fallback_failure_callback): New function.
21250         (print_unicode_char): Call unicode_to_mb.
21251
21252 2002-01-26  Jim Meyering  <meyering@lucent.com>
21253
21254         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
21255         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
21256
21257 2002-01-26  Jim Meyering  <meyering@lucent.com>
21258
21259         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
21260
21261 2002-01-22  Paul Eggert  <eggert@twinsun.com>
21262
21263         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
21264
21265 2002-01-22  Jim Meyering  <meyering@lucent.com>
21266
21267         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
21268         Otherwise, some versions of automake would omit the rule that makes
21269         Makefile from Makefile.in.
21270
21271 2002-01-21  Paul Eggert  <eggert@twinsun.com>
21272
21273         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
21274         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21275         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
21276         (memcoll): Set errno to zero if there is no error.
21277
21278         * lib/quotearg.c (quotearg_buffer_restyled):
21279         Fix bug with quoting buffers containing NUL when backslashing escapes.
21280         This bug was exposed by the other changes in this patch.
21281         (quotearg_n_options): New arg ARGSIZE.
21282         All callers changed.
21283         (quoting_options_from_style): New function.
21284         (quotearg_n_style): Use it.
21285         (quotearg_n_style_mem): New function.
21286
21287         * lib/quotearg.h (quotearg_n_style_mem): New function.
21288
21289 2002-01-19  Jim Meyering  <meyering@lucent.com>
21290
21291         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
21292         Remove useless quotes: DF_PROG="df".
21293         * m4/strnlen.m4: New file.
21294
21295 2002-01-16  Paul Eggert  <eggert@twinsun.com>
21296
21297         * lib/backupfile.c (ISDIGIT): Comment fix.
21298         * lib/getdate.y (ISDIGIT): Likewise.
21299         * lib/posixtm.c (ISDIGIT, year): Likewise.
21300         * lib/strverscmp.c (ISDIGIT): Likewise.
21301         * lib/userspec.c (ISDIGIT): Likewise.
21302
21303 2002-01-16  Jim Meyering  <meyering@lucent.com>
21304
21305         * lib/getdate.y: Add three semicolons, each just before a closing
21306         brace. Bison (as of version 1.31) no longer papers over that mistake.
21307
21308 2002-01-05  Jim Meyering  <meyering@lucent.com>
21309
21310         * lib/version-etc.c (version_etc_copyright): Update copyright year.
21311
21312 2001-12-19  Paul Eggert  <eggert@twinsun.com>
21313
21314         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
21315         not silently exit merely because the output buffer happens to
21316         have nothing pending.
21317
21318 2001-12-18  Paul Eggert  <eggert@twinsun.com>
21319
21320         See the big note in ../ChangeLog.
21321         * lib/human.c (suffixes): Prefer K to k for 1024.
21322         (generate_suffix_backwards): New function.
21323         (human_readable_inexact): Use it.
21324         * lib/xstrtol.c (__xstrtol): If there is no number but there
21325         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
21326         Accept 'K' as well as 'k'.
21327
21328 2001-12-15  Jim Meyering  <meyering@lucent.com>
21329
21330         * lib/regex.h (__restrict_arr): Update from libc.
21331
21332         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
21333         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
21334         (STREQ): Define.
21335
21336 2001-12-14  Jim Meyering  <meyering@lucent.com>
21337
21338         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
21339         Suggestion from Bruno Haible.
21340
21341 2001-12-10  Jim Meyering  <meyering@lucent.com>
21342
21343         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
21344         xrealloc, Instead, include "xalloc.h".
21345         (initbuffer): Don't cast xmalloc return value to char*.
21346         (readline): Reword comment.
21347         Don't cast xrealloc return value to char*
21348         Return NULL, not 0.
21349
21350 2001-12-09  Jim Meyering  <meyering@lucent.com>
21351
21352         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
21353         about `signed and unsigned type in conditional expression'.
21354         * lib/posixtm.c (posix_time_parse): Likewise.
21355
21356         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
21357
21358         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
21359         to avoid a pedantic warning.
21360
21361         * lib/getstr.c: Don't include assert.h.
21362         (getstr): Remove warning-evoking assertions.
21363         Return -1 if offset parameter is out of bounds.
21364         Change the type of a local from int to size_t.
21365
21366         * lib/strftime.c (my_strftime_localtime_r): Include this function
21367         definition in the `#if ! HAVE_TM_GMTOFF' block.
21368
21369         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
21370         Include xalloc.h instead.
21371
21372 2001-12-02  Jim Meyering  <meyering@lucent.com>
21373
21374         * lib/tempname.c: Don't declare getenv, thus reverting the change of
21375         2001-11-18.  It's no longer necessary, now that stdlib.h is always
21376         included.
21377
21378         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
21379         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
21380
21381 2001-11-30  Akim Demaille  <akim@epita.fr>
21382
21383         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
21384         before being defined.
21385
21386 2001-11-27  Paul Eggert  <eggert@twinsun.com>
21387
21388         * lib/quotearg.h (quotearg_n, quotearg_n_style):
21389         First arg is int, not unsigned.
21390         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
21391         (SIZE_MAX, UINT_MAX): New macros.
21392         (quotearg_n_options): Abort if N is negative.
21393         Avoid overflow check on hosts where size_t is 64 bits and int
21394         is 32 bits, as overflow is impossible there.
21395         Fix off-by-one typo that caused unnecessary reallocation.
21396
21397 2001-11-27  Jim Meyering  <meyering@lucent.com>
21398
21399         * lib/tempname.c: Merge with version from libc.
21400         * lib/regex.c: Likewise.
21401
21402         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
21403         systems for which STDC_HEADERS is 0, it was not included, resulting in
21404         a warning about an integer-to-pointer conversion problem with getenv.
21405         Reported by Volker Borchert.
21406
21407 2001-11-26  Jim Meyering  <meyering@lucent.com>
21408
21409         * lib/gtod.h: Remove file.
21410         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
21411         * lib/gettimeofday.c: Don't include gtod.h.
21412         (GTOD_init): Remove function.
21413         (rpl_gettimeofday): Do its job here instead, rather than aborting.
21414         Suggestion from Volker Borchert.
21415
21416 2001-11-23  Jim Meyering  <meyering@lucent.com>
21417
21418         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
21419         it.
21420         * lib/hash.c (struct hash_table): Define it here instead.
21421
21422 2001-11-22  Jim Meyering  <meyering@lucent.com>
21423
21424         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
21425
21426 2001-11-20  Jim Meyering  <meyering@lucent.com>
21427
21428         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
21429         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
21430
21431 2001-11-19  Jim Meyering  <meyering@lucent.com>
21432
21433         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
21434         directory.  Use "conftestXXXXXX" as the template.
21435         Suggestion from Paul Eggert.
21436
21437         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
21438         immediately, so the test doesn't mistakenly hit the max-open-files
21439         limit.
21440
21441 2001-11-18  Paul Eggert  <eggert@twinsun.com>
21442
21443         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
21444         (TEMPORARIES): New macro.
21445         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
21446         removes an artificial limitation (e.g. HP-UX 10.20, where
21447         TMP_MAX is 17576).
21448
21449 2001-11-18  Jim Meyering  <meyering@lucent.com>
21450
21451         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
21452
21453 2001-11-18  Jim Meyering  <meyering@lucent.com>
21454
21455         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
21456         on SunOS 4.
21457
21458         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
21459         files will be created before anything else.
21460
21461 2001-11-17  Paul Eggert  <eggert@twinsun.com>
21462
21463         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
21464         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
21465
21466 2001-11-17  Jim Meyering  <meyering@lucent.com>
21467
21468         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
21469         Prompted by a report from Bob Proulx.
21470
21471         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
21472         Instead, require UTILS_FUNC_MKSTEMP.
21473
21474 2001-11-17  Jim Meyering  <meyering@lucent.com>
21475
21476         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
21477         Now, that's done as part of AC_FUNC_STRTOD.
21478
21479 2001-11-17  Jim Meyering  <meyering@lucent.com>
21480
21481         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
21482         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
21483         rather than group writable.  Patch by Juan F. Codagnone.
21484
21485         * lib/readtokens.c: Remove explicit declarations of xmalloc and
21486         xrealloc, Instead, include "xalloc.h".
21487
21488         * lib/mountlist.c: Include unlocked-io.h after all system headers.
21489         Remove explicit declarations of xmalloc, xrealloc,
21490         and xstrdup.  Instead, include "xalloc.h".
21491
21492         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
21493         unlocked-io.h.
21494         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
21495         Likewise.
21496         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
21497
21498         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
21499         Reported by Padraig Brady.
21500
21501         * lib/mkstemp.c: #undef mkstemp.
21502         Include config.h.
21503         (rpl_mkstemp): Rename from mkstemp.
21504         Protoize.
21505
21506 2001-11-16  Jim Meyering  <meyering@lucent.com>
21507
21508         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
21509         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
21510         determine the amount of total physical memory, use pstat_getstatic.
21511         HPUX-11 doesn't define _SC_PHYS_PAGES.
21512         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
21513         If sysconf couldn't be used to determine the amount of available
21514         physical memory, use both pstat_getstatic and pstat_getdynamic.
21515         Based on a patch from Bob Proulx.
21516
21517 2001-11-10  Jim Meyering  <meyering@lucent.com>
21518
21519         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
21520         (jm_PREREQ): Use it.
21521
21522 2001-11-09  Jim Meyering  <meyering@lucent.com>
21523
21524         * m4/jm-macros.m4: Require autoconf-2.52f.
21525         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
21526         Use these AC_-prefixed names, not the AM_-prefixed ones.
21527
21528         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
21529
21530 2001-11-05  Jim Meyering  <meyering@lucent.com>
21531
21532         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
21533
21534 2001-11-04  Jim Meyering  <meyering@lucent.com>
21535
21536         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
21537         $DEFS.
21538
21539 2001-11-03  Jim Meyering  <meyering@lucent.com>
21540
21541         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
21542         of AC_DEFUN.
21543
21544         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
21545         know the name of the variable in the macro definition.
21546
21547 2001-11-03  Jim Meyering  <meyering@lucent.com>
21548
21549         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
21550         in argmatch_to_argument call.
21551
21552         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
21553         argument.
21554
21555         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
21556         e.g., a fault due to an attempt to free a NULL pointer.
21557
21558 2001-11-01  Jim Meyering  <meyering@lucent.com>
21559
21560         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
21561         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
21562
21563 2001-11-01  Jim Meyering  <meyering@lucent.com>
21564
21565         * lib/dirfd.c, lib/dirfd.h: New files.
21566         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
21567
21568         * lib/hash.c (hash_print) [TESTING]: Clean up.
21569
21570 2001-10-22  Paul Eggert  <eggert@twinsun.com>
21571
21572         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
21573         to avoid a warning if -Wall.
21574
21575 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
21576
21577         * README: New file
21578         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
21579         (per RMS's instructions, this is now the canonical source)
21580         * lgpl/, gpl/: New directories.
21581
21582 2001-10-21  Paul Eggert  <eggert@twinsun.com>
21583
21584         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
21585
21586 2001-10-21  Jim Meyering  <meyering@lucent.com>
21587
21588         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
21589         this code would end up calling gettext even in packages built
21590         with --disable-nls.
21591         * lib/getopt.c (_): Likewise.
21592         * lib/regex.c (_): Likewise.
21593
21594 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21595
21596         * m4/error.m4 (jm_PREREQ_ERROR):
21597         Do not invoke AC_CHECK_FUNCS with strerror_r, as
21598         AC_FUNC_STRERROR_R does that.
21599         Check for strerror declaration.
21600
21601         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
21602         are supposed to have them these days.
21603         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
21604         Merge changes from latest Autoconf CVS.
21605         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
21606         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
21607         POSIX decided to standardize on the int flavor of strerror_r.
21608
21609 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21610
21611         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
21612         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
21613         Use strerror_r that is only a macro, even if it is not a function.
21614         (strerror): Check for HAVE_DECL_STRERROR before declaring.
21615         (private_strerror): Use prototypes, not old-style function definition.
21616         (print_errno_message): New function.
21617         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
21618         char*-flavored one.
21619         (error_tail, error, error_at_line): Use it.
21620
21621 2001-10-11  Jim Meyering  <meyering@lucent.com>
21622
21623         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
21624         and quote_n (1, ... to avoid clobbering a buffer.
21625
21626 2001-10-05  Jim Meyering  <meyering@lucent.com>
21627
21628         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
21629         hash-pjw.h.
21630         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
21631         * lib/hash-pjw.h: New file.
21632
21633 2001-09-30  Jim Meyering  <meyering@lucent.com>
21634
21635         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
21636         `struct fsstat' has the `f_fstypename' member.
21637         Use that to define FS_TYPE, which is now used to make
21638         the getfsstat link test tighter.
21639
21640 2001-09-30  Jim Meyering  <meyering@lucent.com>
21641
21642         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
21643         Include <sys/ucred.h>, for Apple Darwin.
21644         Include sys/mount.h and sys/fs_types.h only if available.
21645         (FS_TYPE): Define.
21646         (read_filesystem_list): Use FS_TYPE.
21647
21648 2001-09-29  Paul Eggert  <eggert@twinsun.com>
21649
21650         * lib/exclude.c (excluded_filename): 0 -> false, since it's
21651         a boolean context.
21652
21653 2001-09-29  Jim Meyering  <meyering@lucent.com>
21654
21655         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21656         [one-argument getmntent function]): Include stdio.h before mntent.h.
21657         SunOS 4.1.x needs it for the declaration of `FILE'.
21658         Patch by Volker Borchert.
21659
21660         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21661         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
21662         sys/fs_types.h, and make the link-test for getfsstat guard #include
21663         directives with appropriate #if HAVE_*_H tests so that we can
21664         detect getfsstat on Apple Darwin1.3.7 systems.
21665         Reported by Nelson Beebe.
21666         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
21667
21668 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21669
21670         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21671         #defines strtoimax.  Also treat the other strto* functions
21672         like strtoimax.
21673
21674         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21675         Check for strtoul and strtoumax,
21676         as those declarations are made even in the signed case.
21677         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
21678         Likewise, for strtol and strtoimax.
21679
21680 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21681
21682         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21683         #defines strtoimax.  Also treat the other strto* functions
21684         like strtoimax.
21685
21686         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
21687         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
21688         (strtoimax, strtoumax): Do not declare if already defined as a macro.
21689
21690 2001-09-26  Jim Meyering  <meyering@lucent.com>
21691
21692         Most macros in unlocked-io.h had the wrong number of arguments.
21693         * lib/gen-uio: New script.
21694         (USE_UNLOCKED_IO): Define to 1 if not already defined.
21695         * lib/unlocked-io.hin: Remove file.
21696         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
21697         rather than trying to embed it here.
21698         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
21699         Reported by Padraig Brady.
21700
21701 2001-09-25  Volker Borchert  <bt@teknon.de>
21702
21703         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
21704         `result'.
21705
21706 2001-09-24  Jim Meyering  <meyering@lucent.com>
21707
21708         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
21709
21710 2001-09-23  Jim Meyering  <meyering@lucent.com>
21711
21712         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
21713         instead of the mere test for existence of mntent.h.  The latter
21714         would get a false-positive on AIX 3.4 systems.
21715         In the outer getmntent if-block, don't die if neither of the getmntent
21716         tests succeeds.  Instead, just fall through and continue with the
21717         remaining tests.
21718
21719 2001-09-23  Jim Meyering  <meyering@lucent.com>
21720
21721         * lib/mountlist.c: Remove useless parentheses in #if directives.
21722         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
21723         the deprecated MOUNTED symbol is no longer defined in mntent.h.
21724
21725 2001-09-22  Jim Meyering  <meyering@lucent.com>
21726
21727         * m4/gettext.m4: New file.  From gettext.
21728         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
21729         * m4/progtest.m4: Likewise
21730         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
21731         * m4/glibc21.m4: Likewise.
21732
21733         * m4/libintl.m4: Remove.  No longer used.
21734
21735 2001-09-22  Jim Meyering  <meyering@lucent.com>
21736
21737         * lib/localcharset.c: Update from latest gettext.
21738         * lib/config.charset: Likewise.
21739
21740 2001-09-20  Jim Meyering  <meyering@lucent.com>
21741
21742         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
21743         strtoimax.
21744         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
21745         strtoumax.
21746
21747 2001-09-20  Jim Meyering  <meyering@lucent.com>
21748
21749         * lib/xstrtol.c (strtoimax): Guard declaration with
21750         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
21751         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
21752         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
21753         (strtoumax): Likewise, for completeness (it wasn't necessary).
21754
21755 2001-09-17  Paul Eggert  <eggert@twinsun.com>
21756
21757         * lib/strtoimax.c (HAVE_LONG_LONG):
21758         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
21759         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
21760         to work around bug in IBM C compiler.
21761
21762 2001-09-17  Jim Meyering  <meyering@lucent.com>
21763
21764         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
21765         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
21766         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
21767         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
21768         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
21769         whenever the right hand side need not be expanded by the shell.
21770
21771 2001-09-16  Paul Eggert  <eggert@twinsun.com>
21772
21773         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
21774         library.  It's not correct, as some older glibcs are buggy.
21775         fnmatch wasn't fixed until glibc 2.2.
21776
21777         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
21778         special shell magic here.
21779
21780 2001-09-16  Jim Meyering  <meyering@lucent.com>
21781
21782         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
21783         * m4/jm-macros.m4: Require it.
21784
21785 2001-09-16  Jim Meyering  <meyering@lucent.com>
21786
21787         * lib/mkdir.c: New file.
21788
21789 2001-09-15  Jim Meyering  <meyering@lucent.com>
21790
21791         * m4/jm-macros.m4: Check for help2man.
21792
21793 2001-09-11  Jim Meyering  <meyering@lucent.com>
21794
21795         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
21796         The body, by Paul Eggert, was moved here from configure.in.
21797         * m4/jm-macros.m4: Require UTILS_HOST_OS.
21798
21799 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21800
21801         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
21802         (jm_PREREQ): Use it.
21803
21804 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21805
21806         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
21807         Use ssize_t, not int, to store result of readlink.
21808         Check for ssize_t overflow as well as size_t overflow,
21809         as POSIX says the result of readlink is implementation-defined
21810         when ssize_t overflows.
21811         Remove unnecessary cast to char*.
21812         Use free+malloc instead of realloc, as the storage doesn't need
21813         to be preserved and it's clearer and can be more efficient that way.
21814         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
21815         * lib/xreadlink.h (xreadlink): Update prototype.
21816
21817 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21818
21819         * lib/xgetcwd.c: Revert some of the previous change; intead,
21820         fix the HAVE_GETCWD_NULL code to behave more like the
21821         !HAVE_GETCWD_NULL code used to.
21822
21823         Include "xalloc.h".
21824         (xgetcwd): Do not return NULL when memory is exhausted; instead,
21825         invoke xalloc_die.
21826
21827 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21828
21829         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
21830         sys/param.h, as pathmax.h includes them.
21831
21832 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21833
21834         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
21835         (jm_PREREQ_XGETCWD): New macro.
21836
21837         * m4/getcwd.m4: New file.
21838
21839 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21840
21841         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
21842         like the HAVE_GETCWD_NULL code.
21843         Include pathmax.h if not HAVE_GETCWD.
21844         Do not include xalloc.h.
21845         (INITIAL_BUFFER_SIZE): New symbol.
21846         Do not use xmalloc / xrealloc, since the caller is responsible for
21847         handling errors.  Preserve errno around `free' during failure.
21848         Do not overrun buffer when using getwd.
21849
21850 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21851
21852         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
21853         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
21854         getcwd (NULL, 0).
21855
21856 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21857
21858         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
21859         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
21860         spotted by Jim Meyering.
21861
21862 2001-09-03  Jim Meyering  <meyering@lucent.com>
21863
21864         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
21865         failure.
21866
21867 2001-09-02  Jim Meyering  <meyering@lucent.com>
21868
21869         * lib/error.c: Update from GNU libc.
21870
21871 2001-09-01  Jim Meyering  <meyering@lucent.com>
21872
21873         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
21874         Used by df.
21875
21876 2001-09-01  Jim Meyering  <meyering@lucent.com>
21877
21878         * lib/xreadlink.c: New file.
21879         * lib/xreadlink.h: New file.
21880         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
21881         xreadlink.h.
21882
21883         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
21884         doesn't conflict with sparc Solaris 7's definition in
21885         /usr/include/sys/int_types.h.
21886
21887         * lib/exclude.c: Use `""', not `<>' to #include non-system header
21888         files.
21889         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
21890         and strncasecmp as r-values.  Unixware didn't have declarations.
21891
21892 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21893
21894         * lib/xstrtol.h: Add copyright notice.
21895         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
21896         LONGINT_INVALID_SUFFIX_CHAR.
21897
21898 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21899
21900         * lib/xstrtol.c (strtoimax): New decl.
21901
21902 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21903
21904         * lib/xgetcwd.c: Don't include pathmax.h.
21905         Include stdlib.h and unistd.h if available.
21906         Include xalloc.h.
21907         (xmalloc, xstrdup, free): Remove decls.
21908         (xgetcwd): Don't assume sizes fit in unsigned.
21909         Check for overflow when computing sizes.
21910         Simplify reallocation code.
21911
21912 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21913
21914         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
21915         a directory's st_size can have an arbitrary value, so the old
21916         usage could waste an arbitrary amount of memory.  All uses
21917         changed.
21918         * lib/savedir.h: Update prototype.
21919
21920 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21921
21922         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
21923
21924         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
21925         old strtoimax.c.
21926
21927         Also, make the following further changes to make this file's
21928         configuration more similar to that of strtol.c:
21929         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
21930         (strtoumax, uintmax_t, strtoull, strtol): Remove.
21931         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
21932         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
21933         changed to signed values.
21934
21935         And make the following changes as well:
21936         Fix copyright notice, as 1999 was missing.
21937         (verify): New macro.
21938         (strtoimax): Check sizes at compile-time, not run-time.
21939         Prefer strtol to strtoll if both work.
21940         (main): Remove; it was not that useful and was a pain to maintain.
21941
21942         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
21943
21944 2001-08-31  Jim Meyering  <meyering@lucent.com>
21945
21946         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
21947         Use an initial, malloc'd, buffer of length 128 rather than
21948         a statically allocated one of length 1024.
21949
21950 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21951
21952         Simplify code, partly by assuming autoconf 2.52 semantics.
21953
21954         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
21955
21956         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
21957         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
21958         All uses removed.
21959         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
21960         Move AC_REQUIRE to next-to-top level, to avoid confusion.
21961         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
21962         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
21963         jm_AC_HEADER_INTTYPES_H.
21964         * m4/jm-macros.m4 (jm_MACROS): Likewise.
21965
21966         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
21967
21968         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21969         Quote first arg of AC_DEFUN.
21970         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
21971         since they are needed to parse the include file even if we need
21972         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
21973         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
21974         but with opposite signedness.
21975
21976 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21977
21978         Merge 'exclude' changes from tar 1.13.22.
21979         This fixes one or two unlikely storage allocation overflow bugs,
21980         but doesn't change user-visible behavior otherwise.
21981
21982 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21983
21984         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
21985         (jm_PREREQ_EXCLUDE): New macro.
21986
21987 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21988
21989         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
21990         tm to be declared.
21991
21992 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21993
21994         * lib/hash.c: Remove '2001' from copyright notice.
21995
21996 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21997
21998         * lib/full-write.h: New file.
21999         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
22000         * lib/full-write.c: Correct credits, as cccp.c no longer
22001         exists and anyway it was so heavily changed from the old cccp
22002         code as to be unrecognizable.  Include full-write.h.
22003         (full_write) Return size_t, with short writes meaning failure.
22004         All callers changed.  This fixes a bug with large buffers
22005         on 64-bit hosts.
22006         * lib/utime.c: Include full-write.h.
22007
22008 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22009
22010         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
22011         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
22012         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
22013         Include if available.
22014         (<xalloc.h>): Include
22015         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
22016         (verify): New macro.  Use it to verify that EXCLUDE macros do not
22017         collide with FNM macros.
22018         (struct patopts): New struct.
22019         (struct exclude): Use it, as exclude patterns now come with options.
22020         (new_exclude): Support above changes.
22021         (new_exclude, add_exclude_file):
22022         Initial size must now be a power of two to simplify overflow checking.
22023         (free_exclude, fnmatch_no_wildcards): New function.
22024         (excluded_filename): No longer requires options arg, as the options
22025         are determined by add_exclude.  Now returns bool, not int.
22026         (excluded_filename, add_exclude):
22027         Add support for the fancy new exclusion options.
22028         (add_exclude, add_exclude_file): Now takes int options arg.
22029         Check for arithmetic overflow when computing sizes.
22030         (add_exclude_file): xrealloc might modify errno, so don't
22031         realloc until after errno might be used.
22032
22033         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
22034         New macros.
22035         (free_exclude): New decl.
22036         (add_exclude, add_exclude_file): Now takes int options arg.
22037         (excluded_filename): No longer requires options arg, as the options
22038         are determined by add_exclude.  Now returns bool, not int.
22039
22040 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22041
22042         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
22043
22044 2001-08-27  Jim Meyering  <meyering@lucent.com>
22045
22046         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
22047
22048         * lib/version-etc.c (N_): Remove definition.
22049         Revert most of last change.
22050         Instead, simply don't mark the `Copyright...' string for translation.
22051         Based on advice from Paul Eggert.
22052
22053         * lib/strtoxmax.c: Tweak comment.
22054
22055 2001-08-26  Jim Meyering  <meyering@lucent.com>
22056
22057         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
22058
22059         * m4/xstrtoimax.m4: New file.
22060         * m4/xstrtoumax.m4: Add comments explaining why we
22061         AC_REPLACE_FUNCS(strtol).
22062
22063 2001-08-26  Jim Meyering  <meyering@lucent.com>
22064
22065         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
22066         of copyright with `%s' so translators don't get an untranslated
22067         message in 2002.
22068         (COPYRIGHT_YEAR): Define.
22069         (version_etc): Use fprintf rather than fputs.
22070         Suggestion from Ulrich Drepper.
22071
22072         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
22073
22074         * lib/strtoll.c: New file, from GNU libc.
22075         * lib/xstrtoimax.c: New file.
22076
22077         * lib/xstrtol.h: Add xstrtoimax.
22078         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
22079         * lib/strtoimax.c: New file.  Likewise, but first define
22080         STRTOUXMAX_SIGNED.
22081
22082         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
22083         ...
22084         * lib/strtoxmax.c: ... then renamed to this.
22085
22086 2001-08-18  Paul Eggert  <eggert@twinsun.com>
22087
22088         * m4/inttypes.m4: Add AC_PREREQ(2.13).
22089         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
22090         (jm_AC_TYPE_INTMAX_T): New macro.
22091         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
22092
22093         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
22094
22095         * m4/longlong.m4: Renamed from ulonglong.m4.
22096         * m4/inttypes.m4: Renamed from inttypes_h.m4.
22097         * m4/uintmax_t.m4: Removed.
22098
22099 2001-08-13  Paul Eggert  <eggert@twinsun.com>
22100
22101         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
22102         Port to Solaris 8, where 'sed' requires a space after the 'r'
22103         command, and where sh dislikes "$/".  Clean up the spacing a bit.
22104         Redirect output to $tmp just once.
22105
22106 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
22107
22108         * lib/addext.c (<errno.h>): Include.
22109         (errno): Declare if not defined.
22110         (addext): Work correctly when pathconf returns -1 and leaves
22111         errno alone because there is no limit.  Also, work even if
22112         pathconf returns a value greater than SIZE_MAX.
22113
22114 2001-08-12  Jim Meyering  <meyering@lucent.com>
22115
22116         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
22117         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
22118         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
22119         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
22120         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
22121         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
22122         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
22123         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
22124         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
22125         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
22126         utime.m4, utimes.m4, xstrtoumax.m4:
22127         Quote the first argument in each use of AC_DEFUN.
22128
22129 2001-08-12  Jim Meyering  <meyering@lucent.com>
22130
22131         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
22132         Simply `return getcwd (NULL, 0);'.
22133         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
22134         Use 1300 as initial value for length, not PATH_MAX.
22135
22136         * lib/pathmax.h: Clean up cpp syntax.
22137
22138 2001-08-12  Jim Meyering  <meyering@lucent.com>
22139
22140         * lib/gettimeofday.c: New file.
22141         * lib/gtod.h: New file.
22142         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
22143
22144 2001-08-05  Jim Meyering  <meyering@lucent.com>
22145
22146         * m4/jm-macros.m4: Require autoconf-2.52.
22147
22148 2001-08-04  Jim Meyering  <meyering@lucent.com>
22149
22150         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
22151         stmt, to get in sync with glibc.
22152
22153 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22154
22155         The following changes are from gettext 0.10.39 as maintained by
22156         Bruno Haible.
22157
22158         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
22159         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
22160         with inverted sense.  All uses changed.
22161
22162         * lib/mbswidth.c: Don't include <limits.h>.
22163         Include <stdlib.h> and <string.h> unconditionally.
22164         (iswcntrl, mbsinit, ISCNTRL): New macros.
22165         (mbsnwidth): Use K&R style function declarations.
22166         Don't bother checking for MB_LEN_MAX == 1, since the compiler
22167         can optimize it when MB_CUR_MAX == 1.
22168         The width of control characters is zero, not 1.
22169
22170 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22171
22172         The following changes are from gettext 0.10.39 as maintained by
22173         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
22174
22175         * m4/codeset.m4: Upgrade to serial AM1.
22176         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
22177         all uses changed.  Quote first arg of AC_DEFUN.
22178         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
22179
22180         * m4/iconv.m4: Upgrade to serial AM2.
22181         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
22182         Add --with-libconv-prefix.
22183         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
22184         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
22185         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
22186         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
22187         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
22188
22189         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
22190         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
22191         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
22192         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
22193         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
22194         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
22195         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
22196         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
22197         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
22198
22199         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
22200         string.h any more.
22201
22202         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
22203         not the default value.
22204
22205         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
22206         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
22207         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
22208         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
22209         Also check for iswcntrl, used for wcwidth fallback.
22210         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
22211         to Autoconf 2.13.
22212
22213 2001-08-03  Jim Meyering  <meyering@lucent.com>
22214
22215         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
22216         as it was in the original.  Reported by Paul Eggert.
22217
22218 2001-07-16  Jim Meyering  <meyering@lucent.com>
22219
22220         * m4/gettimeofday.m4: New file.
22221         Prompted by a report from Bernhard Baehr.
22222
22223 2001-07-15  Jim Meyering  <meyering@lucent.com>
22224
22225         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
22226         stuff. Now it's in ../Makefile.cfg.
22227
22228 2001-07-15  Jim Meyering  <meyering@lucent.com>
22229
22230         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
22231         (BUILT_SOURCES): Add unlocked-io.h.
22232         (io_functions): Define.
22233         (unlocked-io.h): New rule.
22234         (DISTCLEANFILES): Add unlocked-io.h.
22235         (all-local): Depend on unlocked-io.h, to ensure it is created.
22236
22237         * lib/unlocked-io.hin: New file
22238
22239         * lib/regex.c: Update from glibc.
22240
22241 2001-07-05  Jim Meyering  <meyering@lucent.com>
22242
22243         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
22244         recommendation.
22245         (libfetish_a_SOURCES): Put all .h files here instead.
22246         Remove a thus-exposed (better checks in automake) duplicate and
22247         two unnecessary .h files.
22248
22249 2001-07-04  Jim Meyering  <meyering@lucent.com>
22250
22251         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
22252         that generates jm-glibc-io.m4 so that it doesn't trigger any make
22253         distcheck failure.
22254
22255 2001-07-02  Jim Meyering  <meyering@lucent.com>
22256
22257         The following changes were prompted by suggestions from Bruno Haible.
22258
22259         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
22260         is now generated.
22261         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
22262         definition of EXTRA_DIST.
22263         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
22264         ensure that the generated file is created/updated whenever the list
22265         of $(unlocked_functions) is changed.
22266         (jm-glibc-io.m4): New rule.
22267         (unlocked-io.h): New rule -- currently unused.
22268
22269 2001-06-24  Jim Meyering  <meyering@lucent.com>
22270
22271         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
22272         unmatched right bracket, rather than kludging it with an extra,
22273         falsely-matching quote in a comment.  Patch by Akim Demaille.
22274
22275 2001-06-11  Jim Meyering  <meyering@lucent.com>
22276
22277         * lib/regex.c: Update from GNU libc.
22278
22279 2001-05-27  Jim Meyering  <meyering@lucent.com>
22280
22281         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
22282         Check for ut_type in struct utmp.
22283
22284 2001-05-27  Jim Meyering  <meyering@lucent.com>
22285
22286         * lib/readutmp.h (UT_TYPE): Define.
22287
22288 2001-05-24  Jim Meyering  <meyering@lucent.com>
22289
22290         * lib/argmatch.c: Include "quote.h".
22291         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
22292         quote function.  Reported by Göran Uddeborg.
22293
22294 2001-05-22  Jim Meyering  <meyering@lucent.com>
22295
22296         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
22297         now that we use the package-supplied version unconditionally.
22298         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
22299
22300 2001-05-21  Jim Meyering  <meyering@lucent.com>
22301
22302         * m4/regex.m4: Change a couple backticks to single quotes to avoid
22303         shell syntax errors.
22304
22305 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22306
22307         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
22308
22309 2001-05-20  Paul Eggert  <eggert@twinsun.com>
22310
22311         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
22312         Don't bother to check library strftime, since
22313         we'll be using our own my_strftime function anyway.
22314         Define my_strftime instead of strftime.
22315
22316 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
22317
22318         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
22319         which is not yet declared.
22320
22321 2001-05-15  Jim Meyering  <meyering@lucent.com>
22322
22323         * m4/regex.m4: Use proper quoting so brackets appear in the test
22324         program.
22325         Reported by, and with help from, Bruno Haible.
22326
22327 2001-05-13  Jim Meyering  <meyering@lucent.com>
22328
22329         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
22330         undefined.
22331
22332 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22333
22334         dirname code cleanup.  base_name now behaves more compatibly
22335         with POSIX basename when given file names that have trailing
22336         slashes, and similarly for dir_name.  Add new primitives
22337         base_len and dir_len.  Put the directory-name-related decls
22338         into dirname.h.
22339
22340         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
22341         * lib/backupfile.c (base_name): Likewise.
22342         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
22343         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
22344         * lib/makepath.c (strip_trailing_slashes): Likewise.
22345         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
22346         ISSLASH): Likewise.
22347         * lib/rename.c (strip_trailing_slashes): Likewise.
22348         * lib/same.c (base_name): Likewise.
22349         * lib/stripslash.c (ISSLASH): Likewise.
22350
22351         * lib/addext.c: Include <dirname.h> after size_t is defined.
22352         * lib/backupfile.c: Likewise.
22353
22354         * lib/addext.c (addext): Use base_len to trim redundant
22355         trailing slashes instead of doing it ourselves.
22356         But do not trim the last slash if it is not redundant.
22357
22358         * lib/backupfile.c (find_backup_file_name,
22359         max_backup_version): Use base_len instead of rolling it ourselves.
22360         Handle the case of "" and (on DOS) "C:" correctly.
22361
22362         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
22363         needed. Include <string.h>, <dirname.h>.
22364         (base_name): Allow file names ending in slashes, other than names
22365         that are all slashes.  In this case, return the basename followed
22366         by the slashes.  This is more general, and can be used in places
22367         where the original base_name purposely had an assertion failure.
22368         (base_len): New function.
22369
22370         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
22371         Do not include <assert.h>; no longer needed.
22372         Include xalloc.h.
22373         (memrchr): Remove decl.
22374         (dir_name_r): Remove.
22375         (dir_len): Renamed from dirlen.  All callers changed.
22376         Rewrite in terms of base_name, for simplicity and consistency.
22377         (dir_name): Never return NULL.  All callers changed.
22378         Do not include <stdlib.h> in test program; no longer needed.
22379         return 0; is fine for test program.
22380
22381         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
22382         New macros.
22383         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
22384
22385         * lib/path-concat.c (path_concat): Use base_len to compute
22386         base length, not strlen; this means we cannot rely on memcpy
22387         to null-terminate.
22388
22389         * lib/same.c (STREQ): Remove.
22390         (same_name): Handle the case where the basename ends in trailing '/'.
22391
22392         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
22393         a slash was stripped.  Do not strip the last slash after a
22394         file system prefix.
22395
22396 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22397
22398         * lib/Makefile.am (libfetish_a_SOURCES):
22399         Add strftime.c, since we now compile it on all hosts.
22400
22401         * lib/strftime.c (my_strftime):
22402         Define to nstrftime if emacs, but only if my_strftime is not defined.
22403         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
22404         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
22405         Add one more extra argument: a nanoseconds value.
22406         All uses changed.
22407         (ns): New macro.
22408         (my_strftime function): Add %N format.
22409         (emacs_strftimeu): Renamed from emacs_strftime,
22410         with extra ut argument.
22411
22412 2001-05-09  Paul Eggert  <eggert@twinsun.com>
22413
22414         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
22415
22416 2001-04-21  Jim Meyering  <meyering@lucent.com>
22417
22418         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
22419         doesn't interfere.
22420
22421 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22422
22423         * m4/ftruncate.m4: Check for chsize.
22424         Link with ftruncate.o unconditionally if ftruncate is missing.
22425         This was required when cross-compiling to i586-mingw32msvc.
22426
22427 2001-04-08  Jim Meyering  <meyering@lucent.com>
22428
22429         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
22430         recomputed; that's necessary when the offset spans a DST transition.
22431         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
22432
22433 2001-04-02  Jim Meyering  <meyering@lucent.com>
22434
22435         * lib/regex.h, regex.c: Update from GNU libc.
22436
22437 2001-03-24  Jim Meyering  <meyering@lucent.com>
22438
22439         * m4/jm-macros.m4: Require autoconf-2.49d.
22440
22441 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
22442
22443         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
22444
22445 2001-03-19  Paul Eggert  <eggert@twinsun.com>
22446
22447         * lib/version-etc.c (version_etc_copyright): Update to 2001.
22448
22449 2001-03-17  Jim Meyering  <meyering@lucent.com>
22450
22451         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
22452         now that the version in autoconf is equivalent.
22453         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
22454
22455         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
22456         Suggestion from Akim Demaille.
22457
22458         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
22459         (jm_PREREQ_TEMPNAME): New function.
22460
22461 2001-03-16  Paul Eggert  <eggert@twinsun.com>
22462
22463         * lib/tempname.c (uint64_t): Define to uintmax_t if
22464         not defined, and if UINT64_MAX is not defined.
22465         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
22466         Reported by John David Anglin.
22467
22468 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
22469
22470         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
22471         resolve alias if codeset is empty.
22472         * lib/config.charset (BeOS): Use wildcard syntax.
22473
22474 2001-03-13  Jim Meyering  <meyering@lucent.com>
22475
22476         * lib/path-concat.c (path_concat)
22477         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
22478         concatenating e.g., `C:' and `foo'.
22479         From Bruno Haible.
22480
22481 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22482
22483         * lib/localcharset.c (locale_charset): Don't use
22484         setlocale(LC_CTYPE,NULL). Don't return NULL.
22485         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
22486
22487 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22488
22489         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
22490         support for DOS/DJGPP.
22491
22492 2001-03-01  Paul Eggert  <eggert@twinsun.com>
22493
22494         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
22495         lacks mkstemp.  Compile our own tempname.c if we compile our own
22496         mkstemp.c, as mkstemp relies on tempname.
22497
22498 2001-03-01  Jim Meyering  <meyering@lucent.com>
22499
22500         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
22501         AH_VERBATIM really does output its argument verbatim.
22502
22503 2001-02-28  Paul Eggert  <eggert@twinsun.com>
22504
22505         * lib/Makefile.am (libfetish_a_SOURCES):
22506         Add dup-safer.c, fopen-safer.c.
22507         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
22508
22509         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
22510         * lib/unistd-safer.h: New files.
22511
22512 2001-02-25  Paul Eggert  <eggert@twinsun.com>
22513
22514         The mkstemp replacement is taken from glibc 2.2.2, with some
22515         portability fixes for use outside glibc, as follows:
22516
22517         * lib/tempname.c (struct_stat64): New macro.
22518         (direxists, __gen_tempname): Use it.
22519         This avoids a portability problem with Solaris 8.
22520
22521         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
22522         (<stddef.h>, <stdint.h>, <string.h>):
22523         Include only if STDC_HEADERS || _LIBC.
22524         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
22525         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
22526         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
22527         (__set_errno): Define this macro if <errno.h> doesn't.
22528         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
22529         Define these macros if <stdio.h> doesn't.
22530         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
22531         Define these macros if <sys/stat.h>
22532         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
22533         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
22534         __xstat64): Define if not _LIBC.
22535         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
22536         (__gen_tempname): Invoke gettimeofday only if
22537         HAVE_GETTIMEOFDAY || _LIBC;
22538         otherwise, fall back on plain "time".
22539         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
22540
22541         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
22542
22543         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
22544
22545 2001-02-18  Paul Eggert  <eggert@twinsun.com>
22546
22547         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
22548
22549 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22550
22551         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
22552         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
22553         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
22554         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22555
22556 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22557
22558         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
22559         Remove workaround macros for hosts that have mbrtowc but not
22560         mbstate_t, as we now insist on proper declarations for both
22561         before using mbrtowc.
22562
22563 2001-02-17  Jim Meyering  <meyering@lucent.com>
22564
22565         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
22566         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
22567         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
22568         UnixWare 7.1.1.
22569
22570         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
22571         rather than AC_CACHE_VAL.
22572
22573 2001-02-17  Jim Meyering  <meyering@lucent.com>
22574
22575         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
22576         around included file name.
22577
22578         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
22579
22580         * lib/strftime.c: Update from GNU libc (the only changes were to
22581         comments).
22582
22583 2001-02-17  Jim Meyering  <meyering@lucent.com>
22584
22585         * lib/regex.c: Update from libc.
22586
22587 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
22588
22589         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
22590         clash.
22591
22592 2001-02-16  Paul Eggert  <eggert@twinsun.com>
22593
22594         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
22595         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
22596         Reported by Mark Hounschell via Paul Eggert.
22597
22598 2001-02-07  Jim Meyering  <meyering@lucent.com>
22599
22600         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
22601
22602 2001-02-05  Jim Meyering  <meyering@lucent.com>
22603
22604         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
22605         it includes the patch required for `large file' support with at least
22606         HP-UX's 10.20 /bin/cc.
22607
22608 2001-02-03  Jim Meyering  <meyering@lucent.com>
22609
22610         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
22611         AS_IF, now that it works once again (mysteriously).
22612         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22613
22614 2001-01-30  Jim Meyering  <meyering@lucent.com>
22615
22616         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
22617         * m4/chown.m4: Rename conftestchown to conftest.chown.
22618         * m4/rename.m4: s/conftestdir/conftest.d1/ and
22619         s/conftestdir2/conftest.d2/.
22620         * m4/utimes.m4: s/conftestdata/conftest.data/
22621         Inspired by Pavel Roskin's change in autoconf.
22622
22623 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
22624
22625         * lib/config.charset: Update for FreeBSD 4.2.
22626
22627 2001-01-27  Jim Meyering  <meyering@lucent.com>
22628
22629         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
22630         a use of AS_IF.
22631         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22632
22633 2001-01-26  Jim Meyering  <meyering@lucent.com>
22634
22635         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
22636         quotearg.c includes it.
22637
22638 2001-01-26  Jim Meyering  <meyering@lucent.com>
22639
22640         * lib/quotearg.c: Include stddef.h.
22641         * lib/quote.c: Include stddef.h.
22642         Reported by Axel Kittenberger.
22643
22644         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
22645         line in double quotes so that it evokes a better diagnostic.
22646         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
22647         Reported by Axel Kittenberger.
22648
22649 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
22650
22651         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
22652         as if it was a `charset'.
22653
22654 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22655
22656         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
22657         has const.
22658
22659 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22660
22661         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
22662         to avoid a warning.  Add back 'const' to inptr.
22663
22664 2001-01-20  Jim Meyering  <meyering@lucent.com>
22665
22666         Be sure that headers are checked before used in code compiled
22667         for the type checks.
22668         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
22669         In place of that, invoke jm_CHECK_ALL_TYPES.
22670         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
22671         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
22672         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
22673         The check for ssize_t was mistakenly run before the test for unistd.h.
22674
22675         The configure-time check for stdbool.h was missing.
22676         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
22677         (jm_PREREQ_HASH): New function.
22678
22679 2001-01-17  Jim Meyering  <meyering@lucent.com>
22680
22681         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
22682         for autoconf-2.49c.
22683         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
22684
22685 2001-01-16  Jim Meyering  <meyering@lucent.com>
22686
22687         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
22688         From Bruno Haible.
22689
22690 2001-01-14  Jim Meyering  <meyering@lucent.com>
22691
22692         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
22693         foo and bar.  Create conftestdir/ in the script, not in the C code.
22694         Remove directories in the script, not in the C code.
22695         Remove conftestdir{,2} before trying to create the directory.
22696         Make the entire configure script fail if the mkdir fails.
22697
22698 2001-01-14  Jim Meyering  <meyering@lucent.com>
22699
22700         * lib/rename.c: New file.  From Volker Borchert.
22701         Include stdlib.h, string.h or strings.h, and xalloc.h.
22702         Use strip_trailing_slashes rather than open-coding it.
22703
22704 2001-01-03  Paul Eggert  <eggert@twinsun.com>
22705
22706         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
22707
22708 2001-01-03  Jim Meyering  <meyering@lucent.com>
22709
22710         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
22711         of local `inptr' to avoid warning with some system declarations of
22712         iconv.
22713
22714 2001-01-02  Volker Borchert  <bt@teknon.de>
22715
22716         * m4/rename.m4: New file.
22717         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
22718
22719 2001-01-01  Jim Meyering  <meyering@lucent.com>
22720
22721         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
22722         even on systems with utmpx.h.  It's necessary for the declaration of
22723         utmp's ut_user member.  Reported by Andreas Jaeger.
22724
22725         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
22726         available. They are required for the declarations of getgrgid and
22727         getpwuid resp.
22728         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
22729         Reported by Andreas Jaeger.
22730
22731 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
22732
22733         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
22734         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
22735         so `make install' also works in VPATH builds.
22736
22737 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
22738
22739         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
22740         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
22741         can be used in subdirectories.
22742
22743 2000-12-29  Paul Eggert  <eggert@twinsun.com>
22744
22745         * lib/modechange.c: Do not assume that mode_t uses the
22746         traditional octal encoding.  E.g. "chmod 1 FOO" should set
22747         the other-execute bit of FOO even if S_IXOTH != 1.
22748
22749         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
22750         WOTH, XOTH, ALLM): New macros.
22751         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
22752          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
22753         Use them.
22754         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
22755         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
22756         (mode_compile):
22757         No need to use uintmax_t; unsigned long is long enough.
22758         Don't bother to get suffix since we don't use it.
22759
22760 2000-12-26  Jim Meyering  <meyering@lucent.com>
22761
22762         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
22763         better with autoheader.
22764
22765 2000-12-24  Jim Meyering  <meyering@lucent.com>
22766
22767         * lib/hash.c (is_prime): Return explicit boolean values.
22768         (hash_get_first): Return NULL to appease Irix5.6's 89.
22769         Reported by Nelson Beebe.
22770
22771 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
22772
22773         * lib/localcharset.c (locale_charset): Add support for Win32.
22774
22775 2000-12-18  Paul Eggert  <eggert@twinsun.com>
22776
22777         * lib/physmem.h, lib/physmem.c: New files.
22778
22779         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
22780         (noinst_HEADERS): Add physmem.h.
22781
22782         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
22783         't' for compatibility with Solaris 8 sort.
22784
22785 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
22786
22787         * lib/config.charset: Add support for BeOS.
22788
22789 2000-12-17  Jim Meyering  <meyering@lucent.com>
22790
22791         * m4/dos.m4 (jm_AC_DOS): New file and macro.
22792         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
22793
22794 2000-12-16  Jim Meyering  <meyering@lucent.com>
22795
22796         This bug had a serious impact on chown: `chown N:M FILE' (for integer
22797         N and M) would have treated it like `chown N:N FILE'.
22798
22799         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
22800
22801 2000-12-16  Jim Meyering  <meyering@lucent.com>
22802
22803         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
22804         SHELLS_FILE to a file name that's useful on djgpp systems.
22805         Include stdlib.h.
22806         (ADDITIONAL_DEFAULT_SHELLS): Define.
22807         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
22808         Based mostly on a patch from Prashant TR.
22809
22810 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
22811
22812         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
22813         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
22814         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
22815
22816 2000-12-08  Andreas Schwab  <schwab@suse.de>
22817
22818         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
22819         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
22820
22821 2000-12-07  Jim Meyering  <meyering@lucent.com>
22822
22823         * lib/stripslash.c (ISSLASH): Define.
22824         (strip_trailing_slashes): Use ISSLASH rather than comparing against
22825         `/'.
22826         From Prashant TR.
22827
22828         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
22829         (dir_name_r): Declare this function as static.
22830         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
22831         manifest itself on a name containing a mix of slashes and
22832         backslashes.
22833         Make this function work with names starting with a DOS-style
22834         drive letter and colon prefix.
22835         (dir_name): Append `.' if necessary.
22836         Based mostly on patches from Prashant TR and Eli Zaretskii.
22837
22838         * lib/dirname.h (dir_name_r): Remove prototype.
22839
22840 2000-12-06  Paul Eggert  <eggert@twinsun.com>
22841
22842         * m4/off_t-format.m4: Remove this file.
22843         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
22844
22845 2000-12-06  Jim Meyering  <meyering@lucent.com>
22846
22847         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
22848         replacement strtoull, we may well need the replacement strtoul, too.
22849         Check for declarations of strtoul and strtoull.
22850         Check for strtol.  Mainly as a cue to cause automake to include
22851         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
22852         Check for limits.h -- strtol.c needs it.
22853
22854 2000-12-05  Jim Meyering  <meyering@lucent.com>
22855
22856         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
22857
22858 2000-12-04  Jim Meyering  <meyering@lucent.com>
22859
22860         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
22861         Also include memory.h, stdlib.h, unistd.h if appropriate.
22862         Reported by Andreas Jaeger (conflicting declaration of malloc).
22863
22864 2000-12-02  Jim Meyering  <meyering@lucent.com>
22865
22866         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
22867         * m4/jm-macros.m4 (jm_MACROS): require it.
22868
22869 2000-12-02  Jim Meyering  <meyering@lucent.com>
22870
22871         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
22872
22873 2000-12-01  Paul Eggert  <eggert@twinsun.com>
22874
22875         * lib/memrchr.c: Include <config.h> before any system include file.
22876
22877 2000-11-30  Jim Meyering  <meyering@lucent.com>
22878
22879         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
22880
22881 2000-11-30  Jim Meyering  <meyering@lucent.com>
22882
22883         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
22884
22885 2000-11-29  Paul Eggert  <eggert@twinsun.com>
22886
22887         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
22888
22889 2000-11-26  Jim Meyering  <meyering@lucent.com>
22890
22891         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
22892
22893 2000-11-22  Paul Eggert  <eggert@twinsun.com>
22894
22895         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
22896         size of (size_t) -1; it's not portable.
22897
22898 2000-11-17  Jim Meyering  <meyering@lucent.com>
22899
22900         * lib/strstr.c: Update from GNU libc.
22901
22902 2000-11-17  Akim Demaille  <akim@epita.fr>
22903
22904         * lib/obstack.h: Formatting changes.
22905         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
22906         prevent type checking.
22907         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
22908         cast the value to (void *): assigning a `foo *' to a `void *'
22909         variable is valid.
22910         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
22911
22912 2000-11-16  Jim Meyering  <meyering@lucent.com>
22913
22914         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
22915
22916 2000-11-11  Jim Meyering  <meyering@lucent.com>
22917
22918         * lib/error.c: Add a couple #includes, merging from GNU libc version.
22919
22920 2000-11-10  Jim Meyering  <meyering@lucent.com>
22921
22922         * lib/obstack.h: Update from GNU libc.
22923         * lib/obstack.c: Likewise.
22924
22925 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
22926
22927         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
22928
22929 2000-11-06  Paul Eggert  <eggert@twinsun.com>
22930
22931         * lib/getusershell.c (setusershell): Use rewind rather than
22932         fseek/fseeko, to avoid configuration hassles with fseeko.
22933         Don't bother opening SHELLS_FILE if shellstream is NULL;
22934         it's not necessary.
22935
22936 2000-11-05  Jim Meyering  <meyering@lucent.com>
22937
22938         * lib/makepath.h (make_dir): Declare.
22939         * lib/makepath.c (make_dir): Remove `static' attribute.
22940         Tweak a comment.
22941
22942 2000-11-04  Jim Meyering  <meyering@lucent.com>
22943
22944         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
22945
22946 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
22947
22948         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
22949         last one in a bucket, advance to the next bucket.
22950
22951 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
22952
22953         * lib/fnmatch.c: Do not comment out all the code if we are using
22954         the GNU C library, because in some cases we are replacing buggy
22955         code in the GNU C library itself.
22956
22957 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
22958
22959         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
22960         (regex_compile): Catch bogus \(\1\).
22961
22962 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22963
22964         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
22965         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
22966         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
22967
22968 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22969
22970         * lib/error.h, getline.h, modechange.h:
22971         Remove "2000" from Copyright line, as the file hasn't been
22972         changed this year other than in the copyright notice.
22973
22974         * lib/xalloc.h: Add "2000" to Copyright line, as this file
22975         was changed this year.
22976
22977 2000-10-29  Jim Meyering  <meyering@lucent.com>
22978
22979         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
22980         renaming.
22981         * m4/ls-mntd-fs.m4: Likewise
22982
22983 2000-10-29  Jim Meyering  <meyering@lucent.com>
22984
22985         * lib/xstat.in: Fix grammar in comment.
22986
22987 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
22988
22989         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
22990         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
22991         doesn't define __restrict_arr.
22992
22993 2000-10-28  Jim Meyering  <meyering@lucent.com>
22994
22995         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
22996         (jm_PREREQ_MEMCHR): New function.
22997
22998 2000-10-28  Jim Meyering  <meyering@lucent.com>
22999
23000         * lib/memchr.c: Update from libc.
23001         Adjust for portability:
23002         [HAVE_STDLIB_H]: Include stdlib.h.
23003         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
23004         Undef __memchr, too.
23005         [!weak_alias]: Define __memchr to memchr.
23006
23007         * lib/regex.c: Update from libc.
23008         * lib/regex.h: Likewise.
23009         * lib/getopt1.c: Likewise.
23010         * lib/memcmp.c: Likewise.
23011
23012         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
23013         Avoid using fseek, when possible -- it's broken by design.
23014         Patch by Ulrich Drepper.
23015
23016 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
23017
23018         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
23019         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
23020         Giving in to popular pressure to shut up the compiler with casts.
23021
23022 2000-10-26  Jim Meyering  <meyering@lucent.com>
23023
23024         * lib/strftime.c: Update from libc.
23025
23026 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
23027
23028         * regex.c: More `unsigned char' -> `re_char' changes.
23029         Also change several `int' into `re_wchar_t'.
23030         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
23031         (PUSH_FAILURE_POINTER): Don't cast any more.
23032         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
23033         We want GCC to complain, since this piece of code makes
23034         re_match non-reentrant, which *should* be fixed.
23035         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
23036         (EXTEND_BUFFER): Use RETALLOC.
23037         (SET_LIST_BIT): Don't cast.
23038         (re_wchar_t): New type.
23039         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
23040         that those two functions will always properly return.
23041         (IMMEDIATE_QUIT_CHECK): Cast to void.
23042         (analyse_first): Use recursion rather than an explicit stack.
23043         (re_compile_fastmap): Can't fail anymore.
23044         (re_search_2): Don't check re_compile_fastmap for failure.
23045         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
23046         Now also sets the new value (passed in a new argument).
23047         (re_match_2_internal): Use it.
23048         Also, use a new var `reg' of type size_t when looping through regs
23049         rather than reuse the inappropriate `mcnt'.
23050
23051 2000-10-25  Jim Meyering  <meyering@lucent.com>
23052
23053         * lib/obstack.c: Update from libc.
23054
23055 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
23056
23057         * regex.c (regex_compile): Change the way of handling a range from
23058         a char less than 256 to a char not less than 256.
23059
23060 2000-10-24  Andrew Innes  <andrewi@gnu.org>
23061
23062         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
23063         NT-Emacs only.
23064         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
23065         so that re_search functions only quit when callers expect them to.
23066
23067 2000-10-23  Jim Meyering  <meyering@lucent.com>
23068
23069         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
23070         wrong.  That set_locale call must not have any side effects.
23071         From Paul Eggert.
23072
23073 2000-10-22  Jim Meyering  <meyering@lucent.com>
23074
23075         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
23076         [CYCLIC]: Remove now-unused definition.
23077
23078         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
23079         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
23080         Suggestion from Ulrich Drepper.
23081
23082 2000-10-21  Jim Meyering  <meyering@lucent.com>
23083
23084         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
23085         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
23086         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
23087
23088 2000-10-21  Jim Meyering  <meyering@lucent.com>
23089
23090         * lib/dirname.c (memrchr): Declare if necessary.
23091         (dir_name): Remove the restriction that there be no
23092         trailing slashes.  Now, this code skips past them, effectively
23093         ignoring them.
23094         [TEST_DIRNAME] (main): New unit tests.
23095
23096         * lib/memrchr.c: New file from GNU libc.
23097         Undef __memrchr, too.
23098         [!weak_alias]: Define __memrchr to memrchr.
23099         Guard weak_alias use with `#ifdef weak_alias'.
23100
23101 2000-10-21  Jim Meyering  <meyering@lucent.com>
23102
23103         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
23104         (dir_name): Use dir_name_r.
23105         * lib/dirname.h (dir_name_r): Declare it.
23106
23107 2000-10-17  Jim Meyering  <meyering@lucent.com>
23108
23109         * lib/quote.h (PARAMS): Define and use.
23110         Reported by Akim Demaille.
23111
23112         * lib/getopt.c: Update from libc.
23113
23114 2000-10-16  Jim Meyering  <meyering@lucent.com>
23115
23116         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
23117         setlocale.
23118         From Jan Fedak.
23119
23120 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
23121
23122         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
23123
23124 2000-09-25  Jim Meyering  <meyering@lucent.com>
23125
23126         * lib/md5.h (rol): Define (from GnuPG).
23127
23128         * lib/sha.c: Give credit (GnuPG) where due.
23129         (M): Use rol rather than open-coding it.
23130         Add a FIXME comment.
23131
23132 2000-09-21  Jim Meyering  <meyering@lucent.com>
23133
23134         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
23135         Reported by Michael Stone.
23136
23137 2000-09-20  Jim Meyering  <meyering@lucent.com>
23138
23139         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
23140         (noinst_HEADERS): Add sha.h.
23141         Based on code from Scott G. Miller and from GnuPG.
23142
23143 2000-09-18  Jim Meyering  <meyering@lucent.com>
23144
23145         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
23146         LIBS. Otherwise, everyone ends up linking with -lelf for some
23147         configurations.
23148         Reported by Mike Stone.
23149
23150 2000-09-15  Jim Meyering  <meyering@lucent.com>
23151
23152         * lib/regex.c: Update from libc.
23153
23154 2000-09-10  Jim Meyering  <meyering@lucent.com>
23155
23156         * lib/getopt.c (_getopt_internal): Update from glibc.
23157
23158 2000-09-09  Jim Meyering  <meyering@lucent.com>
23159
23160         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
23161         think it should be used as a general replacement for isascii.
23162         * lib/fnmatch.c: Likewise.
23163         * lib/mbswidth.c: Likewise
23164         * lib/regex.c: Likewise.
23165
23166         Don't use atoi.
23167         * lib/userspec.c: Include sys/param.h and limits.h.
23168         Include xstrtol.h.
23169         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23170         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
23171         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
23172         UID, GID.  Check range.
23173
23174 2000-09-06  Jim Meyering  <meyering@lucent.com>
23175
23176         * lib/getopt.c (_getopt_internal): Update from glibc.
23177
23178 2000-08-30  Jim Meyering  <meyering@lucent.com>
23179
23180         * lib/strftime.c: Merge in changes from GNU libc.
23181
23182 2000-08-26  Jim Meyering  <meyering@lucent.com>
23183
23184         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
23185         * m4/fpending.m4: New file.
23186
23187 2000-08-26  Jim Meyering  <meyering@lucent.com>
23188
23189         * lib/closeout.c: Include "__fpending.h".
23190         (close_stdout_status): Return right away if there's nothing to flush.
23191
23192         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
23193         * lib/__fpending.c: New file.
23194         * lib/__fpending.h: New file.
23195
23196 2000-08-20  Jim Meyering  <meyering@lucent.com>
23197
23198         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
23199         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
23200         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
23201
23202 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
23203
23204         Improve fileutils installation on systems where running
23205         programs (like install) can't be unlinked.
23206         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
23207         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
23208
23209 2000-08-07  Paul Eggert  <eggert@twinsun.com>
23210
23211         Standardize on "memory exhausted" instead of "Memory exhausted"
23212         or "virtual memory exhausted".
23213         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
23214         "virtual memory exhausted".
23215         * lib/same.c (same_name): Invoke xalloc_die instead of printing
23216         our own message.
23217         * lib/userspec.c (parse_user_spec): Likewise.
23218         * lib/bumpalloc.h: comment fix
23219         * lib/same.c, userspec.c: Include xalloc.h.
23220
23221         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
23222         not char *const and pointing to a constant array.
23223         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
23224         (xrealloc): Comment fix.
23225
23226         * lib/userspec.c (parse_user_spec):
23227         Don't translate a message until just before returning,
23228         to avoid unnecessary translation.
23229
23230 2000-08-07  Jim Meyering  <meyering@lucent.com>
23231
23232         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
23233         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
23234         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
23235         getgroups.c, gethostname.c, getopt.h, group-member.c,
23236         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
23237         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
23238         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
23239         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
23240         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
23241         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
23242         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
23243         yesno.c: Back out Copyright date changes for each file with no change
23244         this year.  This eases coordination with other programs using the same
23245         source code modules.  From Paul Eggert.
23246
23247 2000-08-06  Paul Eggert  <eggert@twinsun.com>
23248
23249         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
23250         not char, for compatibility with glibc 2.1.3 strftime.c.
23251
23252 2000-08-03  Greg McGary  <greg@mcgary.org>
23253
23254         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
23255         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
23256         (EXTEND_BUFFER): Use them.
23257
23258 2000-08-01  Jim Meyering  <meyering@lucent.com>
23259
23260         * lib/dirname.c (ISSLASH): Define.
23261         (BACKSLASH_IS_PATH_SEPARATOR): Define.
23262         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
23263         both `\' and `/' may be use as path separators.
23264         Based on a patch from Prashant TR.
23265
23266 2000-07-31  Paul Eggert  <eggert@twinsun.com>
23267
23268         * lib/quotearg.c (quotearg_n_options): Don't make the initial
23269         slot vector a constant, since it might get modified.
23270
23271 2000-07-31  Jim Meyering  <meyering@lucent.com>
23272
23273         * lib/xmalloc.c: Use `virtual memory exhausted', not
23274         `Memory exhausted'.
23275         * lib/obstack.c (print_and_abort): Likewise.
23276
23277 2000-07-30  Paul Eggert  <eggert@twinsun.com>
23278
23279         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
23280         buffer, so that the caller can always quote one small
23281         component of a "memory exhausted" message in slot 0.
23282         From a suggestion by Jim Meyering.
23283
23284 2000-07-30  Jim Meyering  <meyering@lucent.com>
23285
23286         * lib/makepath.c (make_path): Quote the other instance, too.
23287
23288         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
23289         (STATIC_BUF_SIZE): Define.
23290         (quotearg_n_options): Use only statically allocated storage when
23291         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
23292         than STATIC_BUF_SIZE.
23293
23294 2000-07-29  Jim Meyering  <meyering@lucent.com>
23295
23296         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
23297         * lib/dirname.c (dir_name): Likewise.
23298
23299         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
23300         `/'.
23301
23302         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
23303         (dir_name): Assert that there are no trailing slashes.
23304
23305 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
23306
23307         * lib/mbswidth.h (mbswidth): Add a flags argument.
23308         (mbswidth): New declaration.
23309         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
23310         * lib/mbswidth.c (mbswidth): Add a flags argument.
23311         (mbsnwidth): New function.
23312
23313 2000-07-24  Jim Meyering  <meyering@lucent.com>
23314
23315         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
23316
23317 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23318
23319         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
23320
23321 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23322
23323         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
23324         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
23325         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
23326         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
23327         invoke multibyte primitives.
23328
23329 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23330
23331         * lib/quotearg.c:
23332         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
23333         so that mbstate_t is always defined.
23334
23335         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
23336         be 1 in at least one GCC installation, and this configuration
23337         error is likely to be common.  Ignoring MB_LEN_MAX hurts
23338         performance on hosts that have mbrtowc but have only unibyte
23339         locales, but I assume these hosts are rare.
23340
23341 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23342
23343         * lib/mbswidth.c (_XOPEN_SOURCE):
23344         Don't define; this causes problems on Solaris 7.
23345         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
23346
23347 2000-07-23  Jim Meyering  <meyering@lucent.com>
23348
23349         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
23350         too: getgrgid, getpwuid, getuid.
23351
23352 2000-07-23  Jim Meyering  <meyering@lucent.com>
23353
23354         * lib/basename.c (base_name): Add an assertion.
23355
23356 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
23357
23358         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
23359         shadow its mbsinit function.
23360
23361 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23362
23363         * lib/mbswidth.h: New file.
23364         * lib/mbswidth.c: New file.
23365         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
23366         (noinst_HEADERS): Add mbswidth.h.
23367
23368 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23369
23370         * lib/config.charset: Add support for FreeBSD. Improve support for
23371         HP-UX and IRIX 6.
23372
23373 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
23374
23375         * m4/mbswidth.m4: New file.
23376         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
23377
23378 2000-07-15  Jim Meyering  <meyering@lucent.com>
23379
23380         * lib/makepath.c: Include quote.h.
23381         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
23382         corresponding argument in a `quote (...)' call.
23383         Give better diagnostics.
23384
23385         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
23386         (noinst_HEADERS): Add quote.h.
23387
23388         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
23389         from tar's src/misc.c.
23390         * lib/quote.h: New file.  Prototypes for same.
23391
23392 2000-07-14  Paul Eggert  <eggert@twinsun.com>
23393
23394         From a suggestion by Bruno Haible.
23395         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
23396         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
23397         to decide whether to define the BeOS workaround macro;
23398         this adjusts to the change to AC_MBSTATE_T.
23399
23400 2000-07-14  Jim Meyering  <meyering@lucent.com>
23401
23402         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
23403         jm_AC_TYPE_UINTMAX_T.
23404
23405 2000-07-13  Paul Eggert  <eggert@twinsun.com>
23406
23407         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
23408
23409         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
23410         quotearg_buffer_restyled): Add support for
23411         clocale_quoting_style.  Undo previous change to
23412         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
23413         and "{RIGHT QUOTATION MARK}" msgids.
23414
23415 2000-07-10  Paul Eggert  <eggert@twinsun.com>
23416
23417         From a suggestion by Bruno Haible.
23418         * m4/mbstate_t.m4 (AC_MBSTATE_T):
23419         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
23420         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
23421         and mbstate_t, to a single-part test that simply defines mbstate_t.
23422         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
23423         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
23424
23425 2000-07-10  Jim Meyering  <meyering@lucent.com>
23426
23427         * m4/strerror_r.m4: Mirror the correction made in autoconf.
23428
23429         * m4/gnu-source.m4: Output to confdefs.h directly.
23430         Suggestion from Akim Demaille.
23431
23432 2000-07-09  Paul Eggert  <eggert@twinsun.com>
23433
23434         The old behavior of quoting `like this' doesn't look good with
23435         newer, ISO-style fonts.  See:
23436         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
23437
23438         Instead, quote "like this" by default.  Let the translator
23439         tailor the locale-specific quoting behavior by providing
23440         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
23441
23442         * lib/quotearg.c (N_): New macro.
23443         (gettext_default): New function.
23444         (quotearg_buffer_restyled): Use
23445         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
23446         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
23447
23448 2000-07-09  Jim Meyering  <meyering@lucent.com>
23449
23450         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
23451         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
23452
23453         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
23454         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
23455
23456 2000-07-09  Jim Meyering  <meyering@lucent.com>
23457
23458         * lib/Most files: Update copyright dates to include 2000.
23459
23460 2000-07-08  Jim Meyering  <meyering@lucent.com>
23461
23462         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
23463         if not defined.
23464         (xgethostname): Remove now-unnecessary #ifdef.
23465         Move declaration of `err' into loop where it's used.
23466
23467 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23468         and Bruno Haible  <haible@clisp.cons.org>
23469
23470         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
23471         only if the test for an object-type mbstate_t fails.  This
23472         prevents us from mistakenly reporting that mbstate_t is a
23473         system object type after we "#define mbstate_t int" to work
23474         around its lack.
23475
23476 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23477         and Bruno Haible  <haible@clisp.cons.org>
23478
23479         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
23480
23481 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23482
23483         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
23484         to strerror_r.
23485         Include <ctype.h> for use of isalpha.
23486
23487 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23488
23489         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
23490         by allocating a larger buffer. Test the gethostname return value for
23491         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
23492         returns an error and ENAMETOOLONG isn't defined.
23493
23494 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23495
23496         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
23497         dimension.
23498
23499 2000-07-04  Jim Meyering  <meyering@lucent.com>
23500
23501         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
23502         of the deprecated AC_CHECKING.
23503
23504 2000-07-04  Jim Meyering  <meyering@lucent.com>
23505
23506         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
23507         Reported by Bruno Haible.
23508
23509 2000-07-04  Jim Meyering  <meyering@lucent.com>
23510
23511         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
23512         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
23513         lacks mbrtowc.
23514
23515 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23516
23517         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
23518         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
23519
23520 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23521         and Bruno Haible  <haible@clisp.cons.org>
23522
23523         * lib/quotearg.c (mbrtowc):
23524         Assign to *pwc, and return 1 only if result is nonzero.
23525         (iswprint): Use ISPRINT when substituting our own mbrtowc.
23526
23527 2000-07-03  Jim Meyering  <meyering@lucent.com>
23528
23529         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
23530
23531 2000-07-03  Jim Meyering  <meyering@lucent.com>
23532
23533         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
23534         This is necessary to get a definition of e.g., UTMP_FILE on
23535         HP-UX 10.20.
23536         From Bob Proulx.
23537
23538 2000-07-02  Jim Meyering  <meyering@lucent.com>
23539
23540         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
23541
23542         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
23543         AC_LIBOBJ(function_name).
23544         * m4/chown.m4: Likewise.
23545         * m4/fnmatch.m4: Likewise.
23546         * m4/ftruncate.m4: Likewise.
23547         * m4/getgroups.m4: Likewise.
23548         * m4/getline.m4: Likewise.
23549         * m4/group-member.m4: Likewise.
23550         * m4/jm-macros.m4: Likewise.
23551         * m4/lstat.m4: Likewise.
23552         * m4/malloc.m4: Likewise.
23553         * m4/memcmp.m4: Likewise.
23554         * m4/nanosleep.m4: Likewise.
23555         * m4/putenv.m4: Likewise.
23556         * m4/realloc.m4: Likewise.
23557         * m4/regex.m4: Likewise.
23558         * m4/stat.m4: Likewise.
23559         * m4/strftime.m4: Likewise.
23560
23561 2000-07-02  Jim Meyering  <meyering@lucent.com>
23562
23563         * lib/quotearg.c (mbstate_t): Don't define here.
23564
23565 2000-07-02  Jim Meyering  <meyering@lucent.com>
23566
23567         * lib/nanosleep.c (SIGCONT): Define if not already defined.
23568
23569 2000-07-01  Jim Meyering  <meyering@lucent.com>
23570
23571         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
23572
23573 2000-07-01  Jim Meyering  <meyering@lucent.com>
23574
23575         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
23576         problem.
23577
23578 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23579
23580         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
23581         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
23582
23583 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23584
23585         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
23586         per change in ../m4/ls-mntd-fs.m4.
23587         (read_filesystem_list): Ignore symbolic links.
23588
23589 2000-06-29  Jim Meyering  <meyering@lucent.com>
23590
23591         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
23592         for declaration of strcmp.
23593
23594         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
23595
23596         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
23597         Avoid warning by casting result to `char *' to remove `const'.
23598
23599 2000-06-28  Jim Meyering  <meyering@lucent.com>
23600
23601         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
23602         included by quotearg.c, for which we perform this test.  From
23603         Bruno Haible.
23604
23605 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23606
23607         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
23608         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
23609         <utmpx.h> exists, put readutmp.o into LIBOBJS.
23610
23611 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23612
23613         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
23614
23615 2000-06-26  Paul Eggert  <eggert@twinsun.com>
23616
23617         savedir now sets errno on failure and invokes xmalloc to get memory.
23618         Fix a couple of other minor bugs while we're at it.
23619
23620         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
23621         (NAMLEN): Remove macro.
23622         (malloc, realloc): Remove decls.
23623         (stpcpy): Likewise.
23624         ("xalloc.h"): Include.
23625         (NAME_SIZE_DEFAULT): New macro.
23626         (savedir): Use xmalloc / xrealloc to allocate memory.
23627         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
23628         Skip "" directory entries.
23629         Use strlen to calculate directory entry length, since the old method
23630         is rarely used these days and isn't worth supporting.
23631         Don't use a pointer after freeing it.
23632         Check for integer overflow when calculating allocation size.
23633         Use memcpy to copy entries, instead of stpcpy.
23634         Set errno properly when returning NULL.
23635         Check for readdir error.
23636
23637 2000-06-26  Jim Meyering  <meyering@lucent.com>
23638
23639         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
23640
23641 2000-06-25  Jim Meyering  <meyering@lucent.com>
23642
23643         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
23644         Linux header bug when _XOPEN_SOURCE is defined to 500.
23645
23646 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23647
23648         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
23649         deficiency.
23650
23651 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23652
23653         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
23654         Include xalloc.h.
23655         Don't include <stdlib.h>.  Don't declare malloc, realloc.
23656
23657 2000-06-24  Jim Meyering  <meyering@lucent.com>
23658
23659         * m4/strerror_r.m4: Revive this file -- to try out an experimental
23660         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
23661         for which strerror does return char*, but which lacks a conveniently
23662         accessible declaration of the function.  If the compile-test says
23663         strerror_r doesn't work, then resort to a `run'-test that works on
23664         BeOS and segfaults on DEC Unix.
23665
23666 2000-06-24  Jim Meyering  <meyering@lucent.com>
23667
23668         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
23669
23670 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23671
23672         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
23673         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
23674
23675 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23676
23677         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
23678         (mbrtowc, mbstate_t): Define substitutes if
23679         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
23680         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
23681         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
23682
23683 2000-06-23  Jim Meyering  <meyering@lucent.com>
23684
23685         * m4/afs.m4: Add missing AC_MSG_RESULT.
23686         Reported by Bruno Haible.
23687
23688         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
23689         Suggestion from Bruno Haible.
23690
23691 2000-06-23  Jim Meyering  <meyering@lucent.com>
23692
23693         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
23694
23695 2000-06-21  Jim Meyering  <meyering@lucent.com>
23696
23697         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
23698
23699 2000-06-21  Jim Meyering  <meyering@lucent.com>
23700
23701         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
23702         (noinst_HEADERS): Add getstr.h.
23703
23704         * lib/getline.c (getstr): Move into a separate file.
23705         * lib/getstr.c (getstr): New file, extracted from getline.c, with
23706         the following changes: new parameter, delim2; both delim[12]
23707         parameters have type `int', not `char'.  The latter would lose
23708         with 8-bit delimiters.
23709         * lib/getstr.h: New file.
23710
23711 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23712
23713         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
23714         than 1024, return a memory chunk of least possible size, instead
23715         of size PATH_MAX + 2. In the loop, increment the size proportionally.
23716         Use free/xmalloc instead of xrealloc to avoid copying for very long
23717         paths.
23718
23719 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23720
23721         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
23722         the empty string.
23723
23724 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23725
23726         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
23727         address, not strdup.  Include <stdlib.h> and don't declare free().
23728
23729 2000-06-19  Jim Meyering  <meyering@lucent.com>
23730
23731         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
23732
23733 2000-06-18  Jim Meyering  <meyering@lucent.com>
23734
23735         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
23736
23737         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
23738         `checking whether...' message to be consistent with that of the
23739         lstat test.
23740
23741 2000-06-18  Jim Meyering  <meyering@lucent.com>
23742
23743         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
23744         Besides, these days every porting target provides a mkdir function.
23745
23746         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
23747         needed. (this snippet comes from src/system.h).
23748
23749 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
23750
23751         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
23752
23753 2000-06-15  Paul Eggert  <eggert@twinsun.com>
23754
23755         * lib/human.c (adjust_value): New function.
23756         (human_readable_inexact): Apply rounding style even when
23757         printing approximate values.
23758
23759 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23760
23761         * lib/human.c (human_readable_inexact): Allow an input block
23762         size that is not a multiple of the output block size, and vice versa.
23763         Reported by Piergiorgio Sartor.
23764
23765 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23766
23767         * lib/getdate.y (get_date): Apply relative times after time
23768         zone indicator, not before.  Reported by Todd A. Jacobs.
23769
23770 2000-06-13  Jim Meyering  <meyering@lucent.com>
23771
23772         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
23773
23774         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
23775
23776 2000-06-12  Paul Eggert  <eggert@twinsun.com>
23777
23778         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
23779
23780 2000-06-12  Jim Meyering  <meyering@lucent.com>
23781
23782         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
23783         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
23784         optional argument.
23785         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
23786         the optional argument, `lib'.
23787
23788 2000-06-08  Jim Meyering  <meyering@lucent.com>
23789
23790         * m4/largefile.m4: Remove file (now that it's part of autoconf).
23791
23792 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23793
23794         Rewrite largefile configuration so that we don't need to run
23795         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
23796         AC_CANONICAL_HOST in configure.in -- jmm]
23797
23798         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
23799         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
23800         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
23801         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
23802         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
23803         All uses changed.
23804         Instead of inspecting the output of getconf, try to compile the
23805         test program without and with the macro definition.
23806         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
23807         for getconf.  Instead, check for the needed flags by compiling
23808         test programs.
23809
23810 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23811
23812         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
23813
23814 2000-06-04  Jim Meyering  <meyering@lucent.com>
23815
23816         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
23817         SunOS 4.1.4 for which gid_t is an unsigned type.
23818
23819 2000-06-03  Jim Meyering  <meyering@lucent.com>
23820
23821         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
23822         now that autoconf requires that.
23823
23824         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
23825         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
23826         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
23827
23828 2000-06-03  Jim Meyering  <meyering@lucent.com>
23829
23830         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
23831
23832 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23833
23834         * m4/glibc21.m4: New file.
23835         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
23836
23837 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23838
23839         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
23840         newer, don't install charset.alias.
23841         * lib/config.charset: Change the Linux/glibc rules so they become empty
23842         on glibc-2.1 or newer.
23843
23844 2000-06-02  Jim Meyering  <meyering@lucent.com>
23845
23846         * lib/mountlist.c: Back out last change.  Instead, do this...
23847         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
23848         me_dummy member using the same `ignore'-testing code.
23849         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
23850         fs_type strings.
23851         From Mark D. Roth.
23852
23853 2000-05-29  Jim Meyering  <meyering@lucent.com>
23854
23855         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
23856         mounts with the `ignore' attribute.  Based on a patch from
23857         Mark D. Roth.
23858
23859 2000-05-28  Jim Meyering  <meyering@lucent.com>
23860
23861         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
23862         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23863         * m4/stat.m4: Likewise.
23864         * m4/lstat.m4: Likewise.
23865         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
23866
23867         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
23868         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
23869
23870 2000-05-26  Jim Meyering  <meyering@lucent.com>
23871
23872         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
23873
23874 2000-05-24  Jim Meyering  <meyering@lucent.com>
23875
23876         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
23877         autoconf requires that.
23878         * m4/lib-check.m4: Likewise.
23879         * m4/jm-macros.m4: Likewise.
23880         * m4/strftime.m4: Likewise.
23881
23882         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
23883         AC_CHECK_DECLS, now that autoconf requires that.
23884
23885 2000-05-22  Jim Meyering  <meyering@lucent.com>
23886
23887         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23888         * m4/lstat.m4: Likewise.
23889
23890 2000-05-22  Jim Meyering  <meyering@lucent.com>
23891
23892         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
23893
23894 2000-05-20  Jim Meyering  <meyering@lucent.com>
23895
23896         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
23897         (jm_PREREQ): Use it.
23898
23899 2000-05-18  Jim Meyering  <meyering@lucent.com>
23900
23901         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
23902         back, too, since it may have been modified by allocate_entry.
23903         (hash_delete): Rewrite to use neither the assignment operator
23904         nor the comma operator in an if-expression.
23905
23906 2000-05-15  Paul Eggert  <eggert@twinsun.com>
23907
23908         * lib/closeout.c:
23909         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
23910         Remove; no longer needed.
23911         "quotearg.h": Add include.
23912         (file_name): Do not bother to explicitly initialize to NULL; it's less
23913         efficient on some hosts.
23914         (close_stdout_status): Remove test as to whether stdout was already
23915         closed; it breaks for the case "echo x | sort >&-".
23916         Quote file name colons.
23917         Do not assume that _("write error") lacks format strings.
23918
23919 2000-05-15  Jim Meyering  <meyering@lucent.com>
23920
23921         * lib/version-etc.c (version_etc_copyright): Update the copyright
23922         string used in all --version output.
23923
23924 2000-05-14  Jim Meyering  <meyering@lucent.com>
23925
23926         * lib/closeout.c (close_stdout_set_file_name): New function.
23927         (close_stdout_status): Use new file-scoped global.
23928         Return right away if fstat says the stdout file descriptor is invalid.
23929         * lib/closeout.h (close_stdout_set_file_name): Declare.
23930
23931 2000-05-10  Jim Meyering  <meyering@lucent.com>
23932
23933         * lib/closeout.c [default_exit_status]: New file-scoped variable.
23934         (close_stdout_set_status): New function.
23935         * lib/closeout.h (close_stdout_set_status): Declare.
23936
23937 2000-05-09  Jim Meyering  <meyering@lucent.com>
23938
23939         * m4/gettext.m4: Rename this...
23940         * m4/libintl.m4: ...to this.
23941
23942 2000-05-08  Jim Meyering  <meyering@lucent.com>
23943
23944         * lib/long-options.c: Don't include closeout.h.
23945         (parse_long_options): Don't call close_stdout for --version.
23946
23947 2000-05-06  Paul Eggert  <eggert@twinsun.com>
23948
23949         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
23950         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
23951         2.1.3 bug.  This avoids a clash when files like regex.c define
23952         _GNU_SOURCE.
23953
23954 2000-05-06  Jim Meyering  <meyering@lucent.com>
23955
23956         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
23957         (AC_REPLACE_FUNCS): Add strnlen.
23958
23959         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
23960         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
23961
23962         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
23963         AC_SEARCH_LIBS call for nanosleep.
23964         (LIB_NANOSLEEP): Set and AC_SUBST.
23965
23966 2000-05-06  Jim Meyering  <meyering@lucent.com>
23967
23968         * lib/strnlen.c: Undefine __strnlen and strnlen.
23969         [!weak_alias]: Define __strnlen to strnlen.
23970
23971         * lib/atexit.c: New file, from libiberty.
23972
23973 2000-05-06  Jim Meyering  <meyering@lucent.com>
23974
23975         * lib/closeout.c (close_stdout_status): Also check for errors on the
23976         stderr stream.
23977
23978 2000-05-05  Jim Meyering  <meyering@lucent.com>
23979
23980         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
23981         AC_SEARCH_LIBS call for clock_gettime.
23982         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
23983
23984         * m4/search-libs.m4: Update from autoconf.
23985
23986         su doesn't work on Solaris 2.6.
23987         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
23988         <shadow.h>.  Reported by Dragos Harabor.
23989
23990 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
23991
23992         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
23993         memcpy instead of xmalloc, xrealloc, path_concat.
23994         (locale_charset): Treat empty environment variables as absent.
23995         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
23996
23997 2000-05-04  Jim Meyering  <meyering@lucent.com>
23998
23999         * lib/getopt.c: Update from glibc.
24000         * lib/obstack.c: Likewise.
24001         * lib/obstack.h: Likewise.
24002         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
24003         file
24004
24005         * lib/regex.h: Likewise.
24006         * lib/strndup.c: Likewise.
24007         * lib/strnlen.c: New file, from glibc.
24008
24009 2000-05-03  Jim Meyering  <meyering@lucent.com>
24010
24011         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
24012
24013 2000-05-02  Paul Eggert  <eggert@twinsun.com>
24014
24015         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
24016         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
24017         compile-time test, rather than inspecting host and OS, to
24018         decide whether to define _LARGEFILE_SOURCE.
24019
24020 2000-05-01  Jim Meyering  <meyering@lucent.com>
24021
24022         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
24023
24024         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
24025         Based on a patch from Bruno Haible.
24026
24027 2000-05-01  Jim Meyering  <meyering@lucent.com>
24028
24029         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
24030
24031 2000-04-29  Jim Meyering  <meyering@lucent.com>
24032
24033         * lib/path-concat.c: Declare strdup only if it's not defined.
24034         * lib/canon-host.c: Likewise.
24035
24036 2000-04-28  Jim Meyering  <meyering@lucent.com>
24037
24038         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
24039         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
24040         is included first, then limits.h is included by locale.h by libintl.h.
24041         From John David Anglin.
24042
24043 2000-04-25  Jim Meyering  <meyering@lucent.com>
24044
24045         * lib/makepath.c (S_IRWXUGO): Define.
24046         (make_path): Always perform explicit chmod if MODE specifies any
24047         of the `special' permission bits.  Prompted by a bug report against
24048         install from Mate Wierdl and Joost van Baal.
24049
24050 2000-04-18  Jim Meyering  <meyering@lucent.com>
24051
24052         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
24053         (jm_PREREQ): Use it.
24054
24055 2000-04-18  Jim Meyering  <meyering@lucent.com>
24056
24057         * lib/README: New file.
24058
24059         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
24060         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
24061
24062 2000-04-17  Jim Meyering  <meyering@lucent.com>
24063
24064         Get it right :-)
24065         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
24066         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
24067         Suggestion from Akim Demaille.
24068
24069 2000-04-17  Jim Meyering  <meyering@lucent.com>
24070
24071         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
24072         the definition of it to rpl_strftime also defined-away the system's
24073         declaration.
24074
24075 2000-04-15  Jim Meyering  <meyering@lucent.com>
24076
24077         Use `C' to denote so-called `contiguous' files, the same way
24078         that tar does.
24079         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
24080         (ftypelet): Use S_ISCTG.
24081         From Michael Deutschmann.
24082
24083 2000-04-14  Jim Meyering  <meyering@lucent.com>
24084
24085         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
24086         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
24087         clobbered.
24088
24089 2000-04-14  Jim Meyering  <meyering@lucent.com>
24090
24091         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
24092
24093 2000-04-13  Jim Meyering  <meyering@lucent.com>
24094
24095         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
24096         AH_VERBATIM to insert required #ifndef into config.h.in.
24097         Suggestion from Akim Demaille.
24098
24099 2000-04-12  Jim Meyering  <meyering@lucent.com>
24100
24101         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
24102         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
24103         Christian Krackowizer.
24104
24105         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
24106         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
24107         (AC_SYS_LARGEFILE): Require.
24108         (AM_C_PROTOTYPES): Require.
24109
24110 2000-04-08  Jim Meyering  <meyering@lucent.com>
24111
24112         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
24113         names don't conflict.  Reported by Eli Zaretskii.
24114
24115 2000-04-07  Jim Meyering  <meyering@lucent.com>
24116
24117         * lib/putenv.c: Move inclusion of errno.h so it follows that of
24118         sys/types.h, to work around system header problems on AIX 3.2.5.
24119         From Bruno Haible.
24120
24121 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
24122
24123         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
24124         bug.  Deal with the different error behavior of Irix iconv.
24125
24126 2000-04-05  Paul Eggert  <eggert@twinsun.com>
24127
24128         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
24129         IRIX if the installer said otherwise.
24130
24131 2000-04-05  Jim Meyering  <meyering@lucent.com>
24132
24133         Portability tweaks required for ultrix4.3.
24134         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
24135         (jm_CHECK_DECLS): Add getutent to the list of functions.
24136         (_jm_DECL_HEADERS): Add utmpx.h.
24137         From John David Anglin.
24138
24139         * m4/strftime.m4: Back out the 2000-04-02 change.
24140         Instead of that change, simply undefine putenv in the test program.
24141
24142 2000-04-05  Jim Meyering  <meyering@lucent.com>
24143
24144         Portability tweaks required for ultrix4.3.
24145         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
24146         getutent.
24147         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
24148         * lib/canon-host.c: Declare strdup.
24149         * lib/path-concat.c: Likewise.
24150         From John David Anglin.
24151
24152 2000-04-04  Jim Meyering  <meyering@lucent.com>
24153
24154         Be more DOS 8.3-friendly.
24155         * lib/ref-add.sin: Renamed from ref-add.sed.in.
24156         * lib/ref-del.sin: Renamed from ref-del.sed.in.
24157         * lib/Makefile.am: Reflect renaming.
24158         Reported by Eli Zaretskii.
24159
24160         Use a temporary file name that won't clash with `charset.alias'
24161         in the DOS 8.3 name space.
24162         * lib/Makefile.am (charset_tmp): Define.
24163         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
24164         (uninstall-local): Likewise.
24165         Reported by Eli Zaretskii.
24166
24167 2000-04-03  Jim Meyering  <meyering@lucent.com>
24168
24169         * m4/gettext.m4: Fix typo in comment.
24170
24171         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
24172         textutils/configure.in).  Suggestion from Paul Eggert.
24173         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
24174
24175 2000-04-02  Paul Eggert  <eggert@twinsun.com>
24176
24177         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
24178         variable in the shell rather than using putenv, which isn't
24179         portable.  This avoids the configure-time inter-test dependency
24180         on the potentially-renamed putenv function.
24181
24182 2000-03-30  Paul Eggert  <eggert@twinsun.com>
24183
24184         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
24185         before checking struct stat.st_blksize, so that
24186         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
24187
24188 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24189
24190         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
24191         since strftime.c uses HAVE_STRFTIME to decide whether to use
24192         the underlying strftime.
24193
24194 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24195
24196         * lib/time/strftime.c (my_strftime): Make sure we call the system
24197         strftime, not ourselves, when invoking the underlying strftime.
24198
24199 2000-03-24  Jim Meyering  <meyering@lucent.com>
24200
24201         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
24202         (charset_alias): Define.
24203         (install-exec-local): Factor out common code.
24204         (uninstall-local): Split lines longer than 80.
24205         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
24206         (SUFFIXES): Define.
24207         (.sed.in.sed): New rule.  Don't redirect directly to $@.
24208         (CLEANFILES): Add ref-add.sed and ref-del.sed.
24209
24210 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
24211
24212         * lib/config.charset: Output a line containing "Packages using this
24213         file".
24214         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
24215         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
24216         ref-del.sed): New rules.
24217
24218 2000-03-17  Jim Meyering  <meyering@lucent.com>
24219
24220         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
24221         Otherwise, include <strings.h>
24222
24223 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
24224
24225         * lib/unicodeio.c (utf8_wctomb): New function.
24226         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
24227         format instead of in UCS-4 with platform dependent endianness.
24228
24229 2000-03-10  Jim Meyering  <meyering@lucent.com>
24230
24231         * m4/lib-check.m4: Look for getspnam in -lgen, too.
24232         From Marco Franzen.
24233
24234 2000-03-07  Paul Eggert  <eggert@twinsun.com>
24235
24236         * lib/savedir.c (savedir): Work even if directory size is
24237         negative; this can happen with some screwy NFS configurations.
24238
24239 2000-03-06  Jim Meyering  <meyering@lucent.com>
24240
24241         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
24242         if it's NULL (because we ran out of memory).  From Bruno Haible.
24243
24244 2000-03-05  Jim Meyering  <meyering@lucent.com>
24245
24246         * lib/localcharset.c ("path-concat.h"): Include.
24247         (get_charset_aliases): Use path_concat instead of ANSI string
24248         concatenation.
24249
24250         * lib/unicodeio.h (PARAMS): Define.
24251         Use it to guard prototype.
24252
24253 2000-03-04  Jim Meyering  <meyering@lucent.com>
24254
24255         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
24256         for lib/localcharset.c.
24257
24258 2000-03-04  Jim Meyering  <meyering@lucent.com>
24259
24260         * lib/Makefile.am (install-exec-local): Create $(libdir) before
24261         installing into it.
24262         (uninstall-local): Uncomment this rule so `make distcheck' works
24263         once again.
24264
24265         * lib/unicodeio.c (<errno.h>): Include it.
24266         (errno): Declare if not defined.
24267
24268         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
24269
24270         * lib/config.charset: New version, incorporating remarks from a linux
24271         i18n mailing list.  From Bruno Haible.
24272
24273 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
24274
24275         * m4/codeset.m4: New file.
24276         * m4/iconv.m4: New file.
24277         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
24278
24279 2000-03-03  Jim Meyering  <meyering@lucent.com>
24280
24281         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
24282
24283 2000-03-02  Jim Meyering  <meyering@lucent.com>
24284
24285         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
24286         the messages come out on separate lines.
24287
24288         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
24289         rather than jm_CHECK_DECLARATIONS.
24290         * m4/decl.m4: Remove now-unused file.
24291
24292         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
24293         geteuid.
24294
24295 2000-03-02  Jim Meyering  <meyering@lucent.com>
24296
24297         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
24298
24299 2000-03-01  Jim Meyering  <meyering@lucent.com>
24300
24301         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
24302         * lib/unicodeio.c: Likewise.
24303
24304 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
24305
24306         * lib/config.charset: New file.
24307         * lib/localcharset.c: New file.
24308         * lib/unicodeio.h, lib/unicodeio.c: New files.
24309         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
24310         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
24311         (noinst_HEADERS): Add unicodeio.h.
24312         (all-local, install-exec-local, charset.alias): New targets.
24313
24314 2000-02-28  Paul Eggert  <eggert@twinsun.com>
24315
24316         * lib/quotearg.c (ALERT_CHAR): New macro.
24317         (quotearg_buffer_restyled): Use it.
24318
24319 2000-02-27  Jim Meyering  <meyering@lucent.com>
24320
24321         * m4/check-decl.m4: Add getenv to the list.
24322
24323 2000-02-27  Jim Meyering  <meyering@lucent.com>
24324
24325         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
24326         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
24327
24328         * lib/backupfile.c: Guard inclusion of stdlib.h with
24329         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
24330         Declare malloc if needed.
24331
24332         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
24333         `#ifndef HAVE_DECL..'
24334         now that autoconf always defines the HAVE_DECL_ symbols.
24335         * lib/human.c: Likewise.
24336         * lib/same.c: Likewise.
24337         * lib/strtoumax.c: Likewise.
24338
24339         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
24340         declaration check was not run.
24341         * lib/hash.c: Likewise.
24342         * lib/human.c: Likewise.
24343         * lib/same.c: Likewise.
24344         * lib/strtoumax.c: Likewise.
24345
24346         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
24347         `.', then first look up the entire `.'-containing string as a login
24348         name.
24349
24350 2000-02-23  Jim Meyering  <meyering@lucent.com>
24351
24352         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
24353         in place of my hack.
24354
24355 2000-02-18  Paul Eggert  <eggert@twinsun.com>
24356
24357         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
24358         (textint): New typedef.
24359         (parser_control): Member year changed from int to textint.
24360         All uses changed.
24361         (YYSTYPE): Removed; replaced by %union with int and textint members.
24362         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
24363         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
24364         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
24365         (tSNUMBER, tUNUMBER): Now of type <textintval>.
24366         (date, number, to_year): Use width of number in digits, not its value,
24367         to determine whether it's a 2-digit year, or a 2-digit time.
24368         (yylex): Store number of digits of numeric tokens.
24369         Reported by John Kendall.
24370
24371         (parser_control): Changed from struct parser_control to typedef (for
24372         consistency).  All uses changed.
24373
24374         (tID): Removed; not used.
24375         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
24376
24377 2000-02-14  Paul Eggert  <eggert@twinsun.com>
24378
24379         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
24380         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
24381
24382 2000-02-12  Jim Meyering  <meyering@lucent.com>
24383
24384         * lib/userspec.c (ISDIGIT): Define it.
24385         (isdigit): Remove definition.
24386         (is_number): Use ISDIGIT, not isdigit.
24387         <libintl.h>: Include.
24388         (_ and N_): Define.
24389         (parse_user_spec): Mark translatable strings.
24390
24391 2000-02-10  Jim Meyering  <meyering@lucent.com>
24392
24393         With these changes, nanosleep.[ch] are finally enough like the other
24394         lib/* replacement files to compile on a few more losing systems.
24395
24396         * lib/nanosleep.h: Don't include config.h.
24397         Remove prototype from declaration of nanosleep.
24398         (PARAMS): Remove now-unneeded definition.
24399         * lib/nanosleep.c: #undef nanosleep.
24400         (rpl_nanosleep): Rename from nanosleep.
24401
24402 2000-02-10  Jim Meyering  <meyering@lucent.com>
24403
24404         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
24405         gnu_nanosleep to rpl_nanosleep.
24406
24407 2000-02-09  Jim Meyering  <meyering@lucent.com>
24408
24409         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
24410         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
24411
24412 2000-02-08  Akim Demaille  <akim@epita.fr>
24413
24414         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
24415         `[' and `]' and remove uses of `changequote'.
24416         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
24417         (AC_SYS_LARGEFILE): Likewise.
24418         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
24419         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
24420         of changequote.
24421         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
24422         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
24423         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
24424         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
24425
24426 2000-02-05  Jim Meyering  <meyering@lucent.com>
24427
24428         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
24429         Remove explicit use of AC_HEADER_TIME.  It is required by
24430         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
24431         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
24432         in autoconf whereby the expansion of the latter ended up preceding
24433         the expansion of its prerequisite, AC_HEADER_TIME.
24434         Reported by Volker Borchert.
24435
24436 2000-02-03  Jim Meyering  <meyering@lucent.com>
24437
24438         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
24439
24440 2000-02-03  Jim Meyering  <meyering@lucent.com>
24441
24442         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
24443         rather than with `#if HAVE_UTMPNAME'.
24444
24445 2000-02-02  Jim Meyering  <meyering@lucent.com>
24446
24447         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
24448         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
24449         Reported by Eli Zaretskii.
24450
24451 2000-02-01  Jim Meyering  <meyering@lucent.com>
24452
24453         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
24454
24455 2000-01-31  Jim Meyering  <meyering@lucent.com>
24456
24457         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
24458         functions.  Add the time.h and sys/time.h headers along with the
24459         AC_REQUIRE'ment of AC_HEADER_TIME.
24460
24461 2000-01-31  Jim Meyering  <meyering@lucent.com>
24462
24463         * lib/nanosleep.h (nanosleep): Guard declaration with
24464         `#if ! HAVE_DECL_NANOSLEEP'.
24465         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
24466         the declaration in that vendor's sys/timers.h.
24467         Reported by Christian Krackowizer.
24468
24469         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
24470         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
24471         (ISPRINT): Likewise.
24472         Reported by Tom Tromey.
24473
24474 2000-01-30  Jim Meyering  <meyering@lucent.com>
24475
24476         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
24477
24478         * m4/prereq.m4 (utmp_includes): Define.
24479         Check for ut_user and ut_name members in both struct utmpx
24480         and struct utmp.
24481
24482 2000-01-30  Jim Meyering  <meyering@lucent.com>
24483
24484         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
24485         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
24486         header files where only utmpx.ut_user is declared.
24487
24488         * lib/readutmp.h (UT_USER): Define.
24489
24490 2000-01-29  Jim Meyering  <meyering@lucent.com>
24491
24492         * m4/lib-check.m4: New file containing library-related checks from
24493         fileutils and sh-utils (textutils had none).
24494
24495 2000-01-28  Jim Meyering  <meyering@lucent.com>
24496
24497         * m4/perl.m4: Change format of warning message to look more like that
24498         from the missing script.  Suggestion from François Pinard.
24499
24500 2000-01-25  Jim Meyering  <meyering@lucent.com>
24501
24502         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
24503         well as time.h in the compile check.
24504         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
24505         Fix typo in cross-compiling case: s/yes/no/.
24506
24507 2000-01-23  Jim Meyering  <meyering@lucent.com>
24508
24509         * m4/jm-macros.m4: Move df-related tests here from
24510         fileutils/configure.in
24511
24512         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
24513         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
24514
24515         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
24516         s/space/ac_fsusage_space/.
24517         (jm_FILE_SYSTEM_USAGE): Take two parameters.
24518
24519         * m4/ftruncate.m4: New file (derived from part of
24520         fileutils/configure.in).
24521         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
24522         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
24523
24524         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
24525         AC_SUBST these here, rather than just in sh-util/configure.in, so
24526         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
24527         all the same.
24528         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
24529         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
24530         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
24531         (AC_SUBST(POW_LIBM)): Likewise.
24532         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
24533
24534 2000-01-23  Jim Meyering  <meyering@lucent.com>
24535
24536         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
24537         obstack.c.
24538
24539 2000-01-22  Jim Meyering  <meyering@lucent.com>
24540
24541         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
24542
24543         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
24544
24545         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
24546         configure.in
24547         (AC_CHECK_HEADERS): Likewise for sh-utils.
24548         (AC_CHECK_HEADERS): Likewise for textutils.
24549         Merge the three lists of headers.
24550
24551         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
24552         from fileutils' configure.in.
24553
24554         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
24555         code. Moved tests into their own function (_jm_DECL_HEADERS) in
24556         check-decl.m4.
24557
24558         * m4/check-decl.m4: Use #if rather than #ifdef.
24559         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
24560         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
24561         (_jm_DECL_HEADERS): Define new function.
24562         (jm_CHECK_DECLARATIONS): Require it.
24563
24564 2000-01-22  Jim Meyering  <meyering@lucent.com>
24565
24566         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
24567         [! HAVE_DECL_STRTOULL]: Declare strtoull.
24568         Required for some AIX systems.  Reported by Christian Krackowizer.
24569         [TESTING] (main): New function.
24570
24571         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
24572         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
24573         letters.
24574
24575         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
24576         iswprint.
24577
24578         * lib/strverscmp.c (ISDIGIT): Define.
24579         (strverscmp): Use ISDIGIT, not isdigit.
24580
24581 2000-01-19  Jim Meyering  <meyering@lucent.com>
24582
24583         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
24584         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
24585         defines `struct timespec' in <sys/time.h>
24586
24587         * m4/c-bs-a.m4: Remove uses of changequote altogether.
24588         Thanks to Akim for explaining.
24589
24590 2000-01-17  Paul Eggert  <eggert@twinsun.com>
24591
24592         * lib/nanosleep.c (nanosleep):
24593         Don't use SA_INTERRUPT to decide whether to call sigaction, as
24594         POSIX.1 doesn't require SA_INTERRUPT and some systems
24595         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
24596         it's been part of POSIX.1 since day 1 (in 1988).
24597
24598 2000-01-17  Jim Meyering  <meyering@lucent.com>
24599
24600         * lib/interlock: Remove unused file.  Reported by François Pinard.
24601
24602 2000-01-16  Paul Eggert  <eggert@twinsun.com>
24603
24604         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
24605         alert, backslash, formfeed, and vertical tab unnecessarily in
24606         shell quoting style.
24607
24608 2000-01-16  Jim Meyering  <meyering@lucent.com>
24609
24610         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
24611         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
24612         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
24613         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
24614
24615 2000-01-16  Jim Meyering  <meyering@lucent.com>
24616
24617         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
24618         because the latter didn't work.
24619
24620 2000-01-15  Jim Meyering  <meyering@lucent.com>
24621
24622         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
24623         (AC_REPLACE_FUNCS): Add memcpy and memset.
24624         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
24625         Add strpbrk.
24626         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
24627
24628 2000-01-12  Jim Meyering  <meyering@lucent.com>
24629
24630         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
24631         (jm_PREREQ): Use it.
24632         (jm_PREREQ_READUTMP): New macro.
24633         (jm_PREREQ): Use it.
24634
24635 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24636
24637         Quote multibyte characters correctly.
24638         * m4/c-bs-a.m4: New file.
24639         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
24640         (jm_PREREQ): Use it.
24641
24642 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24643
24644         * m4/uintmax_t.m4: Port to autoconf 2.13.
24645
24646 2000-01-08  Jim Meyering  <meyering@ascend.com>
24647
24648         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
24649         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
24650
24651 2000-01-04  Jim Meyering  <meyering@ascend.com>
24652
24653         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
24654         jm_STRUCT_DIRENT_D_TYPE.
24655         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
24656         jm_STRUCT_DIRENT_D_INO.
24657         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
24658         jm_STRUCT_UTIMBUF.
24659         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
24660         renamings.
24661         * m4/utime.m4: Likewise.
24662
24663         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
24664         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
24665
24666 2000-01-03  Paul Eggert  <eggert@twinsun.com>
24667
24668         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
24669         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
24670
24671 2000-01-02  Jim Meyering  <meyering@ascend.com>
24672
24673         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
24674         remember if this is necessary.
24675
24676 1999-12-26  Jim Meyering  <meyering@ascend.com>
24677
24678         * m4/jm-macros.m4: Use it here.
24679         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
24680
24681 1999-12-23  Jim Meyering  <meyering@ascend.com>
24682
24683         * m4/jm-macros.m4: Check for clock_gettime (moved from
24684         fileutils/configure.in)
24685         Check for gettimeofday.
24686
24687 1999-12-20  Jim Meyering  <meyering@ascend.com>
24688
24689         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
24690         autoconf-2.14a-1999-12-20.
24691
24692 1999-12-19  Jim Meyering  <meyering@ascend.com>
24693
24694         * m4/lstat-slash.m4: New file.
24695         * m4/jm-macros.m4: Use the new macro:
24696         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24697
24698 1999-12-07  Jim Meyering  <meyering@ascend.com>
24699
24700         * m4/perl.m4: Require that File::Compare be available, too.
24701         Too many systems seem to lack it.
24702
24703         * m4/strftime.m4: Add checks for most of the cpp macros tested in
24704         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
24705
24706 1999-11-18  Paul Eggert  <eggert@twinsun.com>
24707
24708         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
24709         problem with the QNX 4.25 shell, which doesn't propagate exit
24710         status of failed commands inside shell assignments.
24711
24712 1999-11-17  Jim Meyering  <meyering@ascend.com>
24713
24714         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
24715
24716 1999-11-07  Jim Meyering  <meyering@ascend.com>
24717
24718         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
24719
24720 1999-11-06  Jim Meyering  <meyering@ascend.com>
24721
24722         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
24723         * m4/jm-macros.m4 (jm_MACROS): Use it here.
24724
24725 1999-11-05  Jim Meyering  <meyering@ascend.com>
24726
24727         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
24728         configure.in of textutils, fileutils, and sh-utils into this one
24729         (shared between those packages) file.
24730         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
24731         AC_STRUCT_ST_BLKSIZE.
24732
24733 1999-11-03  Jim Meyering  <meyering@ascend.com>
24734
24735         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
24736         of AC_CHECK_TYPE checks includes unistd.h.
24737         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
24738         Suggestion from Akim Demaille.
24739
24740 1999-10-30  Jim Meyering  <meyering@ascend.com>
24741
24742         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
24743         m4-quoted string.
24744         * m4/ls-mntd-fs.m4: Likewise.
24745         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
24746         * m4/jm-winsz1.m4: Likewise.
24747
24748         * m4/const.m4: Remove file, since the fix made it into the experimental
24749         version of autoconf.
24750         * m4/mktime.m4: Likewise.
24751
24752         * m4/check-type.m4: Remove file, now that the latest version of
24753         AC_CHECK_TYPE takes a third arg to specify additional #includes.
24754
24755         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
24756         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
24757         AC_CHECK_TYPE.
24758
24759 1999-10-04  Jim Meyering  <meyering@ascend.com>
24760
24761         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
24762
24763 1999-09-22  Paul Eggert  <eggert@twinsun.com>
24764
24765         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
24766         2.95.1 bug with HP-UX 10.20.
24767
24768 1999-09-17  Jim Meyering  <meyering@ascend.com>
24769
24770         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
24771         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
24772         due to missing strdup (against sh-utils-2.0).
24773
24774 1999-08-29  Jim Meyering  <meyering@ascend.com>
24775
24776         * m4/jm-macros.m4: Require jm_BISON.
24777         * m4/bison.m4: New file.
24778
24779 1999-08-17  Paul Eggert  <eggert@twinsun.com>
24780
24781         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
24782         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
24783
24784 1999-08-05  Jim Meyering  <meyering@ascend.com>
24785
24786         * m4/getline.m4: Rename test file from conftestdata to conftest.data
24787         to avoid conflicts with `conftest' on 8+3 filesystems.
24788         Suggestion from Eli Zaretskii.
24789
24790 1999-08-04  Jim Meyering  <meyering@ascend.com>
24791
24792         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
24793         fileutils and sh-utils (textutils's getline test was inadequate).
24794         (AM_FUNC_GETLINE): Run this test.
24795         (AC_CHECK_FUNCS): Check for getdelim.
24796         Reported by Bob Proulx.
24797
24798 1999-08-02  Jim Meyering  <meyering@ascend.com>
24799
24800         * m4/jm-macros.m4: Add a comment.
24801
24802 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24803
24804         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
24805         <inttypes.h> defines strtoumax as a macro (and not as a
24806         function).
24807
24808 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24809
24810         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
24811         that we can shift, multiply and divide unsigned long long
24812         values; Ultrix cc can't do it.
24813
24814 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24815
24816         * m4/mktime.m4: New file, which is a preview of what should appear
24817         in the next public autoconf release.
24818
24819 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24820
24821         * m4/lfs.m4: Remove this file.
24822         * m4/largefile.m4: New file.  It contains the old contents of
24823         lfs.m4, except that all names with prefix AC_LFS have been
24824         changed to use the prefix AC_SYS_LARGEFILE instead, to be
24825         compatible with future autoconf versions.  Also, some minor m4
24826         quoting problems have been fixed.
24827
24828 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24829
24830         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
24831         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
24832         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
24833         and simplify the shell code.
24834
24835 1999-08-01  Jim Meyering  <meyering@ascend.com>
24836
24837         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
24838         m4.
24839
24840 1999-07-20  Jim Meyering  <meyering@ascend.com>
24841
24842         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
24843
24844 1999-07-15  Jim Meyering  <meyering@ascend.com>
24845
24846         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
24847
24848 1999-05-22  Jim Meyering  <meyering@ascend.com>
24849
24850         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
24851
24852 1999-05-20  Jim Meyering  <meyering@ascend.com>
24853
24854         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
24855         Add a colon after each `then' in case $4 is empty.
24856
24857 1999-05-16  Jim Meyering  <meyering@ascend.com>
24858
24859         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
24860
24861 1999-05-10  Jim Meyering  <meyering@ascend.com>
24862
24863         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
24864
24865         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
24866         AC_FUNC_MKTIME.
24867
24868 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
24869
24870         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
24871
24872 1999-05-04  Paul Eggert  <eggert@twinsun.com>
24873
24874         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
24875         not CPPFLAGS, so that linking works correctly in IRIX.
24876
24877 1999-04-30  Paul Eggert  <eggert@twinsun.com>
24878
24879         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
24880
24881 1999-04-20  Paul Eggert  <eggert@twinsun.com>
24882
24883         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
24884         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
24885         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
24886         jm_AC_TYPE_UNSIGNED_LONG_LONG.
24887         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
24888
24889         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
24890
24891 1999-04-20  Jim Meyering  <meyering@ascend.com>
24892
24893         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
24894         AC_REPLACE xstroull if necessary.  From Paul Eggert.
24895         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
24896
24897 1999-04-18  Jim Meyering  <meyering@ascend.com>
24898
24899         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
24900         * m4/jm-macros.m4: Use it.
24901
24902 1999-04-06  Jim Meyering  <meyering@ascend.com>
24903
24904         * m4/strftime.m4: Remove test for %f.
24905
24906 1999-03-29  Jim Meyering  <meyering@ascend.com>
24907
24908         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
24909         superset of the AC_TYPE_* checks in the textutils, fileutils,
24910         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
24911         AC_TYPE_PID_T.
24912
24913 1999-03-28  Jim Meyering  <meyering@ascend.com>
24914
24915         * m4/jm-macros.m4: Define GNU_PACKAGE here.
24916         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
24917         replaced e.g., in the *.sh files of the sh-utils.
24918
24919 1999-03-20  Jim Meyering  <meyering@ascend.com>
24920
24921         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
24922         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
24923         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
24924
24925 1999-03-19  Jim Meyering  <meyering@ascend.com>
24926
24927         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
24928
24929 1999-03-12  Jim Meyering  <meyering@ascend.com>
24930
24931         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
24932
24933 1999-03-07  Jim Meyering  <meyering@ascend.com>
24934
24935         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
24936         declared.
24937
24938 1999-02-17  Jim Meyering  <meyering@ascend.com>
24939
24940         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
24941         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
24942
24943 1999-02-07  Jim Meyering  <meyering@ascend.com>
24944
24945         * m4/group-member.m4: New file -- extracted from sh-utils'
24946         configure.in.
24947
24948         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
24949         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
24950
24951 1999-02-06  Jim Meyering  <meyering@ascend.com>
24952
24953         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
24954         * m4/fnmatch.m4: Likewise.
24955         * m4/getgroups.m4: Likewise.
24956         * m4/lstat.m4: Likewise.
24957         * m4/malloc.m4: Likewise.
24958         * m4/putenv.m4: Likewise.
24959         * m4/realloc.m4: Likewise.
24960         * m4/regex.m4: Likewise.
24961         * m4/stat.m4: Likewise.
24962         * m4/strftime.m4: Likewise.
24963         Suggestion from Alain Magloire.
24964
24965         * m4/chown.m4: Use `.$ac_objext', not `.o'.
24966         * m4/fnmatch.m4: Likewise.
24967         * m4/getgroups.m4: Likewise.
24968         * m4/getline.m4: Likewise.
24969         * m4/lstat.m4: Likewise.
24970         * m4/malloc.m4: Likewise.
24971         * m4/memcmp.m4: Likewise.
24972         * m4/putenv.m4: Likewise.
24973         * m4/realloc.m4: Likewise.
24974         * m4/regex.m4: Likewise.
24975         * m4/stat.m4: Likewise.
24976         * m4/strftime.m4: Likewise.
24977         Suggestion from Alain Magloire.
24978
24979         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
24980         an argument.
24981
24982         * m4/regex.m4: Add a run-time Test for proper operation of
24983         re_compile_pattern.
24984
24985 1999-01-31  Jim Meyering  <meyering@ascend.com>
24986
24987         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
24988
24989 1999-01-30  Jim Meyering  <meyering@ascend.com>
24990
24991         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
24992
24993         * m4/jm-mktime.m4: Make this a wrapper around the official
24994         AM_FUNC_MKTIME rather than my private copy, now that the official one
24995         is up to date.
24996         * m4/mktime.m4: Remove file.
24997
24998         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
24999         * m4/uptime.m4: Likewise.
25000         * m4/uintmax_t.m4: Likewise.
25001
25002 1999-01-28  Jim Meyering  <meyering@ascend.com>
25003
25004         * m4/jm-macros.m4: Use jm_AFS.
25005         * m4/afs.m4: New file (from fileutils' configure.in).
25006
25007         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
25008         * m4/chown.m4: Likewise.
25009         * m4/d-ino.m4: Likewise.
25010         * m4/d-type.m4: Likewise.
25011         * m4/fnmatch.m4: Likewise.
25012         * m4/getgroups.m4: Likewise.
25013         * m4/gettext.m4: Likewise.
25014         * m4/jm-mktime.m4: Likewise.
25015         * m4/jm-winsz2.m4: Likewise.
25016         * m4/lcmessage.m4: Likewise.
25017         * m4/ls-mntd-fs.m4: Likewise.
25018         * m4/malloc.m4: Likewise.
25019         * m4/memcmp.m4: Likewise.
25020         * m4/putenv.m4: Likewise.
25021         * m4/realloc.m4: Likewise.
25022         * m4/st_mtim.m4: Likewise.
25023         * m4/strftime.m4: Likewise.
25024
25025 1999-01-16  Jim Meyering  <meyering@ascend.com>
25026
25027         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
25028         (ARGMATCH_DIE_DECL): Define.
25029
25030 1999-01-12  Jim Meyering  <meyering@ascend.com>
25031
25032         * m4/Makefile.am.in: Rewrite to avoid using fmt.
25033         Reported by Lars Hecking.
25034
25035 1999-01-10  Jim Meyering  <meyering@ascend.com>
25036
25037         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
25038         gross kludge.
25039         * m4/inttypes_h.m4: Likewise.
25040         * m4/lstat.m4: Likewise.
25041         * m4/malloc.m4: Likewise.
25042         * m4/readdir.m4: Likewise.
25043         * m4/realloc.m4: Likewise.
25044         * m4/st_dm_mode.m4: Likewise.
25045         * m4/stat.m4: Likewise.
25046         * m4/utimbuf.m4: Likewise.
25047         * m4/utimes.m4: Likewise.
25048
25049         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
25050         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
25051         comments in config.h.in are meaningful.
25052
25053         * m4/jm-macros.m4: Require autoconf-2.13 here.
25054
25055         * m4/regex.m4: By default, don't use the included regex.c on systems
25056         with glibc 2.  Suggestion from Uli Drepper.
25057
25058 1999-01-02  Jim Meyering  <meyering@ascend.com>
25059
25060         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
25061
25062 1998-12-18  Jim Meyering  <meyering@ascend.com>
25063
25064         * m4/Makefile.am.in (Makefile.am): Simplify rule.
25065         Based on a suggestion from Lars Hecking.
25066
25067 1998-11-16  Paul Eggert  <eggert@twinsun.com>
25068
25069         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
25070
25071 1998-11-16  Jim Meyering  <meyering@ascend.com>
25072
25073         * m4/lfs.m4: Double-quote the `uname...` expression.
25074
25075 1998-11-14  Jim Meyering  <meyering@ascend.com>
25076
25077         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
25078         * m4/stat.m4: Likewise.
25079
25080 1998-11-03  Jim Meyering  <meyering@ascend.com>
25081
25082         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
25083         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
25084
25085 1998-10-18  Jim Meyering  <meyering@ascend.com>
25086
25087         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
25088
25089 1998-10-17  Jim Meyering  <meyering@ascend.com>
25090
25091         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
25092         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
25093         calls for those previously hard-coded headers.  Instead, take a new
25094         parameter.
25095         (jm_CHECK_DECLARATIONS): Reflect interface change.
25096         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
25097         (jm_CHECK_DECL_LOCALTIME_R): New macro.
25098
25099         * m4/mktime.m4: Test for spring-forward gap before long-running test.
25100
25101 1998-10-14  Jim Meyering  <meyering@ascend.com>
25102
25103         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
25104         instead of "TZ=America/Vancouver".  From Paul Eggert.
25105
25106 1998-10-11  Jim Meyering  <meyering@ascend.com>
25107
25108         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
25109         This adds a test for a recently added compatibility fix for mktime.c.
25110         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
25111
25112 1998-09-27  Jim Meyering  <meyering@ascend.com>
25113
25114         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
25115
25116         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
25117         ../configure.in, including a change from Gordon Matzigkeit to allow
25118         cross-compiling for the Hurd.
25119
25120         * m4/glibc.m4: New file/macro to test for the GNU C Library
25121         versions 1 and 2.  From Gordon Matzigkeit.
25122         Indent.
25123
25124 1998-09-21  Jim Meyering  <meyering@ascend.com>
25125
25126         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
25127
25128 1998-08-18  Paul Eggert  <eggert@twinsun.com>
25129
25130         Port nanosecond-resolution times to UnixWare 2.1.2 and
25131         pedantic Solaris 2.6.
25132
25133         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
25134         AC_STRUCT_ST_MTIM.
25135         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
25136         Generate name of ns member, instead of just 1 or undef.
25137         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
25138
25139 1998-08-15  Jim Meyering  <meyering@ascend.com>
25140
25141         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
25142         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
25143         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
25144         instead of jm_TYPE_SSIZE_T.
25145
25146 1998-08-12  Jim Meyering  <meyering@ascend.com>
25147
25148         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
25149
25150 1998-08-02  Jim Meyering  <meyering@ascend.com>
25151
25152         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
25153         in acconfig.h manually.
25154
25155 1998-07-31  Paul Eggert  <eggert@twinsun.com>
25156
25157         * m4/st_mtim.m4: New file.
25158
25159 1998-07-28  Jim Meyering  <meyering@ascend.com>
25160
25161         * m4/utimes.m4: Undef stat.
25162
25163 1998-07-25  Jim Meyering  <meyering@ascend.com>
25164
25165         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
25166         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
25167
25168 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
25169
25170         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
25171         uid and gid actually remain unchanged.
25172
25173 1998-07-07  Jim Meyering  <meyering@ascend.com>
25174
25175         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
25176
25177 1998-07-04  Jim Meyering  <meyering@ascend.com>
25178
25179         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
25180         to prove that this macro can be used in packages without regex.c.
25181
25182 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
25183
25184         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
25185         is to be used.
25186
25187 1998-07-03  Jim Meyering  <meyering@ascend.com>
25188
25189         * m4/gettext.m4: Add -lintl if it's found to be necessary.
25190
25191         * m4/gettext.m4: New file -- from gettext-0.10.35.
25192         * m4/lcmessage.m4: Likewise.
25193         * m4/progtest.m4: Likewise.
25194
25195         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
25196         * m4/jm-macros.m4: Require the new macro.
25197
25198 1998-06-29  Jim Meyering  <meyering@ascend.com>
25199
25200         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
25201         for the definition of NGROUPS (used in a system header included
25202         by sys/mount.h).
25203
25204 1998-06-28  Jim Meyering  <meyering@ascend.com>
25205
25206         * m4/ls-mntd-fs.m4: New file.
25207         * m4/fstypename.m4: New file.
25208
25209         * m4/jm-macros.m4: Require the new macro.
25210         * m4/jm-glibc-io.m4: New file.
25211
25212 1998-05-19  Jim Meyering  <meyering@ascend.com>
25213
25214         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
25215         * m4/lchown.m4: New file.
25216
25217         * m4/Makefile.am.in: New file.
25218         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
25219
25220 1998-05-14  Jim Meyering  <meyering@ascend.com>
25221
25222         * m4/Makefile.am (EXTRA_DIST): Add them.
25223         * m4/jm-macros.m4: New file.
25224         * m4/utimbuf.m4: New file.
25225
25226 1998-05-12  Jim Meyering  <meyering@ascend.com>
25227
25228         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
25229
25230 1998-05-11  Jim Meyering  <meyering@ascend.com>
25231
25232         * m4/isc-posix.m4: New file.
25233
25234 1998-05-10  Jim Meyering  <meyering@ascend.com>
25235
25236         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
25237
25238 1998-05-09  Jim Meyering  <meyering@ascend.com>
25239
25240         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
25241         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
25242         with automake.
25243
25244         * m4/ssize_t.m4: New file.
25245         * m4/mktime.m4: Remove file -- the new automake has this now.
25246
25247 1998-04-26  Jim Meyering  <meyering@ascend.com>
25248
25249         * m4/assert.m4: New file.
25250         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
25251
25252 1998-04-05  Jim Meyering  <meyering@ascend.com>
25253
25254         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
25255         (jm_PREREQ): Use it here.
25256
25257 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
25258
25259         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
25260         in acconfig.h.
25261
25262 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
25263
25264         * m4/prereq.m4: New file.
25265         * m4/error.m4: New file.
25266         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
25267
25268 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
25269
25270         * m4/getline.m4: Don't set am_cv_func_working_getline before the
25271         cache-check for the same variable -- that defeated the purpose of
25272         the test; the test program was never run.  This was a problem only
25273         on systems with losing getline functions -- HP-UX 10.20 is one.
25274         Reported by Bjorn Helgaas.
25275
25276 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
25277
25278         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
25279
25280 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
25281
25282         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
25283
25284         * m4/const.m4: New file.  Use an initializer in this declaration
25285         typedef int charset[2]; const charset x;
25286         Reported by Bob Glickstein.
25287
25288 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
25289
25290         * m4/chown.m4: Fix reversed types on -1 args to chown.
25291         From Kaveh Ghazi.
25292
25293 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
25294
25295         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
25296         Add lseek and memchr.
25297
25298         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
25299         T.E.Dickey <dickey@clark.net> said that some older preprocessors
25300         have a 20-character limit on names.
25301
25302 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
25303
25304         * m4/inttypes_h.m4: New file.
25305         * m4/uintmax_t.m4: New file.
25306         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
25307
25308 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
25309   Free Software Foundation, Inc.
25310 Copying and distribution of this file, with or without modification,
25311 are permitted provided the copyright notice and this notice are preserved.