Align the temporary buffer.
[pspp] / ChangeLog
1 2007-01-10  Bruno Haible  <bruno@clisp.org>
2
3         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
4
5 2007-01-12  Eric Blake  <ebb9@byu.net>
6
7         Provide a robust <wchar.h>.  Further simplifications are now
8         possible in other modules, but not included here.
9         * modules/wchar: New module.
10         * m4/wchar.m4: New file.
11         * lib/wchar_.h: Likewise.
12         * modules/mbchar (Depends-on): Depend on wchar, as the first use
13         of the new module.
14         * MODULES.html.sh (Extended multibyte and wide character utilities):
15         New section.
16
17 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
18
19         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
20         to a reasonable default for memory allocation.
21         (xreadlink): Don't allocate a huge buffer, to work around a buggy
22         file system that reports garbage st_size values for symlinks.
23         Problem reported by Liyang Hu.
24
25 2007-01-11  Simon Josefsson  <simon@josefsson.org>
26
27         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
28         Emacs .#* auto-save files).
29
30 2007-01-11  Bruno Haible  <bruno@clisp.org>
31
32         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
33         directory.
34
35 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
36
37         Use @...@ consistently in lib/wctype_.h.
38         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
39         on it being set to 1 or 0.
40         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
41         go back to AC_SUBSTing it.
42         * modules/wctype (Makefile.am): Undo previous change.
43
44 2007-01-10  Eric Blake  <ebb9@byu.net>
45
46         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
47         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
48         * modules/wctype (Makefile.am): Likewise.
49         Reported by Chris McGuire.
50
51 2007-01-10  Jim Meyering  <jim@meyering.net>
52
53         fts.c: a small readability/maintainability improvement
54         * lib/fts.c (fts_read): Make this code slightly more readable and
55         maintainable by hoisting the "sp->fts_cur = p" assignments to
56         immediately follow the statements that set P.  Derived from
57         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
58
59 2007-01-10  Eric Blake  <ebb9@byu.net>
60
61         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
62         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
63         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
64         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
65         Reported by Chris McGuire.
66
67 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
68
69         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
70         in sed script.
71
72 2007-01-09  Bruno Haible  <bruno@clisp.org>
73
74         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
75         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
76         variables.
77         (func_module): Use them.
78
79 2007-01-09  Bruno Haible  <bruno@clisp.org>
80
81         * modules/unistr/base: New file.
82         * lib/unistr.h: New file.
83
84         * modules/unistr/u8-to-u16: New file.
85         * lib/unistr/u8-to-u16.c: New file.
86
87         * modules/unistr/u8-to-u32: New file.
88         * lib/unistr/u8-to-u32.c: New file.
89
90         * modules/unistr/u16-to-u8: New file.
91         * lib/unistr/u16-to-u8.c: New file.
92
93         * modules/unistr/u16-to-u32: New file.
94         * lib/unistr/u16-to-u32.c: New file.
95
96         * modules/unistr/u32-to-u8: New file.
97         * lib/unistr/u32-to-u8.c: New file.
98
99         * modules/unistr/u32-to-u16: New file.
100         * lib/unistr/u32-to-u16.c: New file.
101
102         * modules/unistr/u8-check: New file.
103         * modules/unistr/u16-check: New file.
104         * modules/unistr/u32-check: New file.
105         * lib/unistr/u8-check.c: New file.
106         * lib/unistr/u16-check.c: New file.
107         * lib/unistr/u32-check.c: New file.
108
109         * modules/unistr/u8-chr: New file.
110         * modules/unistr/u16-chr: New file.
111         * modules/unistr/u32-chr: New file.
112         * lib/unistr/u8-chr.c: New file.
113         * lib/unistr/u16-chr.c: New file.
114         * lib/unistr/u32-chr.c: New file.
115
116         * modules/unistr/u8-cmp: New file.
117         * modules/unistr/u16-cmp: New file.
118         * modules/unistr/u32-cmp: New file.
119         * lib/unistr/u8-cmp.c: New file.
120         * lib/unistr/u16-cmp.c: New file.
121         * lib/unistr/u32-cmp.c: New file.
122
123         * modules/unistr/u8-cpy: New file.
124         * modules/unistr/u16-cpy: New file.
125         * modules/unistr/u32-cpy: New file.
126         * lib/unistr/u8-cpy.c: New file.
127         * lib/unistr/u16-cpy.c: New file.
128         * lib/unistr/u32-cpy.c: New file.
129         * lib/unistr/u-cpy.h: New file.
130
131         * modules/unistr/u8-cpy-alloc: New file.
132         * modules/unistr/u16-cpy-alloc: New file.
133         * modules/unistr/u32-cpy-alloc: New file.
134         * lib/unistr/u8-cpy-alloc.c: New file.
135         * lib/unistr/u16-cpy-alloc.c: New file.
136         * lib/unistr/u32-cpy-alloc.c: New file.
137         * lib/unistr/u-cpy-alloc.h: New file.
138
139         * modules/unistr/u8-endswith: New file.
140         * modules/unistr/u16-endswith: New file.
141         * modules/unistr/u32-endswith: New file.
142         * lib/unistr/u8-endswith.c: New file.
143         * lib/unistr/u16-endswith.c: New file.
144         * lib/unistr/u32-endswith.c: New file.
145         * lib/unistr/u-endswith.h: New file.
146
147         * modules/unistr/u8-mblen: New file.
148         * modules/unistr/u16-mblen: New file.
149         * modules/unistr/u32-mblen: New file.
150         * lib/unistr/u8-mblen.c: New file.
151         * lib/unistr/u16-mblen.c: New file.
152         * lib/unistr/u32-mblen.c: New file.
153
154         * modules/unistr/u8-mbtouc: New file.
155         * modules/unistr/u16-mbtouc: New file.
156         * modules/unistr/u32-mbtouc: New file.
157         * lib/unistr/u8-mbtouc.c: New file.
158         * lib/unistr/u16-mbtouc.c: New file.
159         * lib/unistr/u32-mbtouc.c: New file.
160
161         * modules/unistr/u8-mbtouc-safe: New file.
162         * modules/unistr/u16-mbtouc-safe: New file.
163         * modules/unistr/u32-mbtouc-safe: New file.
164         * lib/unistr/u8-mbtouc-safe.c: New file.
165         * lib/unistr/u16-mbtouc-safe.c: New file.
166         * lib/unistr/u32-mbtouc-safe.c: New file.
167
168         * modules/unistr/u8-move: New file.
169         * modules/unistr/u16-move: New file.
170         * modules/unistr/u32-move: New file.
171         * lib/unistr/u8-move.c: New file.
172         * lib/unistr/u16-move.c: New file.
173         * lib/unistr/u32-move.c: New file.
174         * lib/unistr/u-move.h: New file.
175
176         * modules/unistr/u8-next: New file.
177         * modules/unistr/u16-next: New file.
178         * modules/unistr/u32-next: New file.
179         * lib/unistr/u8-next.c: New file.
180         * lib/unistr/u16-next.c: New file.
181         * lib/unistr/u32-next.c: New file.
182
183         * modules/unistr/u8-prev: New file.
184         * modules/unistr/u16-prev: New file.
185         * modules/unistr/u32-prev: New file.
186         * lib/unistr/u8-prev.c: New file.
187         * lib/unistr/u16-prev.c: New file.
188         * lib/unistr/u32-prev.c: New file.
189
190         * modules/unistr/u8-set: New file.
191         * modules/unistr/u16-set: New file.
192         * modules/unistr/u32-set: New file.
193         * lib/unistr/u8-set.c: New file.
194         * lib/unistr/u16-set.c: New file.
195         * lib/unistr/u32-set.c: New file.
196         * lib/unistr/u-set.h: New file.
197
198         * modules/unistr/u8-startswith: New file.
199         * modules/unistr/u16-startswith: New file.
200         * modules/unistr/u32-startswith: New file.
201         * lib/unistr/u8-startswith.c: New file.
202         * lib/unistr/u16-startswith.c: New file.
203         * lib/unistr/u32-startswith.c: New file.
204         * lib/unistr/u-startswith.h: New file.
205
206         * modules/unistr/u8-stpcpy: New file.
207         * modules/unistr/u16-stpcpy: New file.
208         * modules/unistr/u32-stpcpy: New file.
209         * lib/unistr/u8-stpcpy.c: New file.
210         * lib/unistr/u16-stpcpy.c: New file.
211         * lib/unistr/u32-stpcpy.c: New file.
212         * lib/unistr/u-stpcpy.h: New file.
213
214         * modules/unistr/u8-stpncpy: New file.
215         * modules/unistr/u16-stpncpy: New file.
216         * modules/unistr/u32-stpncpy: New file.
217         * lib/unistr/u8-stpncpy.c: New file.
218         * lib/unistr/u16-stpncpy.c: New file.
219         * lib/unistr/u32-stpncpy.c: New file.
220         * lib/unistr/u-stpncpy.h: New file.
221
222         * modules/unistr/u8-strcat: New file.
223         * modules/unistr/u16-strcat: New file.
224         * modules/unistr/u32-strcat: New file.
225         * lib/unistr/u8-strcat.c: New file.
226         * lib/unistr/u16-strcat.c: New file.
227         * lib/unistr/u32-strcat.c: New file.
228         * lib/unistr/u-strcat.h: New file.
229
230         * modules/unistr/u8-strchr: New file.
231         * modules/unistr/u16-strchr: New file.
232         * modules/unistr/u32-strchr: New file.
233         * lib/unistr/u8-strchr.c: New file.
234         * lib/unistr/u16-strchr.c: New file.
235         * lib/unistr/u32-strchr.c: New file.
236
237         * modules/unistr/u8-strcmp: New file.
238         * modules/unistr/u16-strcmp: New file.
239         * modules/unistr/u32-strcmp: New file.
240         * lib/unistr/u8-strcmp.c: New file.
241         * lib/unistr/u16-strcmp.c: New file.
242         * lib/unistr/u32-strcmp.c: New file.
243
244         * modules/unistr/u8-strcpy: New file.
245         * modules/unistr/u16-strcpy: New file.
246         * modules/unistr/u32-strcpy: New file.
247         * lib/unistr/u8-strcpy.c: New file.
248         * lib/unistr/u16-strcpy.c: New file.
249         * lib/unistr/u32-strcpy.c: New file.
250         * lib/unistr/u-strcpy.h: New file.
251
252         * modules/unistr/u8-strcspn: New file.
253         * modules/unistr/u16-strcspn: New file.
254         * modules/unistr/u32-strcspn: New file.
255         * lib/unistr/u8-strcspn.c: New file.
256         * lib/unistr/u16-strcspn.c: New file.
257         * lib/unistr/u32-strcspn.c: New file.
258         * lib/unistr/u-strcspn.h: New file.
259
260         * modules/unistr/u8-strdup: New file.
261         * modules/unistr/u16-strdup: New file.
262         * modules/unistr/u32-strdup: New file.
263         * lib/unistr/u8-strdup.c: New file.
264         * lib/unistr/u16-strdup.c: New file.
265         * lib/unistr/u32-strdup.c: New file.
266         * lib/unistr/u-strdup.h: New file.
267
268         * modules/unistr/u8-strlen: New file.
269         * modules/unistr/u16-strlen: New file.
270         * modules/unistr/u32-strlen: New file.
271         * lib/unistr/u8-strlen.c: New file.
272         * lib/unistr/u16-strlen.c: New file.
273         * lib/unistr/u32-strlen.c: New file.
274         * lib/unistr/u-strlen.h: New file.
275
276         * modules/unistr/u8-strmblen: New file.
277         * modules/unistr/u16-strmblen: New file.
278         * modules/unistr/u32-strmblen: New file.
279         * lib/unistr/u8-strmblen.c: New file.
280         * lib/unistr/u16-strmblen.c: New file.
281         * lib/unistr/u32-strmblen.c: New file.
282
283         * modules/unistr/u8-strmbtouc: New file.
284         * modules/unistr/u16-strmbtouc: New file.
285         * modules/unistr/u32-strmbtouc: New file.
286         * lib/unistr/u8-strmbtouc.c: New file.
287         * lib/unistr/u16-strmbtouc.c: New file.
288         * lib/unistr/u32-strmbtouc.c: New file.
289
290         * modules/unistr/u8-strncat: New file.
291         * modules/unistr/u16-strncat: New file.
292         * modules/unistr/u32-strncat: New file.
293         * lib/unistr/u8-strncat.c: New file.
294         * lib/unistr/u16-strncat.c: New file.
295         * lib/unistr/u32-strncat.c: New file.
296         * lib/unistr/u-strncat.h: New file.
297
298         * modules/unistr/u8-strncmp: New file.
299         * modules/unistr/u16-strncmp: New file.
300         * modules/unistr/u32-strncmp: New file.
301         * lib/unistr/u8-strncmp.c: New file.
302         * lib/unistr/u16-strncmp.c: New file.
303         * lib/unistr/u32-strncmp.c: New file.
304
305         * modules/unistr/u8-strncpy: New file.
306         * modules/unistr/u16-strncpy: New file.
307         * modules/unistr/u32-strncpy: New file.
308         * lib/unistr/u8-strncpy.c: New file.
309         * lib/unistr/u16-strncpy.c: New file.
310         * lib/unistr/u32-strncpy.c: New file.
311         * lib/unistr/u-strncpy.h: New file.
312
313         * modules/unistr/u8-strnlen: New file.
314         * modules/unistr/u16-strnlen: New file.
315         * modules/unistr/u32-strnlen: New file.
316         * lib/unistr/u8-strnlen.c: New file.
317         * lib/unistr/u16-strnlen.c: New file.
318         * lib/unistr/u32-strnlen.c: New file.
319         * lib/unistr/u-strnlen.h: New file.
320
321         * modules/unistr/u8-strpbrk: New file.
322         * modules/unistr/u16-strpbrk: New file.
323         * modules/unistr/u32-strpbrk: New file.
324         * lib/unistr/u8-strpbrk.c: New file.
325         * lib/unistr/u16-strpbrk.c: New file.
326         * lib/unistr/u32-strpbrk.c: New file.
327         * lib/unistr/u-strpbrk.h: New file.
328
329         * modules/unistr/u8-strrchr: New file.
330         * modules/unistr/u16-strrchr: New file.
331         * modules/unistr/u32-strrchr: New file.
332         * lib/unistr/u8-strrchr.c: New file.
333         * lib/unistr/u16-strrchr.c: New file.
334         * lib/unistr/u32-strrchr.c: New file.
335
336         * modules/unistr/u8-strspn: New file.
337         * modules/unistr/u16-strspn: New file.
338         * modules/unistr/u32-strspn: New file.
339         * lib/unistr/u8-strspn.c: New file.
340         * lib/unistr/u16-strspn.c: New file.
341         * lib/unistr/u32-strspn.c: New file.
342         * lib/unistr/u-strspn.h: New file.
343
344         * modules/unistr/u8-strstr: New file.
345         * modules/unistr/u16-strstr: New file.
346         * modules/unistr/u32-strstr: New file.
347         * lib/unistr/u8-strstr.c: New file.
348         * lib/unistr/u16-strstr.c: New file.
349         * lib/unistr/u32-strstr.c: New file.
350         * lib/unistr/u-strstr.h: New file.
351
352         * modules/unistr/u8-strtok: New file.
353         * modules/unistr/u16-strtok: New file.
354         * modules/unistr/u32-strtok: New file.
355         * lib/unistr/u8-strtok.c: New file.
356         * lib/unistr/u16-strtok.c: New file.
357         * lib/unistr/u32-strtok.c: New file.
358         * lib/unistr/u-strtok.h: New file.
359
360         * modules/unistr/u8-uctomb: New file.
361         * modules/unistr/u16-uctomb: New file.
362         * modules/unistr/u32-uctomb: New file.
363         * lib/unistr/u8-uctomb.c: New file.
364         * lib/unistr/u16-uctomb.c: New file.
365         * lib/unistr/u32-uctomb.c: New file.
366
367         * MODULES.html.sh (Unicode string functions): Add the new modules.
368
369 2007-01-08  Bruno Haible  <bruno@clisp.org>
370
371         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
372         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
373         subdirectories.
374
375 2007-01-08  Karl Berry  <karl@gnu.org>
376
377         * doc/error.texi: mention that main() fns must set program_name
378         when progname is used.
379
380 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
381
382         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
383         WCTYPE_H is empty, for the benefit of builds from non-distclean
384         directories.  Problem reported by Eric Blake in
385         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
386
387 2007-01-08  Bruno Haible  <bruno@clisp.org>
388
389         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
390         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
391         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
392         PROVIDE_CANONICALIZE_FILENAME_MODE.
393         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
394
395 2007-01-08  Bruno Haible  <bruno@clisp.org>
396
397         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
398         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
399         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
400         * lib/fts.c: Likewise.
401         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
402
403 2006-12-25  Bruno Haible  <bruno@clisp.org>
404
405         * modules/utf8-ucs4-safe: New file.
406         * lib/utf8-ucs4-safe.h: New file.
407         * lib/unistr/utf8-ucs4-safe.c: New file.
408
409         * modules/utf16-ucs4-safe: New file.
410         * lib/utf16-ucs4-safe.h: New file.
411         * lib/unistr/utf16-ucs4-safe.c: New file.
412
413         * MODULES.html.sh (Unicode string functions): Add the new modules.
414
415 2007-01-08  Bruno Haible  <bruno@clisp.org>
416
417         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
418         (Depends-on): Add unitypes.
419         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
420         (u8_mbtouc_aux): Move out to separate file.
421         (u8_mbtouc): Use ucs4_t, uint8_t types.
422         * lib/unistr/utf8-ucs4.c: New file.
423
424         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
425         (Depends-on): Add unitypes.
426         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
427         (u16_mbtouc_aux): Move out to separate file.
428         (u16_mbtouc): Use ucs4_t, uint16_t types.
429         * lib/unistr/utf16-ucs4.c: New file.
430
431         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
432         (Depends-on): Add unitypes.
433         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
434         (u8_uctomb_aux): Move out to separate file.
435         (u8_uctomb): Use ucs4_t, uint8_t types.
436         * lib/unistr/ucs4-utf8.c: New file.
437
438         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
439         (Depends-on): Add unitypes.
440         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
441         (u16_uctomb_aux): Move out to separate file.
442         (u16_uctomb): Use ucs4_t, uint16_t types.
443         * lib/unistr/ucs4-utf16.c: New file.
444
445 2006-12-25  Bruno Haible  <bruno@clisp.org>
446
447         * modules/unitypes: New file.
448         * lib/unitypes.h: New file.
449         * MODULES.html.sh (func_all_modules): New section "Unicode string
450         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
451         this section. Add unitypes.
452
453 2007-01-08  Bruno Haible  <bruno@clisp.org>
454
455         Avoid variable names that conflict with those from libtool.
456         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
457         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
458         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
459         library_names_spec to acl_library_names_spec, hardcode_* to
460         acl_hardcode_*.
461         Reported by Ralf Wildenhues.
462
463 2007-01-08  Bruno Haible  <bruno@clisp.org>
464
465         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
466         definition.
467         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
468         definition.
469         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
470         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
471         definition.
472         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
473         definition.
474         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
475         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
476         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
477         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
478         definition.
479         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
480         definition.
481         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
482         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
483         GC_USE_<algorithm>.
484         * lib/gc-libgcrypt.c: Likewise.
485         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
486         * modules/gc-arctwo (configure.ac): Likewise.
487         * modules/gc-des (configure.ac): Likewise.
488         * modules/gc-hmac-md5 (configure.ac): Likewise.
489         * modules/gc-hmac-sha1 (configure.ac): Likewise.
490         * modules/gc-md2 (configure.ac): Likewise.
491         * modules/gc-md4 (configure.ac): Likewise.
492         * modules/gc-md5 (configure.ac): Likewise.
493         * modules/gc-random (configure.ac): Likewise.
494         * modules/gc-rijndael (configure.ac): Likewise.
495         * modules/gc-sha1 (configure.ac): Likewise.
496
497 2007-01-08  Bruno Haible  <bruno@clisp.org>
498
499         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
500         macro definition.
501         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
502         definition.
503         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
504         definition.
505         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
506         * modules/fcntl-safer (configure.ac): Likewise.
507         * modules/fopen-safer (configure.ac): Likewise.
508         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
509         GNULIB_FWRITEERROR macro definition.
510
511 2007-01-08  Bruno Haible  <bruno@clisp.org>
512
513         * m4/gnulib-common.m4: New file.
514         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
515         (func_get_filelist): Add m4/gnulib-common.m4.
516
517 2007-01-08  Bruno Haible  <bruno@clisp.org>
518
519         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
520         command.
521
522 2007-01-08  Jim Meyering  <jim@meyering.net>
523
524         Use a more robust test for a "can't happen" condition.
525         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
526         narrowed the st_size value.  Presuming the "can't happen" condition
527         is true, that narrowing could conceivably convert an invalid st_size
528         value into a valid one.  Instead, use a change based on Matthew
529         Woehlke's original patch.
530
531         Slight readability improvement: use an assert-like macro
532         in place of literal "abort ()" uses.
533         * lib/fts.c (fts_assert): Define.
534         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
535         Use this macro instead of a bare 'abort'.
536
537 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
538
539         Don't worry about using IRIX 5.3's wctype.h broken definitions;
540         simply work around them.
541         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
542         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
543         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
544         Don't bother to define as macros, since the standard doesn't require it.
545         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
546         longer worry about IRIX 5.3.
547         (HAVE_WCTYPE_CTMP_BUG): Remove.
548
549 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
550
551         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
552         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
553         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
554         Problems reported by Georg Schwarz for IRIX 5.3.
555
556         * gnulib-tool (autoconf_minversion): Take the maximum version number
557         found, not the minimum.  Problem reported by James Youngman.
558
559 2007-01-03  Karl Berry  <karl@gnu.org>
560
561         * doc/error.texi: new file, explaining interaction with progname.
562         * doc/gnulib.texi: include it.  Update copyright.
563
564 2007-01-03  Simon Josefsson  <simon@josefsson.org>
565
566         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
567         AC_CANONICAL_HOST, to improve autobuild outputs.
568
569 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
570             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
571
572         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
573         sockets, server sockets, and other file descriptors.  Count errors
574         to compute the return value.  Reorder the code a bit to be easier
575         to follow.  Don't set event bits that were not requested (except
576         POLLERR and POLLHUP).
577
578 2007-01-01  Bruno Haible  <bruno@clisp.org>
579
580         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
581
582 2007-01-03  Jim Meyering  <jim@meyering.net>
583
584         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
585
586 2007-01-02  Bruno Haible  <bruno@clisp.org>
587
588         * modules/settime (Include): Require timespec.h.
589         * modules/nanosleep (Include): Likewise.
590
591 2007-01-01  Bruno Haible  <bruno@clisp.org>
592
593         * gnulib-tool (func_emit_copyright_notice): Bump year.
594         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
595
596 2007-01-01  Bruno Haible  <bruno@clisp.org>
597
598         Improve support for OpenBSD.
599         * build-aux/config.rpath (libname_spec): Export.
600         (library_names_spec): New variable. Export.
601         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
602         library_names_spec from the config.rpath output. Locate shared library
603         through the name pattern in library_names_spec.
604
605 2007-01-01  Eric Blake  <ebb9@byu.net>
606
607         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
608
609 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
610
611         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
612         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
613         assume the C locale, and avoid an "eval" that could cause trouble.
614         Problem with SORT reported by Bob Proulx.
615
616         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
617         Define.  Trivial patch from Henning Nielsen Lund, originally
618         sent to bug-grep@gnu.org today.
619
620 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
621
622         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
623         struct stat.  Problem reported by Henning Nielsen Lund.
624         * lib/acl.c: Include acl.h first, to check interface.  Don't
625         bother to include sys/types.h and sys/stat.h again.
626
627 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
628
629         Import the following change from libc; problem reported by
630         Sven Verdoolaege.
631
632         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
633
634         [BZ #1373]
635         * lib/argp.h: Remove __NTH for __argp_usage inline function.
636
637 2006-12-28  Jim Meyering  <jim@meyering.net>
638
639         * build-aux/announce-gen: Do not assume that the package
640         builds any of tar.gz, tar.bz2, and .xdelta files.
641         Suggestion from Simon Josefsson.
642
643 2006-12-28  Simon Josefsson  <simon@josefsson.org>
644
645         * modules/announce-gen: New file.
646
647 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
648
649         * lib/mbchar.h: Just include <wctype.h>; the wctype module
650         handles its gotchas now.
651         * lib/mbswidth.c: Likewise.
652         * lib/wcwidth.h: Likewise.
653         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
654         and iswcntrl; the wctype module does this stuff now.
655         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
656         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
657         * modules/mbchar (Depends-on): Add wctype.
658         * modules/mbswidth (Depends-on): Likewise.
659         * modules/wcwidth (Depends-on): Likewise.
660
661 2006-12-27  Eric Blake  <ebb9@byu.net>
662
663         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
664         module uses more than what <wctype.h> is required to provide.
665
666 2006-12-26  Eric Blake  <ebb9@byu.net>
667
668         * gnulib-tool (sed_extract_prog): Avoid space-tab.
669
670 2006-12-26  Eric Blake  <ebb9@byu.net>
671
672         * modules/absolute-header: New module.
673         * modules/fcntl (Depends-on): Depend on it.
674         * modules/inttypes (Depends-on): Likewise.
675         * modules/stdint (Depends-on): Likewise.
676         * modules/sys_stat (Depends-on): Likewise.
677         * modules/wctype (Depends-on): Likewise.
678         * MODULES.html.sh (Support for building libraries and
679         executables): Document it.
680
681 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
682
683         * gnulib-tool (SED): Remove, undoing previous change.
684         The problem was that it broke coreutils on Solaris, because
685         "sed --posix" leaked into a makefile.
686         (sed): New alias, if 'alias' and GNU sed.
687
688 2006-12-24  Jim Meyering  <jim@meyering.net>
689
690         Work around an fchownat bug in glibc-2.4:
691         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
692         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
693         in spite of the -P option.
694         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
695         New macros.
696         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
697         * modules/openat (Files): Add lib/fchownat.c.
698         * lib/openat.c (fchownat): Don't define here.  Move to...
699         * lib/fchownat.c: ...this new file.
700
701 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
702
703         Fix bug reported by Bruno Haible in
704         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
705         where quotearg.c didn't compile on Mac OS X 10.2 because it
706         lacks <wchar.h> and wint_t.
707         * lib/wctype_.h (__wctype_wint_t): New type.
708         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
709         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
710         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
711         Arg is now of type __wctype_wint_t, not wint_t.
712         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
713         substitute HAVE_WINT_T.
714         * modules/wctype (Files): Add m4/wint_t.m4.
715         (wctype.h): Substitute HAVE_WINT_T.
716
717 2006-12-23  Bruno Haible  <bruno@clisp.org>
718
719         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
720
721 2006-12-23  Bruno Haible  <bruno@clisp.org>
722
723         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
724         S_ISLNK.
725         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
726         mingw.
727
728 2006-12-22  Bruno Haible  <bruno@clisp.org>
729
730         * lib/copy-file.c: Include acl.h.
731         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
732         Close the file descriptors only after being done with copy_acl.
733         * modules/copy-file (Depends-on): Add acl.
734
735 2006-12-22  Bruno Haible  <bruno@clisp.org>
736
737         * gnulib-tool (SED): New variable.
738         Use $SED instead of sed everywhere.
739
740 2006-12-22  Bruno Haible  <bruno@clisp.org>
741
742         * modules/no-c++: New file.
743         * m4/no-c++.m4: New file.
744         * MODULES.html.sh (Support for building libraries and executables):
745         Add no-c++.
746
747 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
748
749         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
750         Include <limits.h>, and use its INT_MAX to rewrite the
751         j loop so that it does not overflow 'int'.  Problem reported by
752         Ralf Wildenhues in
753         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
754         Play it safe by shifting left by 1 rather than multiplying by 2,
755         as GCC is less likely to optimize this away when the value
756         is signed (when it assumes overflow leads to undefined behavior).
757         Also, don't assume time_t uses two's complement.
758
759 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
760
761         * MODULES.html.sh: New module wctype.
762         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
763         * lib/fnmatch.c: Don't bother to include <wchar.h> before
764         <wctype.h>, since the new wctype module should fix this.
765         * lib/quotearg.c: Include <wctype.h> unconditionally, since
766         the wctype module should arrange for it.
767         * lib/regex_internal.h: Likewise.
768         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
769         since the wctype module should handle this now.
770         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
771         * modules/fnmatch (Depends-on): Add wctype.
772         * modules/quotearg (Depends-on): Likewise.
773         * modules/regex (Depends-on): Likewise.
774
775 2006-12-19  Bruno Haible  <bruno@clisp.org>
776
777         * lib/strdup.h [C++]: Wrap definitions in extern "C".
778         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
779
780 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
781
782         * modules/savewd (Depends-on): Fix dependency on fcntl.
783
784 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
785
786         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
787         conforms to C99, rather than relying on the user's environment
788         setting of STDINT_H.
789
790 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
791         and Eric Blake  <ebb9@byu.net>
792
793         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
794         This is more consistent with the other defines here.
795         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
796         Port to z/OS.  Problem reported by Paul Gilmartin.
797         Change local vars to use gl_ prefix rather than ac_.
798         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
799         with other defines.
800         * modules/double-slash-root: New module.
801         * modules/dirname (Files): Remove m4/double-slash-root.m4.
802         (Depends-on): Add double-slash-root.
803         * MODULES.html.sh (File system functions): Mention new module.
804
805 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
806
807         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
808         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
809         This is for the benefit of gzip, which doesn't do i18n.
810
811 2006-12-12  Jim Meyering  <jim@meyering.net>
812
813         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
814         Reported by Andreas Schwab <schwab@suse.de>.
815
816 2006-12-12  Bruno Haible  <bruno@clisp.org>
817
818         Merge these changes.
819         2006-09-05  Bruno Haible  <bruno@clisp.org>
820         * lib/iconvme.c (iconv_string): No need to save and restore errno when
821         iconv_alloc succeeded.
822         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
823         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
824         test for " && dest " at the end - dest is always != NULL there. Call
825         iconv with 4xNULL arguments initially, to reset the state. Call iconv
826         with 2xNULL arguments, also to flush the state storage. Handle the
827         IRIX iconv behaviour. Realloc the final result, to throw away unused
828         memory.
829
830 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
831
832         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
833         and fchmodat unconditionally, since glibc 2.4 has them.
834         Problem reported by Arkadiusz Miskiewicz.
835
836 2006-12-10  Bruno Haible  <bruno@clisp.org>
837
838         * gnulib-tool (func_import): Show the include files only for those
839         modules that are copied and specified.
840         Reported by Karl Berry.
841
842 2006-12-08  Jim Meyering  <jim@meyering.net>
843
844         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
845         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
846
847         * build-aux/announce-gen: Add two new options, both optional:
848         --bootstrap-tools=TOOL_LIST
849               a comma-separated list of tools, e.g.,
850               autoconf,automake,bison,gnulib
851         --gnulib-snapshot-date=DATE
852               if gnulib is in the bootstrap tool list,
853               then report this as the snapshot date.
854               If not specified, use the current date/time.
855               If you specify a date here, be sure it's UTC.
856
857 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
858
859         * tests/test-argp-2.sh: Fix test to match actual output.
860         (func_compare): Fix sed script to be portable.
861
862 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
863
864         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
865         workaround for this case.  It is not autoconfigured now; offhand
866         it's hard to see how to autoconfigure it.
867
868 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
869
870         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
871         a directory that is about to be chowned.  Such a directory's
872         initial file permissions should permit the owner only and this
873         should not be changed until after the chown, since the group and
874         other bits would be incorrect if they granted permission before
875         the chown.
876
877         Fix porting problem for iswctype reported by Georg Schwarz in:
878         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
879         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
880         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
881         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
882         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
883
884 2006-12-03  Jim Meyering  <jim@meyering.net>
885
886         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
887         p->fts_statp may not yet be defined.
888         (fts_read): Instead, set it in the caller, once p->fts_statp is
889         sure to be defined, and corresponds to a top-level directory.
890         This bug made du -x fail.  Here's the coreutils test case:
891         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
892         Reported by Mike Frysinger.
893
894 2006-12-01  Jim Meyering  <jim@meyering.net>
895
896         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
897         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
898         Reported by Simon Josefsson.
899
900 2006-11-30  Jim Meyering  <jim@meyering.net>
901
902         * m4/warning.m4: Use the all-permissive copyright notice
903         recommended by RMS (rather than LGPL).
904         * m4/vararrays.m4: Likewise.
905         * m4/flexmember.m4: Likewise.
906
907 2006-11-29  Bruno Haible  <bruno@clisp.org>
908
909         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
910         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
911         using +=.
912         Reported by Simon Josefsson <simon@josefsson.org>.
913
914 2006-11-28  James Youngman <jay@gnu.org>
915
916         * README: Advise users that they might find the bug-gnulib@gnu.org
917         and autotools-announce@gnu.org mailing lists useful.
918
919 2006-11-28  Bruno Haible  <bruno@clisp.org>
920
921         * m4/ptrdiff_max.m4: Remove file.
922
923 2006-11-21  Bruno Haible  <bruno@clisp.org>
924
925         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
926         _AC_COMPUTE_INT.
927         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
928         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
929         _AC_COMPUTE_INT.
930         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
931         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
932         _AC_COMPUTE_INT.
933         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
934
935 2006-11-28  Jim Meyering  <jim@meyering.net>
936
937         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
938         warning from "gcc -Wshadow" about shadowing the builtin.
939
940 2006-11-27  Bruno Haible  <bruno@clisp.org>
941
942         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
943         _AC_COMPUTE_INT.
944         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
945
946 2006-11-27  Bruno Haible  <bruno@clisp.org>
947             Paul Eggert  <eggert@cs.ucla.edu>
948
949         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
950
951 2006-11-26  Bruno Haible  <bruno@clisp.org>
952
953         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
954         noinst_LTLIBRARIES.
955
956 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
957             Bruno Haible  <bruno@clisp.org>
958
959         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
960         if compiling with "gcc -ansi".
961
962 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
963
964         Fix some incompatibilities with gcc -ansi -pedantic.
965         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
966         if compiling pedantically with GCC, unless it's C99 or later.
967         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
968         it mishandles gcc -ansi -pedantic as well.
969         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
970         if gcc -pedantic.
971         * lib/regexec.c (check_node_accept_bytes): Don't use auto
972         initializers for struct if -pedantic, unless it's C99 or later.
973
974 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
975
976         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
977         Don't close an fd more than once. Identical atimes indicate
978         success, not failure.
979
980 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
981
982         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
983
984 2006-11-23  Jim Meyering  <jim@meyering.net>
985
986         * build-aux/announce-gen: New file.  From coreutils.
987
988 2006-11-22  Jim Meyering  <jim@meyering.net>
989
990         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
991         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
992         (fts_read): Use a temporary to narrow the overused st_size member
993         before using it in a switch statement.  Reported by Matthew Woehlke.
994
995         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
996         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
997
998 2006-11-20  Bruno Haible  <bruno@clisp.org>
999
1000         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
1001         changequote instead of pairs of brackets.
1002         Reported by Andreas Schwab <schwab@suse.de>.
1003
1004 2006-11-21  Jim Meyering  <jim@meyering.net>
1005
1006         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
1007         so as to remain compatible with older compilers.
1008         Patch from Michael Deutschmann.
1009
1010 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1011
1012         * MODULES.html.sh (File system functions): Add openat.
1013
1014         * lib/openat.h (rpl_fstatat): New macro, if
1015         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
1016         (fstatat): Define to rpl_fstatat under the same conditions,
1017         unless COMPILING_FSTATAT.
1018         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
1019         seems to have the bug.
1020         * lib/fstatat.c: New file.
1021         * modules/openat (Files): Add it.
1022
1023 2006-11-20  Bruno Haible  <bruno@clisp.org>
1024
1025         * Makefile: New file.
1026
1027 2006-11-20  Jim Meyering  <jim@meyering.net>
1028
1029         The beginnings of syntax-related checks for gnulib.
1030         * lib/Makefile: New file.
1031         * lib/t-idcache: New script.  Ensure that the two halves of
1032         idcache.c stay in sync.
1033
1034         * lib/idcache.c: Adjust comments in user- and group- portions to
1035         be more accurate, and to be consistent with one another.
1036
1037 2006-11-20  Jim Meyering  <jim@meyering.net>
1038
1039         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
1040         continue using the flexible array member (thus, this module performs
1041         half as many malloc calls), with the addition that...
1042         (getgroup, getuser): Consistently record a non-match via an empty
1043         "name" string, and map an empty string match to a NULL return value.
1044         * modules/idcache (Depends-on): Re-add flexmember.
1045
1046         * lib/idcache.c (getuser): Remove all uses of the register keyword.
1047         (getuidbyname, getgroup, getgidbyname): Likewise.
1048
1049         Use cleaner syntax: NULL rather than 0.
1050         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
1051
1052 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1053
1054         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
1055         It mishandled the case where the group was missing.
1056         Problem reported by Greg Schafer.
1057         * modules/idcache: Likewise.
1058
1059 2006-11-18  Jim Meyering  <jim@meyering.net>
1060
1061         * check-module (%exempt_header): Add exception for some
1062         conditionally-included headers.
1063
1064         * modules/i-ring (Depends-on): Add verify.
1065         (License): Change to LGPL.
1066
1067 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
1068
1069         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
1070         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
1071         and inttostr.h.  Use snprintf rather than uinttostr, so that
1072         LGPLed code doesn't depend on GPLed.
1073
1074 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
1075
1076         * modules/inline (License): Change from GPL to LGPL.
1077
1078 2006-11-17  Jim Meyering  <jim@meyering.net>
1079
1080         * modules/d-type (License): Switch to LGPL.
1081
1082 2006-11-15  Bruno Haible  <bruno@clisp.org>
1083
1084         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
1085
1086 2006-11-15  Eric Blake  <ebb9@byu.net>
1087
1088         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
1089         the module dependency.
1090
1091 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1092             Bruno Haible  <bruno@clisp.org>
1093
1094         * gnulib-tool (func_create_testdir): Add license consistency check.
1095
1096 2006-11-15  Eric Blake  <ebb9@byu.net>
1097
1098         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
1099         random "(cached)" in configure output.
1100
1101 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1102
1103         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
1104         test for conforming inttypes.h is both announced and cached.
1105
1106         * MODULES.html.sh (seen_modules, seen_files): New variables.
1107         (func_module): Rewrite to use a few less gnulib-tool and sed
1108         invocations.  Avoid a couple of quadratic algorithms for ...
1109         (missed_modules, missed_files): ... these, with ...
1110         (func_append, func_tmpdir): ... these new functions, from
1111         gnulib-tool.  Analogously, install traps for cleanup.
1112
1113         * tests/test-gc.c (main): Remove unused variables.
1114         * tests/test-read-file.c: Include stdlib.h, for 'free'.
1115
1116 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
1117
1118         * modules/inttostr (License): Change to LGPL.
1119
1120 2006-11-14  Eric Blake  <ebb9@byu.net>
1121
1122         * modules/tempname (License): Change to LGPL.
1123
1124 2006-11-14  Eric Blake  <ebb9@byu.net>
1125
1126         * doc/functions.texi (Function Portability): *printf functions on
1127         Cygwin now understand all POSIX size specifiers.
1128
1129 2006-11-14  Bruno Haible  <bruno@clisp.org>
1130
1131         * modules/c-ctype (License): Change to LGPL.
1132
1133 2006-11-12  Bruno Haible  <bruno@clisp.org>
1134
1135         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
1136         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
1137         for GNOME libraries, for which the include files are installed in
1138         subdirectories of $prefix/include.
1139
1140 2006-11-12  Bruno Haible  <bruno@clisp.org>
1141
1142         * m4/lib-link.m4: Require at least autoconf-2.54.
1143         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
1144         name to underscores for the --with option.
1145
1146 2006-11-13  Bruno Haible  <bruno@clisp.org>
1147
1148         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
1149         the tests directory.
1150         Reported by Ralf Wildenhues.
1151
1152 2006-11-13  Bruno Haible  <bruno@clisp.org>
1153
1154         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
1155         (func_emit_initmacro_end): Undo the override here.
1156         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
1157         Works around the famous automake error in coreutils.
1158
1159 2006-11-13  Eric Blake  <ebb9@byu.net>
1160
1161         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
1162         element, not its node.
1163
1164 2006-11-12  Bruno Haible  <bruno@clisp.org>
1165
1166         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
1167         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
1168
1169 2006-11-12  Bruno Haible  <bruno@clisp.org>
1170
1171         * gnulib-tool: New option --local-symlink.
1172         (func_usage): Document it.
1173         (lsymbolic): New variable.
1174         (func_import, func_create_testdir): If --symlink was not specified,
1175         test whether --local-symlink was specified and the file comes from
1176         the local_gnulib_dir.
1177
1178 2006-11-12  Bruno Haible  <bruno@clisp.org>
1179
1180         * gnulib-tool (func_ln): New function.
1181         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
1182
1183 2006-11-12  Bruno Haible  <bruno@clisp.org>
1184
1185         Finish support for source files in subdirectories.
1186         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
1187         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
1188         AUTOMAKE_OPTIONS.
1189         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
1190
1191 2006-11-12  Bruno Haible  <bruno@clisp.org>
1192
1193         * gnulib-tool (func_get_automake_snippet): Synthesize also an
1194         EXTRA_lib_SOURCES augmentation.
1195         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
1196
1197 2006-11-12  Jim Meyering  <jim@meyering.net>
1198
1199         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
1200         file descriptors.  This also averts a failure on systems with
1201         native openat support when a traversed directory lacks "x" access.
1202         * lib/fts_.h: Include "i-ring.h"
1203         (struct FTS) [fts_fd_ring]: New member.
1204         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
1205         (FCHDIR): Add parentheses.
1206         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
1207         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
1208         When descending, rather than simply closing the previous
1209         fts_cwd_fd value, push that file descriptor onto the ring.
1210         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
1211         (fts_open): Initialize the new fd_ring member.
1212         (fts_close): Clear the ring.
1213         (fts_safe_changedir): When possible, use our new fd_ring to skip
1214         the diropen and fstat and dev/ino comparison that would normally
1215         accompany a virtual `chdir ("..")'.
1216
1217         * modules/fts (Depends-on): Add i-ring.
1218         * modules/i-ring: New module.
1219         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
1220         * m4/i-ring.m4: New file.
1221
1222 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1223
1224         * gnulib-tool (func_create_testdir): Fix replacement of
1225         `build-aux' in configure.ac.  Run autotools in gltests
1226         subdirectory.
1227         (func_create_testdir, func_create_megatestdir, test): There is
1228         no need for '--force' in most autotool invocations in a new
1229         tree.  Actually fail the whole test if any of the tools, or the
1230         configure or make stages fail.
1231
1232         Sync from Automake.
1233         * build-aux/gnupload: Revert last change.  Add pointer to upload
1234         instructions of the GNU Maintenance Instructions.
1235         Suggestion by Karl Berry.
1236
1237 2006-11-10  Jim Meyering  <jim@meyering.net>
1238
1239         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
1240
1241 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1242
1243         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
1244         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
1245         (bind_textdomain_codeset) [! ENABLE_NLS]:
1246         Evaluate all the arguments.  That way, callers get compatible behavior
1247         if the arguments have side effects.  Also, it avoids some GCC
1248         diagnostics in some cases; Joel E. Denny reported problems when Bison
1249         was configured with --enable-gcc-warnigs.
1250
1251 2006-11-10  Jim Meyering  <jim@meyering.net>
1252
1253         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
1254         relevant options in CFLAGS (like -O, -fno-inline) are taken into
1255         account.
1256
1257 2006-11-10  Jim Meyering  <jim@meyering.net>
1258
1259         * modules/inline: New file/module.
1260         * modules/xalloc (Files): Remove m4/inline.m4.
1261         (Depends-on): Add inline, instead.
1262         * modules/oset: Likewise.
1263         * modules/list: Likewise.
1264
1265 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1266
1267         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
1268         Problem reported by Matthew Woehlke.
1269
1270 2006-11-09  Bruno Haible  <bruno@clisp.org>
1271
1272         * lib/tempname.c (gen_tempname): Remove variant that invokes
1273         __gen_tempname.
1274         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
1275         __gen_tempname.
1276
1277 2006-11-08  Bruno Haible  <bruno@clisp.org>
1278
1279         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
1280         to 'yes' instead of 'cross-compiling'.
1281
1282 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
1283
1284         * lib/quotearg.h (quotearg_free): New decl.
1285         * lib/quotearg.c (quotearg_free): New function.
1286         (slot0, nslots, slotvec0, slotvec):
1287         Now file-scope so that quotearg_free can get at them.
1288
1289 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1290
1291         Sync from Automake.
1292         * build-aux/gnupload: Add missing 'gnu' to example URL.
1293         Report by Karl Berry.
1294
1295 2006-11-08  Bruno Haible  <bruno@clisp.org>
1296
1297         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
1298         Suggested by Paul Eggert.
1299
1300 2006-11-08  Jim Meyering  <jim@meyering.net>
1301
1302         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
1303         It's already included if !_LIBC.
1304         (fts_safe_changedir): Add a comment.
1305
1306 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1307
1308         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
1309         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
1310         Matthew Woehlke.
1311
1312         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
1313         definitions up, to avoid colliding with change below.
1314         (static_inline) [HAVE_INLINE]: New macro.
1315         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
1316         Provide extern decls when !HAVE_INLINE.  Do not define unless
1317         static_inline is defined, either by us or by xmalloc.c.  Use
1318         static_inline rather than static inline.
1319         (XCALLOC): Optimize sizeof(T) = 1 case.
1320         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
1321
1322 2006-11-07  Bruno Haible  <bruno@clisp.org>
1323
1324         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
1325         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
1326         AC_C_INLINE.
1327         * modules/xalloc (Files): Add m4/inline.m4.
1328
1329 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1330
1331         * README: Fix typo.
1332         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
1333         (Miscellanous Notes): ...from this.
1334
1335 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1336
1337         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
1338         Mention that offsetof should be used instead of sizeof.
1339         From Bruno Haible.
1340
1341 2006-11-07  Bruno Haible  <bruno@clisp.org>
1342
1343         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
1344
1345 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1346
1347         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1348         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
1349         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1350         (gl_tree_add_before, gl_tree_add_after):
1351         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
1352         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
1353         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1354         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
1355         (gl_linked_add_after, gl_linked_add_at): Likewise.
1356         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
1357         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1358         (gl_tree_add_before, gl_tree_add_after): Likewise.
1359         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
1360         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
1361         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
1362
1363 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1364
1365         * lib/gl_oset.h: Use C comment style, not C++ comment style.
1366
1367 2006-11-06  Bruno Haible  <bruno@clisp.org>
1368
1369         * m4/inline.m4: New file.
1370         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
1371         * modules/list (Files): Add m4/inline.m4.
1372         * modules/oset (Files): Likewise.
1373
1374 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1375
1376         * lib/idcache.c: Include <stddef.h>, for offsetof.
1377         (struct userid.name): Change from char * to a flexible array member.
1378         All uses changed.
1379         * modules/idcache (Depends-on): Add flexmember.
1380
1381         * MODULES.html.sh (Core language properties): New module flexmember.
1382         * modules/flexmember, m4/flexmember.m4: New files.
1383
1384         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
1385         inline functions that are identical with the old xnmalloc_inline,
1386         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
1387         that we can avoid some unnecessary integer multiplications and
1388         divisions in the common case where the element size is known at
1389         compile time.
1390         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
1391         needed.
1392         (xnboundedmalloc): Remove.
1393         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
1394         arguments, for consistency with rest of this header.
1395         (xcharalloc): Rewrite using XNMALLOC.
1396         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
1397         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
1398         versions have been moved to lib/xalloc.h and renamed to be the
1399         non-*_inline versions.
1400         (xmalloc, xrealloc): Implement without reference to the xnmalloc
1401         and xnrealloc functions, since those functions are now inline and
1402         now call us.
1403         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
1404         renaming described above.
1405         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
1406         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
1407         captures the dependency in AC_C_INLINE.
1408
1409         New module canonicalize-lgpl, proposed by Charles Wilson in
1410         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
1411         with a few small changes afterwards.
1412         * MODULES.html.sh (File system functions): New module
1413         canonicalize-lgpl.
1414         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
1415         and canonicalize_file_name.
1416         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
1417         * modules/canonicalize-lgpl: New files.
1418
1419 2006-11-05  Bruno Haible  <bruno@clisp.org>
1420
1421         * gnulib-tool (func_import, func_create_testdir): Create directories
1422         also for files in subdirectories of lib/.
1423
1424 2006-11-05  Bruno Haible  <bruno@clisp.org>
1425
1426         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
1427         ANSI C compliant.
1428
1429 2006-11-03  Bruno Haible  <bruno@clisp.org>
1430
1431         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1432         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
1433         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
1434         (xnboundedmalloc): New inline function.
1435         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
1436         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
1437         xmalloc.
1438         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
1439         xmalloc.
1440         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
1441         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
1442         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
1443         xmalloc.
1444         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1445         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
1446         xmalloc.
1447         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
1448         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1449         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
1450         xmalloc.
1451         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1452         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
1453         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1454         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
1455         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
1456         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
1457         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
1458
1459 2006-11-03  Bruno Haible  <bruno@clisp.org>
1460
1461         * lib/c-ctype.h [C++]: Define functions without name mangling.
1462         * lib/fwriteerror.h [C++]: Likewise.
1463         * lib/gcd.h [C++]: Likewise.
1464         * lib/linebreak.h [C++]: Likewise.
1465
1466 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
1467
1468         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
1469         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
1470         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
1471         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1472         Check for functions and headers just once.
1473         Check for declaration of canonicalize_file_name.
1474         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
1475
1476 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1477
1478         * gnulib-tool (func_import): Fix typo in actioncmd.
1479
1480 2006-11-02  Bruno Haible  <bruno@clisp.org>
1481
1482         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
1483         newline sequence in the Makefile.am snippet as a space, like "make"
1484         does.
1485         Reported by Roger Persson <perrog@gmail.com>.
1486
1487 2006-11-01  Bruno Haible  <bruno@clisp.org>
1488
1489         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
1490         already declared in <string.h>.
1491         * lib/strcase.h (strncasecmp): Don't declare it if yes.
1492
1493 2006-11-01  Bruno Haible  <bruno@clisp.org>
1494
1495         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
1496         * lib/strcase.h: Include <string.h>.
1497         (strcasecmp): Define to rpl_strcasecmp here.
1498
1499 2006-11-01  Bruno Haible  <bruno@clisp.org>
1500
1501         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
1502
1503 2006-11-01  Eric Blake  <ebb9@byu.net>
1504
1505         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
1506
1507         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
1508
1509 2006-10-29  Bruno Haible  <bruno@clisp.org>
1510
1511         Make it compile in C++ mode.
1512         * lib/full-write.c (full_rw): Add a cast.
1513
1514 2006-11-01  Bruno Haible  <bruno@clisp.org>
1515
1516         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
1517         be POSIX compliant.
1518         Reported by Roger Persson <perrog@gmail.com>.
1519
1520 2006-11-01  Eric Blake  <ebb9@byu.net>
1521
1522         * lib/getopt_.h: Fix comments.
1523
1524 2006-10-31  Eric Blake  <ebb9@byu.net>
1525
1526         * modules/tmpdir (Depends-on): Add sys_stat.
1527         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
1528         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
1529         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
1530         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
1531         tempname.
1532
1533 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
1534
1535         Avoid some C++ diagnostics reported by Bruno Haible.
1536         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
1537         xmalloc.
1538         (quotearg_alloc): Use xcharalloc rather than xmalloc.
1539         (struct slotvec): Move to top level.
1540         (quotearg_n_options): Rewrite to avoid xmalloc.
1541         * lib/xalloc.h (xcharalloc): New function.
1542         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
1543         [defined __cplusplus]: Add function template that provides result
1544         type propagation.  This part of the change is from Bruno Haible.
1545
1546 2006-10-29  Bruno Haible  <bruno@clisp.org>
1547
1548         Make it compile in C++ mode.
1549         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
1550         * lib/strnlen1.c (strnlen1): Cast memchr result.
1551         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
1552         * lib/clean-temp.c (string_equals, string_hash): Add casts.
1553         (create_temp_dir): Rename local variable 'template'.
1554         (compile_csharp_using_sscli): Add cast.
1555         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
1556         * lib/findprog.c (find_in_path): Likewise.
1557         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
1558         * lib/wait-process.c (register_slave_subprocess): Likewise.
1559
1560 2006-10-22  Bruno Haible  <bruno@clisp.org>
1561
1562         * modules/tsearch: New file.
1563         * lib/tsearch.h: New file.
1564         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
1565         * m4/tsearch.m4: New file.
1566         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
1567
1568 2006-10-29  Eric Blake  <ebb9@byu.net>
1569
1570         * lib/arcfour.c: Assume config.h.
1571         * lib/arctwo.c: Likewise.
1572         * lib/base64.c: Likewise.
1573         * lib/check-version.c: Likewise.
1574         * lib/crc.c: Likewise.
1575         * lib/des.c: Likewise.
1576         * lib/gc-gnulib.c: Likewise.
1577         * lib/gc-libgcrypt.c: Likewise.
1578         * lib/gc-pbkdf2-sha1.c: Likewise.
1579         * lib/getaddrinfo.c: Likewise.
1580         * lib/getdelim.c: Likewise.
1581         * lib/getline.c: Likewise.
1582         * lib/hmac-md5.c: Likewise.
1583         * lib/hmac-sha1.c: Likewise.
1584         * lib/iconvme.c: Likewise.
1585         * lib/md2.c: Likewise.
1586         * lib/md4.c: Likewise.
1587         * lib/memxor.c: Likewise.
1588         * lib/read-file.c: Likewise.
1589         * lib/readline.c: Likewise.
1590         * lib/rijndael-alg-fst.c: Likewise.
1591         * lib/rijndael-api-fst.c: Likewise.
1592         * lib/xgetdomainname.c: Likewise.
1593
1594 2006-10-28  Eric Blake  <ebb9@byu.net>
1595
1596         * lib/xstrndup.c: Assume config.h.
1597
1598 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
1599
1600         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
1601         stat-macros.h is now for our own macros, whereas stat_h is for
1602         macros in the <sys/stat.h> name space.
1603         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
1604         (STAT_MACROS_H): Remove.
1605         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
1606         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
1607         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
1608         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
1609         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
1610         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
1611         Move these macros to ...
1612         * lib/stat_.h: here.  Don't include stat-macros.h.
1613         * lib/canonicalize.c: Don't include stat-macros.h.
1614         * lib/chown.c: Likewise.
1615         * lib/euidaccess.c: Likewise.
1616         * lib/file-type.c: Likewise.
1617         * lib/filemode.c: Likewise.
1618         * lib/glob.c: Likewise.
1619         * lib/isapipe.c: Likewise.
1620         * lib/lchown.c: Likewise.
1621         * lib/lstat.c: Likewise.
1622         * lib/mkdir-p.c: Likewise.
1623         * lib/rmdir.c: Likewise.
1624         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
1625         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
1626         unless mkdir isn't declared, to speed up 'configure'.
1627         Always create sys/stat.h, since it's unlikely any real sys/stat.h
1628         would define all the S_* symbols.
1629         * modules/canonicalize (Depends-on):
1630         Depend on sys_stat, not stat-macros.
1631         * modules/chown: Likewise.
1632         * modules/euidaccess: Likewise.
1633         * modules/filemode: Likewise.
1634         * modules/file-type: Likewise.
1635         * modules/glob: Likewise.
1636         * modules/isapipe: Likewise.
1637         * modules/lchown: Likewise.
1638         * modules/lstat: Likewise.
1639         * modules/mkancesdirs: Likewise.
1640         * modules/rmdir: Likewise.
1641         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
1642         * modules/modechange: Likewise.
1643         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
1644         (configure.ac): Remove gl_STAT_MACROS.
1645         * modules/sys_stat (Depends-on): Remove stat-macros.
1646
1647 2006-10-27  Bruno Haible  <bruno@clisp.org>
1648
1649         * m4/signed.m4: Remove file.
1650         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
1651         invocation.
1652         * modules/vasnprintf (Files): Remove m4/signed.m4.
1653
1654 2006-10-27  Bruno Haible  <bruno@clisp.org>
1655
1656         Update to GNU gettext 0.16.
1657         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
1658         m4/inttypes-h.m4, m4/signed.m4.
1659         * m4/gettext.m4: Update to GNU gettext 0.16.
1660         * m4/intl.m4: New file, from GNU gettext.
1661         * m4/intldir.m4: New file, from GNU gettext.
1662         * config/srclist.txt: Update
1663
1664 2006-10-27  Eric Blake  <ebb9@byu.net>
1665
1666         * MODULES.html.sh: Document tempname.
1667         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
1668         dependencies.
1669         (Files): Move lib/tempname.c...
1670         * modules/tempname: ...to this new module.
1671         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
1672         (gl_PREREQ_TEMPNAME): Move...
1673         * m4/tempname.m4: ...to this new file.
1674         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
1675         * modules/sys_stat (Depends-on): Add stat-macros.
1676         * lib/stat_.h (includes): Pick up stat macros.
1677         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
1678         if stat macros are broken.
1679         * lib/tempname.c (includes): No need to include "stat-macros.h".
1680         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
1681         (direxists, __path_search) [!_LIBC]: Don't compile these in
1682         gnulib; the tmpdir module covers that.
1683         * lib/tempname.h: New file.
1684
1685 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
1686
1687         * COPYING: Explain how gnulib-tool converts licence headers.
1688         Almost all wording by Eric Blake.
1689
1690 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
1691
1692         * lib/mbchar.h (is_basic_table): Make read-only.
1693         * lib/mbchar.c (is_basic_table): Likewise.
1694         Reported by John Darrington.
1695
1696 2006-10-25  Bruno Haible  <bruno@clisp.org>
1697
1698         * lib/progname.h (set_program_name): Undefine before defining.
1699
1700 2006-10-25  Bruno Haible  <bruno@clisp.org>
1701
1702         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
1703         false for non-gcc C++ compilers.
1704         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
1705
1706 2006-10-24  Bruno Haible  <bruno@clisp.org>
1707
1708         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
1709         iconv implementations like Irix iconv.
1710
1711 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1712
1713         * modules/vararrays: New file.
1714         * m4/vararrays.m4: New file, taken from diffutils.
1715         * MODULES.html.sh: New module vararrays.
1716
1717 2006-10-24  Karl Berry  <karl@gnu.org>
1718
1719         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
1720         Don't call GNU Unix.
1721
1722 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1723
1724         * users.txt: Add Libtool.
1725
1726         Sync from Libtool:
1727
1728         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1729
1730         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
1731         to gnulib's policy of including config.h unconditionally.
1732
1733 2006-10-24  Bruno Haible  <bruno@clisp.org>
1734
1735         * modules/wcwidth (Files): Add m4/wint_t.m4.
1736         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
1737         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
1738
1739 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1740
1741         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
1742         to pacify GCC with some -W flags enabled.  Problem reported by
1743         Bruno Haible.
1744
1745 2006-10-24  Jim Meyering  <jim@meyering.net>
1746
1747         * MODULES.html.sh: Remove uinttostr.  It's not a module.
1748         Reported by Karl Berry.
1749
1750 2006-10-23  Bruno Haible  <bruno@clisp.org>
1751
1752         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
1753
1754 2006-10-24  Bruno Haible  <bruno@clisp.org>
1755
1756         * lib/gl_list.h: Use C comment style, not C++ comment style.
1757
1758 2006-10-23  Eric Blake  <ebb9@byu.net>
1759
1760         * lib/getaddrinfo.c (includes): Add missing include.
1761
1762 2006-10-23  Bruno Haible  <bruno@clisp.org>
1763             Paul Eggert  <eggert@cs.ucla.edu>
1764
1765         Ability to rename obstack_free.
1766         * lib/obstack.h (__obstack_free): New macro. Declare instead of
1767         obstack_free.
1768         (obstack_free): Invoke the __obstack_free macro.
1769         * lib/obstack.c (obstack_free): Use __obstack_free macro.
1770
1771 2006-10-23  Bruno Haible  <bruno@clisp.org>
1772             Paul Eggert  <eggert@cs.ucla.edu>
1773
1774         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
1775         __argc, __argv from the declaration. (They are defined as macros on
1776         mingw.)
1777
1778 2006-10-22  Bruno Haible  <bruno@clisp.org>
1779
1780         * doc/gnulib-intro.texi: New file.
1781         * doc/gnulib.texi: Include it.
1782
1783 2006-10-21  Bruno Haible  <bruno@clisp.org>
1784
1785         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
1786         "Introduction", "Miscellanous Notes", "Particular Modules".
1787
1788 2006-10-21  Bruno Haible  <bruno@clisp.org>
1789
1790         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1791         Change mostlyclean-local rule to avoid sh syntax error from bash
1792         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
1793
1794 2006-10-23  Jim Meyering  <jim@meyering.net>
1795
1796         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
1797         in place of snprintf.
1798
1799         * modules/inttostr (Files): Add lib/uinttostr.c.
1800         * lib/uinttostr.c (inttostr): New file/function.
1801         * lib/inttostr.h (uinttostr): Declare.
1802         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
1803         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
1804         Add uinttostr.
1805         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
1806
1807 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1808
1809         * lib/canonicalize.c (ELOOP): Define if not already defined.
1810         Problem reported by Bruno Haible in
1811         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
1812
1813 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1814
1815         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
1816         Problem reported by Perry Smith and Ville Laurikari.
1817
1818         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
1819         uses.
1820
1821 2006-10-19  Bruno Haible  <bruno@clisp.org>
1822
1823         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
1824         for mingw.
1825
1826 2006-10-19  Bruno Haible  <bruno@clisp.org>
1827
1828         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
1829         Needed for mingw.
1830
1831 2006-10-19  Bruno Haible  <bruno@clisp.org>
1832
1833         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
1834
1835 2006-10-19  Bruno Haible  <bruno@clisp.org>
1836
1837         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
1838         it.
1839
1840 2006-10-19  Bruno Haible  <bruno@clisp.org>
1841
1842         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
1843         invocation.
1844
1845 2006-10-19  Bruno Haible  <bruno@clisp.org>
1846
1847         * gnulib-tool (func_create_testdir): Don't include ftruncate and
1848         mountlist by default.
1849
1850 2006-10-16  Bruno Haible  <bruno@clisp.org>
1851
1852         * lib/c-strstr.c: Include c-strstr.h.
1853
1854 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1855
1856         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
1857         in a slash.
1858
1859 2006-10-18  Bruno Haible  <bruno@clisp.org>
1860
1861         * lib/lock.h [C++]: Wrap definitions in extern "C".
1862
1863 2006-10-18  Bruno Haible  <bruno@clisp.org>
1864
1865         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
1866         gl_LIBOBJS list.
1867
1868 2006-10-18  Bruno Haible  <bruno@clisp.org>
1869
1870         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
1871
1872 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
1873
1874         * lib/xstrtol.h: Include gettext.h.
1875         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
1876         Problem reported by Eric Blake.
1877         * modules/xstrtol (Depends-on): Add gettext-h.
1878
1879 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
1880
1881         * lib/strftime.c (advance): New macro.
1882         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
1883         incomplete type, so you can't add 0 to it.  Problem and patch
1884         reported by Eelco Dolstra for dietlibc.
1885
1886 2006-10-18  Jim Meyering  <jim@meyering.net>
1887
1888         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
1889         type for a local, and rename it: s/up/user_proc/.
1890
1891 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
1892
1893         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
1894         READ_UTMP_USER_PROCESS.
1895         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
1896
1897 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
1898
1899         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
1900         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
1901
1902 2006-10-17  Eric Blake  <ebb9@byu.net>
1903
1904         * lib/sigprocmask.c (sigprocmask): Fix typo.
1905
1906         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
1907
1908         * modules/clean-temp (Makefile.am): Don't add to make output...
1909         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
1910         config.h.
1911
1912 2006-10-17  Bruno Haible  <bruno@clisp.org>
1913
1914         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
1915         differently if DEFAULT_TEXT_DOMAIN is set.
1916
1917 2006-10-16  Bruno Haible  <bruno@clisp.org>
1918
1919         * lib/clean-temp.c: Include fwriteerror.h.
1920
1921 2006-10-16  Bruno Haible  <bruno@clisp.org>
1922
1923         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
1924
1925 2006-10-16  Bruno Haible  <bruno@clisp.org>
1926
1927         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
1928         * lib/sigprocmask.h: Include <sys/types.h>.
1929         (sigset_t): Use the system's definition if present.
1930
1931 2006-10-17  Eric Blake  <ebb9@byu.net>
1932
1933         * lib/xvasprintf.c (includes): Assume config.h.
1934         * lib/xasprintf.c (includes): Likewise.
1935
1936 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
1937
1938         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
1939         at least as wide as intmax_t.
1940
1941 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
1942
1943         (Imported from Automake.)
1944         * build-aux/gnupload: Update to version 1.1 of directive file.
1945
1946 2006-10-16  Eric Blake  <ebb9@byu.net>
1947
1948         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
1949         match Automake 1.10a.
1950
1951 2006-10-14  Bruno Haible  <bruno@clisp.org>
1952
1953         * modules/sigprocmask: New file.
1954         * lib/sigprocmask.h: New file.
1955         * lib/sigprocmask.c: New file.
1956         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
1957         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
1958         request sigprocmask.o.
1959         (gl_PREREQ_SIGPROCMASK): New macro.
1960         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
1961         (Depends-on): Add sigprocmask.
1962         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
1963         gt_SIGNALBLOCKING. Test for 'raise' only once.
1964         * lib/fatal-signal.c: Include sigprocmask.h.
1965         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
1966         unblock_fatal_signals): Define always.
1967         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
1968         sigprocmask.
1969
1970 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
1971
1972         Sync from Automake.
1973         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
1974         which incorrectly sets the mode of an existing destination
1975         directory.  In some cases the unpatched install-sh could do the
1976         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
1977         system.  We hope this is rare in practice, but it's clearly worth
1978         fixing.  Problem reported by Alex Unleashed in
1979         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
1980         Also, don't bother to check for -m bugs unless we're using -m;
1981         suggested by Stepan Kasal.
1982
1983 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1984
1985         Sync from Automake.
1986         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
1987         `-c' flag, so they appear at the same position as in %FASTDEP%
1988         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
1989         which ignores unknown options only after the first non-option.
1990         Bug report against M4 by Nelson H. F. Beebe.
1991
1992 2006-10-13  Jim Meyering  <jim@meyering.net>
1993
1994         Fix a bug in yesterday's change.
1995         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
1996         p->fts_statp->st_dev would be used uninitialized.
1997         Ensures that we always call fts_stat on the very first entry.
1998         Miklos Szeredi reported that find -xdev stopped working.
1999
2000 2006-10-12  Bruno Haible  <bruno@clisp.org>
2001
2002         * gnulib-tool (func_get_automake_snippet): Append an automatically
2003         computed EXTRA_DIST augmentation.
2004         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
2005         * modules/alloca-opt (Makefile.am): Likewise.
2006         * modules/allocsa (Makefile.am): Likewise.
2007         * modules/arcfour (Makefile.am): Likewise.
2008         * modules/arctwo (Makefile.am): Likewise.
2009         * modules/argmatch (Makefile.am): Likewise.
2010         * modules/argz (Makefile.am): Likewise.
2011         * modules/atexit (Makefile.am): Likewise.
2012         * modules/backupfile (Makefile.am): Likewise.
2013         * modules/byteswap (Makefile.am): Likewise.
2014         * modules/c-strtod (Makefile.am): Likewise.
2015         * modules/c-strtold (Makefile.am): Likewise.
2016         * modules/calloc (Makefile.am): Likewise.
2017         * modules/canon-host (Makefile.am): Likewise.
2018         * modules/canonicalize (Makefile.am): Likewise.
2019         * modules/chdir-long (Makefile.am): Likewise.
2020         * modules/chdir-safer (Makefile.am): Likewise.
2021         * modules/check-version (Makefile.am): Likewise.
2022         * modules/chown (Makefile.am): Likewise.
2023         * modules/cloexec (Makefile.am): Likewise.
2024         * modules/close-stream (Makefile.am): Likewise.
2025         * modules/closeout (Makefile.am): Likewise.
2026         * modules/crc (Makefile.am): Likewise.
2027         * modules/csharpexec (Makefile.am): Likewise.
2028         * modules/cycle-check (Makefile.am): Likewise.
2029         * modules/des (Makefile.am): Likewise.
2030         * modules/dev-ino (Makefile.am): Likewise.
2031         * modules/dirfd (Makefile.am): Likewise.
2032         * modules/dirname (Makefile.am): Likewise.
2033         * modules/dup2 (Makefile.am): Likewise.
2034         * modules/eealloc (Makefile.am): Likewise.
2035         * modules/error (Makefile.am): Likewise.
2036         * modules/euidaccess (Makefile.am): Likewise.
2037         * modules/exclude (Makefile.am): Likewise.
2038         * modules/exitfail (Makefile.am): Likewise.
2039         * modules/fcntl-safer (Makefile.am): Likewise.
2040         * modules/fcntl (Makefile.am): Likewise.
2041         * modules/file-type (Makefile.am): Likewise.
2042         * modules/fileblocks (Makefile.am): Likewise.
2043         * modules/filemode (Makefile.am): Likewise.
2044         * modules/filenamecat (Makefile.am): Likewise.
2045         * modules/fnmatch (Makefile.am): Likewise.
2046         * modules/fopen-safer (Makefile.am): Likewise.
2047         * modules/fpending (Makefile.am): Likewise.
2048         * modules/fprintftime (Makefile.am): Likewise.
2049         * modules/free (Makefile.am): Likewise.
2050         * modules/fsusage (Makefile.am): Likewise.
2051         * modules/ftruncate (Makefile.am): Likewise.
2052         * modules/fts (Makefile.am): Likewise.
2053         * modules/gc-arcfour (Makefile.am): Likewise.
2054         * modules/gc-des (Makefile.am): Likewise.
2055         * modules/gc-hmac-md5 (Makefile.am): Likewise.
2056         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
2057         * modules/gc-md4 (Makefile.am): Likewise.
2058         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2059         * modules/gc-sha1 (Makefile.am): Likewise.
2060         * modules/gc (Makefile.am): Likewise.
2061         * modules/getaddrinfo (Makefile.am): Likewise.
2062         * modules/getcwd (Makefile.am): Likewise.
2063         * modules/getdelim (Makefile.am): Likewise.
2064         * modules/getdomainname (Makefile.am): Likewise.
2065         * modules/getgroups (Makefile.am): Likewise.
2066         * modules/gethostname (Makefile.am): Likewise.
2067         * modules/gethrxtime (Makefile.am): Likewise.
2068         * modules/getline (Makefile.am): Likewise.
2069         * modules/getloadavg (Makefile.am): Likewise.
2070         * modules/getlogin_r (Makefile.am): Likewise.
2071         * modules/getndelim2 (Makefile.am): Likewise.
2072         * modules/getopt (Makefile.am): Likewise.
2073         * modules/getpagesize (Makefile.am): Likewise.
2074         * modules/getpass-gnu (Makefile.am): Likewise.
2075         * modules/getpass (Makefile.am): Likewise.
2076         * modules/getsubopt (Makefile.am): Likewise.
2077         * modules/gettime (Makefile.am): Likewise.
2078         * modules/gettimeofday (Makefile.am): Likewise.
2079         * modules/getugroups (Makefile.am): Likewise.
2080         * modules/getusershell (Makefile.am): Likewise.
2081         * modules/glob (Makefile.am): Likewise.
2082         * modules/group-member (Makefile.am): Likewise.
2083         * modules/hard-locale (Makefile.am): Likewise.
2084         * modules/hash (Makefile.am): Likewise.
2085         * modules/hmac-md5 (Makefile.am): Likewise.
2086         * modules/hmac-sha1 (Makefile.am): Likewise.
2087         * modules/human (Makefile.am): Likewise.
2088         * modules/idcache (Makefile.am): Likewise.
2089         * modules/imaxabs (Makefile.am): Likewise.
2090         * modules/imaxdiv (Makefile.am): Likewise.
2091         * modules/inet_ntop (Makefile.am): Likewise.
2092         * modules/inet_pton (Makefile.am): Likewise.
2093         * modules/intprops (Makefile.am): Likewise.
2094         * modules/inttostr (Makefile.am): Likewise.
2095         * modules/inttypes (Makefile.am): Likewise.
2096         * modules/isapipe (Makefile.am): Likewise.
2097         * modules/javaversion (Makefile.am): Likewise.
2098         * modules/lchmod (Makefile.am): Likewise.
2099         * modules/lchown (Makefile.am): Likewise.
2100         * modules/localcharset (Makefile.am): Likewise.
2101         * modules/long-options (Makefile.am): Likewise.
2102         * modules/lstat (Makefile.am): Likewise.
2103         * modules/malloc (Makefile.am): Likewise.
2104         * modules/mathl (Makefile.am): Likewise.
2105         * modules/mbchar (Makefile.am): Likewise.
2106         * modules/md2 (Makefile.am): Likewise.
2107         * modules/md4 (Makefile.am): Likewise.
2108         * modules/md5 (Makefile.am): Likewise.
2109         * modules/memcasecmp (Makefile.am): Likewise.
2110         * modules/memchr (Makefile.am): Likewise.
2111         * modules/memcmp (Makefile.am): Likewise.
2112         * modules/memcoll (Makefile.am): Likewise.
2113         * modules/memcpy (Makefile.am): Likewise.
2114         * modules/memmem (Makefile.am): Likewise.
2115         * modules/memmove (Makefile.am): Likewise.
2116         * modules/mempcpy (Makefile.am): Likewise.
2117         * modules/memrchr (Makefile.am): Likewise.
2118         * modules/memset (Makefile.am): Likewise.
2119         * modules/memxor (Makefile.am): Likewise.
2120         * modules/mkancesdirs (Makefile.am): Likewise.
2121         * modules/mkdir-p (Makefile.am): Likewise.
2122         * modules/mkdir (Makefile.am): Likewise.
2123         * modules/mkdtemp (Makefile.am): Likewise.
2124         * modules/mkstemp (Makefile.am): Likewise.
2125         * modules/mktime (Makefile.am): Likewise.
2126         * modules/modechange (Makefile.am): Likewise.
2127         * modules/mountlist (Makefile.am): Likewise.
2128         * modules/nanosleep (Makefile.am): Likewise.
2129         * modules/obstack (Makefile.am): Likewise.
2130         * modules/openat (Makefile.am): Likewise.
2131         * modules/pagealign_alloc (Makefile.am): Likewise.
2132         * modules/pathmax (Makefile.am): Likewise.
2133         * modules/physmem (Makefile.am): Likewise.
2134         * modules/poll (Makefile.am): Likewise.
2135         * modules/posixtm (Makefile.am): Likewise.
2136         * modules/posixver (Makefile.am): Likewise.
2137         * modules/putenv (Makefile.am): Likewise.
2138         * modules/quote (Makefile.am): Likewise.
2139         * modules/quotearg (Makefile.am): Likewise.
2140         * modules/raise (Makefile.am): Likewise.
2141         * modules/read-file (Makefile.am): Likewise.
2142         * modules/readline (Makefile.am): Likewise.
2143         * modules/readlink (Makefile.am): Likewise.
2144         * modules/readtokens (Makefile.am): Likewise.
2145         * modules/readutmp (Makefile.am): Likewise.
2146         * modules/realloc (Makefile.am): Likewise.
2147         * modules/regex (Makefile.am): Likewise.
2148         * modules/rename-dest-slash (Makefile.am): Likewise.
2149         * modules/rename (Makefile.am): Likewise.
2150         * modules/rijndael (Makefile.am): Likewise.
2151         * modules/rmdir (Makefile.am): Likewise.
2152         * modules/rpmatch (Makefile.am): Likewise.
2153         * modules/safe-read (Makefile.am): Likewise.
2154         * modules/safe-write (Makefile.am): Likewise.
2155         * modules/same-inode (Makefile.am): Likewise.
2156         * modules/same (Makefile.am): Likewise.
2157         * modules/save-cwd (Makefile.am): Likewise.
2158         * modules/savedir (Makefile.am): Likewise.
2159         * modules/setenv (Makefile.am): Likewise.
2160         * modules/settime (Makefile.am): Likewise.
2161         * modules/sha1 (Makefile.am): Likewise.
2162         * modules/sig2str (Makefile.am): Likewise.
2163         * modules/snprintf (Makefile.am): Likewise.
2164         * modules/stat-macros (Makefile.am): Likewise.
2165         * modules/stat-time (Makefile.am): Likewise.
2166         * modules/stdbool (Makefile.am): Likewise.
2167         * modules/stdint (Makefile.am): Likewise.
2168         * modules/stdlib-safer (Makefile.am): Likewise.
2169         * modules/stpcpy (Makefile.am): Likewise.
2170         * modules/stpncpy (Makefile.am): Likewise.
2171         * modules/strcase (Makefile.am): Likewise.
2172         * modules/strcasestr (Makefile.am): Likewise.
2173         * modules/strchrnul (Makefile.am): Likewise.
2174         * modules/strcspn (Makefile.am): Likewise.
2175         * modules/strdup (Makefile.am): Likewise.
2176         * modules/strerror (Makefile.am): Likewise.
2177         * modules/strftime (Makefile.am): Likewise.
2178         * modules/strndup (Makefile.am): Likewise.
2179         * modules/strnlen (Makefile.am): Likewise.
2180         * modules/strpbrk (Makefile.am): Likewise.
2181         * modules/strsep (Makefile.am): Likewise.
2182         * modules/strstr (Makefile.am): Likewise.
2183         * modules/strtod (Makefile.am): Likewise.
2184         * modules/strtoimax (Makefile.am): Likewise.
2185         * modules/strtok_r (Makefile.am): Likewise.
2186         * modules/strtol (Makefile.am): Likewise.
2187         * modules/strtoll (Makefile.am): Likewise.
2188         * modules/strtoul (Makefile.am): Likewise.
2189         * modules/strtoull (Makefile.am): Likewise.
2190         * modules/strtoumax (Makefile.am): Likewise.
2191         * modules/strverscmp (Makefile.am): Likewise.
2192         * modules/sys_socket (Makefile.am): Likewise.
2193         * modules/sys_stat (Makefile.am): Likewise.
2194         * modules/sysexits (Makefile.am): Likewise.
2195         * modules/time_r (Makefile.am): Likewise.
2196         * modules/timegm (Makefile.am): Likewise.
2197         * modules/timespec (Makefile.am): Likewise.
2198         * modules/tmpfile-safer (Makefile.am): Likewise.
2199         * modules/trim (Makefile.am): Likewise.
2200         * modules/unistd-safer (Makefile.am): Likewise.
2201         * modules/unlinkdir (Makefile.am): Likewise.
2202         * modules/unlocked-io (Makefile.am): Likewise.
2203         * modules/userspec (Makefile.am): Likewise.
2204         * modules/utime (Makefile.am): Likewise.
2205         * modules/utimecmp (Makefile.am): Likewise.
2206         * modules/utimens (Makefile.am): Likewise.
2207         * modules/vasnprintf (Makefile.am): Likewise.
2208         * modules/vasprintf (Makefile.am): Likewise.
2209         * modules/vsnprintf (Makefile.am): Likewise.
2210         * modules/xalloc (Makefile.am): Likewise.
2211         * modules/xgetcwd (Makefile.am): Likewise.
2212         * modules/xnanosleep (Makefile.am): Likewise.
2213         * modules/xreadlink (Makefile.am): Likewise.
2214         * modules/xstrtod (Makefile.am): Likewise.
2215         * modules/xstrtol (Makefile.am): Likewise.
2216         * modules/xstrtold (Makefile.am): Likewise.
2217         * modules/yesno (Makefile.am): Likewise.
2218         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
2219
2220 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2221
2222         * modules/error (Makefile.am): Distribute files through
2223         EXTRA_DIST, not lib_SOURCES.
2224
2225 2006-10-12  Eric Blake  <ebb9@byu.net>
2226
2227         * modules/error (Makefile.am): Distribute files in /lib.
2228         * modules/obstack (Makefile.am): Likewise.
2229
2230 2006-10-12  Bruno Haible  <bruno@clisp.org>
2231
2232         * modules/acl (Makefile.am): Distribute all files in lib/ through
2233         EXTRA_DIST.
2234         * modules/arcfour (Makefile.am): Likewise.
2235         * modules/arctwo (Makefile.am): Likewise.
2236         * modules/argmatch (Makefile.am): Likewise.
2237         * modules/argz (Makefile.am): Likewise.
2238         * modules/atexit (Makefile.am): Likewise.
2239         * modules/backupfile (Makefile.am): Likewise.
2240         * modules/c-strtod (Makefile.am): Likewise.
2241         * modules/c-strtold (Makefile.am): Likewise.
2242         * modules/calloc (Makefile.am): Likewise.
2243         * modules/canon-host (Makefile.am): Likewise.
2244         * modules/canonicalize (Makefile.am): Likewise.
2245         * modules/chdir-long (Makefile.am): Likewise.
2246         * modules/chdir-safer (Makefile.am): Likewise.
2247         * modules/check-version (Makefile.am): Likewise.
2248         * modules/chown (Makefile.am): Likewise.
2249         * modules/cloexec (Makefile.am): Likewise.
2250         * modules/close-stream (Makefile.am): Likewise.
2251         * modules/closeout (Makefile.am): Likewise.
2252         * modules/crc (Makefile.am): Likewise.
2253         * modules/cycle-check (Makefile.am): Likewise.
2254         * modules/des (Makefile.am): Likewise.
2255         * modules/dirfd (Makefile.am): Likewise.
2256         * modules/dirname (Makefile.am): Likewise.
2257         * modules/dup2 (Makefile.am): Likewise.
2258         * modules/euidaccess (Makefile.am): Likewise.
2259         * modules/exclude (Makefile.am): Likewise.
2260         * modules/exitfail (Makefile.am): Likewise.
2261         * modules/fcntl-safer (Makefile.am): Likewise.
2262         * modules/file-type (Makefile.am): Likewise.
2263         * modules/fileblocks (Makefile.am): Likewise.
2264         * modules/filemode (Makefile.am): Likewise.
2265         * modules/filenamecat (Makefile.am): Likewise.
2266         * modules/fnmatch (Makefile.am): Likewise.
2267         * modules/fopen-safer (Makefile.am): Likewise.
2268         * modules/fpending (Makefile.am): Likewise.
2269         * modules/fprintftime (Makefile.am): Likewise.
2270         * modules/free (Makefile.am): Likewise.
2271         * modules/fsusage (Makefile.am): Likewise.
2272         * modules/ftruncate (Makefile.am): Likewise.
2273         * modules/fts (Makefile.am): Likewise.
2274         * modules/gc (Makefile.am): Likewise.
2275         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2276         * modules/getaddrinfo (Makefile.am): Likewise.
2277         * modules/getcwd (Makefile.am): Likewise.
2278         * modules/getdelim (Makefile.am): Likewise.
2279         * modules/getdomainname (Makefile.am): Likewise.
2280         * modules/getgroups (Makefile.am): Likewise.
2281         * modules/gethostname (Makefile.am): Likewise.
2282         * modules/gethrxtime (Makefile.am): Likewise.
2283         * modules/getline (Makefile.am): Likewise.
2284         * modules/getloadavg (Makefile.am): Likewise.
2285         * modules/getlogin_r (Makefile.am): Likewise.
2286         * modules/getopt (Makefile.am): Likewise.
2287         * modules/getpass (Makefile.am): Likewise.
2288         * modules/getpass-gnu (Makefile.am): Likewise.
2289         * modules/getsubopt (Makefile.am): Likewise.
2290         * modules/gettime (Makefile.am): Likewise.
2291         * modules/gettimeofday (Makefile.am): Likewise.
2292         * modules/getugroups (Makefile.am): Likewise.
2293         * modules/getusershell (Makefile.am): Likewise.
2294         * modules/glob (Makefile.am): Likewise.
2295         * modules/group-member (Makefile.am): Likewise.
2296         * modules/hard-locale (Makefile.am): Likewise.
2297         * modules/hash (Makefile.am): Likewise.
2298         * modules/hmac-md5 (Makefile.am): Likewise.
2299         * modules/hmac-sha1 (Makefile.am): Likewise.
2300         * modules/human (Makefile.am): Likewise.
2301         * modules/idcache (Makefile.am): Likewise.
2302         * modules/imaxabs (Makefile.am): Likewise.
2303         * modules/imaxdiv (Makefile.am): Likewise.
2304         * modules/inet_ntop (Makefile.am): Likewise.
2305         * modules/inet_pton (Makefile.am): Likewise.
2306         * modules/inttostr (Makefile.am): Likewise.
2307         * modules/isapipe (Makefile.am): Likewise.
2308         * modules/lchown (Makefile.am): Likewise.
2309         * modules/long-options (Makefile.am): Likewise.
2310         * modules/lstat (Makefile.am): Likewise.
2311         * modules/malloc (Makefile.am): Likewise.
2312         * modules/mathl (Makefile.am): Likewise.
2313         * modules/mbchar (Makefile.am): Likewise.
2314         * modules/md2 (Makefile.am): Likewise.
2315         * modules/md4 (Makefile.am): Likewise.
2316         * modules/md5 (Makefile.am): Likewise.
2317         * modules/memcasecmp (Makefile.am): Likewise.
2318         * modules/memchr (Makefile.am): Likewise.
2319         * modules/memcmp (Makefile.am): Likewise.
2320         * modules/memcoll (Makefile.am): Likewise.
2321         * modules/memcpy (Makefile.am): Likewise.
2322         * modules/memmem (Makefile.am): Likewise.
2323         * modules/memmove (Makefile.am): Likewise.
2324         * modules/mempcpy (Makefile.am): Likewise.
2325         * modules/memrchr (Makefile.am): Likewise.
2326         * modules/memset (Makefile.am): Likewise.
2327         * modules/memxor (Makefile.am): Likewise.
2328         * modules/mkancesdirs (Makefile.am): Likewise.
2329         * modules/mkdir (Makefile.am): Likewise.
2330         * modules/mkdir-p (Makefile.am): Likewise.
2331         * modules/mkdtemp (Makefile.am): Likewise.
2332         * modules/mkstemp (Makefile.am): Likewise.
2333         * modules/mktime (Makefile.am): Likewise.
2334         * modules/modechange (Makefile.am): Likewise.
2335         * modules/mountlist (Makefile.am): Likewise.
2336         * modules/nanosleep (Makefile.am): Likewise.
2337         * modules/openat (Makefile.am): Likewise.
2338         * modules/pagealign_alloc (Makefile.am): Likewise.
2339         * modules/physmem (Makefile.am): Likewise.
2340         * modules/poll (Makefile.am): Likewise.
2341         * modules/posixtm (Makefile.am): Likewise.
2342         * modules/posixver (Makefile.am): Likewise.
2343         * modules/putenv (Makefile.am): Likewise.
2344         * modules/quote (Makefile.am): Likewise.
2345         * modules/quotearg (Makefile.am): Likewise.
2346         * modules/raise (Makefile.am): Likewise.
2347         * modules/read-file (Makefile.am): Likewise.
2348         * modules/readline (Makefile.am): Likewise.
2349         * modules/readlink (Makefile.am): Likewise.
2350         * modules/readtokens (Makefile.am): Likewise.
2351         * modules/readutmp (Makefile.am): Likewise.
2352         * modules/realloc (Makefile.am): Likewise.
2353         * modules/regex (Makefile.am): Likewise.
2354         * modules/rename (Makefile.am): Likewise.
2355         * modules/rename-dest-slash (Makefile.am): Likewise.
2356         * modules/rijndael (Makefile.am): Likewise.
2357         * modules/rmdir (Makefile.am): Likewise.
2358         * modules/rpmatch (Makefile.am): Likewise.
2359         * modules/safe-read (Makefile.am): Likewise.
2360         * modules/safe-write (Makefile.am): Likewise.
2361         * modules/same (Makefile.am): Likewise.
2362         * modules/save-cwd (Makefile.am): Likewise.
2363         * modules/savedir (Makefile.am): Likewise.
2364         * modules/setenv (Makefile.am): Likewise.
2365         * modules/settime (Makefile.am): Likewise.
2366         * modules/sha1 (Makefile.am): Likewise.
2367         * modules/sig2str (Makefile.am): Likewise.
2368         * modules/snprintf (Makefile.am): Likewise.
2369         * modules/stdlib-safer (Makefile.am): Likewise.
2370         * modules/stpcpy (Makefile.am): Likewise.
2371         * modules/stpncpy (Makefile.am): Likewise.
2372         * modules/strcase (Makefile.am): Likewise.
2373         * modules/strcasestr (Makefile.am): Likewise.
2374         * modules/strchrnul (Makefile.am): Likewise.
2375         * modules/strcspn (Makefile.am): Likewise.
2376         * modules/strdup (Makefile.am): Likewise.
2377         * modules/strerror (Makefile.am): Likewise.
2378         * modules/strftime (Makefile.am): Likewise.
2379         * modules/strndup (Makefile.am): Likewise.
2380         * modules/strnlen (Makefile.am): Likewise.
2381         * modules/strpbrk (Makefile.am): Likewise.
2382         * modules/strsep (Makefile.am): Likewise.
2383         * modules/strstr (Makefile.am): Likewise.
2384         * modules/strtod (Makefile.am): Likewise.
2385         * modules/strtoimax (Makefile.am): Likewise.
2386         * modules/strtok_r (Makefile.am): Likewise.
2387         * modules/strtol (Makefile.am): Likewise.
2388         * modules/strtoll (Makefile.am): Likewise.
2389         * modules/strtoul (Makefile.am): Likewise.
2390         * modules/strtoull (Makefile.am): Likewise.
2391         * modules/strtoumax (Makefile.am): Likewise.
2392         * modules/strverscmp (Makefile.am): Likewise.
2393         * modules/time_r (Makefile.am): Likewise.
2394         * modules/timegm (Makefile.am): Likewise.
2395         * modules/tmpfile-safer (Makefile.am): Likewise.
2396         * modules/unistd-safer (Makefile.am): Likewise.
2397         * modules/unlinkdir (Makefile.am): Likewise.
2398         * modules/userspec (Makefile.am): Likewise.
2399         * modules/utime (Makefile.am): Likewise.
2400         * modules/utimecmp (Makefile.am): Likewise.
2401         * modules/utimens (Makefile.am): Likewise.
2402         * modules/vasnprintf (Makefile.am): Likewise.
2403         * modules/vasprintf (Makefile.am): Likewise.
2404         * modules/vsnprintf (Makefile.am): Likewise.
2405         * modules/xalloc (Makefile.am): Likewise.
2406         * modules/xgetcwd (Makefile.am): Likewise.
2407         * modules/xnanosleep (Makefile.am): Likewise.
2408         * modules/xreadlink (Makefile.am): Likewise.
2409         * modules/xstrtod (Makefile.am): Likewise.
2410         * modules/xstrtol (Makefile.am): Likewise.
2411         * modules/xstrtold (Makefile.am): Likewise.
2412         * modules/yesno (Makefile.am): Likewise.
2413
2414 2006-10-12  Jim Meyering  <jim@meyering.net>
2415
2416         * m4/getloadavg.m4: Revert the change below.
2417
2418         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
2419         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
2420         fail with a symlink, which is what coreutils' ./bootstrap now
2421         creates by default.
2422
2423 2006-10-12  Bruno Haible  <bruno@clisp.org>
2424
2425         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
2426         mingw.
2427         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
2428         MSVC and mingw explicitly.
2429
2430 2006-10-11  Simon Josefsson  <jas@extundo.com>
2431             Bruno Haible  <bruno@clisp.org>
2432
2433         Add support for multiple gnulib-tool invocations in the scope of a
2434         single configure.ac file.
2435         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
2436         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
2437         with the same contents as the _LIBADD variable.
2438         (func_emit_initmacro_start, func_emit_initmacro_end,
2439         func_emit_initmacro_done): New functions.
2440         (func_import, func_create_testdir): Invoke them. Allow the identifiers
2441         gl_LIBOBJS and gl_LTLIBOBJS.
2442
2443 2006-10-11  Bruno Haible  <bruno@clisp.org>
2444
2445         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
2446         (func_create_testdir): Don't create po/Makefile.am, don't invoke
2447         autoreconf. Instead, invoke autopoint explicitly but move back the
2448         *.m4 files from gnulib.
2449
2450 2006-10-11  Bruno Haible  <bruno@clisp.org>
2451
2452         * gnulib-tool (func_usage): Make module names after --create-testdir
2453         optional.
2454         (func_create_testdir): If no module was specified, use nearly all
2455         modules.
2456
2457 2006-10-12  Jim Meyering  <jim@meyering.net>
2458
2459         Big performance improvement for fts-based tools that use FTS_NOSTAT.
2460         Avoid spurious inode-mismatch problems on non-POSIX file systems.
2461         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
2462         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
2463         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
2464         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
2465         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
2466         (fts_set_stat_required): New function.
2467         (fts_open): Defer the calls to fts_stat, if possible or requested.
2468         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
2469         into fts_stat itself.
2470         (fts_read): Perform any required (deferred) fts_stat call.
2471         (fts_build): Likewise, for the directory we're about to open and read.
2472         In the readdir loop, carefully decide whether each entry will require
2473         an eventual call to fts_stat, using dirent.d_type info if available.
2474         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
2475         a command line argument into this function.  Update all callers.
2476         Map a return value of FTS_DOT to FTS_D for a command line argument.
2477         * modules/fts (Depends-on): Add d-type.  Alphabetize.
2478         Thanks to Miklos Szeredi for his tenacity and for the initial
2479         bug report about "find" failing on a FUSE-based file system.
2480
2481         * lib/fts.c (fts_open): Use consistent indentation.
2482
2483 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2484
2485         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
2486         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
2487         reported by Jim Meyering.  All uses of cache variables renamed
2488         to match Autoconf's.
2489         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
2490         the other one.
2491
2492         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
2493         Fix misspelling in diagnostic.
2494
2495 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2496
2497         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
2498         defined.  Problem reported by Matthew Woehlke.
2499
2500         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
2501         Add support for Tandem NonStop R series.
2502         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
2503         Use new macro.
2504
2505         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
2506         (has_trailing_slash): Omit size arg; all callers changed.
2507         Omit 'inline', since it doesn't help performance and we'd
2508         need to configure it.
2509         Don't count //, ///, etc. as having a trailing slash.
2510         As a side effect, this removes a C99ism reported by Matthew Woehlke.
2511         (rpl_rename_dest_slash): On failure, use rename's errno rather
2512         than (in some cases) an incorrect or junk errno.
2513         Simplify code by removing need to compute length; this does
2514         cause it to make two passes instead of one over the file name,
2515         but it's worth it.
2516
2517         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
2518         change, since Autoconf's version may no longer be appropriate now
2519         that we are using CVS Autoconf's version.  Add support for Tandem.
2520
2521 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2522             Bruno Haible  <bruno@clisp.org>
2523
2524         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
2525         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
2526         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
2527         gl_AC_TYPE_LONG_LONG.
2528
2529         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
2530         instead of HAVE_LONG_LONG.
2531         * lib/printf-args.c (printf_fetchargs): Likewise.
2532         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
2533         * lib/vasnprintf.c (VASNPRINTF): Likewise.
2534         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
2535         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
2536         gl_AC_TYPE_LONG_LONG.
2537
2538 2006-10-11  Bruno Haible  <bruno@clisp.org>
2539
2540         * m4/longlong.m4: Add comments.
2541         * m4/ulonglong.m4: Likewise.
2542
2543 2006-10-10  Bruno Haible  <bruno@clisp.org>
2544
2545         Make it possible to #define stpcpy, strdup to aliases.
2546         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
2547         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
2548
2549 2006-10-10  Bruno Haible  <bruno@clisp.org>
2550
2551         Make it possible to #define gcd to an alias.
2552         * lib/gcd.c: Include config.h.
2553
2554 2006-10-10  Bruno Haible  <bruno@clisp.org>
2555
2556         Make it possible to #define c_isascii to an alias.
2557         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
2558         defined. Undefine the macros before defining them, to avoid gcc
2559         warnings.
2560         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
2561         define NO_C_CTYPE_MACROS early.
2562
2563 2006-10-10  Bruno Haible  <bruno@clisp.org>
2564
2565         Make it possible to #define set_program_name to an alias.
2566         * lib/progname.c: Don't undefine set_program_name; instead, undefine
2567         ENABLE_RELOCATABLE early.
2568
2569 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
2570
2571         Port to Tandem NSK OSS, which has 64-bit signed int but at most
2572         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
2573         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
2574         More generally, don't assume that 64-bit signed int is available
2575         if unsigned int is, and vice versa.
2576         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
2577         unsigned symbols, not on their signed counterparts.
2578         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
2579         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
2580         (UINT64_C, UINTMAX_C):
2581         Likewise.
2582         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
2583         unsigned counterparts.
2584         (Have_long_long, Unsigned): New macros.
2585         (Int): Renamed from INT.
2586         (strtoimax): Use the new macros.
2587         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
2588         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
2589         * modules/inttypes (inttypes.h): Substitute
2590         HAVE_UNSIGNED_LONG_LONG_INT.
2591         * modules/stdint (stdint.h): Likewise.
2592         (Files): Add m4/ulonglong.m4.
2593
2594 2006-10-10  Bruno Haible  <bruno@clisp.org>
2595
2596         Fix a gcc -Wshadow warning.
2597         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
2598         to 'bucket'.
2599         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
2600         gl_linked_indexof_from_to): Likewise.
2601         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
2602         Likewise.
2603         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
2604         Likewise.
2605         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
2606         Reported by Eric Blake.
2607
2608 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2609
2610         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
2611         for NetBSD.  Problem reported by Bruno Haible.
2612
2613 2006-10-09  Jim Meyering  <jim@meyering.net>
2614
2615         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
2616         Patch from Bruno Haible.
2617
2618 2006-10-09  Jim Meyering  <jim@meyering.net>
2619
2620         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
2621         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
2622         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
2623
2624 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
2625
2626         Don't include <config.h> twice; this doesn't work in some cases,
2627         e.g., when config.h has "#define intmax_t long long int" and
2628         we include <config.h>, <inttypes.h>, <config.h> in that order.
2629         Problem reported by Matthew Woehlke in:
2630         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
2631         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
2632         * lib/fts-cycle.c: Don't include config.h.
2633         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
2634         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
2635         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
2636         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
2637         inttypes.h.
2638         * lib/xstrtoumax.c: Likewise.
2639         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
2640         __strtol and the like, so that this module is more like its siblings.
2641         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
2642         Remove; no longer needed now that we assume gnulib inttypes.h.
2643
2644 2006-10-08  Bruno Haible  <bruno@clisp.org>
2645
2646         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
2647         option.
2648
2649 2006-10-07  Jim Meyering  <jim@meyering.net>
2650
2651         * modules/inttypes (inttypes.h): Revert what seems to have been
2652         an inadvertent part of today's change: use "|", not "/" in the
2653         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
2654
2655 2006-10-07  Bruno Haible  <bruno@clisp.org>
2656
2657         * modules/sublist: New file.
2658
2659 2006-10-07  Bruno Haible  <bruno@clisp.org>
2660
2661         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
2662         * modules/argz (argz.h): Likewise.
2663         * modules/arpa_inet (arpa/inet.h): Likewise.
2664         * modules/byteswap (byteswap.h): Likewise.
2665         * modules/configmake (configmake.h): Likewise.
2666         * modules/fcntl (fcntl.h): Likewise.
2667         * modules/fnmatch (fnmatch.h): Likewise.
2668         * modules/getopt (getopt.h): Likewise.
2669         * modules/glob (glob.h): Likewise.
2670         * modules/inttypes (inttypes.h): Likewise.
2671         * modules/netinet_in (netinet/in.h): Likewise.
2672         * modules/poll (poll.h): Likewise.
2673         * modules/stdbool (stdbool.h): Likewise.
2674         * modules/stdint (stdint.h): Likewise.
2675         * modules/sys_select (sys/select.h): Likewise.
2676         * modules/sys_socket (sys/socket.h): Likewise.
2677         * modules/sys_stat (sys/stat.h): Likewise.
2678         * modules/sysexits (sysexits.h): Likewise.
2679         * modules/unistd (unistd.h): Likewise.
2680         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2681         Add a "DO NOT EDIT" comment to the generated file.
2682         (func_import): Likewise for gnulib-comp.m4.
2683
2684 2006-10-07  Bruno Haible  <bruno@clisp.org>
2685
2686         * lib/gl_sublist.h: New file.
2687         * lib/gl_sublist.c: New file.
2688
2689 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
2690
2691         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
2692         name (relative to the original working directory) and the file
2693         name component (relative to the temporary working directory).  All
2694         callers changed.
2695         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
2696         * lib/mkdir-p.c (make_dir_parents): Likewise.
2697         * lib/mkdir-p.h (make_dir_parents): Likewise.
2698
2699 2006-10-06  Eric Blake  <ebb9@byu.net>
2700
2701         Define several macros for use by the clean-temp module.
2702         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
2703         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
2704         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
2705
2706         * lib/clean-temp.h (close_stream_temp): New declaration.
2707         * lib/clean-temp.c (includes): Pull in headers according to what
2708         other modules are in use.
2709         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
2710
2711 2006-10-06  Bruno Haible  <bruno@clisp.org>
2712
2713         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
2714         instead of fopen, fwriteerror.
2715
2716 2006-10-06  Bruno Haible  <bruno@clisp.org>
2717
2718         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
2719         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
2720         int.
2721         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
2722         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
2723         Return an error indicator.
2724         Suggested by Eric Blake.
2725
2726 2006-10-06  Bruno Haible  <bruno@clisp.org>
2727
2728         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
2729         Reported by Eric Blake.
2730
2731 2006-10-06  Bruno Haible  <bruno@clisp.org>
2732
2733         * modules/closeout (Description): Mention stderr too.
2734
2735 2006-10-06  Bruno Haible  <bruno@clisp.org>
2736         and Paul Eggert  <eggert@cs.ucla.edu>
2737
2738         * lib/closeout.c (close_stdout): Also close stderr.
2739         * lib/closeout.h: Update comment.
2740
2741 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
2742
2743         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
2744         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
2745         * lib/dirchownmod.c: Include lchown.h.
2746         * lib/lchown.c: Don't include files that lchown.h now includes.
2747         Don't declare chown, since lchown.h now does that.
2748         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
2749         (lchown): Define to rpl_chown if lchown is declared but
2750         does not exist.  Declare using a prototype if lchown is not
2751         declared.  Add a copyright notice.
2752         * lib/mkstemp.h: Include <unistd.h>.
2753         * lib/openat.c: Include lchown.h.
2754
2755         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
2756         we now test for that separately.
2757         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
2758         rather than O_NOFOLLOW, when testing whether it's possible to
2759         avoid a race condition reliably.
2760         * lib/savewd.c (savewd_chdir): Likewise.
2761
2762         Remove macros that are no longer needed now that stdint.h is
2763         reliable.
2764         * lib/fsusage.c (UINTMAX_MAX): Remove.
2765         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
2766         * lib/utimecmp.c (SIZE_MAX): Remove.
2767
2768         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
2769
2770         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
2771         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
2772         O_NOATIME works.
2773
2774 2006-10-05  Bruno Haible  <bruno@clisp.org>
2775
2776         * lib/gl_list.h (gl_sortedlist_search_from_to,
2777         gl_sortedlist_indexof_from_to): New declarations.
2778         (gl_list_implementation): New fields sortedlist_search_from_to,
2779         sortedlist_indexof_from_to.
2780         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
2781         inline functions.
2782         * lib/gl_list.c (gl_sortedlist_search_from_to,
2783         gl_sortedlist_indexof_from_to): New functions.
2784         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
2785         function.
2786         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
2787         (gl_array_sortedlist_search_from_to): New function.
2788         (gl_array_list_implementation): Update.
2789         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
2790         function.
2791         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
2792         (gl_carray_sortedlist_search_from_to): New function.
2793         (gl_carray_list_implementation): Update.
2794         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
2795         gl_linked_sortedlist_indexof_from_to): New functions.
2796         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2797         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2798         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
2799         gl_tree_sortedlist_indexof_from_to): New functions.
2800         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2801         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2802         Update.
2803         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2804         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
2805         Update.
2806
2807 2006-10-05  Bruno Haible  <bruno@clisp.org>
2808
2809         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
2810         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
2811         (struct gl_list_implementation): Add fields search_from_to,
2812         indexof_from_to. Remove fields search, indexof.
2813         (gl_list_search): Use the search_from_to method.
2814         (gl_list_search_from, gl_list_search_from_to): New functions.
2815         (gl_list_indexof): Use the indexof_from_to method.
2816         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2817         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
2818         (gl_list_search_from, gl_list_search_from_to): New functions.
2819         (gl_list_indexof): Use the indexof_from_to method.
2820         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2821         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
2822         gl_array_indexof. Add start_index, end_index arguments.
2823         (gl_array_search_from_to): Renamed from gl_array_search. Add
2824         start_index, end_index arguments.
2825         (gl_array_remove, gl_array_list_implementation): Update.
2826         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
2827         gl_carray_indexof. Add start_index, end_index arguments.
2828         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
2829         start_index, end_index arguments.
2830         (gl_carray_remove, gl_carray_list_implementation): Update.
2831         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
2832         gl_linked_search. Add start_index, end_index arguments.
2833         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
2834         start_index, end_index arguments.
2835         (gl_linked_remove): Update.
2836         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2837         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2838         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
2839         field to 'size_t'.
2840         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
2841         gl_tree_search. Add start_index, end_index arguments.
2842         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2843         start_index, end_index arguments.
2844         (gl_tree_remove): Update.
2845         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2846         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2847         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
2848         function.
2849         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
2850         gl_tree_search. Add start_index, end_index arguments.
2851         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2852         start_index, end_index arguments.
2853         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2854         Update.
2855         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
2856
2857 2006-10-05  Bruno Haible  <bruno@clisp.org>
2858
2859         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
2860
2861         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
2862         fwriteerror_temp): New declarations.
2863         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
2864         (descriptors): New variable.
2865         (cleanup): First, close the descriptors.
2866         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
2867         fclose_temp, fwriteerror_temp): New functions.
2868
2869 2006-10-04  Jim Meyering  <jim@meyering.net>
2870
2871         * lib/fts.c (fts_open): Tiny comment change.
2872
2873 2006-10-04  Bruno Haible  <bruno@clisp.org>
2874
2875         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
2876         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
2877         gl_LOCK_BODY.
2878         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
2879         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
2880         gl_LOCK_EARLY_BODY.
2881         (gl_LOCK): Require gl_LOCK_BODY.
2882
2883 2006-10-04  Bruno Haible  <bruno@clisp.org>
2884
2885         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
2886         (gl_oset_search_atleast): New declaration.
2887         (struct gl_oset_implementation): Add field 'search_atleast'.
2888         (gl_oset_search_atleast): New inline function.
2889         * lib/gl_oset.c (gl_oset_search_atleast): New function.
2890         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
2891         (gl_array_oset_implementation): Update.
2892         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
2893         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
2894         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
2895
2896 2006-10-04  Bruno Haible  <bruno@clisp.org>
2897
2898         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
2899
2900 2006-10-03  Bruno Haible  <bruno@clisp.org>
2901
2902         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
2903         from gl_avltreehash_list_implementation.
2904
2905 2006-10-03  Bruno Haible  <bruno@clisp.org>
2906
2907         * lib/gl_oset.c (gl_oset_add): Fix return type.
2908
2909 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
2910
2911         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
2912
2913 2006-10-02  Eric Blake  <ebb9@byu.net>
2914
2915         * modules/strnlen (Depends-on): Add extensions.
2916
2917 2006-10-02  Eric Blake  <ebb9@byu.net>
2918
2919         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
2920         definition in 2.60+.
2921
2922 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
2923
2924         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
2925         checks.
2926
2927 2006-10-02  Bruno Haible  <bruno@clisp.org>
2928
2929         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
2930         to the AUTOMAKE_OPTIONS.
2931         Reported by Jim Meyering.
2932
2933 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
2934
2935         Work around bug in Solaris 10 /proc file system:
2936         /proc/self/fd/NNN/.. isn't the parent directory of
2937         the directory whose file descriptor is NNN.  This needs to
2938         be worked around at run time, not compile time, since a
2939         program might be built on Solaris 8, where things work, and
2940         run on Solaris 10.
2941         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
2942         to use the following interface instead:
2943         (OPENAT_BUFFER_SIZE): New macro.
2944         (openat_proc_name): New function.
2945         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
2946         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
2947         Likewise.
2948         * lib/openat-proc.c: New file.
2949         * modules/openat (Files): Add lib/openat-proc.c.
2950         (Depends-on): Add same-inode, stdbool.
2951         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
2952
2953 2006-09-29  Bruno Haible  <bruno@clisp.org>
2954
2955         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
2956         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
2957         argument. Set stdout_closed before testing for ferror, not after.
2958         (fwriteerror, fwriteerror_no_ebadf): New functions.
2959
2960 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2961
2962         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
2963
2964 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
2965
2966         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
2967         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
2968
2969 2006-09-28  Jim Meyering  <jim@meyering.net>
2970
2971         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
2972         Include <unistd.h>.
2973
2974 2006-09-28  Bruno Haible  <bruno@clisp.org>
2975
2976         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
2977         * modules/linkedhash-list (Depends-on): Likewise.
2978         * modules/rbtreehash-list (Depends-on): Likewise.
2979
2980 2006-09-28  Bruno Haible  <bruno@clisp.org>
2981
2982         * lib/strndup.h: Simplify the redefinition of strndup.
2983         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
2984         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
2985
2986 2006-09-28  Bruno Haible  <bruno@clisp.org>
2987
2988         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
2989         * lib/gl_linkedhash_list.c: Likewise.
2990         * lib/gl_rbtreehash_list.c: Likewise.
2991
2992 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
2993
2994         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
2995         getaddrinfo.
2996
2997         * lib/__fpending.h: Don't include <stdio_ext.h> unless
2998         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
2999         it causes <stdio_ext.h> to cause a compile-time error.
3000         Problem reported by Nelson H. F. Beebe.
3001         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
3002         of HAVE_DECL___PENDING.
3003
3004         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
3005         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
3006         declaration.
3007
3008 2006-09-27  Jim Meyering  <jim@meyering.net>
3009
3010         This file could end up with a definition for a function
3011         named __strndup, rather than rpl_strndup on a system with
3012         incomplete weak_alias support.
3013         * lib/strndup.c (strndup): Rename from __strndup.
3014         Remove #defines that used to map __strndup to strndup.
3015         Don't use K&R prototypes.
3016         Remove LIBC-related code, since this file is not sync'd with glibc.
3017         * lib/strndup.h: Revamp, accordingly.
3018         * m4/strndup.m4: Modernize.
3019
3020 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
3021
3022         * modules/savewd (Depends-on): Add 'raise'.
3023         * lib/savewd.c: Include <signal.h>, for 'raise'.
3024
3025 2006-09-26  Jim Meyering  <jim@meyering.net>
3026
3027         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
3028         when we detect Darwin 8.7.0's acl_get_file bug.
3029         Rearrange to perform the new (below) run-test while $LIBS
3030         contains any acl-related library.  Set USE_ACL at the end.
3031         (gl_ACL_GET_FILE): New function.
3032
3033 2006-09-26  Eric Blake  <ebb9@byu.net>
3034
3035         * lib/verror.c: Include <config.h> unconditionally.
3036
3037 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
3038
3039         * modules/clock-time (Maintainer): Add self.
3040         * modules/getlogin_r (Depends-on): Add extensions.
3041
3042 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3043
3044         * modules/clock-time: New module.
3045         * modules/nanosleep (Depends-on): Add clock-time.
3046         * modules/gethrxtime (Depends-on): Likewise.
3047         * modules/gettime (Depends-on): Likewise.
3048         * modules/settime (Depends-on): Likewise.
3049
3050         * modules/fts-lgpl: Depend on openat.
3051         * modules/mkancesdirs: Depend on savewd.
3052         * modules/mkdir-p: Likewise.
3053
3054 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3055
3056         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
3057
3058         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
3059         `gl_have_arbitrary_file_name_length_limit' to
3060         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
3061         actually works between configure runs.
3062
3063 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3064             Bruno Haible  <bruno@clisp.org>
3065
3066         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
3067
3068 2006-09-25  Jim Meyering  <jim@meyering.net>
3069
3070         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
3071         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
3072
3073 2006-09-25  Eric Blake  <ebb9@byu.net>
3074
3075         * gnulib-tool (func_import, func_create_testdir): Fix typos in
3076         exec's in 2006-09-18 patch when shuffling fds.
3077
3078 2006-09-25  Bruno Haible  <bruno@clisp.org>
3079
3080         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
3081         Reported by Jim Meyering.
3082
3083 2006-09-24  Jim Meyering  <jim@meyering.net>
3084
3085         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
3086         compare a pointer against a literal "0".  That caused failures with
3087         at least HP-UX's hpcc.
3088
3089 2006-09-22  Simon Josefsson  <jas@extundo.com>
3090
3091         * modules/gc-sha1:
3092         * modules/gc-md4:
3093         * modules/gc-hmac-sha1:
3094         * modules/gc-hmac-md5:
3095         * modules/gc-des:
3096         * modules/gc-arcfour: Distribute more files.
3097
3098 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3099
3100         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
3101         (gl_linked_iterator_from_to): Initialize struct completely.
3102         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
3103         (gl_tree_iterator_from_to): Likewise
3104         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
3105         * lib/gl_array_list.c [lint] (gl_array_iterator)
3106         (gl_array_iterator_from_to): Likewise.
3107         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
3108         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
3109         (gl_carray_iterator_from_to): Likewise.
3110
3111         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
3112         * lib/md4.c (md4_process_block): Remove unused variable.
3113         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
3114         parentheses for clarity.
3115
3116 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3117
3118         * modules/bison-i18n (Depends-on): Add gettext.
3119
3120 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3121
3122         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
3123         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
3124         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
3125         also add missing comma that caused broken test.
3126         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
3127         stdlib.h, for `abort'.
3128         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
3129         variables.
3130         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
3131         include unistd.h if present, for `rmdir'.
3132         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
3133         variables.
3134         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
3135         in the process include standard headers for prototypes.
3136         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
3137         gets declared on GNU/Linux.
3138         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
3139         unistd.h, for `rmdir'.
3140         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
3141
3142         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
3143         always true.
3144         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
3145
3146         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
3147
3148 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3149
3150         * gnulib-tool (func_version): Create output all at once.  This
3151         may help avoid triggering unnecessary SIGPIPEs, and at any
3152         rate it doesn't hurt.
3153
3154 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3155             Bruno Haible  <bruno@clisp.org>
3156
3157         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
3158         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
3159         * m4/signed.m4 (bh_C_SIGNED): Likewise.
3160
3161         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
3162         (gl_FUNC_VASPRINTF): Invoke it.
3163
3164 2006-09-22  Bruno Haible  <bruno@clisp.org>
3165
3166         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
3167         getloadavg.c as first argument.
3168
3169 2006-09-22  Bruno Haible  <bruno@clisp.org>
3170
3171         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
3172         at the beginning of the gl_INIT macro.
3173         * modules/getloadavg (configure.ac): Pass $gl_source_base to
3174         gl_GETLOADAVG.
3175
3176 2006-09-22  Bruno Haible  <bruno@clisp.org>
3177
3178         * gnulib-tool (func_create_megatestdir): Don't include the config-h
3179         module.
3180         Suggested by Ralf Wildenhues.
3181
3182 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
3183
3184         Import this patch from libc:
3185
3186         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
3187
3188         * lib/regex_internal.c (re_string_reconstruct): Handle
3189         offset < pstr->valid_raw_len && pstr->offsets_needed case.
3190         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
3191         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
3192         re_string_context_at.
3193
3194         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
3195         now requires it.
3196         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
3197         gl_REGEX now does it for us.
3198         (gl_REGEX): Add test taken from
3199         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
3200
3201         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
3202         Check that large offsets work.  Modernize Autoconf usages.
3203         Prefer "yes" to mean a good thing rather than a bad.
3204         Don't put "#define mkstemp" in config.h, as this might interfere
3205         with standard system headers that "#define mkstemp mkstemp64".
3206
3207         * modules/mkstemp (Depends-on): Add extensions, so that
3208         mkstemp is visible on some platforms.
3209         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
3210         (Include): Change to "mkstemp.h" from <stdlib.h>.
3211         (Files): Add mkstemp.h.
3212
3213         * lib/mkstemp.h: New file, since some standard headers
3214         #define mkstemp.
3215         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
3216         Include "mkstemp.h".
3217         Make the _LIBC code resemble glibc original more,
3218         e.g., use K&R style.
3219         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
3220         (mkstemp): Remove, since mkstemp.h does this for us.
3221         * lib/stdlib--.h: Include mkstemp.h.
3222
3223         Import this patch from libc:
3224
3225         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3226
3227         * lib/tempname.c (__gen_tempname): Change attempts_min
3228         into a macro.  Use preprocessor to decide how to initialize
3229         attempts [Coverity CID 67].
3230
3231 2006-09-20  Bruno Haible  <bruno@clisp.org>
3232
3233         * lib/mkdtemp.c: Import from libc.
3234         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3235                 * sysdeps/posix/tempname.c (__gen_tempname): Change
3236                 attempts_min into a macro.  Use preprocessor to decide how to
3237                 initialize attempts [Coverity CID 67].
3238         2001-11-27  Paul Eggert  <eggert@twinsun.com>
3239                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
3240                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
3241
3242 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3243
3244         * gnulib-tool (func_exit): New function, to allow to pass the
3245         exit status portably through the trap.  Use everywhere.
3246         (--help, --version): Signal a write error.
3247         (trap): catch SIGPIPE, for write errors.
3248         Exit at the end of the trap, with the correct exit status.
3249
3250 2006-09-19  Karl Berry  <karl@gnu.org>
3251
3252         * doc/gnulib.texi: note about the license texinfo files.
3253
3254 2006-09-19  Eric Blake  <ebb9@byu.net>
3255
3256         * gnulib-tool: Avoid space-tab.
3257
3258 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3259
3260         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
3261         that prevented coreutils 6.1 from building.  Problem reported
3262         by Petter Reinholdtsen.
3263
3264 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3265
3266         * gnulib-tool (avoidlist): Fix typo that broke options like
3267         --avoid=lock that are used by coreutils bootstrap.
3268
3269 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
3270
3271         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
3272         more systematically.
3273
3274 2006-09-18  Jim Meyering  <jim@meyering.net>
3275
3276         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
3277
3278 2006-09-18  Bruno Haible  <bruno@clisp.org>
3279
3280         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
3281
3282 2006-09-18  Bruno Haible  <bruno@clisp.org>
3283
3284         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
3285         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
3286         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
3287         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
3288         * m4/gettext.m4: Require autoconf >= 2.52.
3289         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
3290         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
3291         of gl_cv_header_inttypes_h.
3292
3293 2006-09-18  Bruno Haible  <bruno@clisp.org>
3294
3295         * lib/javaversion.c: Include configmake.h.
3296
3297 2006-09-18  Bruno Haible  <bruno@clisp.org>
3298
3299         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
3300         avoid that the while loops be executed in a subshell.
3301
3302 2006-09-18  Bruno Haible  <bruno@clisp.org>
3303
3304         * MODULES.html.sh (func_module): Break long lines.
3305         Suggested by Bruce Korb <bkorb@gnu.org>.
3306
3307 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3308
3309         Speed up by a factor of 1.12.
3310         * gnulib-tool (nl): New variable.
3311         (func_import): Rewrite include directive extraction to only read each
3312         directive once.
3313
3314 2006-09-17  Bruno Haible  <bruno@clisp.org>
3315
3316         * modules/javaversion (Makefile.am): Remove DEFS setting.
3317         (Depends-on): Add configmake, for PKGDATADIR definition.
3318
3319 2006-09-17  Bruno Haible  <bruno@clisp.org>
3320
3321         * gnulib-tool (func_create_testdir): Rewrite all files at once.
3322
3323 2006-09-17  Bruno Haible  <bruno@clisp.org>
3324
3325         * gnulib-tool (func_append): New function, stolen from libtool.m4.
3326         (func_modules_transitive_closure, func_modules_add_dummy,
3327         func_modules_to_filelist, func_import, func_create_testdir,
3328         func_create_megatestdir, ...): Use it wherever possible.
3329         Suggested by Ralf Wildenhues.
3330
3331 2006-09-16  Karl Berry  <karl@gnu.org>
3332
3333         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
3334         to avoid sectioning errors.
3335         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
3336         [ifinfo]: blank line after @center-ed titles.
3337         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
3338         Spell FSF address consistently with others.
3339         (These changes approved by rms.)
3340
3341 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3342
3343         Speed up by a factor of 1.61.
3344         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
3345         already checked module names again.
3346
3347 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3348
3349         Speed up by a factor of 1.13.
3350         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
3351         for new_files, and the input to func_add_or_update.
3352
3353 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3354
3355         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
3356         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
3357
3358 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3359
3360         * modules/mkancesdirs (Depends-on): Add fcntl.
3361         * modules/savewd: New file.
3362         * MODULES.html.sh (File system functions): Add savewd.
3363
3364         * modules/configmake (Makefile.am): Add support for the
3365         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
3366
3367 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3368
3369         * m4/savewd.m4: New file.
3370
3371 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3372
3373         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
3374         (dirchownmod): New arg FD.  All callers changed.
3375         Use FD rather than opening the directory ourself, as opening is
3376         now the caller's responsibility.
3377         * lib/dirchownmod.h: Likewise.
3378         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
3379         hosts that require <sys/types.h> before <sys/stat.h>.  Include
3380         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
3381         (test_dir): Remove.
3382         (mkancesdirs): Return length of prefix of FILE that has already
3383         been made, or -2 if there is a child doing the work.  Redo
3384         algorithm so that it is O(N) rather than O(N**2).  Optimize away
3385         ".", and treat ".." specially since it might stray back into
3386         already-created areas.  Use a subprocess if necessary.  New arg
3387         WD; all users changed.  MAKE_DIR function should now return 1
3388         if it creates a directory that is not readable.  Return -2 if
3389         a child process is spun off.
3390         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
3391         Adjust signature to match code.
3392         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
3393         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
3394         all users changed.
3395         * lib/savewd.c, lib/savewd.h: New files.
3396
3397 2006-09-15  Jim Meyering  <jim@meyering.net>
3398
3399         * modules/rename-dest-slash: New module.
3400         * MODULES.html.sh (posix_compat): Add it here.
3401
3402         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
3403
3404 2006-09-15  Jim Meyering  <jim@meyering.net>
3405
3406         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
3407         file.
3408
3409         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
3410
3411 2006-09-15  Jim Meyering  <jim@meyering.net>
3412
3413         * lib/rename-dest-slash.c (has_trailing_slash): Use
3414         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
3415         (rpl_rename_dest_slash): Perform the cheaper trailing slash
3416         test before testing whether SRC is a directory.
3417         Suggestions from Bruno Haible.
3418
3419         Avoid a warning about an unused variable.
3420         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
3421         into the #ifdef block where it's used.
3422
3423         * lib/rename-dest-slash.c: New file.
3424
3425 2006-09-14  Bruno Haible  <bruno@clisp.org>
3426
3427         * lib/allocsa.c: Include <config.h> unconditionally.
3428         * lib/asnprintf.c: Likewise.
3429         * lib/asprintf.c: Likewise.
3430         * lib/c-strcasecmp.c: Likewise.
3431         * lib/c-strcasestr.c: Likewise.
3432         * lib/c-strncasecmp.c: Likewise.
3433         * lib/c-strstr.c: Likewise.
3434         * lib/classpath.c: Likewise.
3435         * lib/clean-temp.c: Likewise.
3436         * lib/concatpath.c: Likewise.
3437         * lib/copy-file.c: Likewise.
3438         * lib/csharpcomp.c: Likewise.
3439         * lib/csharpexec.c: Likewise.
3440         * lib/execute.c: Likewise.
3441         * lib/fatal-signal.c: Likewise.
3442         * lib/findprog.c: Likewise.
3443         * lib/fwriteerror.c: Likewise.
3444         * lib/gl_array_list.c: Likewise.
3445         * lib/gl_array_oset.c: Likewise.
3446         * lib/gl_avltree_list.c: Likewise.
3447         * lib/gl_avltree_oset.c: Likewise.
3448         * lib/gl_avltreehash_list.c: Likewise.
3449         * lib/gl_carray_list.c: Likewise.
3450         * lib/gl_linked_list.c: Likewise.
3451         * lib/gl_linkedhash_list.c: Likewise.
3452         * lib/gl_list.c: Likewise.
3453         * lib/gl_oset.c: Likewise.
3454         * lib/gl_rbtree_list.c: Likewise.
3455         * lib/gl_rbtree_oset.c: Likewise.
3456         * lib/gl_rbtreehash_list.c: Likewise.
3457         * lib/imaxabs.c: Likewise.
3458         * lib/imaxdiv.c: Likewise.
3459         * lib/javacomp.c: Likewise.
3460         * lib/javaexec.c: Likewise.
3461         * lib/javaversion.c: Likewise.
3462         * lib/linebreak.c: Likewise.
3463         * lib/localcharset.c: Likewise.
3464         * lib/lock.c: Likewise.
3465         * lib/mbchar.c: Likewise.
3466         * lib/mbswidth.c: Likewise.
3467         * lib/mkdtemp.c: Likewise.
3468         * lib/pipe.c: Likewise.
3469         * lib/printf-args.c: Likewise.
3470         * lib/printf-parse.c: Likewise.
3471         * lib/progname.c: Likewise.
3472         * lib/progreloc.c: Likewise.
3473         * lib/readlink.c: Likewise.
3474         * lib/sh-quote.c: Likewise.
3475         * lib/stpcpy.c: Likewise.
3476         * lib/stpncpy.c: Likewise.
3477         * lib/strcasecmp.c: Likewise.
3478         * lib/strcasestr.c: Likewise.
3479         * lib/strcspn.c: Likewise.
3480         * lib/striconv.c: Likewise.
3481         * lib/strncasecmp.c: Likewise.
3482         * lib/strnlen1.c: Likewise.
3483         * lib/strstr.c: Likewise.
3484         * lib/strtok_r.c: Likewise.
3485         * lib/tls.c: Likewise.
3486         * lib/tmpdir.c: Likewise.
3487         * lib/unicodeio.c: Likewise.
3488         * lib/unsetenv.c: Likewise.
3489         * lib/vasnprintf.c: Likewise.
3490         * lib/vasprintf.c: Likewise.
3491         * lib/wait-process.c: Likewise.
3492         * lib/xallocsa.c: Likewise.
3493         * lib/xsetenv.c: Likewise.
3494         * lib/xstriconv.c: Likewise.
3495
3496 2006-09-13  Simon Josefsson  <jas@extundo.com>
3497
3498         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
3499         that internally, suggested by Ralf Wildenhues
3500         <Ralf.Wildenhues@gmx.de>.
3501
3502 2006-09-13  Simon Josefsson  <jas@extundo.com>
3503
3504         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
3505         @LIBOBJS@.
3506         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3507
3508 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
3509
3510         * lib/_fpending.c: Include <config.h> unconditionally, since we no
3511         longer worry about uses that don't define HAVE_CONFIG_H.
3512         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
3513         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
3514         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
3515         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
3516         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
3517         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
3518         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
3519         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
3520         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
3521         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
3522         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
3523         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
3524         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
3525         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
3526         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
3527         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
3528         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
3529         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
3530         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
3531         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
3532         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
3533         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
3534         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
3535         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
3536         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
3537         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
3538         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
3539         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
3540         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
3541         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
3542         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
3543         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
3544         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
3545         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
3546         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
3547         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
3548         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
3549         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
3550         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
3551         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
3552         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
3553         Likewise.
3554
3555 2006-09-13  Eric Blake  <ebb9@byu.net>
3556
3557         * lib/getopt.c: Fix typo in last commit.
3558
3559 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
3560
3561         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
3562         dgettext.
3563
3564 2006-09-12  Jim Meyering  <jim@meyering.net>
3565
3566         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
3567         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
3568         Reported by Nelson H. F. Beebe.
3569
3570 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
3571
3572         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
3573         program_invocation_name and program_invocation_short_name are
3574         initialized.
3575         * lib/argp-namefrob.h: Move declarations of program_invocation_name
3576         and program_invocation_short_name to argp.h, so they are visible
3577         to user programs.
3578         * lib/argp.h: Likewise
3579
3580 2006-09-10  Bruno Haible  <bruno@clisp.org>
3581
3582         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
3583         m4/inttypes_h.m4, m4/uintmax_t.m4.
3584
3585 2006-09-10  Bruno Haible  <bruno@clisp.org>
3586
3587         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
3588         gl_AC_TYPE_UINTMAX_T.
3589
3590 2006-09-10  Bruno Haible  <bruno@clisp.org>
3591
3592         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
3593
3594 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
3595
3596         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
3597         convention.  Text proposed by Bruno Haible.
3598         (struct argp_option): Document the use of N_() wrappers.
3599
3600         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
3601         '\v', and translate the two parts separately, instead of feeding
3602         the whole string to gettext.  This allows to exclude
3603         '\v' from the strings visible to the translator by writing doc
3604         strings as N_("..") "\v" N_("..").
3605
3606 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
3607
3608         * config/srclist.txt: Undo latest change; the bug was fixed.
3609
3610 2006-09-09  Bruno Haible  <bruno@clisp.org>
3611
3612         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
3613         assignments if building a library without libtool.
3614         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
3615         in func_emit_lib_Makefile_am.
3616         (func_import): When building a static library libfoo.a, arrange to
3617         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
3618         (func_create_testdir): Likewise.
3619         * modules/gc (configure.ac, Makefile.am): If building statically,
3620         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
3621         * modules/iconvme (configure.ac, Makefile.am): Likewise.
3622         * modules/striconv (configure.ac, Makefile.am): Likewise.
3623         Based on a suggestion by Ralf Wildenhues.
3624
3625 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3626
3627         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
3628         Check for unistd.h too, since Autoconf doesn't assume POSIX.
3629         Also:
3630
3631         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3632         Add year_2050_test to catch glibc bug 2821
3633         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3634
3635         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
3636         Prefer #ifdef to #if.
3637
3638         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
3639         Return from 'main' instead of calling 'exit'.
3640
3641 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3642
3643         * lib/mktime.c (guess_time_tm): Fix bug where mktime
3644         returned the maximum time_t value rather than (time_t) -1.
3645         Problem originally reported by William Bardwell
3646         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3647
3648         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3649         Moved to here ...
3650         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3651         ... from here.
3652
3653 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3654
3655         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
3656         2821 is fixed.
3657
3658 2006-09-08  Jim Meyering  <jim@meyering.net>
3659
3660         Don't make generated files read-only.  That would bother too many
3661         people.  However, do retain the ability to work when targets are
3662         read-only: remove the destination and temporary files before writing
3663         them (when generated via sed or echo), or by using the -f option for
3664         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
3665         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3666         * modules/byteswap, modules/configmake, modules/fcntl:
3667         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3668         * modules/localcharset, modules/netinet_in, modules/poll:
3669         * modules/stdbool, modules/stdint, modules/sys_select:
3670         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3671
3672 2006-09-08  Jim Meyering  <jim@meyering.net>
3673
3674         Avoid new build failure on FreeBSD 6.0.
3675         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
3676         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
3677         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
3678
3679 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3680
3681         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
3682
3683 2006-09-07  Jim Meyering  <jim@meyering.net>
3684
3685         Fix global typo in last change: use chmod u-w, not chmod u-x.
3686         Spotted by Paul Eggert and Bruce Korb.
3687         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3688         * modules/byteswap, modules/configmake, modules/fcntl:
3689         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3690         * modules/localcharset, modules/netinet_in, modules/poll:
3691         * modules/stdbool, modules/stdint, modules/sys_select:
3692         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3693
3694 2006-09-06  Jim Meyering  <jim@meyering.net>
3695
3696         Make generated files be read-only.
3697         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
3698         Ensure that each generated file is now read-only.
3699         * modules/argz: Likewise.
3700         * modules/arpa_inet: Likewise.
3701         * modules/byteswap: Likewise.
3702         * modules/configmake: Likewise.
3703         * modules/fcntl: Likewise.
3704         * modules/fnmatch: Likewise.
3705         * modules/getopt: Likewise.
3706         * modules/glob: Likewise.
3707         * modules/inttypes: Likewise.
3708         * modules/netinet_in: Likewise.
3709         * modules/poll: Likewise.
3710         * modules/stdbool: Likewise.
3711         * modules/stdint: Likewise.
3712         * modules/sys_select: Likewise.
3713         * modules/sys_socket: Likewise.
3714         * modules/sys_stat: Likewise.
3715         * modules/sysexits: Likewise.
3716         * modules/localcharset: Same as above, but continue using temporary
3717         file named "t-$@" (why different?) rather than the "$@-t" used
3718         everywhere else.
3719
3720         * modules/sysexits (Makefile.am): Replace literal occurrences
3721         of "sysexit.h" more readable, and more consistent, "$@".
3722
3723 2006-09-06  Bruno Haible  <bruno@clisp.org>
3724
3725         * modules/striconv: New file.
3726         * modules/xstriconv: New file.
3727         * MODULES.html.sh (Internationalization functions): Add striconv,
3728         xstriconv.
3729
3730 2006-09-06  Bruno Haible  <bruno@clisp.org>
3731
3732         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
3733         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
3734         not using libtool correctly.
3735
3736 2006-09-06  Bruno Haible  <bruno@clisp.org>
3737
3738         * lib/striconv.h: New file.
3739         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
3740         iconvstring.c.
3741         * lib/xstriconv.h: New file.
3742         * lib/xstriconv.c: New file.
3743
3744 2006-09-06  Bruno Haible  <bruno@clisp.org>
3745
3746         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
3747         lib_..._LDFLAGS.
3748
3749 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3750
3751         * lib/argz_.h: Sync from Libtool.
3752
3753         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
3754                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3755
3756         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
3757
3758 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3759
3760         * modules/trim: New file.
3761
3762 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3763
3764         * lib/trim.h: New file.
3765         * lib/trim.c: New file.
3766
3767 2006-09-05  Bruno Haible  <bruno@clisp.org>
3768
3769         * MODULES.html.sh (String handling): Add trim.
3770
3771 2006-09-04  Karl Berry  <karl@gnu.org>
3772
3773         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
3774         until next release.
3775
3776 2006-09-03  Bruno Haible  <bruno@clisp.org>
3777
3778         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
3779         correctly.
3780
3781 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3782
3783         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
3784         not gl_GETLOADAVG.  Omit unneeded semicolons.
3785         Problems reported by Ralf Wildenhues in
3786         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3787         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
3788         at the end, which is the usual gnulib style.
3789
3790         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
3791         of doing all the work ourselves.
3792         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
3793         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
3794
3795 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3796
3797         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
3798         Problem reported by Ralf Wildenhues in
3799         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3800
3801         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
3802         HAVE_STRUCT_STATFS_F_FSTYPENAME.
3803
3804 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3805
3806         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
3807         yesterday's patch by changing test -n to test -z.
3808
3809 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3810
3811         * modules/getloadavg (Files): Add m4/getloadavg.m4.
3812         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
3813         the former is now obsolescent.
3814
3815         * modules/chdir-long (Depends-on): Add fcntl.
3816
3817 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3818
3819         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
3820         obsolescent, and programs should use gnulib instead.
3821         * m4/getloadavg.m4: New file, with contents taken from Autoconf
3822         but with prefixes changed.
3823
3824 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3825
3826         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
3827         or stdbool.h, because they might not exist while configuring.
3828
3829         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
3830         Don't include unistd.h or limits.h; not needed, since chdir-long.h
3831         does that for us.
3832         (O_DIRECTORY): Remove.
3833
3834 2006-08-31  Eric Blake  <ebb9@byu.net>
3835
3836         * gnulib-tool: Don't let emacs change spaces to TAB.
3837
3838 2006-08-31  Bruno Haible  <bruno@clisp.org>
3839
3840         * gnulib-tool: When calling func_import more than once, do it in a
3841         subshell.
3842         Reported by Eric Blake <ebb9@byu.net>.
3843
3844 2006-08-31  Bruno Haible  <bruno@clisp.org>
3845
3846         * gnulib-tool (nl): Remove variable.
3847         (sed_transform_lib_file): Use more robust test for config-h module.
3848         (func_import): Fix typo in 2006-08-25 patch.
3849
3850 2006-08-31  Bruno Haible  <bruno@clisp.org>
3851
3852         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
3853         specified, augment Makefile.am variables instead of assigning them.
3854
3855 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3856
3857         Work around a bug in both the Linux and SunOS 64-bit kernels:
3858         nanosleep mishandles sleeps for longer than 2**31 seconds.
3859         Problem reported by Frank v Waveren in
3860         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3861         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
3862         Check for nanosleep bug.
3863         (LIB_NANOSLEEP): Append clock_gettime library if needed.
3864
3865 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3866
3867         Work around a bug in both the Linux and SunOS 64-bit kernels:
3868         nanosleep mishandles sleeps for longer than 2**31 seconds.
3869         Problem reported by Frank v Waveren in
3870         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3871         * lib/nanosleep.c (BILLION): New constant.
3872         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
3873         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
3874         implementation.
3875
3876 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3877
3878         * modules/nanosleep (Depends-on): Add gettime.
3879
3880 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3881         and Simon Josefsson  <jas@extundo.com>
3882         and Oskar Liljeblad  <oskar@osk.mine.nu>
3883
3884         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
3885         * gnulib-tool (func_import): New license type 'unmodifiable license
3886         text'.
3887         * modules/fdl: Use it.  Longer description.
3888         * module/gpl, module/lgpl: New files.
3889
3890 2006-08-30  Jim Meyering  <jim@meyering.net>
3891
3892         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
3893         shadowing the parameter.
3894
3895 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3896
3897         Sync from Libtool:
3898
3899         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3900
3901         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
3902         sharing with gnulib.  Report by Eric Blake.
3903
3904 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3905
3906         * modules/isapipe: New file.
3907         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
3908
3909 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3910
3911         * modules/configmake (Makefile.am): Add a comment, and omit
3912         the CONFIGMAKE_ prefix from generated macro names.  Suggested
3913         by Bruno Haible.
3914
3915 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3916
3917         * m4/isapipe.m4: New file.
3918
3919 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3920
3921         * lib/isapipe.c, lib/isapipe.h: New files.
3922
3923 2006-08-29  Jim Meyering  <jim@meyering.net>
3924
3925         * modules/configmake (Makefile.am): Make configmake.h depend on
3926         Makefile.  Otherwise, a stale configmake.h could hang around.
3927
3928 2006-08-29  Eric Blake  <ebb9@byu.net>
3929
3930         * lib/error.c (error_at_line, print_errno_message): Match libc, after
3931         resolution of upstream bug 3044.
3932
3933 2006-08-29  Bruno Haible  <bruno@clisp.org>
3934
3935         * modules/localcharset (Depends-on): Add configmake.
3936         (Makefile.am): Remove setting of LIBDIR through DEFS.
3937
3938 2006-08-29  Bruno Haible  <bruno@clisp.org>
3939
3940         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
3941         defined.
3942
3943 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3944
3945         * modules/fcntl: New file.
3946         * modules/chdir-safer (Depends-on): Add fcntl.
3947         * modules/fts: Likewise.
3948         * modules/mkdir-p: Likewise.
3949
3950         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
3951         This undoes the most recent change, since we're now addressing the
3952         problem in a different way.
3953
3954         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
3955         into output, since the output might be called Makefile.am even
3956         if $makefile_name is something different.
3957         (func_import): Use $makefile_am rather than
3958         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
3959         empty.
3960
3961         * modules/inttypes (Files): Add m4/inttypes-h.m4.
3962
3963 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3964
3965         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
3966         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
3967         recent change to stdint.m4, since we're now addressing the problem in a
3968         different way.
3969
3970 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3971
3972         * m4/fcntl_h.m4: New file.
3973
3974 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3975
3976         * lib/fcntl_.h: New file.
3977         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
3978         the fcntl module.
3979         * lib/dirchownmod.c: Likewise.
3980         * lib/fts.c: Likewise.
3981
3982         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
3983         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
3984         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
3985         just before including <inttypes.h>, to avoid circular inclusion.
3986
3987 2006-08-28  Jim Meyering  <jim@meyering.net>
3988
3989         * doc/visibility.texi: Actually read and correct the grammar of the
3990         sentence affected by yesterday's change.
3991
3992 2006-08-28  Eric Blake  <ebb9@byu.net>
3993
3994         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
3995         needs wrapper.
3996
3997 2006-08-28  Eric Blake  <ebb9@byu.net>
3998
3999         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
4000
4001 2006-08-28  Eric Blake  <ebb9@byu.net>
4002
4003         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
4004
4005 2006-08-28  Bruno Haible  <bruno@clisp.org>
4006
4007         * modules/c-strstr: New file, from GNU gettext.
4008         * MODULES.html.sh (String handling): Add c-strstr.
4009
4010 2006-08-28  Bruno Haible  <bruno@clisp.org>
4011
4012         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
4013         macros.
4014         Reported by Eric Blake.
4015
4016 2006-08-28  Bruno Haible  <bruno@clisp.org>
4017
4018         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
4019         (VASNPRINTF): Return a string of length > INT_MAX without failing.
4020         * lib/vasprintf.c: Include errno.h, limits.h.
4021         (EOVERFLOW): New fallback definition.
4022         (vasprintf): Test here whether the string length is > INT_MAX.
4023         * lib/vsnprintf.c: Include errno.h, limits.h.
4024         (EOVERFLOW): New fallback definition.
4025         (vsnprintf): Fix bug when generated string was too long for the buffer.
4026         Test here whether the string length is > INT_MAX.
4027
4028 2006-08-28  Bruno Haible  <bruno@clisp.org>
4029
4030         * lib/inttypes_.h (SCNX*): Remove definitions.
4031         Reported by Eric Blake.
4032
4033 2006-08-28  Bruno Haible  <bruno@clisp.org>
4034
4035         * lib/c-strstr.h: New file, from GNU gettext.
4036         * lib/c-strstr.c: New file, from GNU gettext.
4037
4038 2006-08-28  Bruno Haible  <bruno@clisp.org>
4039
4040         * gnulib-tool: Reorder some statements.
4041
4042 2006-08-28  Bruno Haible  <bruno@clisp.org>
4043
4044         * gnulib-tool: New option --makefile-name.
4045         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
4046         $makefile_name.
4047         (func_import): Write $makefile_name to the cache file, and read it from
4048         there unless explicitly specified. Use $makefile_name as file name
4049         instead of Makefile.am. Adjust the recommendations accordingly.
4050
4051 2006-08-28  Bruno Haible  <bruno@clisp.org>
4052
4053         * gnulib-tool (func_verify_module): Check against misapplying patch.
4054
4055 2006-08-28  Bruno Haible  <bruno@clisp.org>
4056
4057         * gnulib-tool (func_relativize, func_relconcat): New functions.
4058         Give an error if --local-dir is given with --update.
4059         Remove trailing slashes from $local_gnulib_dir.
4060         (func_import): Store the relativized $local_gnulib_dir in
4061         gnulib-cache.m4, and read it from there if not specified explicitly.
4062
4063 2006-08-28  Bruno Haible  <bruno@clisp.org>
4064
4065         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
4066         is the current directory. Respect also $local_gnulib_dir.
4067
4068 2006-08-28  Bruno Haible  <bruno@clisp.org>
4069             Simon Josefsson  <jas@extundo.com>
4070
4071         BeOS portability.
4072         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
4073
4074 2006-08-27  Jim Meyering  <jim@meyering.net>
4075
4076         * doc/visibility.texi: Remove duplicate word: "pointer".
4077
4078 2006-08-26  Bruno Haible  <bruno@clisp.org>
4079
4080         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
4081         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
4082         (Makefile.am): Create inttypes.h from inttypes_.h.
4083         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
4084
4085         * modules/imaxabs: New file.
4086
4087         * modules/imaxdiv: New file.
4088
4089 2006-08-26  Bruno Haible  <bruno@clisp.org>
4090
4091         * m4/inttypes.m4: New file.
4092         * m4/_inttypes_h.m4: Remove file.
4093         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
4094         PRI_MACROS_BROKEN.
4095         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
4096
4097         * m4/imaxabs.m4: New file.
4098
4099         * m4/imaxdiv.m4: New file.
4100
4101 2006-08-26  Bruno Haible  <bruno@clisp.org>
4102
4103         * lib/inttypes_.h: New file.
4104         * lib/inttypes.h: Remove file.
4105         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
4106
4107         * lib/imaxabs.c: New file.
4108
4109         * lib/imaxdiv.c: New file.
4110
4111 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4112
4113         New config-h module, so that "make" output needn't be cluttered
4114         by -DHAVE_CONFIG_H.
4115         * MODULES.html.sh (Support for building libraries and executables):
4116         Add config-h.
4117         * modules/config-h: New file.
4118         * gnulib-tool (nl, sed_transform_lib_file): New vars.
4119         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
4120         the config-h module is used.
4121
4122         New configmake module, so that "make" output needn't be cluttered
4123         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
4124         * MODULES.html.sh (Support for building libraries and executables):
4125         Add configmake.
4126         * modules/configmake: New file.
4127
4128 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4129
4130         * m4/config-h.m4: New file.
4131
4132 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4133
4134         * config/srclist.txt: Add elisp-comp.
4135
4136 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4137
4138         * MODULES.html.sh (Support for building libraries and executables):
4139         Add elisp-comp.
4140         * build-aux/elisp-comp: New file.
4141         * modules/elisp-comp: New file.
4142
4143 2006-08-24  Bruno Haible  <bruno@clisp.org>
4144
4145         * gnulib-tool (func_create_testdir): Use non-default values of
4146         sourcebase and m4base.
4147
4148 2006-08-24  Bruno Haible  <bruno@clisp.org>
4149
4150         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
4151         HTML structure.
4152
4153 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
4154
4155         * modules/openat (Depends-on): Add lchown.
4156
4157 2006-08-23  Bruno Haible  <bruno@clisp.org>
4158
4159         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
4160         of gl_LOCK_EARLY instead of gl_LOCK.
4161
4162 2006-08-23  Bruno Haible  <bruno@clisp.org>
4163
4164         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
4165         on OSF/1 to no.
4166         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
4167
4168 2006-08-23  Bruno Haible  <bruno@clisp.org>
4169
4170         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
4171         as unusable.
4172
4173         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
4174         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
4175         (gl_LOCK): New macro.
4176
4177 2006-08-22  Simon Josefsson  <jas@extundo.com>
4178
4179         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
4180         to md5 module.
4181
4182 2006-08-22  Simon Josefsson  <jas@extundo.com>
4183
4184         * MODULES.html.sh: Add "Support for maintaining and release
4185         projects".
4186
4187         * build-aux/gnupload: New file, from coreutils.
4188
4189 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4190
4191         Avoid the need for AC_LIBSOURCES in m4 macros.
4192         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
4193         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
4194         * modules/check-version (EXTRA_DIST): Add check-version.h.
4195         * modules/crc (EXTRA_DIST): Add crc.h.
4196         * modules/des (EXTRA_DIST): Add des.h.
4197         * modules/gc (EXTRA_DIST): Add gc.h.
4198         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
4199         * modules/getline (EXTRA_DIST): Add getline.h.
4200         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
4201         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
4202         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
4203         * modules/md2 (EXTRA_DIST): Add md2.h.
4204         * modules/md4 (EXTRA_DIST): Add md4.h.
4205         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
4206         * modules/read-file (EXTRA_DIST): Add read-file.h.
4207         * modules/readline (EXTRA_DIST): Add readline.h.
4208         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
4209         rijndael-api-fst.h.
4210
4211 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4212
4213         * m4/rijndael.m4 (gl_ARCFOUR):
4214         * m4/arctwo.m4 (gl_ARCTWO):
4215         * m4/check-version.m4 (gl_CHECK_VERSION):
4216         * m4/crc.m4 (gl_CRC):
4217         * m4/des.m4 (gl_DES):
4218         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
4219         * m4/gc.m4 (gl_GC):
4220         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
4221         * m4/getline.m4 (gl_FUNC_GETLINE):
4222         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
4223         * m4/hmac-md5.m4 (gl_HMAC_MD5):
4224         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
4225         * m4/md2.m4 (gl_MD2):
4226         * m4/md4.m4 (gl_MD4):
4227         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
4228         * m4/read-file.m4 (gl_FUNC_READ_FILE):
4229         * m4/readline.m4 (gl_FUNC_READLINE):
4230         * m4/rijndael.m4 (gl_RIJNDAEL):
4231         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4232         to get the necessary .h files and whatnot.
4233
4234 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4235
4236         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
4237         gnulib rather than the other way around.
4238         * config/srclistvars.sh (COREUTILS): Remove.
4239
4240 2006-08-22  Jim Meyering  <jim@meyering.net>
4241
4242         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
4243
4244         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
4245
4246 2006-08-22  Eric Blake  <ebb9@byu.net>
4247
4248         * modules/regexprops-generic: New file.
4249         * MODULES.html.sh (Support for building documentation): List it.
4250
4251 2006-08-22  Eric Blake  <ebb9@byu.net>
4252
4253         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
4254         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
4255         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
4256         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
4257
4258 2006-08-22  Bruno Haible  <bruno@clisp.org>
4259
4260         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
4261         and lib_LTLIBRARIES like the other lib_* variables.
4262
4263 2006-08-22  Bruno Haible  <bruno@clisp.org>
4264
4265         * build-aux/x-to-1.in: New file, from GNU gettext.
4266
4267 2006-08-22  Bruno Haible  <bruno@clisp.org>
4268
4269         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
4270         <utmpx.h> exists.
4271
4272 2006-08-22  Bruno Haible  <bruno@clisp.org>
4273
4274         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
4275         <utmpx.h> exists.
4276
4277 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4278
4279         BeOS portability.
4280         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
4281         exist.
4282         Problem reported by Bruno Haible.
4283
4284 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4285
4286         Avoid the need for AC_LIBSOURCES in m4 macros.
4287         * modules/acl (EXTRA_DIST): Add acl.h.
4288         * modules/argmatch (Files): Add m4/argmatch.m4.
4289         (configure.ac): Add gl_ARGMATCH.
4290         (EXTRA_DIST): Renamed from lib_SOURCES, for
4291         consistency with the other modules.  Remove argmatch.c.
4292         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
4293         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
4294         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
4295         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
4296         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
4297         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
4298         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
4299         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
4300         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
4301         * modules/closeout (EXTRA_DIST): Add closeout.h.
4302         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
4303         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
4304         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
4305         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
4306         dirname.h; remove basename.c and stripslash.c.
4307         * modules/exclude (EXTRA_DIST): Add exclude.h.
4308         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
4309         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
4310         * modules/file-type (EXTRA_DIST): Add file-type.h.
4311         * modules/filemode (EXTRA_DIST): Add filemode.h.
4312         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
4313         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4314         * modules/fpending (EXTRA_DIST): Add __fpending.h.
4315         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
4316         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
4317         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
4318         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
4319         * modules/getdate (EXTRA_DIST): Add getdate.c.
4320         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
4321         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
4322         * modules/getpass (EXTRA_DIST): Add getpass.h.
4323         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
4324         * modules/group-member (EXTRA_DIST): Add group-member.h.
4325         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
4326         * modules/hash (EXTRA_DIST): Add hash.h.
4327         * modules/human (EXTRA_DIST): Add human.h.
4328         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
4329         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
4330         * modules/lchown (EXTRA_DIST): Add lchown.h.
4331         * modules/long-options (EXTRA_DIST): Add long-options.h.
4332         * modules/lstat (EXTRA_DIST): Add lstat.h.
4333         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
4334         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
4335         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
4336         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
4337         * modules/memxor (EXTRA_DIST): Add memxor.h.
4338         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
4339         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
4340         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
4341         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
4342         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
4343         * modules/physmem (EXTRA_DIST): Add physmem.h.
4344         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
4345         * modules/posixver (EXTRA_DIST): Add posixver.h.
4346         * modules/quote (EXTRA_DIST): Add quote.h.
4347         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
4348         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
4349         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
4350         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
4351         regex_internal.h regexec.c.
4352         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
4353         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
4354         * modules/same (EXTRA_DIST): Add same.h.
4355         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
4356         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
4357         * modules/savedir (EXTRA_DIST): Add savedir.h.
4358         * modules/sha1 (EXTRA_DIST): Add sha1.h.
4359         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
4360         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
4361         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
4362         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
4363         * modules/strdup (EXTRA_DIST): Add strdup.h.
4364         * modules/strftime (EXTRA_DIST): Add strftime.h.
4365         * modules/strndup (EXTRA_DIST): Add strndup.h.
4366         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
4367         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
4368         * modules/time_r (EXTRA_DIST): Add time_r.h.
4369         * modules/timespec (EXTRA_DIST): Add timespec.h.
4370         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4371         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
4372         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
4373         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
4374         * modules/userspec (EXTRA_DIST): Add userspec.h.
4375         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
4376         * modules/utimens (EXTRA_DIST): Add utimens.h.
4377         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
4378         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
4379         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
4380         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
4381         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
4382         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
4383         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
4384         * modules/yesno (EXTRA_DIST): Add yesno.h.
4385
4386 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4387
4388         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
4389
4390         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
4391         * m4/dev-ino.m4, same-inode.m4: Remove.
4392
4393         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
4394         * m4/acl.m4 (AC_FUNC_ACL):
4395         * m4/backupfile.m4 (gl_BACKUPFILE):
4396         * m4/c-strtod.m4 (gl_C99_STRTOLD):
4397         * m4/canon-host.m4 (gl_CANON_HOST):
4398         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4399         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
4400         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
4401         * m4/cloexec.m4 (gl_CLOEXEC):
4402         * m4/close-stream.m4 (gl_CLOSE_STREAM):
4403         * m4/closeout.m4 (gl_CLOSEOUT):
4404         * m4/dirfd.m4 (gl_FUNC_DIRFD):
4405         * m4/dirname.m4 (gl_DIRNAME):
4406         * m4/exclude.m4 (gl_EXCLUDE):
4407         * m4/exitfail.m4 (gl_EXITFAIL):
4408         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
4409         * m4/file-type.m4 (gl_FILE_TYPE):
4410         * m4/filemode.m4 (gl_FILEMODE):
4411         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
4412         * m4/fpending.m4 (gl_FUNC_FPENDING):
4413         * m4/fprintftime.m4 (gl_FPRINTFTIME):
4414         * m4/fts.m4 (gl_FUNC_FTS):
4415         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
4416         * m4/getdate.m4 (gl_GETDATE):
4417         * m4/gethrxtime.m4 (gl_GETHRXTIME):
4418         * m4/getpagesize.m4 (gl_GETPAGESIZE):
4419         * m4/getpass.m4 (gl_FUNC_GETPASS):
4420         * m4/gettime.m4 (gl_GETTIME):
4421         * m4/getugroups.m4 (gl_GETUGROUPS):
4422         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
4423         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
4424         * m4/hard-locale.m4 (gl_HARD_LOCALE):
4425         * m4/hash.m4 (gl_HASH):
4426         * m4/idcache.m4 (gl_IDCACHE):
4427         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
4428         * m4/lchown.m4 (gl_FUNC_LCHOWN):
4429         * m4/long-options.m4 (gl_LONG_OPTIONS):
4430         * m4/lstat.m4 (gl_FUNC_LSTAT):
4431         * m4/md5.m4 (gl_MD5):
4432         * m4/memcasecmp.m4 (gl_MEMCASECMP):
4433         * m4/memcoll.m4 (gl_MEMCOLL):
4434         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
4435         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
4436         * m4/memxor.m4 (gl_MEMXOR):
4437         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
4438         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
4439         * m4/modechange.m4 (gl_MODECHANGE):
4440         * m4/mountlist.m4 (gl_MOUNTLIST):
4441         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4442         * m4/openat.m4 (gl_FUNC_OPENAT):
4443         * m4/pathmax.m4 (gl_PATHMAX):
4444         * m4/physmem.m4 (gl_PHYSMEM):
4445         * m4/posixtm.m4 (gl_POSIXTM):
4446         * m4/posixver.m4 (gl_POSIXVER):
4447         * m4/quote.m4 (gl_QUOTE):
4448         * m4/quotearg.m4 (gl_QUOTEARG):
4449         * m4/readtokens.m4 (gl_READTOKENS):
4450         * m4/readutmp.m4 (gl_READUTMP):
4451         * m4/regex.m4 (gl_REGEX):
4452         * m4/safe-read.m4 (gl_SAFE_READ):
4453         * m4/safe-write.m4 (gl_SAFE_WRITE):
4454         * m4/same.m4 (gl_SAME):
4455         * m4/save-cwd.m4 (gl_SAVE_CWD):
4456         * m4/savedir.m4 (gl_SAVEDIR):
4457         * m4/settime.m4 (gl_SETTIME):
4458         * m4/sha1.m4 (gl_SHA1):
4459         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
4460         * m4/stat-macros.m4 (gl_STAT_MACROS):
4461         * m4/stat-time.m4 (gl_STAT_TIME):
4462         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
4463         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
4464         * m4/strdup.m4 (gl_FUNC_STRDUP):
4465         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
4466         * m4/strndup.m4 (gl_FUNC_STRNDUP):
4467         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
4468         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
4469         * m4/time_r.m4 (gl_TIME_R):
4470         * m4/timespec.m4 (gl_TIMESPEC):
4471         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
4472         * m4/unlinkdir.m4 (gl_UNLINKDIR):
4473         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
4474         * m4/userspec.m4 (gl_USERSPEC):
4475         * m4/utimecmp.m4 (gl_UTIMECMP):
4476         * m4/utimens.m4 (gl_UTIMENS):
4477         * m4/xalloc.m4 (gl_XALLOC):
4478         * m4/xgetcwd.m4 (gl_XGETCWD):
4479         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
4480         * m4/xreadlink.m4 (gl_XREADLINK):
4481         * m4/xstrtod.m4 (gl_XSTRTOD):
4482         * m4/yesno.m4 (gl_YESNO):
4483         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4484         to get the necessary .h files and whatnot.
4485
4486 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
4487             Bruno Haible  <bruno@clisp.org>
4488
4489         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
4490         /bin/sh understanding of '!' conditional negation.
4491
4492 2006-08-21  Jim Meyering  <jim@meyering.net>
4493
4494         * modules/openat (Depends-on): Really alphabetize.
4495
4496         * modules/acl (Depends-on): Add error and quote.
4497
4498         * check-module (find_included_lib_files): Add at-func.c to the
4499         ok-to-include-more-than-once white list.
4500
4501         * modules/openat (Depends-on): Add lstat.  Alphabetize.
4502
4503 2006-08-21  Bruno Haible  <bruno@clisp.org>
4504
4505         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4506         Emit a pkgdata_DATA variable only if some snippets add contents to it.
4507         Reported by Martin Lambers <marlam@marlam.de>.
4508
4509 2006-08-21  Bruno Haible  <bruno@clisp.org>
4510
4511         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
4512         specify an installation location, don't emit a noinst_LIBRARIES or
4513         noinst_LTLIBRARIES assignment.
4514
4515 2006-08-21  Bruno Haible  <bruno@clisp.org>
4516
4517         BeOS portability.
4518         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
4519         BeOS has mbrtowc() but no <wctype.h>.
4520
4521 2006-08-21  Bruno Haible  <bruno@clisp.org>
4522
4523         BeOS portability.
4524         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
4525         exist.
4526
4527 2006-08-21  Bruno Haible  <bruno@clisp.org>
4528
4529         BeOS portability.
4530         * lib/mbchar.h: Include <wctype.h> only if it exists.
4531
4532 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4533
4534         Remove files that are no longer needed by their respective modules.
4535         * m4/obstack.m4: Remove.
4536         * m4/strerror_r.m4: Remove.
4537         * m4/uint32_t.m4: Remove.
4538         * m4/uintptr_t.m4: Remove.
4539         * m4/ullong_max.m4: Remove.
4540         * m4/xstrtoimax.m4: Remove.
4541         * m4/xstrtoumax.m4: Remove.
4542
4543         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
4544         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
4545         dependencies now capture this.
4546
4547         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
4548         Do not use AC_LIBSOURCES, since gnulib modules now do this.
4549         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
4550         * m4/human.m4 (gl_HUMAN): Likewise.
4551         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
4552         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
4553
4554         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
4555
4556         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
4557         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
4558         stdint.
4559         * m4/human.m4 (gl_HUMAN): Likewise.
4560         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
4561         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
4562         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4563         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4564         * m4/xstrtol (gl_XSTRTOL): Likewise.
4565
4566         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
4567         AC_TYPE_LONG_LONG_INT.
4568         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4569         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
4570         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
4571         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4572
4573         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
4574         on stdbool.
4575
4576         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
4577         (gl_PREREQ_XSTRTOUL): Remove.
4578
4579         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
4580
4581         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
4582         mode.
4583
4584 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4585
4586         Add and change modules to make it easier for coreutils to use
4587         gnulib-tool.
4588         * modules/backupfile (Files): Remove m4/d-ino.m4.
4589         (Depends-on): Add d-ino.
4590         * modules/cycle-check (Depends-on): Add stdint.
4591         (lib_SOURCES): Add cycle-check.h.
4592         * modules/d-ino: New module.
4593         * modules/d-type: New module.
4594         * modules/error (Files): Remove m4/strerror_r.m4.
4595         * modules/filemode (Files): Add m4/st_dm_mode.m4.
4596         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4597         m4/inttypes_h.m4, m4/uintmax_t.m4.
4598         (Depends-on): Add stdint.
4599         (lib_SOURCES): Add fsusage.h.
4600         * modules/getcwd (Files): Remove d-ino.m4.
4601         (Depends-on): Add d-ino.
4602         * modules/getndelim2 (Depends-on): Add stdint.
4603         * modules/glob (Files): Remove m4/d-type.m4.
4604         (Depends-on): Add d-type.
4605         * modules/host-os: New module.
4606         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
4607         m4/inttypes_h.m4, m4/uintmax_t.m4.
4608         * Depends-on: Add stdint.
4609         (lib_SOURCES): Add human.h.
4610         * modules/inttostr (Files): Remove m4/intmax_t.m4,
4611         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
4612         m4/uintmax_t.m4, m4/ulonglong.m4.
4613         (Depends-on): Add stdint.
4614         (EXTRA_DIST): Add inttostr.h.
4615         * modules/lchmod: New module.
4616         * modules/link-follow: New module.
4617         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
4618         (Depends-on): Add lchmod.
4619         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
4620         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
4621         (Depends-on): Add stdint.
4622         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
4623         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
4624         (Depends-on): Add stdint.
4625         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
4626         * modules/perl: New module.
4627         * modules/regex (Depends-on): Add stdint.
4628         * modules/rmdir-errno: New module.
4629         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4630         m4/intmax_t.m4.
4631         (Depends-on): Add stdint.
4632         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4633         m4/uintmax_t.m4.
4634         (Depends-on): Add stdint.
4635         * modules/unlink-busy: New module.
4636         * modules/utimecmp (Depends-on): Add stdint.
4637         * modules/uptime: New module.
4638         * modules/winsz-ioctl: New module.
4639         * modules/winsz-termios: New module.
4640         * modules/xnanosleep (Depends-on): Add nanosleep.
4641         * modules/ullong_max: Remove.
4642         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
4643         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
4644         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
4645         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
4646         (Depends-on): Add inttypes.
4647         (lib_SOURCES): Add xstrtol.h.
4648         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
4649         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
4650         * MODULES.html.sh: Move 'assert' into the assert section.
4651         Move 'dummy' into the linking section.
4652         Remove ullong_max.
4653         Add section for compatibility checks for POSIX:2001 functions,
4654         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
4655         winsz-ioctl, and winsz-termios into it.
4656         Add lchmod.
4657         Add top-level Misc section and put host-os, perl, and uptime
4658         into it.
4659
4660 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4661
4662         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
4663         now assume the stdint module.  Do not include inttypes.h.
4664         * lib/fsusage.h: Likewise.
4665         * lib/getndelim2.c: Likewise.
4666         * lib/human.h: Likewise.
4667         * lib/inttostr.h: Likewise.
4668         * lib/obstack.c: Likewise.
4669         * lib/regex_internal.h: Likewise.
4670         * lib/tempname.c: Likewise.
4671         * lib/utimecmp.c: Likewise.
4672         * lib/xstrtol.h: Likewise.
4673
4674         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
4675
4676         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
4677         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
4678         * lib/xtime.h: Likewise.
4679
4680 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4681
4682         * modules/openat (Files): Add lib/fchmodat.c.
4683         Fixes problem reported by Jay Youngman.
4684
4685 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4686
4687         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
4688         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
4689
4690 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
4691             Bruno Haible  <bruno@clisp.org>
4692
4693         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
4694         and is a script that invokes bison. Tighten the code. Add comments.
4695
4696 2006-08-18  Jim Meyering  <jim@meyering.net>
4697
4698         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
4699         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
4700         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
4701         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
4702
4703 2006-08-18  Bruno Haible  <bruno@clisp.org>
4704
4705         * modules/bison-i18n: New file.
4706         * MODULES.html.sh (Internationalization functions): Add it.
4707
4708 2006-08-18  Bruno Haible  <bruno@clisp.org>
4709
4710         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
4711         sys/statvfs.h. When getmntinfo was found, check its declaration and
4712         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
4713
4714 2006-08-18  Bruno Haible  <bruno@clisp.org>
4715
4716         * m4/bison-i18n.m4: New file, from bison.
4717
4718 2006-08-18  Bruno Haible  <bruno@clisp.org>
4719
4720         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
4721         (ME_DUMMY): Treat "kernfs" as a dummy.
4722         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
4723
4724 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4725
4726         Update from coreutils.
4727
4728         2006-08-15  Jim Meyering  <jim@meyering.net>
4729
4730         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
4731
4732         2006-01-17  Jim Meyering  <jim@meyering.net>
4733
4734         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
4735
4736         2006-01-11  Jim Meyering  <jim@meyering.net>
4737
4738         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
4739         Check for the lchmod function.
4740
4741 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4742
4743         Update from coreutils.
4744
4745         * lib/__fpending.h: Add copyright notice.
4746         * lib/fprintftime.h: Likewise.
4747         * lib/savedir.c: Use (C) in copyright notice.
4748         * lib/savedir.h: Likewise.
4749
4750         2006-08-15  Jim Meyering  <jim@meyering.net>
4751
4752         * lib/at-func.c: New file, with the logic of all emulated at-functions.
4753         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
4754         in support of the EXPECTED_ERRNO macro.
4755         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
4756         definitions.  Instead, define the appropriate symbols and include
4757         "at-func.c".
4758         * lib/mkdirat.c (mkdirat): Likewise.
4759         * lib/fchmodat.c (fchmodat): Likewise.
4760         (ENOSYS): Remove definition.
4761         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
4762         it.  Don't include "unistd--.h" -- it wasn't ever used.
4763
4764         2006-01-17  Jim Meyering  <jim@meyering.net>
4765
4766         Rewrite fts.c not to change the current working directory,
4767         by using openat, fstatat, fdopendir, etc..
4768
4769         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
4770         (HAVE_OPENAT_SUPPORT): Define.
4771         [_LIBC] (fchdir): Don't undef or define; no longer used.
4772         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
4773         Now, this `function' always succeeds, and consumes its file descriptor
4774         parameter -- so callers must not close such FDs.  Update callers.
4775         (diropen_fd, opendirat, cwd_advance_fd): New functions.
4776         (diropen): Add parameter, SP.  Adjust all callers.
4777         Implement using diropen_fd, rather than open.
4778         (fts_open): Initialize new member, fts_cwd_fd.
4779         Remove fts_rft-setting code.
4780         (fts_close): Close fts_cwd_fd, if necessary.
4781         (__opendir2): Define in terms of opendir or opendirat,
4782         depending on whether the FST_NOCHDIR flag is set.
4783         (fts_build): Since fts_safe_changedir consumes its FD, and since
4784         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
4785         and close the dup'd file descriptor upon failure.
4786         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
4787         (fts_safe_changedir): Tweak semantics to reflect that this function
4788         now calls cwd_advance_fd and hence consumes its FD argument.
4789         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
4790         [struct FTS] (fts_rft): Remove now-unused member.
4791         [struct FTS] (fts_cycle.state): Improve comment.
4792
4793         * lib/openat.c (openat_needs_fchdir): New function.
4794         * lib/openat.h (openat_needs_fchdir): Declare it.
4795
4796 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
4797
4798         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
4799         Problem and fix reported by Pádraig Brady in
4800         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
4801
4802 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4803
4804         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
4805
4806 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4807
4808         * lib/memcoll.c (memcoll): Optimize for the common case where the
4809         arguments are bytewise equal.
4810
4811 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4812
4813         * doc/regexprops-generic.texi: Add a copyright notice.
4814
4815 2006-08-15  Bruno Haible  <bruno@clisp.org>
4816
4817         * modules/tmpdir (License): Change to LGPL.
4818
4819 2006-08-15  Bruno Haible  <bruno@clisp.org>
4820
4821         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
4822         module.
4823
4824 2006-08-14  Simon Josefsson  <jas@extundo.com>
4825
4826         * config/srclist.txt: Add gnupload.
4827
4828 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4829
4830         Change copyright notice from LGPL 2 to GPL 2, since that's the
4831         standard form used in the gnulib repository.
4832         * tests/test-lock.c: Likewise.
4833         * tests/test-stdint.c: Likewise.
4834         * tests/test-tls.c: Likewise.
4835
4836         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
4837         prelude-manager.  User shorter URLs for GNU projects, without '?'.
4838         Add copyright notice.
4839
4840         * check-module: Add copyright notice.  Output a copyright
4841         notice if "--version" is specified.
4842         * modules/COPYING: New file.
4843         * tests/test-getaddrinfo.c: Add copyright notice.
4844         * tests/test-verify.c: Likewise.
4845
4846 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4847
4848         Change copyright notice from LGPL 2 to GPL 2, since that's the
4849         standard form used in the gnulib repository.
4850         * lib/lock.c: LGPL -> GPL.
4851         * lib/lock.h: Likewise.
4852         * lib/strnlen1.c: Likewise.
4853         * lib/strnlen1.h: Likewise.
4854         * lib/tls.c: Likewise.
4855         * lib/tls.h: Likewise.
4856         * lib/tmpdir.c: Likewise.
4857
4858         * lib/TODO: Remove; this belongs only in coreutils.
4859
4860 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4861
4862         Add copyright notices to long-enough files that lack them, since
4863         otherwise the files aren't clearly free.  Use the same notice that
4864         getdate.texi already uses.
4865         * doc/alloca-opt.texi: Add copyright notice.
4866         * doc/alloca.texi: Likewise.
4867         * doc/ctime.texi: Likewise.
4868         * doc/functions.texi: Likewise.
4869         * doc/gcd.texi: Likewise.
4870         * doc/gnulib-tool.texi: Likewise.
4871         * doc/inet_ntoa.texi: Likewise.
4872         * doc/visibility.texi: Likewise.
4873
4874         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
4875         * doc/quote.texi: Add copyright notice.
4876
4877         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
4878         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
4879         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
4880         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
4881         is now obsolete, and give a pointer to the Sun list.
4882         Add copyright notice.
4883
4884 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4885
4886         * config/srclistvars.sh: Add copyright notice.
4887
4888 2006-08-14  Eric Blake  <ebb9@byu.net>
4889
4890         Import the following change from libc:
4891
4892         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
4893
4894         Upstream bug 2997.
4895         * lib/misc/error.c: Add space between program name and message if file
4896         name is missing.
4897
4898 2006-08-12  Karl Berry  <karl@gnu.org>
4899
4900         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
4901         remove, these originate in gnulib now.
4902
4903 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4904
4905         * doc/Makefile (standards.info standards.html standards.dvi):
4906         Also depend on make-stds.texi.
4907
4908 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
4909
4910         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
4911         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
4912
4913         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
4914         in wchar_t.  Problem reported by Eric Blake.
4915
4916         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
4917         LEN is smaller than SIZE.  Suggested by Bruno Haible.
4918         Also, help the compiler to keep LEN in a register.
4919
4920 2006-08-11  Eric Blake  <ebb9@byu.net>
4921
4922         * users.txt: Sort.  Add tar.
4923
4924 2006-08-11  Bruno Haible  <bruno@clisp.org>
4925
4926         * users.txt: New file.
4927
4928 2006-08-11  Bruno Haible  <bruno@clisp.org>
4929
4930         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
4931         before <wchar.h>. Needed for OSF/1 and BSD/OS.
4932
4933 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
4934
4935         * modules/snprintf (Depends-on): Remove minmax.
4936         (Maintainer): Add self and Bruno.
4937
4938 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
4939
4940         * lib/.cppi-disable: Add snprintf.h, socket_.h.
4941         * lib/snprintf.c: Include <errno.h> and <limits.h>.
4942         (EOVERFLOW): Define if the system does not.
4943         Do not include "minmax.h"; it wasn't used.
4944         (snprintf): Don't assume size_t promotes to an unsigned type.
4945         Fix bug when generated string was too long for the buffer: the
4946         buffer's contents are supposed to be the initial prefix of the
4947         output.  Don't assume vasnprintf returns EOVERFLOW if the size
4948         exceeds INT_MAX; do the check ourselves.
4949
4950         Import the following changes from libc:
4951
4952         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
4953
4954         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
4955         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
4956         set wc to the byte which couldn't be converted.
4957         (re_string_reconstruct): Don't clear valid_raw_len before calling
4958         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
4959         tip_context using re_string_context_at.
4960
4961         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
4962
4963         * lib/posix/regex.h: g++ still cannot handled [restrict].
4964
4965         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
4966
4967         * lib/posix/regex.h: Remove special handling for VMS.
4968
4969 2006-08-10  Jim Meyering  <jim@meyering.net>
4970
4971         * modules/same-inode: New module.
4972         * modules/dev-ino: New module.
4973         * modules/cycle-check: Depend on these modules, rather than simply
4974         including their .h files.
4975         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
4976         required via m4/cycle-check.m4.
4977         * modules/same: Depend on new same-inode module, rather than
4978         including same-inode.h.
4979         * modules/chdir-safer: New file.
4980
4981         * modules/chown (Depends-on): Add stat-macros.
4982
4983 2006-08-10  Jim Meyering  <jim@meyering.net>
4984
4985         * m4/cycle-check.m4: New file.
4986         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
4987         * m4/dev-ino.m4, m4/same-inode.m4: New files.
4988
4989 2006-08-10  Eric Blake  <ebb9@byu.net>
4990
4991         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
4992         in from original proposal.
4993
4994 2006-08-10  Eric Blake  <ebb9@byu.net>
4995         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
4996
4997         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
4998         namespace.
4999
5000 2006-08-10  Bruno Haible  <bruno@clisp.org>
5001
5002         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
5003         as well.
5004
5005 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5006
5007         Sync from coreutils.
5008
5009         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
5010
5011         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
5012         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
5013
5014 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5015
5016         * modules/restrict: Remove; no longer needed now that we assume
5017         Autoconf 2.59 or later.
5018         * MODULES.html.sh: Remove 'restrict'.
5019         * modules/argp (Depends-on): Remove 'restrict'.
5020         * modules/base64 (Depends-on): Likewise.
5021         * modules/gc (Depends-on): Likewise.
5022         * modules/getaddrinfo (Depends-on): Likewise.
5023         * modules/glob (Depends-on): Likewise.
5024         * modules/inet_ntop (Depends-on): Likewise.
5025         * modules/inet_pton (Depends-on): Likewise.
5026         * modules/memxor (Depends-on): Likewise.
5027         * modules/regex (Depends-on): Likewise.
5028         * modules/strtok_r (Depends-on): Likewise.
5029         * modules/time_r (Depends-on): Likewise.
5030
5031 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5032
5033         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
5034         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
5035         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5036         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
5037         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
5038         * m4/memxor.m4 (gl_MEMXOR): Likewise.
5039         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
5040         gl_C_RESTRICT replaced by AC_C_RESTRICT.
5041
5042         Merge from coreutils.
5043         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
5044         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
5045         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
5046         * m4/time_r.m4 (gl_TIME_R): Likewise.
5047
5048 2006-08-09  Karl Berry  <karl@gnu.org>
5049
5050         * config/srclist.txt: no more gettext-tools, per Bruno.
5051
5052 2006-08-08  Eric Blake  <ebb9@byu.net>
5053
5054         * modules/verror: New module.
5055         * MODULES.html.sh: Document it.
5056
5057 2006-08-08  Eric Blake  <ebb9@byu.net>
5058
5059         * lib/verror.h, lib/verror.c: New files.
5060
5061 2006-08-08  Eric Blake  <ebb9@byu.net>
5062
5063         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
5064         verror_at_line output complies with GNU Coding Standards even when
5065         file is NULL.
5066
5067 2006-08-07  Bruno Haible  <bruno@clisp.org>
5068
5069         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
5070         versions of AIX.
5071         Reported by Ralf Wildenhues.
5072
5073 2006-08-07  Bruno Haible  <bruno@clisp.org>
5074
5075         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
5076         in an AC_DEFUN. Needed so that the autoconf snippets can use
5077         AC_REQUIRE.
5078
5079 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5080
5081         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5082         Initialize pkgdata_DATA.
5083         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
5084         overriding it.
5085
5086 2006-08-06  Eric Blake  <ebb9@byu.net>
5087
5088         * lib/error.h: Fold in some upstream changes from glibc.
5089         * lib/error.c: Likewise.
5090
5091 2006-08-04  Bruno Haible  <bruno@clisp.org>
5092
5093         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5094         Make the mostlyclean-local rule depend on mostlyclean-generic.
5095         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
5096
5097 2006-07-31  Bruno Haible  <bruno@clisp.org>
5098
5099         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
5100         <stdlib.h>, <string.h>.
5101
5102 2006-07-30  Bruno Haible  <bruno@clisp.org>
5103
5104         * modules/readlink (License): Change to LGPL.
5105
5106 2006-07-30  Bruno Haible  <bruno@clisp.org>
5107
5108         * modules/javaversion (Makefile.am): Distribute javaversion.java and
5109         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
5110         set PKGDATADIR to point to it.
5111
5112 2006-07-30  Bruno Haible  <bruno@clisp.org>
5113
5114         * modules/csharpexec (configure.ac): Comment out macro invocation.
5115         * modules/javaexec (configure.ac): Likewise.
5116         * modules/javacomp-script (configure.ac): Likewise.
5117
5118         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
5119
5120 2006-07-30  Bruno Haible  <bruno@clisp.org>
5121
5122         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
5123         linked-list.
5124
5125 2006-07-30  Bruno Haible  <bruno@clisp.org>
5126
5127         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
5128
5129 2006-07-30  Bruno Haible  <bruno@clisp.org>
5130
5131         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5132         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
5133         get removed.
5134
5135 2006-07-29  Bruno Haible  <bruno@clisp.org>
5136
5137         Make it possible for gnulib-tool to work with locally modified or
5138         augmented gnulib repositories.
5139         * gnulib-tool (func_usage): Document --local-dir option.
5140         (local_gnulib_dir): New variable.
5141         Handle --local-dir option.
5142         (func_lookup_file): New function.
5143         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
5144         (func_get_description, func_get_filelist, func_get_description,
5145         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
5146         func_get_automake_snippet, func_get_include_directive,
5147         func_get_license, func_get_maintainer): Use func_lookup_file.
5148         (func_import, func_create_testdir): Use func_lookup_file.
5149
5150 2006-07-29  Bruno Haible  <bruno@clisp.org>
5151
5152         * modules/setenv (Depends-on): Add unistd.
5153
5154 2006-07-29  Bruno Haible  <bruno@clisp.org>
5155
5156         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
5157
5158 2006-07-29  Bruno Haible  <bruno@clisp.org>
5159
5160         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
5161
5162 2006-07-29  Bruno Haible  <bruno@clisp.org>
5163
5164         * gnulib-tool (import, update): If there is no Makefile.am, look at
5165         aclocal.m4, instead of bailing out.
5166
5167 2006-07-29  Bruno Haible  <bruno@clisp.org>
5168
5169         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
5170         Categorize the options by when they are useful.
5171
5172 2006-07-29  Bruno Haible  <bruno@clisp.org>
5173
5174         * gnulib-tool (func_usage): Document option --no-libtool.
5175         Handle option --no-libtool.
5176         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
5177         for changed semantics of $libtool variable.
5178         (func_import): Likewise. If libtool is not used, show this through
5179         an option --no-libtool.
5180         (func_create_testdir): Update.
5181
5182 2006-07-29  Bruno Haible  <bruno@clisp.org>
5183
5184         * gnulib-tool (func_import): Extend error message about missing
5185         --doc-base.
5186
5187 2006-07-29  Bruno Haible  <bruno@clisp.org>
5188
5189         * gnulib-tool (func_import): Don't create the $docbase directory if
5190         there is no file to store there.
5191
5192 2006-07-29  Bruno Haible  <bruno@clisp.org>
5193
5194         * gnulib-tool (autoconf_minversion): If a --dir option is given and
5195         relevant, look for configure.ac there, not in the current directory.
5196         Also use a simple search for AC_PREREQ, not "autoconf --trace".
5197
5198 2006-07-29  Bruno Haible  <bruno@clisp.org>
5199
5200         * gnulib-tool (SORT): New variable.
5201         (func_usage): Undocument --assume-autoconf option.
5202         Remove --assume-autoconf option handling.
5203         (autoconf_minversion): Determine from the contents of configure.ac.
5204         (func_import): Remove autoconf_minversion handling.
5205         Suggested by Eric Blake.
5206
5207 2006-07-29  Bruno Haible  <bruno@clisp.org>
5208
5209         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
5210
5211 2006-07-29  Bruno Haible  <bruno@clisp.org>
5212
5213         * config/srclist.txt (*setenv.[ch]): Remove rules.
5214
5215 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5216
5217         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
5218
5219 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5220
5221         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
5222         arpa/inet.h.
5223
5224 2006-07-28  Simon Josefsson  <jas@extundo.com>
5225
5226         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
5227         * modules/inet_pton (Depends-on): Likewise.
5228
5229 2006-07-28  Simon Josefsson  <jas@extundo.com>
5230
5231         * m4/netinet_in_h.m4: New file.
5232
5233 2006-07-28  Simon Josefsson  <jas@extundo.com>
5234
5235         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
5236         #include's.
5237
5238 2006-07-28  Simon Josefsson  <jas@extundo.com>
5239
5240         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
5241         #include's.
5242
5243 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
5244
5245         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
5246         setgid on directories only if they set these bits.
5247         * lib/modechange.h: Remove obsolete comment about masks.
5248
5249 2006-07-28  Eric Blake  <ebb9@byu.net>
5250
5251         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
5252         macro expansion.
5253
5254 2006-07-28  Bruno Haible  <bruno@clisp.org>
5255
5256         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
5257
5258 2006-07-28  Bruno Haible  <bruno@clisp.org>
5259
5260         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
5261
5262 2006-07-28  Bruno Haible  <bruno@clisp.org>
5263
5264         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
5265         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
5266         Define fallbacks.
5267         Avoids link error on FreeBSD 4.x.
5268         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
5269
5270         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
5271         encoding.
5272         * lib/mbswidth.c (iswcntrl): Likewise.
5273
5274 2006-07-27  Bruno Haible  <bruno@clisp.org>
5275
5276         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
5277         test.
5278
5279 2006-07-27  Bruno Haible  <bruno@clisp.org>
5280
5281         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
5282         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
5283         defined.
5284
5285 2006-07-26  Eric Blake  <ebb9@byu.net>
5286
5287         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
5288
5289 2006-07-26  Eric Blake  <ebb9@byu.net>
5290
5291         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
5292         like mingw that lack mkstemp.
5293         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
5294         avoid compilation warning on mingw.
5295
5296 2006-07-26  Bruno Haible  <bruno@clisp.org>
5297
5298         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
5299         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
5300         INT_FAST*_MIN, INTPTR_MIN.
5301
5302 2006-07-25  Bruno Haible  <bruno@clisp.org>
5303
5304         * modules/version-etc (Depends-on): Add stdarg.
5305
5306 2006-07-25  Bruno Haible  <bruno@clisp.org>
5307
5308         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
5309         complex commands.
5310
5311 2006-07-25  Bruno Haible  <bruno@clisp.org>
5312
5313         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
5314         defined in <stdarg.h> or config.h.
5315
5316 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5317
5318         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
5319         (gl_STDIO_SAFER): Remove.
5320
5321 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5322
5323         * MODULES.html.sh (File stream based Input/Output):
5324         Add fopen-safer, tmpfile-safer; remove stdio-safer.
5325         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
5326         * modules/fopen-safer, modules/tmpfile-safer: New files.
5327         * modules/stdio-safer: Remove.
5328
5329 2006-07-24  Bruno Haible  <bruno@clisp.org>
5330
5331         * modules/tmpdir: New file.
5332         * MODULES.html.sh (File system functions): Add it.
5333
5334 2006-07-24  Bruno Haible  <bruno@clisp.org>
5335
5336         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
5337         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
5338
5339 2006-07-24  Bruno Haible  <bruno@clisp.org>
5340
5341         * modules/clean-temp: New file.
5342
5343 2006-07-24  Bruno Haible  <bruno@clisp.org>
5344
5345         * m4/tmpdir.m4: New file, from GNU gettext.
5346
5347 2006-07-24  Bruno Haible  <bruno@clisp.org>
5348
5349         * lib/tmpdir.h: New file, from GNU gettext.
5350         * lib/tmpdir.c: New file, from GNU gettext.
5351
5352 2006-07-24  Bruno Haible  <bruno@clisp.org>
5353
5354         * lib/clean-temp.h: New file, from GNU gettext.
5355         * lib/clean-temp.c: New file, from GNU gettext.
5356
5357 2006-07-23  Eric Blake  <ebb9@byu.net>
5358
5359         * modules/stdio-safer (Files): Add tmpfile-safer.c.
5360         (Depends-on): Add binary-io.
5361
5362 2006-07-23  Eric Blake  <ebb9@byu.net>
5363
5364         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
5365
5366 2006-07-23  Eric Blake  <ebb9@byu.net>
5367
5368         * lib/tmpfile-safer.c: New file.
5369         * lib/stdio-safer.h (fopen_safer): Add prototype.
5370         * lib/stdio--.h (tmpfile): Make safer.
5371
5372 2006-07-23  Bruno Haible  <bruno@clisp.org>
5373
5374         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
5375         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
5376         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
5377         gl_linked_remove_at): Use it.
5378
5379 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5380         and Simon Josefsson <jas@extundo.com>
5381
5382         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
5383
5384         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
5385
5386 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5387
5388         * modules/close-stream: New file.
5389         * modules/closeout (Description): Make it clear that it exits
5390         with a diagnostic on error.
5391         (Depends-on): Add close-stream.  Remove fpending, stdbool.
5392         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
5393
5394 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5395
5396         * m4/close-stream.m4: New file.
5397
5398 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5399
5400         * lib/close-stream.c, lib/close-stream.h: New files.
5401
5402 2006-07-22  Bruno Haible  <bruno@clisp.org>
5403
5404         Merge from GNU gettext 0.15.
5405
5406         2006-05-01  Bruno Haible  <bruno@clisp.org>
5407
5408                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
5409
5410         2006-07-22  Bruno Haible  <bruno@clisp.org>
5411
5412                 * modules/javaversion: New file.
5413                 * MODULES.html.sh (Java): Add javaversion.
5414
5415         2006-03-12  Bruno Haible  <bruno@clisp.org>
5416
5417                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
5418
5419         2005-12-04  Bruno Haible  <bruno@clisp.org>
5420
5421                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
5422                 (untested).
5423
5424         2006-06-21  Bruno Haible  <bruno@clisp.org>
5425
5426                 Avoid warnings from recent versions of mcs.
5427                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
5428                 -o, -L, -r any more. Use options documented since mcs-1.0
5429                 instead. Similarly for -g.
5430
5431         2005-12-04  Bruno Haible  <bruno@clisp.org>
5432
5433                 * build-aux/csharpcomp.sh.in: Suffix for resources is
5434                 .resources, not .resource.
5435
5436         2005-07-09  Bruno Haible  <bruno@clisp.org>
5437
5438                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
5439                 add a .dll suffix.
5440                 Reported by Mark Junker <mjscod@gmx.de>.
5441
5442         2006-07-22  Bruno Haible  <bruno@clisp.org>
5443
5444                 * modules/gettext: Upgrade to gettext-0.15.
5445                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
5446                 m4/visibility.m4.
5447                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
5448
5449 2006-07-22  Bruno Haible  <bruno@clisp.org>
5450
5451         Merge from GNU gettext 0.15.
5452
5453         2006-03-25  Bruno Haible  <bruno@clisp.org>
5454
5455                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
5456
5457         2006-07-21  Bruno Haible  <bruno@clisp.org>
5458
5459                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
5460                 "1.1".
5461
5462         2006-05-09  Bruno Haible  <bruno@clisp.org>
5463
5464                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
5465                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
5466                 for the conftestver execution.
5467
5468         2006-05-01  Bruno Haible  <bruno@clisp.org>
5469
5470                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
5471                 optional target-version argument. Verify that the compiler
5472                 groks source of the specified source-version, or add -source
5473                 option as necessary. Verify that the compiler produces
5474                 bytecode in the specified target-version, or add -target and
5475                 -source options as necessary. Make the result of the test
5476                 available as variable CONF_JAVAC. Also log error output in
5477                 config.log.
5478
5479         2006-03-11  Bruno Haible  <bruno@clisp.org>
5480
5481                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
5482
5483         2006-05-09  Bruno Haible  <bruno@clisp.org>
5484
5485                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
5486                 CLASSPATH_SEPARATOR to a semicolon.
5487
5488         2006-03-12  Bruno Haible  <bruno@clisp.org>
5489
5490                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
5491                 available as variable CONF_JAVA, for subsequent autoconf
5492                 tests. Also log error output in config.log.
5493
5494         2006-07-19  Bruno Haible  <bruno@clisp.org>
5495
5496                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
5497                 that getline works on glibc2 systems. Needed to avoid trouble
5498                 in relocatable.c.
5499                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
5500
5501         2005-12-04  Bruno Haible  <bruno@clisp.org>
5502
5503                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
5504                 launcher (untested).
5505
5506         2005-12-04  Bruno Haible  <bruno@clisp.org>
5507
5508                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
5509
5510         2006-07-22  Bruno Haible  <bruno@clisp.org>
5511
5512                 * gettext.m4: Update from GNU gettext-0.15.
5513                 * nls.m4: Likewise.
5514                 * po.m4: Likewise.
5515                 * inttypes-pri.m4: Likewise.
5516                 * inttypes-h.m4: Renamed from inttypes.m4.
5517                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
5518
5519 2006-07-22  Bruno Haible  <bruno@clisp.org>
5520
5521         Merge from GNU gettext 0.15.
5522
5523         2005-07-05  Bruno Haible  <bruno@clisp.org>
5524
5525                 * printf-args.c (printf_fetchargs): Work around broken
5526                 definition of wint_t on mingw.
5527
5528         2005-02-12  Bruno Haible  <bruno@clisp.org>
5529
5530                 * xallocsa.h: Add extern "C" for C++.
5531
5532         2006-05-17  Bruno Haible  <bruno@clisp.org>
5533
5534                 Cygwin portability.
5535                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
5536
5537         2006-04-30  Bruno Haible  <bruno@clisp.org>
5538
5539                 * progreloc.c: Include <mach-o/dyld.h> if available.
5540                 (find_executable): Use _NSGetExecutablePath when possible.
5541
5542         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5543
5544                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
5545                 function.
5546
5547         2005-12-29  Bruno Haible  <bruno@clisp.org>
5548
5549                 * progreloc.c (set_program_name_and_installdir): Fix
5550                 compilation error.
5551
5552         2005-12-04  Bruno Haible  <bruno@clisp.org>
5553
5554                 Cygwin portability.
5555                 * progreloc.c: Include <windows.h> also on Cygwin.
5556                 (find_executable): Add support for Cygwin.
5557                 (set_program_name_and_installdir): Handle also platforms with
5558                 nonempty EXEEXT.
5559
5560         2006-07-11  Bruno Haible  <bruno@clisp.org>
5561
5562                 * javacomp.c: Fix a comment.
5563                 Reported by Jim Meyering.
5564
5565         2006-04-30  Bruno Haible  <bruno@clisp.org>
5566
5567                 * javacomp.h (compile_java_class): Add source_version,
5568                 target_version arguments.
5569                 * javacomp.c: Rewritten to choose only a compiler that
5570                 respects the specified source_version and target_version.
5571
5572         2006-06-27  Bruno Haible  <bruno@clisp.org>
5573
5574                 Assume correct S_ISDIR macro.
5575                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
5576
5577         2006-07-22  Bruno Haible  <bruno@clisp.org>
5578
5579                 * javaversion.h: New file, from GNU gettext.
5580                 * javaversion.c: New file, from GNU gettext.
5581                 * javaversion.java: New file, from GNU gettext.
5582                 * javaversion.class: New file, from GNU gettext.
5583
5584         2006-05-17  Bruno Haible  <bruno@clisp.org>
5585
5586                 Cygwin portability.
5587                 * javaexec.c (execute_java_class): Test for jview program
5588                 also on Cygwin.
5589
5590         2006-04-09  Bruno Haible  <bruno@clisp.org>
5591
5592                 * fatal-signal.c: Don't include string.h.
5593                 (at_fatal_signal): Use a copying loop instead of memcpy.
5594
5595         2005-12-04  Bruno Haible  <bruno@clisp.org>
5596
5597                 * csharpexec.c: Add support for 'clix' launcher (untested).
5598                 (execute_csharp_using_sscli): New function.
5599                 (execute_csharp_program): Call it.
5600
5601         2006-06-21  Bruno Haible  <bruno@clisp.org>
5602
5603                 Avoid warnings from recent versions of mcs.
5604                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
5605                 -o, -L, -r any more. Use options documented since mcs-1.0
5606                 instead. Similarly for -g.
5607
5608         2005-07-09  Bruno Haible  <bruno@clisp.org>
5609
5610                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
5611                 add a .dll suffix.
5612                 Reported by Mark Junker <mjscod@gmx.de>.
5613
5614         2006-06-17  Bruno Haible  <bruno@clisp.org>
5615
5616                 * config.charset: Update for NetBSD 3.0.
5617
5618         2006-05-17  Bruno Haible  <bruno@clisp.org>
5619
5620                 Cygwin portability.
5621                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
5622
5623         2006-05-16  Bruno Haible  <bruno@clisp.org>
5624
5625                 * localcharset.c [CYGWIN]: Include <windows.h>.
5626                 (get_charset_aliases): For Cygwin, return the same CPxxx
5627                 aliases list as under WIN32.
5628                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
5629                 the environment variables. Fall back to GetACP().
5630
5631         2006-04-05  Bruno Haible  <bruno@clisp.org>
5632
5633                 * config.charset: Update Juan Manuel Guerrero's address.
5634
5635         2005-02-12  Bruno Haible  <bruno@clisp.org>
5636
5637                 * allocsa.h: Add extern "C" for C++.
5638
5639         2005-02-10  Bruno Haible  <bruno@clisp.org>
5640
5641                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
5642                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
5643
5644         2006-07-22  Bruno Haible  <bruno@clisp.org>
5645
5646                 * gettext.h: Update to GNU gettext-0.15.
5647
5648 2006-07-22  Bruno Haible  <bruno@clisp.org>
5649
5650         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
5651         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
5652         lib-prefix.m4, longdouble.m4, ssize_t.m4.
5653
5654 2006-07-21  Eric Blake  <ebb9@byu.net>
5655
5656         * modules/stdlib-safer: New file.
5657         * MODULES.html.sh (File stream based Input/Output): Add
5658         stdlib-safer.
5659
5660 2006-07-21  Eric Blake  <ebb9@byu.net>
5661
5662         * lib/stdlib-safer.h: New file from coreutils, required by
5663         stdlib--.h.
5664
5665 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
5666
5667         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
5668
5669 2006-07-20  Bruno Haible  <bruno@clisp.org>
5670
5671         * gnulib-tool: Recognize new option --assume-autoconf.
5672         (autoconf_minversion): New variable.
5673         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
5674
5675 2006-07-20  Bruno Haible  <bruno@clisp.org>
5676
5677         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
5678
5679 2006-07-19  Derek R. Price  <derek@ximbiot.com>
5680
5681         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
5682         Reindent and repaginate.
5683
5684 2006-07-19  Derek Price  <derek@ximbiot.com>
5685
5686         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
5687         Correct grammar.
5688
5689 2006-07-17  Bruno Haible  <bruno@clisp.org>
5690
5691         * modules/list: New file.
5692         * modules/array-list: New file.
5693         * modules/carray-list, modules/carray-list-tests: New files.
5694         * modules/linked-list, modules/linked-list-tests: New files.
5695         * modules/avltree-list, modules/avltree-list-tests: New files.
5696         * modules/rbtree-list, modules/rbtree-list-tests: New files.
5697         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
5698         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
5699         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
5700         * modules/oset: New file.
5701         * modules/array-oset: New file.
5702         * modules/avltree-oset, modules/avltree-oset-tests: New files.
5703         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
5704         * tests/test-carray_list.c: New file.
5705         * tests/test-linked_list.c: New file.
5706         * tests/test-avltree_list.c: New file.
5707         * tests/test-rbtree_list.c: New file.
5708         * tests/test-linkedhash_list.c: New file.
5709         * tests/test-avltreehash_list.c: New file.
5710         * tests/test-rbtreehash_list.c: New file.
5711         * tests/test-avltree_oset.c: New file.
5712         * tests/test-rbtree_oset.c: New file.
5713         * MODULES.html.sh (Container data structures): New section.
5714
5715 2006-07-17  Bruno Haible  <bruno@clisp.org>
5716
5717         * m4/gl_list.m4: New file.
5718
5719 2006-07-17  Bruno Haible  <bruno@clisp.org>
5720
5721         * lib/gl_list.h: New file.
5722         * lib/gl_list.c: New file.
5723         * lib/gl_array_list.h: New file.
5724         * lib/gl_array_list.c: New file.
5725         * lib/gl_carray_list.h: New file.
5726         * lib/gl_carray_list.c: New file.
5727         * lib/gl_linked_list.h: New file.
5728         * lib/gl_linked_list.c: New file.
5729         * lib/gl_anylinked_list1.h: New file.
5730         * lib/gl_anylinked_list2.h: New file.
5731         * lib/gl_avltree_list.h: New file.
5732         * lib/gl_avltree_list.c: New file.
5733         * lib/gl_anyavltree_list1.h: New file.
5734         * lib/gl_anyavltree_list2.h: New file.
5735         * lib/gl_rbtree_list.h: New file.
5736         * lib/gl_rbtree_list.c: New file.
5737         * lib/gl_anyrbtree_list1.h: New file.
5738         * lib/gl_anyrbtree_list2.h: New file.
5739         * lib/gl_anytree_list1.h: New file.
5740         * lib/gl_anytree_list2.h: New file.
5741         * lib/gl_linkedhash_list.h: New file.
5742         * lib/gl_linkedhash_list.c: New file.
5743         * lib/gl_anyhash_list1.h: New file.
5744         * lib/gl_anyhash_list2.h: New file.
5745         * lib/gl_avltreehash_list.h: New file.
5746         * lib/gl_avltreehash_list.c: New file.
5747         * lib/gl_rbtreehash_list.h: New file.
5748         * lib/gl_rbtreehash_list.c: New file.
5749         * lib/gl_anytreehash_list1.h: New file.
5750         * lib/gl_anytreehash_list2.h: New file.
5751
5752         * lib/gl_oset.h: New file.
5753         * lib/gl_oset.c: New file.
5754         * lib/gl_array_oset.h: New file.
5755         * lib/gl_array_oset.c: New file.
5756         * lib/gl_avltree_oset.h: New file.
5757         * lib/gl_avltree_oset.c: New file.
5758         * lib/gl_rbtree_oset.h: New file.
5759         * lib/gl_rbtree_oset.c: New file.
5760         * lib/gl_anytree_oset.h: New file.
5761
5762 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5763
5764         * m4/mkancesdirs.m4: New file.
5765         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
5766         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
5767         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
5768         it.
5769
5770 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5771
5772         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
5773         * lib/mkancesdirs.h: New files.
5774         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
5775         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
5776         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
5777         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
5778         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
5779         callers changed.  Revamp internals significantly, by not
5780         attempting to create directories that are temporarily more
5781         permissive than the final results.  Do not attempt to use
5782         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
5783         This removes some race conditions, fixes some bugs, and simplifies
5784         things.  Use new dirchownmod function to do owner and mode changes.
5785         * lib/mkdir-p.h: Likewise.
5786         * lib/modechange.c (octal_to_mode): New function.
5787         (struct mode_change): New member mentioned.
5788         (make_node_op_equals): New arg mentioned.  All callers changed.
5789         (mode_compile): Keep track of which mode bits the user has explicitly
5790         mentioned.
5791         (mode_adjust): New arg DIR, so that we implement the X op correctly.
5792         New arg PMODE_BITS, to keep track of which mode bits the user
5793         mentioned; it treats S_ISUID and S_ISGID speciall.
5794         All callers changed.
5795         * lib/modechange.h: Likewise.
5796
5797 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5798
5799         * MODULES.html.sh: Add mkancestors.
5800         * modules/mkancesdirs: New module.
5801         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
5802         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
5803         The chdir-safer and afs files are now orphans; I'll remove them
5804         unless someone speaks up.
5805         Add lib/dirchownmod.c, lib/dirchownmod.h.
5806         (Depends-on): Remove alloca, chown, save-cwd, dirname.
5807         Add lchown, mkancesdirs.
5808         (Maintainer): Add self.
5809
5810 2006-07-15  Karl Berry  <karl@gnu.org>
5811
5812         * gnulib-tool: help message wording/arrangement.
5813
5814 2006-07-14  Simon Josefsson  <jas@extundo.com>
5815
5816         * doc/gnulib.texi (Libtool and Windows): New section.
5817
5818 2006-07-12  Simon Josefsson  <jas@extundo.com>
5819
5820         * modules/gendocs (License): Fix license, approved by Karl.
5821
5822 2006-07-12  Eric Blake  <ebb9@byu.net>
5823
5824         * MODULES.html.sh: Add gendocs.
5825
5826 2006-07-11  Eric Blake  <ebb9@byu.net>
5827
5828         * modules/fdl: New module, to install doc/fdl.texi.
5829         * MODULES.html.sh: Add new section for documentation modules.
5830         * gnulib-tool: Avoid space-tab.
5831         (--doc-base): New option, to manage files from doc.
5832
5833 2006-07-11  Eric Blake  <ebb9@byu.net>
5834
5835         * m4/absolute-header.m4: Fix comments to match recent change.
5836
5837 2006-07-11  Eric Blake  <ebb9@byu.net>
5838
5839         * gnulib-tool: List --doc-base before --tests-base.
5840
5841 2006-07-11  Derek R. Price  <derek@ximbiot.com>
5842
5843         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
5844
5845 2006-07-11  Bruno Haible  <bruno@clisp.org>
5846
5847         * README: Mention where to put documentation.
5848
5849 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5850
5851         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
5852
5853 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5854
5855         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
5856         to stdint.m4.
5857
5858 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5859
5860         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
5861         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
5862         "no/such/file/stdint.h" when there is no such file, so that
5863         the resulting C code can be parsed by dodgy compilers.
5864         Problems reported by Bob Proulx.
5865
5866 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5867
5868         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
5869         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5870         macros into the GNU _D_EXACT_NAMLEN.
5871         * lib/savedir.c:  Likewise.
5872         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
5873
5874 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5875         and Paul Eggert  <eggert@cs.ucla.edu>
5876
5877         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
5878         * m4/savedir.m4:
5879         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5880         macros into the GNU _D_EXACT_NAMLEN.
5881
5882 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5883
5884         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
5885         around the absolute name, to work around a problem with the HP-UX
5886         11.23 native C compiler, reported by Bob Proulx.
5887
5888 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5889
5890         * doc/maintain.texi, make-stds.texi: Sync from
5891         <http://savannah.gnu.org/projects/gnustandards>.
5892
5893 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5894
5895         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
5896
5897 2006-07-09  Jim Meyering  <jim@meyering.net>
5898
5899         * m4/glob.m4: Remove a doubled word in a comment.
5900
5901 2006-07-09  Jim Meyering  <jim@meyering.net>
5902
5903         * lib/argp-pv.c: Remove a doubled word in a comment.
5904         * lib/check-version.c (check_version): Likewise.
5905         * lib/javacomp.c (compile_java_class): Likewise.
5906
5907 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
5908
5909         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
5910         for the benefit of people using Autoconf 2.60.  If you want to
5911         support older Autoconf versions you can copy m4/onceonly_2_57.m4
5912         (or m4/onceonly.m4, if pre-2.57) manually.
5913
5914 2006-07-08  Jim Meyering  <jim@meyering.net>
5915
5916         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
5917         comment.
5918         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
5919         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
5920         comment.
5921
5922 2006-07-08  Jim Meyering  <jim@meyering.net>
5923
5924         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
5925
5926 2006-07-07  Simon Josefsson  <jas@extundo.com>
5927
5928         * tests/test-crc.c: Change expected crc value, the test vector
5929         were probably computed using the old broken crc.c?
5930
5931 2006-07-06  Simon Josefsson  <jas@extundo.com>
5932
5933         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
5934         now the canonical place for the M4 file).
5935
5936         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
5937         from the sys_socket dependency now.
5938
5939         * modules/inet_pton (Files): Ditto.
5940
5941         * modules/inet_ntop (Files): Ditto.
5942
5943 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
5944
5945         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
5946         not gl_PREREQ_GETUSERSHELL.
5947
5948 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5949
5950         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
5951         with only one argument, for Autoconf 2.60.
5952         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
5953         expand to nothing, so add a shell command to avoid syntax error.
5954         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
5955
5956 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5957
5958         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
5959
5960 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5961
5962         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
5963         no longer needed.  Check for isblank decl.
5964         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
5965         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
5966         of existence.
5967
5968 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5969
5970         * lib/getloadavg.c: Use __VMS, not VMS.
5971         * lib/getopt.c: Likewise.
5972         * lib/getpagesize.h: Likewise.
5973         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
5974         and probably does not work.
5975
5976 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5977
5978         * lib/.cppi-disable: Add wcwidth.
5979         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
5980         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
5981         (ISGRAPH): Remove.  All uses changed to isgraph.
5982         (FOLD) [!defined _LIBC]: Remove special case.
5983         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
5984         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
5985         HAVE_ISBLANK.
5986         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
5987         case.
5988
5989 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
5990
5991         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
5992         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
5993         brackets.  Other minor changes to suppress some compiler
5994         warnings.
5995
5996 2006-07-06  Derek R. Price  <derek@ximbiot.com>
5997         and Paul Eggert  <eggert@cs.ucla.edu>
5998
5999         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
6000         of invoking obsolescent AC_HEADER_DIRENT macro.
6001         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
6002         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
6003         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
6004         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
6005         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
6006         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
6007         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
6008         * m4/readdir.m4: Remove; no longer needed.
6009
6010 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6011         and Paul Eggert  <eggert@cs.ucla.edu>
6012
6013         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
6014         Don't worry about this obsolete case any more.
6015         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
6016         directories.
6017         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
6018         worry about this obsolete case any more.
6019         * lib/fts.c: Likewise.
6020         * lib/getcwd.c: Likewise.
6021         * lib/glob.h: Likewise.
6022         * lib/savedir.c: Likewise.
6023
6024 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6025
6026         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
6027         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
6028         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
6029         needed.
6030         All uses removed.
6031         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6032         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6033         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
6034         needed.
6035         * m4/getdate.m4 (gl_GETDATE): Likewise.
6036         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6037         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6038         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6039         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6040         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6041         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6042         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
6043         needed.
6044
6045 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6046
6047         * lib/memcasecmp.c: Include <limits.h>.
6048         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
6049         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
6050         Don't assume isdigit succeeds only on '0' through '9'.
6051
6052 2006-07-05  Eric Blake  <ebb9@byu.net>
6053
6054         * modules/getaddrinfo (Depends-on): Add snprintf.
6055
6056 2006-07-05  Eric Blake  <ebb9@byu.net>
6057
6058         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
6059         to avoid 'header present but could not be compiled' on cygwin.
6060
6061 2006-07-05  Eric Blake  <ebb9@byu.net>
6062
6063         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
6064         missing from netdb.h.
6065         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
6066
6067 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6068
6069         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
6070         no longer needed.
6071         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
6072         * m4/getdate.m4 (gl_GETDATE): Likewise.
6073         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6074         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6075         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6076         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6077         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6078
6079 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6080
6081         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
6082         All uses of is_space replaced by isspace.
6083         * lib/exit.h: Don't talk about STDC_HEADERS.
6084         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
6085         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
6086         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
6087         replaced by isprint etc.
6088         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
6089         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6090         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
6091         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
6092         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
6093         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6094
6095 2006-07-05  Bruno Haible  <bruno@clisp.org>
6096
6097         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
6098         the function exists, before testing against AIX.
6099         Reported by Martin Lambers <marlam@marlam.de>.
6100
6101 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6102
6103         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
6104         From Mark D. Baushke.
6105
6106 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6107
6108         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
6109         to the absolute name, not just one, to bypass Sun C 5.8's
6110         "warning: #include of /usr/include/... may be non-portable".
6111
6112 2006-07-04  Eric Blake  <ebb9@byu.net>
6113
6114         * modules/dirname-tests: New test module.
6115         * tests/test-dirname.c: New file, replacing dirname.c
6116         TEST_DIRNAME section that was recently deleted.
6117
6118 2006-07-04  Bruno Haible  <bruno@clisp.org>
6119
6120         Assume ANSI C header files and <ctype.h> functions.
6121         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
6122         (mbsnwidth): Use isprint, iscntrl instead.
6123
6124 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6125
6126         Merge from coreutils.
6127         * MODULES.html.sh: Add xstrtold.
6128         * modules/xstrtold: New file.
6129         * modules/cycle-check (Files): Add lib/same-inode.h.
6130         * modules/dirname (Files): Add m4/double-slash-root.m4.
6131         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
6132         * modules/mkdir-p (Files): Add lib/same-inode.h.
6133         * modules/same (Files): Add lib/same-inode.h.
6134
6135 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6136
6137         * m4/absolute-header.m4: Renamed from full-header-path.m4.
6138         This is to keep the terminology clean; POSIX talks about
6139         "absolute pathnames", not "full pathnames", but the GNU
6140         Coding Standards say to use "path" for something else;
6141         so use "absolute" to keep both sides happy.
6142         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
6143         Set gl_absolute_header, not gl_full_header_path.
6144         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
6145         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
6146         All uses changed.
6147
6148         Merge from coreutils.
6149
6150         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6151
6152         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
6153         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
6154         want to require the building of c-strtod.o.
6155         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
6156         needs -lm directly.
6157         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
6158
6159         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6160
6161         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
6162         --as-needed option if available.  Problem reported by Albert Chin in
6163         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
6164         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
6165         cc merely issues a bunch of annoying warnings for --as-needed
6166         (this problem was reported by Bob Proulx).  Also, try linking with
6167         -lm to detect a bug in binutils 2.16 (this problem was reported
6168         by Ralf Wildenhues).
6169
6170         2006-06-18  Jim Meyering  <jim@meyering.net>
6171
6172         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
6173         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
6174         macro.
6175         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
6176         also check for glibc-2.4's abort-inducing bug.
6177
6178         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
6179         Low-probability clean-up should be to use rmdir to get rid of
6180         the just-created directory, not unlink.
6181
6182         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
6183         configure fail, and request a bug report to inform us about it.
6184         Add a comment that, barring reports to the contrary, in 2007 we'll
6185         assume ftruncate is universally available.
6186
6187         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6188
6189         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
6190
6191         2006-03-12  Jim Meyering  <jim@meyering.net>
6192
6193         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
6194         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
6195         * m4/same.m4 (gl_SAME): Likewise.
6196         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
6197
6198         2006-03-11  Eric Blake  <ebb9@byu.net>
6199
6200         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
6201         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
6202         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
6203         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
6204
6205 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6206
6207         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
6208         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
6209         reported by Mark D. Baushke, one in
6210         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
6211
6212         Merge from coreutils.
6213
6214         * lib/.cppi-disable: Add stdint_.h.
6215         * lib/.cvsignore: Add stdint.h.
6216
6217         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6218
6219         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
6220         both double and long double versions.
6221         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
6222         * lib/xstrtold.c: New file.
6223         * lib/xstrtod.h (xstrtold): New decl.
6224
6225         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
6226
6227         * lib/filemode.c (setst): Remove.
6228         (strmode): Rewrite to avoid setst.  This makes the code shorter,
6229         (arguably) clearer, and the generated code is a bit smaller on my
6230         Debian GNU/Linux stable x86 host.
6231
6232         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6233
6234         * lib/filemode.c: Include "filemode.h" first, to test the interface.
6235         Assume that filemode.h includes sys/types.h and sys/stat.h.
6236         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
6237         (ftypelet): Reorder to put common cases first, for efficiency.
6238         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
6239         to do 'M'.
6240         (strmode): Renamed from mode_string, and now stores 12 bytes instead
6241         of 10, for compatibility with FreeBSD.  All callers changed.
6242         (filemodestring): Now stores 12 bytes instead of 10, and sets file
6243         types that can't be deduced solely from st_mode.  First arg is now a
6244         const pointer.
6245         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
6246         (strmode): Renamed from mode_string.
6247         (filemodestring): New decl.
6248         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
6249         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
6250         needed.
6251         (S_ISPORT, S_ISWHT): New macros, if not already defined.
6252
6253         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
6254
6255         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
6256         fsusage.h now does that.  Include fsusage.h first, to test interface.
6257         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
6258         at most one method (the old code could have generated decls that
6259         didn't conform to C89, not that this was ever exercised).
6260         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
6261
6262         2006-03-19  Jim Meyering  <jim@meyering.net>
6263
6264         Work even in a chroot where d_ino values for entries in "/"
6265         don't match the stat.st_ino values for the same names.
6266         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
6267         number, iterate through all entries again, using lstat instead.
6268         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
6269         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
6270
6271         * lib/getcwd.c (__getcwd): Clarify a comment.
6272         Use memcpy in place of a call to strcpy.
6273
6274         2006-03-12  Jim Meyering  <jim@meyering.net>
6275
6276         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
6277         matches that of the current directory (which we're about to chdir ".."
6278         out of), then save the dev-ino of the parent, instead.
6279
6280         * lib/same-inode.h (SAME_INODE): New file/macro.
6281         * lib/chdir-safer.c (SAME_INODE): Remove definition.
6282         Include "same-inode.h", instead.
6283         * lib/same.c: Likewise.
6284         * lib/cycle-check.h: Include "same-inode.h".
6285         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
6286         * lib/cycle-check.c (SAME_INODE): Remove definition.
6287         * lib/root-dev-ino.h: Include "same-inode.h".
6288
6289         2006-03-11  Eric Blake  <ebb9@byu.net>
6290
6291         * lib/same.c (same_name): s/base_name/last_component/
6292         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
6293         * lib/filenamecat.c (file_name_concat): Likewise.
6294
6295         2006-03-11  Eric Blake  <ebb9@byu.net>,
6296                     Paul Eggert  <eggert@cs.ucla.edu>
6297
6298         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
6299         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
6300         drive prefix.
6301         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
6302         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
6303         (last_component): New method.
6304         * lib/dirname.c (dir_len): Determine when drive letters need a
6305         subsequent slash.  Preserve // when it is special.
6306         (dir_name): Don't append dot when drive letter is absolute.
6307         [TEST_DIRNAME]: Move into a full-blown gnulib test.
6308         * lib/basename.c (base_name): New semantics - malloc the result.
6309         Preserve // when it is special.  Preserve relative files that look
6310         like drive letters.
6311         (base_len): Preserve // when it is special.
6312         (last_component): New method, similar to old base_name semantics.
6313         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
6314         base_name.  Strip redundant slashes from ///.
6315
6316 2006-07-03  Jim Meyering  <jim@meyering.net>
6317
6318         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
6319         macro is used before the first cycle_check call.
6320
6321 2006-07-03  Eric Blake  <ebb9@byu.net>
6322
6323         * modules/dirname (Depends-on): Add xstrndup.
6324
6325 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6326
6327         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
6328         test cases, so that config.log is a bit easier to follow.
6329
6330 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6331
6332         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
6333         both are 64 bits, since this seems to be the tradition, and this
6334         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
6335         we ever run into a host that prefers long long to long in this
6336         case, we'll need another configure-time test.  Problem reported by
6337         Jim Meyering.
6338
6339 2006-07-02  Eric Blake  <ebb9@byu.net>
6340
6341         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
6342
6343 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6344
6345         * modules/inttypes (Depends-on): No longer depends on stdint.
6346         * modules/stdint (Description): Say more about assumptions.
6347         Say that the fast types might differ.  Say macros are used.
6348         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
6349         (Makefile.am): Revise list of substituted symbols to match
6350         new stdint.m4.
6351         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
6352         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
6353         * tests/test-stdint.c (verify_same_types)
6354         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
6355         the code conforms to C99/C89.
6356         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
6357         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
6358
6359 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6360
6361         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
6362         but fix a bug, by requiring at least 64 bits.
6363         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
6364         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
6365         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
6366         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
6367
6368         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
6369         changes.  Make 2.59 a prerequisite.  Check and substitute for
6370         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
6371         inttypes.h.  Do not use special include files; just use the
6372         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
6373         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
6374         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
6375         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
6376         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
6377         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
6378         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
6379         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
6380         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
6381         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
6382         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
6383         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
6384         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
6385         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
6386         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
6387         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
6388         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
6389         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
6390         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
6391         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
6392         WINT_MAX.  Check for C99 conformance more strictly, by detecting
6393         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
6394         not check for things that C99 does not require, e.g., int8_t.  If
6395         a test isn't needed unless <stdint.h> isn't working, and is
6396         unlikely to be needed for any other reason, then don't do it
6397         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
6398         size_t, since we assume C89 freestanding at least.  Do not check
6399         for sig_atomic_t, wchar_t, or wint_t, since the code now does
6400         the right thing even if the types are not defined.  Instead use:
6401         (gl_STDINT_TYPE_PROPERTIES): New macro.
6402         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
6403         testing whether <sys/types.h> clashes, as Autoconf does this for
6404         us now.  All uses removed.
6405         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
6406         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
6407         (gl_CHECK_TYPE_SAME):
6408         Remove; no longer needed.
6409         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
6410         exists, since we'll return 0 anyway in that case.
6411         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
6412
6413 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6414
6415         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
6416         possible collision with system files.
6417         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
6418         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
6419         WCHAR_MIN and WCHAR_MAX in this case.
6420         (<stddef.h>): Do not include; no longer needed.
6421         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
6422         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
6423         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
6424         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
6425         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
6426         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
6427         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
6428         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
6429         !defined(__c99))]: Include in this case too, since it's harmless
6430         now.
6431         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
6432         dangerous to do so.
6433         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
6434         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
6435         (_STDINT_MIN, _STDINT_MAX): New macros.
6436         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
6437         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
6438         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
6439         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
6440         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
6441         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
6442         macros, not typedefs; this simplifies things quite a bit.
6443         Use long int for all types narrower than int64_t.
6444         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
6445         Define in terms of long long int or int64_t or long int,
6446         not int64_t or int32_t.  This saves some compile-time testing.
6447         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
6448         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
6449         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
6450         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
6451         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
6452         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
6453         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
6454         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
6455         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
6456         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
6457         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6458         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6459         undef any previous version and define our own version, for
6460         simplicity and consistency with the new macros for types.
6461         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6462         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6463         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
6464         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
6465         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
6466         @WINT_T_SUFFIX@ to keep things simple here.
6467         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
6468         Simplify by assuming typical 8/16/32/64 host, since we're
6469         already doing that elsewhere anyway.
6470         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
6471         and assume long long int is 64 bits if available.  This
6472         speeds up 'configure'.
6473
6474 2006-07-01  Eric Blake  <ebb9@byu.net>
6475
6476         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
6477         Reported by Andreas Buening.
6478
6479 2006-07-01  Eric Blake  <ebb9@byu.net>
6480
6481         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
6482
6483 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6484
6485         * lib/getaddrinfo.c: fixed typo
6486
6487 2006-06-29  Jim Meyering  <jim@meyering.net>
6488
6489         * modules/strftime (Maintainer): Add my name, since with the
6490         FPRINTFTIME changes strftime.c has forked from glibc.
6491
6492 2006-06-29  Eric Blake  <ebb9@byu.net>
6493
6494         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
6495
6496 2006-06-29  Eric Blake  <ebb9@byu.net>
6497
6498         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
6499
6500 2006-06-29  Eric Blake  <ebb9@byu.net>
6501
6502         * lib/stat_.h: New file.
6503
6504 2006-06-29  Eric Blake  <ebb9@byu.net>
6505
6506         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
6507         unused static function.
6508
6509 2006-06-29  Eric Blake  <ebb9@byu.net>
6510
6511         * doc/functions.texi (Function Portability): Document missing lstat
6512         on mingw.
6513
6514 2006-06-29  Eric Blake  <ebb9@byu.net>
6515
6516         * MODULES.html.sh: Add sys_stat.
6517         * modules/sys_stat: New module.
6518         * modules/mkstemp (Depends-on): Add sys_stat.
6519
6520 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6521
6522         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
6523
6524 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6525
6526         * m4/c-bs-a.m4: Removed.
6527
6528 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6529
6530         * lib/strftime.c: Assume strftime() exists.
6531
6532 2006-06-29  Derek Price  <derek@ximbiot.com>
6533
6534         * modules/c-bs-a: Removed - \a is C89.
6535         * MODULES.html.sh: Remove c-bs-a.
6536
6537 2006-06-29  Bruno Haible  <bruno@clisp.org>
6538
6539         * modules/wcwidth (License): Change to LGPL.
6540
6541 2006-06-28  Simon Josefsson  <jas@extundo.com>
6542
6543         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
6544         on _WIN32.
6545
6546         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
6547         getnameinfo.
6548
6549 2006-06-28  Simon Josefsson  <jas@extundo.com>
6550
6551         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
6552
6553 2006-06-28  Simon Josefsson  <jas@extundo.com>
6554
6555         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
6556         functions there.  It will succeed on Windows XP, but on Windows
6557         2000 and (presumably) earlier, it will fail, and use the internal
6558         re-implementation.
6559         (use_win32_p): New function.
6560         (getaddrinfo): Use strtoul on servname, to support numeric ports.
6561         Support AI_NUMERICSERV to disable getservbyname.
6562         (getnameinfo): New function, only supports
6563         NI_NUMERICHOST|NI_NUMERICSERV for now.
6564
6565         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
6566         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
6567         getnameinfo.
6568
6569 2006-06-28  Eric Blake  <ebb9@byu.net>
6570
6571         * modules/wcwidth: New file.
6572         * modules/mbchar (Depends-on): Add wcwidth.
6573         * modules/mbswidth (Depends-on): Add wcwidth.
6574         * MODULES.html.sh: Add wcwidth.
6575
6576 2006-06-28  Eric Blake  <ebb9@byu.net>
6577
6578         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
6579         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
6580
6581 2006-06-28  Eric Blake  <ebb9@byu.net>
6582
6583         * lib/xvasprintf.h: Fix comments.
6584
6585 2006-06-28  Eric Blake  <ebb9@byu.net>
6586
6587         * lib/mbchar.h (wcwidth): Include wcwidth.h.
6588         * lib/mbswidth.c (wcwidth): Move from here...
6589         * lib/wcwidth.h: ...to this new file.
6590
6591 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6592
6593         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
6594
6595         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
6596         it's obsolete.
6597         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
6598
6599 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6600
6601         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
6602         Autoconf 2.60 says this stuff was obsolete.
6603
6604 2006-06-28  Bruno Haible  <bruno@clisp.org>
6605
6606         * modules/wcwidth (Files): Add m4/wchar_t.m4.
6607
6608 2006-06-28  Bruno Haible  <bruno@clisp.org>
6609
6610         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
6611         gt_TYPE_WCHAR_T.
6612
6613 2006-06-28  Bruno Haible  <bruno@clisp.org>
6614
6615         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
6616         declaration for wcwidth.
6617         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
6618
6619 2006-06-28  Bruno Haible  <bruno@clisp.org>
6620
6621         * lib/mkdtemp.c [MINGW]: Include <io.h>.
6622         (mkdir): Define using _mkdir.
6623
6624 2006-06-28  Bruno Haible  <bruno@clisp.org>
6625
6626         * lib/getaddrinfo.h: Fix POSIX URL.
6627         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
6628         _WIN32.
6629         (use_win32_p): Make static.
6630         (getaddrinfo): Reject service name if it is empty or does not consist
6631         solely of decimal digits, or if its value is > 65535.
6632         (getnameinfo): Remove useless casts.
6633
6634 2006-06-27  Simon Josefsson  <jas@extundo.com>
6635
6636         * modules/sys_select: New file, suggested by Bruno Haible, Paul
6637         Eggert and Martin Lambers.
6638
6639 2006-06-27  Simon Josefsson  <jas@extundo.com>
6640
6641         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
6642         Eggert and Martin Lambers.
6643
6644 2006-06-27  Bruno Haible  <bruno@clisp.org>
6645
6646         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
6647         result to 0, not to empty.
6648         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
6649
6650 2006-06-27  Bruno Haible  <bruno@clisp.org>
6651
6652         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
6653
6654 2006-06-26  Simon Josefsson  <jas@extundo.com>
6655
6656         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
6657         present.
6658
6659 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
6660
6661         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
6662         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
6663         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
6664
6665 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
6666
6667         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
6668
6669 2006-06-26  Bruno Haible  <bruno@clisp.org>
6670
6671         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
6672
6673 2006-06-26  Bruno Haible  <bruno@clisp.org>
6674
6675         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
6676
6677 2006-06-26  Bruno Haible  <bruno@clisp.org>
6678
6679         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
6680         SGI C compiler in pre-C99 mode.
6681         Suggested by Mark D. Baushke and Larry Jones.
6682
6683 2006-06-26  Bruno Haible  <bruno@clisp.org>
6684
6685         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
6686         WCHAR_MAX.
6687         Reported by Mark D. Baushke and Larry Jones.
6688
6689 2006-06-26  Bruno Haible  <bruno@clisp.org>
6690
6691         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
6692         in pre-C99 mode.
6693         Suggested by Mark D. Baushke and Larry Jones.
6694
6695 2006-06-23  Simon Josefsson  <jas@extundo.com>
6696             Bruno Haible  <bruno@clisp.org>
6697
6698         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
6699         Emit mostlyclean-local rule.
6700         (func_emit_tests_Makefile_am): Likewise.
6701         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
6702
6703 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
6704
6705         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
6706
6707 2006-06-23  Bruno Haible  <bruno@clisp.org>
6708
6709         * tests/test-stdint.c: Update to match ISO C 99 Technical
6710         Corrigendum 1.
6711
6712 2006-06-23  Bruno Haible  <bruno@clisp.org>
6713
6714         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
6715
6716 2006-06-23  Bruno Haible  <bruno@clisp.org>
6717
6718         * lib/stdint_.h: Treat IRIX like OpenBSD.
6719
6720 2006-06-23  Bruno Haible  <bruno@clisp.org>
6721
6722         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
6723         ISO C 99 Technical Corrigendum 1.
6724
6725 2006-06-22  Simon Josefsson  <jas@extundo.com>
6726
6727         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
6728         MinGW.
6729
6730 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
6731
6732         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
6733         needed.  Some compiler complained about some of them.  Problem reported
6734         by Larry Jones in
6735         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
6736
6737 2006-06-21  Simon Josefsson  <jas@extundo.com>
6738
6739         * tests/test-getaddrinfo.c: New file.
6740
6741         * modules/getaddrinfo-tests: New file.
6742
6743         * MODULES.html.sh: Add inet_pton.
6744
6745         * modules/inet_pton: New file.
6746
6747 2006-06-21  Simon Josefsson  <jas@extundo.com>
6748
6749         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
6750         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
6751         of using the (limited) gnulib implementation on Windows XP.
6752
6753         * m4/inet_pton.m4: New file.
6754
6755 2006-06-21  Simon Josefsson  <jas@extundo.com>
6756
6757         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
6758         variable.
6759
6760         * lib/socket_.h: Don't define WINVER.
6761
6762         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
6763         slightly modified to work in gnulib.
6764
6765 2006-06-21  Simon Josefsson  <jas@extundo.com>
6766
6767         * doc/gnulib.texi (Windows sockets): Add.
6768
6769 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
6770
6771         * lib/read-file.c (fread_file): Start with buffer allocation of
6772         0 bytes rather than 1 byte; this simplifies the code.
6773         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
6774         code to free buffer and save/restore errno.
6775         (internal_read_file): Remove unused local.
6776
6777 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
6778
6779         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
6780         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
6781         Problem reported by Denis Excoffier in
6782         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
6783
6784 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6785
6786         * modules/sys_socket, modules/socklen: Include sys/types since
6787         FreeBSD 4.x's sys/socket.h needs it.
6788
6789 2006-06-19  Simon Josefsson  <jas@extundo.com>
6790
6791         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
6792
6793 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6794
6795         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
6796
6797 2006-06-19  Bruno Haible  <bruno@clisp.org>
6798
6799         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
6800         and FULL_PATH_INTTYPES_H in angle brackets.
6801         Reported by Mark D. Baushke <mdb@gnu.org>.
6802
6803 2006-06-17  Eric Blake  <ebb9@byu.net>
6804
6805         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
6806         errno.
6807
6808 2006-06-17  Bruno Haible  <bruno@clisp.org>
6809
6810         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
6811         <sys/inttypes.h>.
6812
6813 2006-06-17  Bruno Haible  <bruno@clisp.org>
6814
6815         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
6816         whether errno is declared. Assume <errno.h> declares errno.
6817
6818 2006-06-17  Bruno Haible  <bruno@clisp.org>
6819
6820         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
6821
6822 2006-06-17  Bruno Haible  <bruno@clisp.org>
6823
6824         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
6825         problem on Solaris 2.5.1.
6826
6827 2006-06-16  Eric Blake  <ebb9@byu.net>
6828
6829         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
6830         * lib/unicodeio.c [!defined errno]: Likewise.
6831         * lib/strtol.c [!defined errno]: Likewise.
6832         * lib/strtod.c [!defined errno]: Likewise.
6833
6834 2006-06-15  Eric Blake  <ebb9@byu.net>
6835
6836         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
6837
6838 2006-06-15  Eric Blake  <ebb9@byu.net>
6839
6840         * config/srclist.txt (ssize_t.m4): Lose sync.
6841
6842 2006-06-15  Bruno Haible  <bruno@clisp.org>
6843
6844         * modules/stdint (Files): Include m4/full-header-path.m4,
6845         m4/size_max.m4, m4/wchar_t.m4.
6846         (Makefile.am): Many more substitutions.
6847         * modules/stdint-tests: New file.
6848         * tests/test-stdint.c: New file.
6849
6850 2006-06-15  Bruno Haible  <bruno@clisp.org>
6851
6852         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
6853         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
6854         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
6855         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
6856         gl_CHECK_TYPE_SAME): New macros.
6857
6858 2006-06-15  Bruno Haible  <bruno@clisp.org>
6859
6860         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
6861
6862 2006-06-15  Bruno Haible  <bruno@clisp.org>
6863
6864         * lib/stdint_.h: Rewritten to be fully auto-configured.
6865         Fixes bug on HP-UX/IA64.
6866
6867 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
6868
6869         * lib/getdate.y (__attribute__): Don't define if already defined.
6870         Problem reported by Larry Jones.
6871         * lib/utimens.c (__attribute__): Likewise.
6872
6873 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
6874
6875         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
6876         reported by Andreas Schwab.
6877
6878 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6879             Bruno Haible  <bruno@clisp.org>
6880
6881         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
6882         check for the declaration of strnlen and a run test that exposes the
6883         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
6884         rpl_strndup.
6885
6886 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6887             Bruno Haible  <bruno@clisp.org>
6888
6889         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
6890
6891 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6892
6893         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
6894         compile test, for Tru64 4.0D.
6895
6896 2006-05-28  Karl Berry  <karl@gnu.org>
6897
6898         * config/srclist.txt (printf-args.c): lose sync.
6899
6900 2006-05-26  Martin Lambers  <marlam@marlam.de>
6901
6902         * lib/getpass.c: Updates the test for the native W32 API, and adds
6903         missing includes, thus fixing compilation warnings.
6904
6905 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
6906
6907         * lib/exclude.c (exclude_fnmatch): New function.
6908         (excluded_file_name): Call exclude_fnmatch.
6909         * lib/exclude.h (excluded_file_name): New prototype
6910
6911 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
6912
6913         * lib/tempname.c (small_open, large_open): New macros.
6914         (__open, __open64) [!_LIBC]: Remove.
6915         (__gen_tempname): Use small_open and large_open instead of __open
6916         and __open64.  This fixes a portability bug on HP-UX 11.11i
6917         reported by Simon Wing-Tang in
6918         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
6919
6920 2006-05-24  Bruno Haible  <bruno@clisp.org>
6921
6922         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
6923         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
6924         Reported by Thorsten Maerz <torte@netztorte.de> via
6925         Aaron Stone <aaron@serendipity.cx>.
6926
6927 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6928
6929         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
6930         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
6931         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
6932         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
6933         not really conditional on the cache.
6934         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
6935
6936 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6937
6938         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
6939         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
6940         (my_usleep): Don't mishandle maximum value.
6941
6942 2006-05-19  Jim Meyering  <jim@meyering.net>
6943
6944         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
6945
6946 2006-05-17  Bruno Haible  <bruno@clisp.org>
6947
6948         Cygwin portability.
6949         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
6950
6951 2006-05-17  Bruno Haible  <bruno@clisp.org>
6952
6953         * lib/stdint_.h: Fix recognition of Cygwin.
6954
6955 2006-05-15  Bruno Haible  <bruno@clisp.org>
6956
6957         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
6958         on libtool patch by Ralf Wildenhues.
6959
6960 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
6961
6962         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
6963         test for C99 conformance; (bool) 0.5 is an integer constant
6964         expression, but (bool) -0.5 is not.  Problem reported by Fedor
6965         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
6966
6967 2006-05-11  Simon Josefsson  <jas@extundo.com>
6968
6969         * m4/xvasprintf.m4: Fix obvious typo.
6970
6971 2006-05-11  Jim Meyering  <jim@meyering.net>
6972
6973         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
6974         James Lemley.
6975
6976 2006-05-10  Simon Josefsson  <jas@extundo.com>
6977
6978         * lib/md4.c: Typo fix, update copyright years.
6979         (K1, K2): Don't use L because it turn computations into 64-bit on
6980         64-bit platforms.
6981
6982 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
6983
6984         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
6985         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
6986         unwanted sign propagation, e.g., on hosts with 64-bit int.
6987         There still are some problems with reeelly weird theoretical hosts
6988         (e.g., 33-bit int) but it's not worth worrying about now.
6989         * lib/sha1.c (rol): Likewise.
6990         (K1, K2, K3, K4): Remove unnecessary L suffix.
6991
6992 2006-05-10  Bruno Haible  <bruno@clisp.org>
6993
6994         * lib/des.c: Cast to avoid warnings.
6995
6996 2006-05-09  Bruno Haible  <bruno@clisp.org>
6997
6998         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
6999         (Depends-on): Depend also on xsize, stdarg.
7000         (configure.ac): Add gl_XVASPRINTF.
7001
7002 2006-05-09  Bruno Haible  <bruno@clisp.org>
7003
7004         * m4/xvasprintf.m4: New file.
7005
7006 2006-05-09  Bruno Haible  <bruno@clisp.org>
7007
7008         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
7009         (EOVERFLOW): Define fallback value.
7010         (xstrcat): New function.
7011         (xvasprintf): Recognize the special case of a string concatenation.
7012
7013 2006-05-08  Eric Blake  <ebb9@byu.net>
7014
7015         * gnulib-tool (func_version): Base copyright year on CVS date.
7016         (func_emit_copyright_notice): New function.
7017         (func_emit_lib_Makefile_am): Use it.
7018         (func_emit_tests_Makefile_am): Likewise.
7019         (func_import): Likewise.
7020
7021 2006-05-08  Bruno Haible  <bruno@clisp.org>
7022
7023         * modules/stdarg: New file.
7024         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
7025
7026 2006-05-08  Bruno Haible  <bruno@clisp.org>
7027
7028         * m4/stdarg.m4: New file, from GNU gettext.
7029
7030 2006-05-08  Bruno Haible  <bruno@clisp.org>
7031
7032         * config/srclist.txt (build-aux/config.rpath): different from latest
7033         release.
7034
7035 2006-05-08  Bruno Haible  <bruno@clisp.org>
7036
7037         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
7038
7039 2006-05-05  Jim Meyering  <jim@meyering.net>
7040
7041         * m4/warning.m4: New file, derived from bison's file by the same name.
7042
7043 2006-05-03  Bruno Haible  <bruno@clisp.org>
7044
7045         * lib/stdint_.h: Shorter URL.
7046         * lib/inttypes.h: Likewise.
7047
7048 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7049
7050         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
7051
7052 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7053
7054         * lib/verify.h: Document the internals better.  Most of this change
7055         was written by Bruno Haible.
7056
7057 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7058
7059         * doc/verify.texi: New file, partly based on a proposal by
7060         Bruno Haible.
7061
7062 2006-05-02  Bruno Haible  <bruno@clisp.org>
7063
7064         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
7065         test from here...
7066         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
7067
7068 2006-04-29  Bruno Haible  <bruno@clisp.org>
7069
7070         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
7071         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
7072
7073 2006-04-29  Bruno Haible  <bruno@clisp.org>
7074
7075         * gnulib-tool: Make --update option actually work.
7076
7077 2006-04-29  Bruno Haible  <bruno@clisp.org>
7078
7079         * doc/gcd.texi: New file.
7080         * doc/gnulib.texi: Include it.
7081
7082 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
7083
7084         * lib/getdate.y (get_date): When adding relative date, start with the
7085         initial time, not with the result of the first mktime call.
7086
7087 2006-04-25  Bruno Haible  <bruno@clisp.org>
7088
7089         * gnulib-tool (func_import): Output the include directives in three
7090         blocks, sorted separately.
7091         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7092
7093 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7094
7095         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
7096         to define main with arguments, for C++.  Reported by Eric Blake.
7097         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
7098         Prefer 'int main ()' to 'int main (void)', for C++.
7099         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
7100         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
7101         for 'main', for C99 and C++.
7102
7103 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7104
7105         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
7106         Don't assume that exit status -1 is valid.
7107         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7108         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
7109         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7110         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
7111         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
7112         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
7113         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
7114         functions can be used without declaring them, or that you can
7115         exit with status -1.
7116         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7117
7118 2006-04-24  Karl Berry  <karl@gnu.org>
7119
7120         * config/srclist.txt (longdouble.m4): sync lost.
7121
7122 2006-04-24  Eric Blake  <ebb9@byu.net>
7123
7124         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
7125
7126 2006-04-24  Bruno Haible  <bruno@clisp.org>
7127
7128         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
7129         poll() implementation in AIX.
7130         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7131
7132 2006-04-24  Bruno Haible  <bruno@clisp.org>
7133
7134         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
7135         assigned exactly once.
7136
7137 2006-04-23  Claudio Fontana  <claudio@gnu.org>
7138             Bruno Haible  <bruno@clisp.org>
7139
7140         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
7141         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
7142         for AM_CPPFLAGS.
7143
7144 2006-04-23  Bruno Haible  <bruno@clisp.org>
7145
7146         * modules/copy-file: Depend on unistd.
7147         * modules/execute: Likewise.
7148         * modules/fatal-signal: Likewise.
7149         * modules/findprog: Likewise.
7150         * modules/mkdtemp : Likewise.
7151         * modules/pipe: Likewise.
7152         * modules/wait-process: Likewise.
7153
7154 2006-04-23  Bruno Haible  <bruno@clisp.org>
7155
7156         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
7157         condition was already detected.
7158         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7159
7160 2006-04-23  Bruno Haible  <bruno@clisp.org>
7161
7162         * lib/copy-file.c: Include <unistd.h> unconditionally.
7163         * lib/execute.c: Likewise.
7164         * lib/fatal-signal.c: Likewise.
7165         * lib/findprog.c: Likewise.
7166         * lib/mkdtemp.c: Likewise.
7167         * lib/pipe.h: Likewise.
7168         * lib/pipe.c: Likewise.
7169         * lib/wait-process.h: Likewise.
7170
7171 2006-04-23  Bruno Haible  <bruno@clisp.org>
7172
7173         * gnulib-tool (func_usage): Fix --import description. Document
7174         --update.
7175         (func_import): Create temporary file in a temporary directory, if
7176         --dry-run is specified. Silence errors from 'grep' when there are no
7177         m4 files in $m4dir.
7178         (func_create_testdir): Silence errors from 'grep' when there are no
7179         m4 files in $m4dir.
7180         Reported by Karl Berry <karl@freefriends.org>.
7181
7182 2006-04-20  Bruno Haible  <bruno@clisp.org>
7183
7184         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
7185         one argument, so that the code will be portable to Autoconf 2.60.
7186         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
7187         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7188         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
7189
7190 2006-04-19  Derek Price  <derek@ximbiot.com>
7191             Eric Blake  <ebb9@byu.net>
7192
7193         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
7194         rather than "/full/path.h".  Update comment to match.  Shorten &
7195         generalize m4_translit call via AS_TR_CPP.
7196
7197 2006-04-19  Derek Price  <derek@ximbiot.com>
7198             Eric Blake  <ebb9@byu.net>
7199
7200         * lib/inttypes.h: Correct grammar in comment.
7201
7202 2006-04-18  Derek Price  <derek@ximbiot.com>
7203             Paul Eggert  <eggert@cs.ucla.edu>
7204
7205         * modules/inttypes: New file.
7206         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
7207
7208 2006-04-18  Derek Price  <derek@ximbiot.com>
7209             Paul Eggert  <eggert@cs.ucla.edu>
7210
7211         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
7212         New files.
7213
7214 2006-04-18  Derek Price  <derek@ximbiot.com>
7215             Paul Eggert  <eggert@cs.ucla.edu>
7216
7217         * lib/inttypes.h: New file.
7218         * lib/strtoimax.c: Assume <inttypes.h>.
7219
7220 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
7221
7222         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
7223         isn't mounted.  Problem reported by Kir Kolyshkin.
7224
7225 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
7226
7227         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
7228         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
7229         Derek R. Price.
7230         * lib/regex.h (RE_DUP_MAX): Update comment to match current
7231         implementation.
7232
7233 2006-04-12  Eric Blake  <ebb9@byu.net>
7234
7235         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
7236         is now done automatically by the corresponding Autoconf macro.
7237
7238 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
7239
7240         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
7241         time_r.h.
7242
7243 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7244
7245         Merge regex changes from libc, removing some of our
7246         POSIX-conformance changes that were rejected and redoing them in a
7247         less-intrusive way.
7248
7249         * lib/regcomp.c (re_compile_internal, init_dfa):
7250         Length arg is now size_t, not Idx.  All uses changed.
7251         (peek_token): Forward decl now says internal_function.
7252         (__re_error_msgid, __re_error_msgid_idx):
7253         Now static rather than extern with attribute_hidden.
7254         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
7255         For some reason libc prefers K&R style defns for external functions.
7256         (regerror) [!defined _LIBC]: Likewise.
7257         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
7258         (seek_collating_symbol_entry, lookup_collation_sequence_value):
7259         (build_range_exp, build_collating_symbol):
7260         Use K&R-style defn.
7261         (re_compile_fastmap): Use '\0' to memset, not 0.
7262         (utf8_sb_map): Make the calculations more obvious.
7263         (init_dfa, parse_bracket_exp, build_charclass_op):
7264         Call calloc and cast result, as glibc does.
7265         (init_word_char, fetch_token, peek_token, peek_token_bracket):
7266         (build_range_exp, build_collating_symbol):
7267         Now internal functions.
7268
7269         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
7270
7271         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
7272         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
7273         Don't depend on VMS; depend on __VMS instead, for POSIX
7274         namespace cleanness.
7275         (regoff_t): Define to ssize_t, not long int.
7276
7277         Remove the REG_ macros named below.  Instead, make the old names
7278         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
7279         __USE_GNU_REGEX.
7280         (REG_BACKSLASH_ESCAPE_IN_LISTS):
7281         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
7282         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
7283         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
7284         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
7285         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
7286         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
7287         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
7288         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
7289         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
7290         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
7291         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
7292         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
7293         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
7294         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
7295         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
7296         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
7297         (REG_NREGS):
7298         Remove.  All uses replaced by the old RE_* names.
7299         (RE_BACKSLASH_ESCAPE_IN_LISTS):
7300         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
7301         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
7302         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
7303         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
7304         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
7305         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
7306         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
7307         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
7308         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
7309         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
7310         Don't bother having these macros be independent of each others'
7311         values, since they no longer exist in the POSIX name space.
7312
7313         Rename the following member names back to their old names,
7314         unless !__USE_GNU_REGEX.  All uses changed back.
7315         (buffer): Renamed from re_buffer.
7316         (allocated): Renamed from re_allocated.
7317         (used): Renamed from re_used.
7318         (syntax): Renamed from re_syntax.
7319         (fastmap): Renamed from re_fastmap.
7320         (translate): Renamed from re_translate.
7321         (can_be_null): Renamed from re_can_be_null.
7322         (regs_allocated): Renamed from re_regs_allocated.
7323         (fastmap_accurate): Renamed from re_fastmap_accurate.
7324         (no_sub): Renamed from re_no_sub.
7325         (not_bol): Renamed from re_not_bol.
7326         (not_eol): Renamed from re_not_eol.
7327         (newline_anchor): Renamed from re_newline_anchor.
7328         (num_regs): Renamed from rm_num_regs.
7329         (start): Renamed from rm_start.
7330         (end): Renamed from rm_end.
7331
7332         (free_state): Move up a bit.
7333
7334         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
7335         #define to be empty.
7336         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
7337         when that is what is intended.
7338         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
7339         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
7340         (MAX): New macro.
7341         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
7342         All uses changed back to re_malloc, etc.  It's now the caller's
7343         responsibility to check for overflow; all callers changed.
7344         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
7345         (re_x2nrealloc): Remove.
7346         (free_state): Remove decl.
7347
7348         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
7349         (re_set_registers, re_exec):
7350         Use K&R-style defn.
7351
7352         2006-01-31  Roland McGrath  <roland@redhat.com>
7353
7354         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
7355         Reported by Mike Frysinger <vapier@gentoo.org>.
7356
7357         2006-01-15  Andreas Jaeger  <aj@suse.de>
7358
7359         [BZ #1950]
7360         * lib/regex_internal.c (re_string_reconstruct): Adjust for
7361         build_wcs_upper_buffer change.
7362         (build_wcs_upper_buffer): Change return type.
7363
7364         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
7365
7366         * lib/regex_internal.h: Include <stdint.h> if available.
7367
7368         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
7369
7370         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
7371
7372         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7373
7374         * lib/regcomp.c: Adjust for changed secondary hash function.
7375
7376         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
7377
7378         * lib/regex.h: Pretty printing.
7379         Clean up namespace a bit.
7380
7381         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
7382
7383         * lib/regexec.c (update_cur_sifted_state, check_arrival,
7384         check_arrival_add_next_nodes): Avoid using uninitialized variable.
7385
7386         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7387                     Ulrich Drepper  <drepper@redhat.com>
7388
7389         [BZ #1302]
7390         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
7391         changed.
7392         (bitset_word_t): Renamed from bitset_word.  All uses changed.
7393
7394         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
7395
7396         [BZ #281]
7397         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
7398         * lib/regcomp.c: Remove unnecessary uses of
7399         unsigned RE_TRANSLATE_TYPE.
7400         * lib/regex_internal.h: Likewise.
7401         * lib/regex_internal.c: Likewise.
7402         * lib/regexec.c: Likewise.
7403         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
7404
7405         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
7406
7407         * lib/regexec.c (find_recover_state): Remove unnecessary
7408         initialization.
7409         (transit_state_bkref): Make DFA a const pointer.
7410         (get_subexp): Likewise.
7411         (check_arrival): Likewise.
7412         (update_cur_sifted_state): Likewise.
7413         (re_search_internal): Likewise.
7414         (prune_impossible_nodes): Likewise.
7415         (acquire_init_state_context): Likewise.
7416         (proceed_next_node): Likewise.
7417         (set_regs): Likewise.
7418         (free_fail_stack_return): Likewise.
7419         (check_arrival_expand_ecl): Mark DFA parameter as const.
7420         (check_arrival_expand_ecl_sub): Likewise.
7421         (check_subexp_limits): Likewise.
7422         (sub_epsilon_src_nodes):  Likewise.
7423         (add_epsilon_src_nodes):  Likewise.
7424         (merge_state_array): Likewise.
7425         (update_regs): Likewise.
7426         (build_trtable): Likewise.
7427         (sift_states_backward): Mark MCTX parameter as const.
7428         (build_sifted_states): Likewise.
7429         (update_cur_sifted_state): Likewise.
7430         (sift_states_mkref): Likewise.
7431         (check_arrival_expand_ecl): Mark eclosure as const.
7432         (check_dst_limits_calc_pos_1): Likewise.
7433         * lib/regex_internal.h (re_match_context_t): Make dfa a const
7434         pointer.
7435
7436         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
7437
7438         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
7439         (transit_state_sb): Likewise.
7440         (transit_state_mb): Likewise.
7441         (sift_states_iter_mb): Likewise.
7442         (check_arrival_add_next_nodes): Likewise.
7443         (check_node_accept_bytes): Change first parameter to pointer-to-const.
7444         [_LIBC] (re_search_2_stub): Use mempcpy.
7445
7446         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
7447         mbrtowc for very simple UTF-8 case.
7448
7449         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
7450         a pointer-to-const.
7451         (re_acquire_state_context): Likewise.
7452         * lib/regex_internal.h: Adjust prototypes.
7453
7454         * lib/regex.c: Prevent using C++ compilers.
7455
7456         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
7457         (re_acquire_state_context): Likewise.
7458
7459 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7460
7461         * modules/regex (Depends-on): Add ssize_t.
7462
7463 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7464
7465         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
7466         translation table.
7467
7468 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7469
7470         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
7471
7472 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
7473             Bruno Haible  <bruno@clisp.org>
7474
7475         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
7476         <sys/types.h> and <inttypes.h>.
7477
7478 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7479
7480         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
7481         `__error_t_defined', so argp.h will not typedef the former.
7482
7483 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
7484
7485         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
7486         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
7487         glibc names.  Even if glibc is changed to conform to POSIX, the
7488         traditional names will be available anyway, since regex depends on
7489         the extensions module.  Also, fix a longstanding typo in the
7490         implementation of Spencer ERE test #75 from grep 2.3.  Problems
7491         reported by Emanuele Giaquinta.  Also, change sense of cached
7492         variable, so that the message makes sense.
7493
7494 2006-03-24  Simon Josefsson  <jas@extundo.com>
7495
7496         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
7497         including some doc fixes.
7498         (base64_encode_alloc): Fix +1 bug on allocation failures.
7499
7500 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7501
7502         * lib/base64.c (base64_encode): Do not read past end of array with
7503         unsanitized input on systems with CHAR_BIT > 8.
7504
7505 2006-03-24  Eric Blake  <ebb9@byu.net>
7506
7507         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
7508
7509 2006-03-22  Karl Berry  <karl@gnu.org>
7510
7511         * config/srclist.txt (*setenv.[ch]): get from coreutils.
7512         * config/srclistvars.sh (COREUTILS): new var.
7513
7514 2006-03-17  Jim Meyering  <jim@meyering.net>
7515
7516         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
7517         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
7518
7519 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7520
7521         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
7522         no longer needs it.  Instead, check that regoff_t is as least
7523         as wide as ptrdiff_t.
7524
7525         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
7526         so that our regex.h stays compatible with the installed regex.
7527         This is helpful for installers who configure --without-included-regex.
7528         Problem reported by Emanuele Giaquinta.
7529
7530 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7531
7532         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
7533         Typedef to long int, not to off_, as POSIX will likely change
7534         in that direction.
7535
7536 2006-03-15  Eric Blake  <ebb9@byu.net>
7537
7538         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
7539
7540 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7541
7542         * lib/argp-help.c (validate_uparams): Fix typo
7543         * lib/argp-parse.c (argp_default_options): Consistently begin help
7544         messages with a lowercase letter.
7545
7546 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
7547
7548         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
7549         overrun buffers and shouldn't be used (much as gets shouldn't be
7550         used).
7551         * lib/time_r.c (asctime_r, ctime_r): Likewise.
7552
7553 2006-03-08  Simon Josefsson  <jas@extundo.com>
7554
7555         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
7556         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7557
7558 2006-03-08  Simon Josefsson  <jas@extundo.com>
7559
7560         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
7561         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7562
7563 2006-03-08  Simon Josefsson  <jas@extundo.com>
7564
7565         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
7566         signal that configure disabled the device.
7567
7568 2006-03-08  Simon Josefsson  <jas@extundo.com>
7569
7570         * build-aux/maint.mk: Fix refresh-po, to handle no translated
7571         languages.
7572
7573 2006-03-07  Simon Josefsson  <jas@extundo.com>
7574
7575         * modules/getopt (Depends-on): Add unistd.
7576
7577         * modules/unistd: New file.
7578
7579 2006-03-07  Simon Josefsson  <jas@extundo.com>
7580
7581         * modules/gc-random: New file.
7582
7583 2006-03-07  Simon Josefsson  <jas@extundo.com>
7584
7585         * m4/unistd_h.m4: New file.
7586
7587 2006-03-07  Simon Josefsson  <jas@extundo.com>
7588
7589         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
7590         test to be side-effect free by storing the result in the cache
7591         variable gl_cv_lib_readline, and moving the assignment of
7592         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
7593         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7594
7595 2006-03-07  Simon Josefsson  <jas@extundo.com>
7596
7597         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
7598         error on missing devices (the functions will return an error).
7599
7600         * m4/gc.m4: Move random stuff to gc-random.m4
7601
7602 2006-03-07  Simon Josefsson  <jas@extundo.com>
7603
7604         * lib/unistd_.h: New file.
7605
7606 2006-03-07  Simon Josefsson  <jas@extundo.com>
7607
7608         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
7609
7610 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7611
7612         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
7613         Problem reported by Juan Manuel Guerrero.
7614
7615 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7616
7617         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
7618         the unistd module.
7619         * lib/getlogin_r.c: Likewise.
7620         * lib/getlogin_r.h: Likewise.
7621         * lib/glob.c: Likewise.
7622         * lib/pagealign_alloc.c: Likewise.
7623         * lib/unistd_.h: Remove; no longer needed.
7624
7625 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7626
7627         * MODULES.html.sh (Support for systems lacking POSIX:2001):
7628         Add unistd.
7629         * modules/c-stack (Depends-on): Add unistd.
7630         * modules/getlogin_r: Likewise.
7631         * modules/glob: Likewise.
7632         * modules/pagealign_alloc: Likewise.
7633         * modules/unistd (Files): Remove lib/unistd_.h.
7634         (EXTRA_DIST): Remove.
7635         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
7636         need unistd_.h.
7637         (MOSTLYCLEANFILES): Remove unistd.h-t.
7638
7639 2006-03-03  Simon Josefsson  <jas@extundo.com>
7640
7641         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
7642
7643 2006-03-03  Simon Josefsson  <jas@extundo.com>
7644
7645         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
7646         libidn and bison.
7647
7648 2006-03-03  Simon Josefsson  <jas@extundo.com>
7649
7650         * build-aux/maint.mk: Add indent target.
7651
7652 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
7653
7654         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
7655         our replacement poll.h in any case, to avoid a differing
7656         declaration from a system header.  Seen on AIX.
7657
7658 2006-03-01  Simon Josefsson  <jas@extundo.com>
7659
7660         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
7661         <kasal@ucw.cz>.
7662
7663 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7664
7665         * modules/gettime (Depends-on): Add extensions module.
7666         * modules/nanosleep (Depends-on): Likewise.
7667         * modules/settime (Depends-on): Likewise.
7668
7669 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7670
7671         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
7672         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
7673         pedantically.
7674         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7675         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
7676
7677         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
7678         not "==".  Reported by Ralf Wildenhues.
7679
7680 2006-03-01  Karl Berry  <karl@gnu.org>
7681
7682         * doc/Copyright/request-*: new files, synced from gnuorg.
7683
7684 2006-03-01  Karl Berry  <karl@gnu.org>
7685
7686         * config/srclist.txt (Copyright/*): new entries.
7687
7688 2006-02-28  Simon Josefsson  <jas@extundo.com>
7689
7690         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
7691
7692 2006-02-27  Simon Josefsson  <jas@extundo.com>
7693
7694         * lib/base64.h: Indent #define's.  From Jim Meyering
7695         <jim@meyering.net>.
7696
7697 2006-02-27  Jim Meyering  <jim@meyering.net>
7698
7699         Revert the change of 2006-02-24, so these files can continue
7700         to be sync'd from gettext.
7701         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
7702         of `config.h'.
7703
7704 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
7705
7706         * modules/intprops: New file.
7707         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7708         Add intprops.
7709         * modules/getloadavg (Files): Remove lib/intprops.h.
7710         (Depends-on): Add intprops.
7711         * modules/human: Likewise.
7712         * modules/inttostr: Likewise.
7713         * modules/openat: Likewise.
7714         * modules/sig2str: Likewise.
7715         * modules/userspec: Likewise.
7716         * modules/utimecmp: Likewise.
7717         * modules/xnanosleep: Likewise.
7718         * modules/xstrtol: Likewise.
7719
7720 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
7721
7722         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
7723         * modules/lock-tests (TESTS): Use $(EXEEXT).
7724         * modules/tls-tests: Likewise.
7725         * modules/argp-tests: Likewise.
7726         (check_PROGRAMS): New var, replacing...
7727         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
7728
7729 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7730
7731         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
7732         `config.h'.
7733
7734 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
7735
7736         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
7737
7738 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7739
7740         Sync from coreutils.
7741         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
7742         gl_CHDIR_SAFER.
7743
7744 2006-02-22  Jim Meyering  <jim@meyering.net>
7745
7746         Sync from coreutils.
7747         * m4/chdir-safer.m4: New file.
7748
7749 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
7750
7751         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
7752         AT_FDCWD exceeds INT_MAX.
7753         * lib/openat.h (AT_FDCWD): Likewise.
7754
7755 2006-02-17  Eric Blake  <address@hidden>
7756
7757         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
7758
7759 2006-02-16  Simon Josefsson  <jas@extundo.com>
7760
7761         * modules/getaddrinfo (Depends-on): Add sys_socket.
7762
7763 2006-02-15  Simon Josefsson  <jas@extundo.com>
7764
7765         * build-aux/maint.mk: Add dsyntax-check rule.
7766
7767 2006-02-15  Eric Blake  <ebb9@byu.net>
7768
7769         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
7770         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
7771         'present but cannot compile' warnings on cygwin.
7772         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
7773         use ws2tcpip.h if sys/socket.h works.
7774         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
7775         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
7776
7777 2006-02-14  Simon Josefsson  <jas@extundo.com>
7778
7779         * modules/maintainer-makefile (Files): Rename.
7780
7781         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
7782         and (the local) Makefile.cfg to maint-cfg.mk.
7783
7784         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
7785         to the latter.
7786
7787         * modules/maintainer-makefile: New module.
7788
7789         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
7790         severaly stripped to make it possible to build it up from scratch
7791         with reliable tests.
7792
7793         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
7794         fixes to permit overriding the default actions when configure and
7795         makefile are not available.
7796
7797 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
7798
7799         Sync from coreutils.
7800         * modules/lstat (Depends-on): Don't depend on xalloc.
7801         (License): Change from GPL to LGPL, since this is now simply a
7802         replacement for a libc function.
7803
7804 2006-02-14  Jim Meyering  <jim@meyering.net>
7805
7806         Sync from coreutils.
7807
7808         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
7809         failure on deficient systems, and simplify gnulib lgpl dependencies.
7810         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
7811         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
7812
7813         * lib/xalloc-die.c: Remove unused definition of N_.
7814
7815 2006-02-14  Jim Meyering  <jim@meyering.net>
7816
7817         Sync from coreutils.
7818         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
7819         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
7820         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
7821         double-quote uses of that variable, to accommodate the rare case in
7822         which getmntent is available in none of the libraries checked.  This
7823         happens at least on FreeBSD 5.0.
7824
7825 2006-02-13  Simon Josefsson  <jas@extundo.com>
7826
7827         * gnulib-tool (Usage): Fix --import, from
7828         karl@freefriends.org (Karl Berry).
7829
7830 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7831
7832         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
7833
7834 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
7835
7836         * lib/argp-namefrob.h: Restore changes accidentally lost during the
7837         "autoupdate" on 2005-12-12.
7838
7839 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7840
7841         * modules/closeout (Depends-on): Remove atexit.
7842
7843 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7844
7845         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
7846         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
7847
7848 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
7849
7850         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
7851         __EXTENSIONS__ if this causes compilation to fail.  Problem
7852         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
7853         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
7854
7855 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
7856
7857         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
7858         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
7859         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
7860         All uses changed.
7861
7862 2006-01-26  Simon Josefsson  <jas@extundo.com>
7863
7864         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
7865         prototype is visible on mingw32.
7866
7867         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
7868         for mingw32.
7869
7870         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
7871         mingw32).
7872
7873 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7874
7875         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
7876         attempt to open for write; this always fails, at least on POSIX
7877         hosts.  This reinstates the 2006-01-09 change, which was
7878         inadvertently removed.
7879
7880 2006-01-26  Bruno Haible  <bruno@clisp.org>
7881
7882         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
7883         Reported by Paul Eggert.
7884
7885 2006-01-26  Bruno Haible  <bruno@clisp.org>
7886             Paul Eggert  <eggert@cs.ucla.edu>
7887
7888         * lib/stdbool_.h (_Bool)
7889         [(! (defined __cplusplus || defined __BEOS__)
7890           && !defined __GNUC__
7891           && !(defined __HP_cc || defined __xlc__
7892                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
7893                || defined __sgi))]:
7894         #define to signed char in these cases too; this simplifies
7895         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
7896         etc., separately) and makes it more conservative.
7897
7898 2006-01-25  Simon Josefsson  <jas@extundo.com>
7899
7900         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
7901         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
7902         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
7903
7904 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7905
7906         * lib/argp-namefrob.h: Bugfix. Remove stray #
7907
7908 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
7909
7910         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
7911         so that we test the test.
7912         Check for yet another HP-UX cc bug involving *bool |= bool.
7913
7914 2006-01-25  Karl Berry  <karl@gnu.org>
7915
7916         * config/srclist.txt (vasnprintf.c): sync lost.
7917
7918 2006-01-25  Jim Meyering  <jim@meyering.net>
7919
7920         Sync from the stable (b5) branch of coreutils:
7921
7922         * lib/fts.c (fts_children): Don't let close() clobber errno from
7923         failed fchdir().
7924
7925         * lib/fts.c (fts_stat): When following a symlink-to-directory,
7926         don't necessarily interpret stat-fails+lstat-succeeds as indicating
7927         a dangling symlink.  That can also happen at least for ELOOP.
7928         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
7929         FYI, this bug predates the inclusion of fts.c in coreutils.
7930
7931         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
7932         in their own block, so pre-c99 compilers don't object.
7933
7934         Avoid the double-free (first in fts_read, second in fts_close) that
7935         would occur when an `active' directory is made inaccessible (e.g.,
7936         via chmod a-x) during a traversal.
7937         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
7938         before returning.  Reproduce this failure by
7939         mkdir -p a/b; cd a; chmod a-x . b
7940         Reported by Stavros Passas.
7941
7942 2006-01-25  Jim Meyering  <jim@meyering.net>
7943
7944         * lib/fileblocks.c: Remove more useless parentheses.
7945         * lib/readutmp.h: Likewise.
7946
7947 2006-01-25  Bruno Haible  <bruno@clisp.org>
7948
7949         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
7950         warnings.
7951         Reported by Paul Eggert.
7952
7953 2006-01-25  Bruno Haible  <bruno@clisp.org>
7954
7955         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
7956         rid of a trap command. For Solaris sh.
7957         Reported by Mark D. Baushke <mdb@gnu.org>.
7958
7959 2006-01-24  Simon Josefsson  <jas@extundo.com>
7960
7961         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
7962         Bruno.
7963
7964 2006-01-24  Karl Berry  <karl@gnu.org>
7965
7966         * config/srclist.txt (argp-namefrob.h): sync lost.
7967
7968 2006-01-24  Jim Meyering  <jim@meyering.net>
7969
7970         * modules/openat (Files): Add lib/intprops.h.
7971         From Mark D. Baushke.
7972
7973 2006-01-24  Jim Meyering  <jim@meyering.net>
7974
7975         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
7976         Reported by Mark D. Baushke.
7977
7978 2006-01-24  Jim Meyering  <jim@meyering.net>
7979
7980         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
7981
7982 2006-01-24  Bruno Haible  <bruno@clisp.org>
7983
7984         * modules/strnlen (Maintainer): Change from glibc to all.
7985
7986 2006-01-24  Bruno Haible  <bruno@clisp.org>
7987
7988         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
7989         Patch by Paul Eggert.
7990
7991 2006-01-24  Bruno Haible  <bruno@clisp.org>
7992
7993         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
7994         already has it.
7995         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
7996         2005-11-26.
7997
7998         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
7999         'signed char' to avoid problems with the built-in _Bool type.
8000         Reported by Paul Eggert on 2005-11-26.
8001
8002 2006-01-24  Bruno Haible  <bruno@clisp.org>
8003
8004         * gnulib-tool (func_import): Avoid constructing complicated sed
8005         expressions inside backquote.
8006         Report and solution by Mark D. Baushke <mdb@gnu.org>.
8007
8008 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
8009
8010         These changes imported from libc.
8011         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
8012         test and two separate function calls.
8013         * lib/strndup.c (__strndup): Add libc_hidden_def.
8014
8015 2006-01-23  Simon Josefsson  <jas@extundo.com>
8016
8017         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
8018         Remove the test_*_SOURCES variable: automake infers it by default.
8019         * modules/tls-tests: Likewise.
8020
8021 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8022
8023         Work around porting bugs reported by Dieter in
8024         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
8025         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
8026         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
8027         Include "getopt.h" first, to check interface.
8028         (getenv): Declare only if defined HAVE_DECL_GETENV &&
8029         !HAVE_DECL_GETENV.
8030         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
8031         (__strndup): Revert to K&R-style function dfns, the glibc style.
8032         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
8033         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
8034         Include strnlen.h first, to get prototype properly.
8035         (strnlen): Renamed from __strnlen.
8036         Remove weak alias.
8037
8038 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8039
8040         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
8041
8042 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8043
8044         * config/srclist.txt: Adjust to reflect glibc reorganization.
8045         This affects only comments.
8046
8047 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
8048
8049          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
8050          Reported by Bruce Korb <bkorb@gnu.org>.
8051
8052 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
8053
8054         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
8055         to pacify gcc -Wswitch-default.
8056
8057 2006-01-22  Bruno Haible  <bruno@clisp.org>
8058
8059         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
8060         temporary buffer for sprintf, take into account the precision also
8061         for 'd', 'i', 'u', 'o', 'x', 'X'.
8062
8063 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8064
8065         * modules/argp-tests: New module
8066         * tests/test-argp.c: New file
8067         * tests/test-argp-2.sh: New file
8068
8069 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8070
8071         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
8072         (__argp_base_name): Removed
8073         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
8074         typo.
8075         (__argp_base_name): Provide macro definition or extern declaration
8076         depending on the configuration
8077
8078 2006-01-20  Simon Josefsson  <jas@extundo.com>
8079
8080         * modules/inet_ntop (Depends-on): Depend on sys_socket.
8081
8082 2006-01-20  Simon Josefsson  <jas@extundo.com>
8083
8084         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
8085
8086 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
8087
8088         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
8089         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
8090         Suggested by Bruno Haible.
8091
8092 2006-01-20  Karl Berry  <karl@gnu.org>
8093
8094         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
8095         until changes propagate, I guess.
8096
8097 2006-01-19  Simon Josefsson  <jas@extundo.com>
8098
8099         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
8100
8101 2006-01-19  Simon Josefsson  <jas@extundo.com>
8102
8103         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
8104
8105 2006-01-19  Simon Josefsson  <jas@extundo.com>
8106
8107         * gnulib-tool: Set check_PROGRAMS.
8108
8109         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8110         modules/des-tests, modules/gc-arcfour-tests,
8111         modules/gc-arctwo-tests, modules/gc-des-tests,
8112         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8113         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8114         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8115         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8116         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8117         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
8118         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
8119         test_*_SOURCES.
8120
8121 2006-01-18  Simon Josefsson  <jas@extundo.com>
8122
8123         * modules/socklen (Depends-on): Depend on sys_socket.
8124
8125 2006-01-18  Simon Josefsson  <jas@extundo.com>
8126
8127         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8128         modules/des-tests, modules/gc-arcfour-tests,
8129         modules/gc-arctwo-tests, modules/gc-des-tests,
8130         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8131         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8132         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8133         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8134         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8135         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
8136         $(EXEEXT) to automake TESTS variable, for mingw32.
8137
8138 2006-01-17  Simon Josefsson  <jas@extundo.com>
8139
8140         * modules/socklen (Include): Need sys/socket.h.
8141
8142 2006-01-17  Bruno Haible  <bruno@clisp.org>
8143
8144         * modules/ssize_t (Include): Add <sys/types.h>.
8145
8146 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
8147
8148         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
8149         it's not portable and it doesn't work with cross-compiles.
8150         Problem reported by Bruno Haible.  Fix missing-$ typo in
8151         'test "gl_cv_ignore_unused_libraries" ...' that prevented
8152         -zignore from being used with Sun's C compiler.
8153
8154 2006-01-12  Simon Josefsson  <jas@extundo.com>
8155
8156         * lib/base64.c: Fix warning, reported by Bruno Haible
8157         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
8158
8159 2006-01-12  Bruno Haible  <bruno@clisp.org>
8160
8161         * modules/ldd: New file.
8162         * build-aux/ldd.sh.in: New file.
8163         * MODULES.html.sh (Support for building libraries and executables): Add
8164         ldd.
8165
8166 2006-01-12  Bruno Haible  <bruno@clisp.org>
8167
8168         * m4/ldd.m4: New file.
8169
8170 2006-01-12  Bruno Haible  <bruno@clisp.org>
8171
8172         * gnulib-tool (func_import, func_create_testdir): Don't go into an
8173         endless loop while replacing $auxdir with build-aux.
8174
8175 2006-01-11  Simon Josefsson  <jas@extundo.com>
8176
8177         * lib/stdint_.h (SIZE_MAX): Add missing (.
8178
8179 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
8180
8181         Sync from coreutils.
8182         * lib/md5.c: Fix commentary typos.
8183         (alignof, UNALIGNED_P): No need for a GCC-specific version.
8184         * lib/md5.h (__attribute__): Remove; unused.
8185         * lib/sha1.c: Fix commentary to match md5 better.
8186         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
8187         so that we don't need to worry about alignment.  All uses changed.
8188         This merges the 2005-10-28 md5 change into sha1.
8189
8190 2006-01-11  Jim Meyering  <jim@meyering.net>
8191
8192         Sync from coreutils.
8193         * lib/md5.c (OP): Fix spacing.
8194
8195 2006-01-11  Bruno Haible  <bruno@clisp.org>
8196
8197         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8198         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
8199         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
8200
8201 2006-01-11  Bruno Haible  <bruno@clisp.org>
8202
8203         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8204         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
8205         the "early" section as well.
8206
8207 2006-01-11  Bruno Haible  <bruno@clisp.org>
8208
8209         Avoid "ar: no archive members specified" error on MacOS X.
8210         * gnulib-tool (func_modules_add_dummy): New function.
8211         (func_import, func_create_testdir): Invoke it.
8212
8213 2006-01-11  Bruno Haible  <bruno@clisp.org>
8214
8215         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
8216         with $auxdir in AC_CONFIG_FILES statements.
8217
8218 2006-01-11  Bruno Haible  <bruno@clisp.org>
8219
8220         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8221         Initialize also noinst_HEADERS to empty.
8222
8223 2006-01-11  Bruno Haible  <bruno@clisp.org>
8224
8225         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
8226         variables.
8227         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
8228         autoreconf.
8229
8230 2006-01-11  Bruno Haible  <bruno@clisp.org>
8231
8232         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
8233         overridable by the user.
8234         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8235
8236 2006-01-10  Simon Josefsson  <jas@extundo.com>
8237
8238         * modules/sys_socket: New file.
8239
8240 2006-01-10  Simon Josefsson  <jas@extundo.com>
8241
8242         * m4/sys_socket_h.m4: New file.
8243
8244 2006-01-10  Simon Josefsson  <jas@extundo.com>
8245
8246         * lib/socket_.h: New file.
8247
8248 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8249
8250         * modules/readutmp (Maintainer): Add myself.
8251
8252 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8253
8254         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
8255         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
8256         People who are still concerned with buggy memcmp implementations
8257         can invoke gl_FUNC_MEMCMP themselves.
8258
8259 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8260
8261         * lib/regex_internal.h (BITSET_WORD_BITS):
8262         Work around a bug in 64-bit PGC (before version 6.1-2), where the
8263         preprocessor mishandles large unsigned values as if they were signed.
8264         Problem reported by Claudio Fontana in
8265         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
8266
8267 2006-01-10  Jim Meyering  <jim@meyering.net>
8268
8269         Avoid the double-free (first in fts_read, second in fts_close) that
8270         would occur when an `active' directory is made inaccessible (e.g.,
8271         via chmod a-x) during a traversal.
8272         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8273         before returning.  Reproduce this failure by
8274         mkdir -p a/b; cd a; chmod a-x . b
8275         Reported by Stavros Passas.
8276
8277         Sync from coreutils.
8278         * lib/sha1.c: Tweak grammar in a comment.
8279
8280 2006-01-10  Jim Meyering  <jim@meyering.net>
8281
8282         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
8283         Patch by Joerg Sonnenberger.
8284
8285 2006-01-10  Bruno Haible  <bruno@clisp.org>
8286
8287         * modules/readutmp: Depend on module free.
8288         * modules/strtok_r: Depend on module restrict.
8289
8290 2006-01-10  Bruno Haible  <bruno@clisp.org>
8291
8292         * modules/gettext (configure.ac): Add an invocation of
8293         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
8294
8295 2006-01-10  Bruno Haible  <bruno@clisp.org>
8296
8297         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
8298         Reported by Werner Lemberg <wl@gnu.org>.
8299
8300 2006-01-10  Bruno Haible  <bruno@clisp.org>
8301
8302         * lib/localcharset.c: Update from GNU gettext.
8303
8304 2006-01-10  Bruno Haible  <bruno@clisp.org>
8305
8306         * lib/argp.h (__const): Remove macro. Use const instead.
8307         * lib/argp-fmtstream.h (__const): Likewise.
8308         * lib/glob_.h (__const): Remove macro.
8309         * lib/glob-libc.h: Use const instead of __const.
8310
8311 2006-01-10  Bruno Haible  <bruno@clisp.org>
8312
8313         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
8314         variable.
8315         Needed to avoid an automake error regarding the 'gettext' module.
8316
8317 2006-01-09  Simon Josefsson  <jas@extundo.com>
8318
8319         * modules/inet_ntop (Depends-on): Add restrict.
8320
8321 2006-01-09  Simon Josefsson  <jas@extundo.com>
8322
8323         * modules/gc-rijndael-tests (License): Put under LGPL.
8324
8325         * modules/gc-des-tests (License): Likewise.
8326
8327         * modules/gc-arcfour-tests (License): Likewise.
8328
8329         * modules/gc-arctwo-tests (License): Likewise.
8330
8331         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
8332
8333         * modules/gc-hmac-sha1-tests (Files): Likewise.
8334
8335         * modules/gc-hmac-md5-tests (License): Likewise.
8336
8337         * modules/gc-sha1-tests (License): Likewise.
8338
8339         * modules/gc-md5-tests (License): Likewise.
8340
8341         * modules/gc-md4-tests (License): Likewise.
8342
8343         * modules/gc-md2-tests (License): Likewise.
8344
8345         * modules/gc-tests (License): Likewise.
8346
8347         * modules/des-tests (License): Likewise.
8348
8349         * modules/md4-tests (License): Likewise.
8350
8351         * modules/md2-tests (License): Likewise.
8352
8353 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8354
8355         Sync from coreutils:
8356
8357         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
8358         * modules/lib-ignore: New file.
8359         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
8360         chdir-safer.m4, lchmod.m4.
8361         * modules/openat: Add mkdirat.c, openat-priv.h.
8362
8363 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8364
8365         Sync from coreutils.
8366         * m4/lib-ignore.m4: New file.
8367         * m4/lchmod.m4: New file.
8368
8369 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8370
8371         Sync from coreutils.
8372         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
8373         for write access: POSIX says that must fail.
8374         * lib/fts.c (diropen): Likewise.
8375         * lib/save-cwd.c (save_cwd): Likewise.
8376         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
8377         well, for minor improvements on hosts that lack O_DIRECTORY.
8378         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
8379         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
8380         Fall back on chown if open failed with EACCES.
8381
8382         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
8383         Report an error at compile-time if only a 1-second nominal clock
8384         resolution is found.
8385
8386         * lib/lchmod.h: New file.
8387         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
8388         (make_dir_parents): Use lchown rather than chown, and
8389         lchmod rather than chmod.
8390
8391         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
8392         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
8393         "proc" reported by n0dalus.
8394
8395         * lib/mountlist.c: Include <limits.h>.
8396         (dev_from_mount_options)
8397         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
8398         New function.  It no longer assumes "dev=" has the System V meaning
8399         on Linux (since it doesn't).  It also parses "dev=" more carefully.
8400         (read_file_system_list)
8401         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
8402         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
8403         dev= in that case.
8404
8405         * lib/posixtm.h (PDS_PRE_2000): New macro.
8406         * lib/posixtm.c (year): Arg is now syntax_bits rather than
8407         allow_century.  All usages changed.  Reject dates outside the range
8408         1969-1999 if PDS_PRE_2000 is used.
8409
8410 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8411
8412         Sync from coreutils.
8413         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
8414         (Time of day items): Mention the possibility of leap seconds.
8415         Problem reported by Dr. David Alan Gilbert.
8416
8417 2006-01-09  Jim Meyering  <jim@meyering.net>
8418
8419         Sync from coreutils.
8420
8421         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
8422
8423         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
8424
8425         * lib/modechange.c (mode_compile): Reject an invalid mode string
8426         that starts with an octal digit.  From Andreas Gruenbacher.
8427
8428         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
8429         and dup to open_safer and dup_safer, respectively.
8430         (openat_permissive): Fix typo in comment.
8431
8432         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
8433         "gettext.h"; either no longer needed or are guaranteed by openat.h.
8434         (_): Remove; no longer needed.
8435         (openat): Renamed from rpl_openat; no need for rpl_openat
8436         since openat.h renames openat for us.
8437         Replace most of the body with a call to openat_permissive,
8438         to avoid duplicate code.
8439         Port to (probably hypothetical) environments were mode_t is
8440         wider than int.
8441         (openat_permissive): Require mode arg, so that we can check
8442         types better.  Put it just after flags.  Change cwd failure
8443         indicator from pointer-to-bool to pointer-to-errno-value.
8444         All callers changed.
8445         Invoke openat_save_fail and/or openat_restore_fail if
8446         cwd_errno is null, so that openat can call us.
8447         (openat_permissive, fdopendir, fstatat, unlinkat):
8448         Simplify errno handling to avoid some duplicate code,
8449         as it's OK to set errno on success.
8450         * lib/openat.h: Revamp code so that function macros depend on
8451         __OPENAT_PREFIX only, not also on AT_FDCWD.
8452         (openat_ro): Remove.  Caller changed to use openat_permissive.
8453         (openat_permissive): Now a macro, if not a function.
8454         (openat_restore_fail, openat_save_fail): Now always functions,
8455         since mkdirat needs them even if __OPENAT_PREFIX is defined.
8456
8457         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
8458         and openat.c.
8459         * lib/mkdirat.c: Include openat-priv.h.
8460         Remove definitions of macros defined therein.
8461         * lib/openat.c: Likewise.
8462
8463         * lib/mkdirat.c (mkdirat): New file and function.
8464         * lib/openat.h (mkdirat): Declare.
8465
8466         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
8467
8468         * lib/openat.h (openat_permissive): Declare.
8469         (openat_ro): Define.
8470
8471         * lib/openat.c (EXPECTED_ERRNO): New macro.
8472         (openat_permissive): New function -- used in remove.c rewrite.
8473         (all functions): Set errno just before returning, only if there
8474         was an actual failure.
8475         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
8476
8477         Emulate openat-family functions using Linux's procfs, if possible.
8478         Idea and some code based on Ulrich Drepper's glibc changes.
8479
8480         * lib/openat.c: (BUILD_PROC_NAME): New macro.
8481         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
8482         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
8483         before falling back on save_cwd and restore_cwd.
8484         (fdopendir, fstatat, unlinkat): Likewise.
8485
8486         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
8487         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
8488
8489         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
8490         as second argument to va_arg.  Otherwise, some versions of gcc
8491         warn that `if this code is reached, the program will abort'.
8492
8493 2006-01-09  Jim Meyering  <jim@meyering.net>
8494
8495         Sync from coreutils.
8496         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
8497         Require openat-priv.h.
8498
8499 2006-01-09  Bruno Haible  <bruno@clisp.org>
8500
8501         * modules/strnlen (Include): Use strnlen.h.
8502
8503 2006-01-09  Bruno Haible  <bruno@clisp.org>
8504
8505         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
8506
8507 2006-01-09  Bruno Haible  <bruno@clisp.org>
8508
8509         * lib/sysexit_.h (EX_OK): New macro.
8510         Suggested by Martin Lambers <marlam@marlam.de>.
8511
8512 2006-01-09  Bruno Haible  <bruno@clisp.org>
8513
8514         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
8515         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
8516
8517 2006-01-09  Bruno Haible  <bruno@clisp.org>
8518
8519         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
8520         numbers.
8521
8522 2006-01-09  Bruno Haible  <bruno@clisp.org>
8523
8524         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
8525         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
8526         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
8527         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
8528
8529 2006-01-09  Bruno Haible  <bruno@clisp.org>
8530
8531         * build-aux/javacomp.sh.in: New file, moved from lib/.
8532         * modules/javacomp-script (Files): Update.
8533         (configure.ac): Add AC_CONFIG_FILES invocation.
8534         (EXTRA_DIST): Remove variable.
8535
8536         * build-aux/javaexec.sh.in: New file, moved from lib/.
8537         * modules/javaexec (Files): Update.
8538         (configure.ac): Add AC_CONFIG_FILES invocation.
8539         (EXTRA_DIST): Remove javaexec.sh.in.
8540
8541         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
8542         * modules/csharpcomp-script (Files): Update.
8543         (configure.ac): Add AC_CONFIG_FILES invocation.
8544         (EXTRA_DIST): Remove variable.
8545
8546         * build-aux/csharpexec.sh.in: New file, moved from lib/.
8547         * modules/csharpexec (Files): Update.
8548         (configure.ac): Add AC_CONFIG_FILES invocation.
8549         (EXTRA_DIST): Remove csharpexec.sh.in.
8550
8551 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8552
8553         Sync from coreutils.
8554
8555         Add POSIX ACL support
8556         * lib/acl.h (copy_acl, set_acl): Add declarations.
8557         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
8558         systems other than Linux.
8559         (chmod_or_fchmod): New function: use fchmod when possible,
8560         and chmod otherwise.
8561         (file_has_acl): Add a POSIX ACL implementation, with a
8562         Linux-specific subcase.
8563         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
8564         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
8565         acls are unsupported.
8566         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
8567         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
8568         are unsupported.
8569
8570 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8571
8572         Sync from coreutils.
8573         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
8574
8575 2006-01-07  Bruno Haible  <bruno@clisp.org>
8576
8577         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
8578         gl_EARLY.
8579
8580 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8581
8582         * lib/strftime.c (tzname): Don't declare if it is already #defined.
8583         Problem reported for Mingw by Mark Junker.
8584
8585 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8586
8587         * README: Gnulib normally doesn't generate a tarball.
8588
8589 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
8590
8591         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
8592         long int, not int, for nanosecond counts, so that people who are
8593         used to POSIX struct timespec won't be surprised.  Reported by Jim
8594         Meyering.
8595
8596 2005-12-28  Bruno Haible  <bruno@clisp.org>
8597
8598         * build-aux/config.rpath: Update from GNU gettext.
8599
8600 2005-12-16  Jim Meyering  <jim@meyering.net>
8601
8602         * modules/fprintftime: New module.
8603         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
8604
8605 2005-12-16  Jim Meyering  <jim@meyering.net>
8606
8607         * m4/fprintftime.m4: New file.
8608
8609 2005-12-16  Jim Meyering  <jim@meyering.net>
8610
8611         * lib/fprintftime.c, lib/fprintftime.h: New files.
8612
8613 2005-12-15  Simon Josefsson  <jas@extundo.com>
8614
8615         * modules/socklen (configure.ac): Fix M4 macro name, to align with
8616         new m4/socklen.m4.
8617
8618 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8619
8620         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
8621         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
8622
8623 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8624
8625         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
8626         * lib/argp-help.c (fill_in_uparams): Check if the constructed
8627         struct uparams is valid. Fall back to the default values if it is
8628         not.
8629
8630 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8631
8632         * modules/argp (Files): Add argp-pin.c
8633         (Depends-on): dirname
8634         (lib_SOURCES): Add argp-pin.c
8635
8636 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8637
8638         * m4/argp.m4:  Check if program_invocation_name and
8639         program_invocation_short_name are declared and define appropriate
8640         macros if they are not.
8641
8642 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8643
8644         * lib/argp-help.c (__argp_base_name): New function
8645         (__argp_short_program_name): Rewrite using __argp_base_name
8646         * lib/argp-namefrob.h: Define program_invocation_name and
8647         program_invocation_short_name if requested
8648         (__argp_base_name): Add prototype
8649         * lib/argp-parse.c (argp_def): Use gettext wrappers
8650         (argp_default_parser): Use __argp_base_name
8651         * lib/argp-pin.c: New file. Defines program_invocation_name and
8652         program_invocation_short_name on systems that lack them.
8653
8654 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8655
8656         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
8657         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8658         porting problem reported by Georg Schwarz in
8659         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8660
8661 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8662
8663         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
8664         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8665         porting problem reported by Georg Schwarz in
8666         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8667
8668 2005-12-05  Bruno Haible  <bruno@clisp.org>
8669
8670         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
8671         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
8672         Reported by Mark Junker <mjscod@gmx.de>.
8673
8674 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
8675
8676         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
8677         Use implementation from Albert Chin, with some
8678         comments/corrections by Stepan Kasal and myself.
8679
8680 2005-12-02  Bruno Haible  <bruno@clisp.org>
8681
8682         * gnulib-tool (func_import): Accept GPLed build tool modules when
8683         --lgpl is given.
8684         * modules/csharpcomp-script: New file.
8685         * modules/csharpcomp: Depend on it.
8686         * modules/javacomp-script: New file.
8687         * modules/javacomp: Depend on it.
8688         Suggested by Simon Josefsson.
8689
8690 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
8691
8692         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
8693         statement, to work around an HP-UX 10.20 compiler bug reported by
8694         Peter O'Gorman.
8695
8696 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8697
8698         * modules/savedir (Depends-on): Add openat.
8699
8700 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8701
8702         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
8703         (uintmax_t) [defined uintmax_t]: Do not declare.
8704         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
8705         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
8706         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
8707         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
8708         sake of portability to weird hosts that C allows (though we don't
8709         know of any practical examples).
8710
8711         * lib/savedir.h (fdsavedir): New decl.
8712         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
8713         contains most of the former guts of savedir.
8714         (savedir): Use savedirstream.
8715         Include "openat.h".
8716
8717 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
8718
8719         * modules/obstack (Files): Add m4/ulonglong.m4.
8720         Problem reported by Davide Angelocola.
8721
8722 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
8723
8724         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
8725         coreutils no longer futzes with rounding modes.
8726
8727 2005-11-14  Jim Meyering  <jim@meyering.net>
8728
8729         * lib/mkstemp-safer.c: Include <config.h>, required for possible
8730         replacement of mkstemp.
8731
8732 2005-11-10  Simon Josefsson  <jas@extundo.com>
8733
8734         * lib/readline.c: Remove EOL.
8735
8736 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8737
8738         * modules/gethrxtime (Depends-on): Add gettime.
8739
8740 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8741
8742         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
8743         or gettimeofday; no longer needed.
8744
8745 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8746
8747         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
8748         time business.
8749         (gethrxtime) [! (HAVE_NANOUPTIME
8750         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
8751         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
8752         our own approximation.
8753
8754 2005-11-08  Eric Blake  <ebb9@byu.net>
8755
8756         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8757
8758 2005-11-08  Eric Blake  <ebb9@byu.net>
8759
8760         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8761
8762 2005-11-04  Bruno Haible  <bruno@clisp.org>
8763
8764         * gnulib-tool: Implement --update mode.
8765
8766 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8767
8768         Fix porting problem reported by Theodoros V. Kalamatianos.
8769         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
8770         Don't assume that futimes failing means we must fail.
8771
8772 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8773
8774         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
8775         variables to suggest the intended function of the PATH_MAX check.
8776
8777 2005-10-30  Kean Johnston  <jkj@sco.com>
8778
8779         Trivial changes to support SCO systems.
8780         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
8781         as PATH_MAX.
8782         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
8783         where __ptr is null when no I/O is pending.
8784
8785 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
8786
8787         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
8788         leave errno alone.  Problem reported by Dmitry V. Levin.
8789
8790 2005-10-28  Simon Josefsson  <jas@extundo.com>
8791
8792         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
8793         Test more.
8794
8795         * tests/test-gc-md2.c, tests/test-md2.c: New files.
8796
8797         * modules/md2, modules/md2-tests: New files.
8798
8799 2005-10-28  Simon Josefsson  <jas@extundo.com>
8800
8801         * m4/inet_ntop.m4: More tests.
8802
8803         * m4/gc-md2.m4, md2.m4: New file.
8804
8805 2005-10-28  Simon Josefsson  <jas@extundo.com>
8806
8807         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
8808         "restrict" keywords, as per POSIX.  Protect the function
8809         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
8810         Don't use K&R prototypes.  Check the sprintf return values.
8811         Re-define EAFNOSUPPORT if not present.  Indent.
8812
8813         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
8814         suggested by Bruno Haible <bruno@clisp.org>.
8815
8816         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
8817
8818         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
8819
8820         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
8821         libgcrypt).
8822
8823         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
8824
8825         * lib/md2.h, lib/md2.c: New files.
8826
8827 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
8828
8829         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
8830         errno alone.  Problem reported by Frederic Jolliton.
8831
8832 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8833
8834         * modules/verify (License): Change from GPL to LGPL.  This is a
8835         tiny module and there are apparently near-equivalents that are
8836         under the BSD license.
8837
8838 2005-10-24  Simon Josefsson  <jas@extundo.com>
8839
8840         * modules/sha1: Relicense to LGPL.
8841
8842 2005-10-24  Simon Josefsson  <jas@extundo.com>
8843
8844         * lib/md4.h: Shrink buffer size, now that we changed the type.
8845
8846 2005-10-23  Simon Josefsson  <jas@extundo.com>
8847
8848         * gnulib-tool (func_import): Fix --tests-base.
8849
8850 2005-10-22  Simon Josefsson  <jas@extundo.com>
8851
8852         * modules/arcfour (Depends-on): Need stdint.
8853
8854 2005-10-22  Simon Josefsson  <jas@extundo.com>
8855
8856         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
8857         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
8858
8859 2005-10-22  Simon Josefsson  <jas@extundo.com>
8860
8861         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
8862         suggested by Bruno Haible <bruno@clisp.org>.
8863
8864 2005-10-22  Simon Josefsson  <jas@extundo.com>
8865
8866         * lib/crc.h: Include stddef.h, for size_t.
8867
8868 2005-10-22  Simon Josefsson  <jas@extundo.com>
8869
8870         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
8871         arcfour_context struct (simplify test vector testing in GNU
8872         Shishi).
8873
8874 2005-10-21  Simon Josefsson  <jas@extundo.com>
8875
8876         * modules/des, modules/des-tests: New files.
8877
8878         * modules/gc-des, modules/gc-des-tests: New files.
8879
8880         * tests/test-des.c, tests/test-gc-des.c: New file.
8881
8882 2005-10-21  Simon Josefsson  <jas@extundo.com>
8883
8884         * modules/arctwo, modules/arctwo-tests: New files.
8885
8886         * tests/test-arctwo.c: New file.
8887
8888         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
8889
8890         * tests/test-gc-arctwo.c: New file.
8891
8892 2005-10-21  Simon Josefsson  <jas@extundo.com>
8893
8894         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
8895         Bruno Haible <bruno@clisp.org>.
8896
8897         * m4/gc-des.m4: New file.
8898
8899 2005-10-21  Simon Josefsson  <jas@extundo.com>
8900
8901         * m4/arctwo.m4: New file.
8902
8903         * m4/gc-arctwo.m4: New file.
8904
8905 2005-10-21  Simon Josefsson  <jas@extundo.com>
8906
8907         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
8908         block.
8909
8910 2005-10-21  Simon Josefsson  <jas@extundo.com>
8911
8912         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
8913         <bruno@clisp.org>.
8914
8915         * lib/hmac-sha1.c (hmac_sha1): Likewise.
8916
8917         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
8918         Bruno Haible <bruno@clisp.org>.
8919
8920         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
8921         <bruno@clisp.org>.
8922
8923 2005-10-21  Simon Josefsson  <jas@extundo.com>
8924
8925         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
8926
8927 2005-10-21  Simon Josefsson  <jas@extundo.com>
8928
8929         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
8930
8931 2005-10-21  Simon Josefsson  <jas@extundo.com>
8932
8933         * lib/des.h, lib/des.c: New files.
8934
8935         * lib/gc-gnulib.c: Support DES.c
8936
8937 2005-10-21  Simon Josefsson  <jas@extundo.com>
8938
8939         * lib/arctwo.h, lib/arctwo.c: New files.
8940
8941         * lib/gc-gnulib.c: Support ARCTWO.
8942
8943 2005-10-21  Simon Josefsson  <jas@extundo.com>
8944
8945         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
8946         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8947
8948 2005-10-21  Simon Josefsson  <jas@extundo.com>
8949
8950         * gnulib-tool (func_import, func_create_testdir): Define automake
8951         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
8952         Makefile.am snippet),
8953         suggested by Bruno Haible <bruno@clisp.org>.
8954
8955         * modules/gc (Makefile.am): Use it.
8956
8957 2005-10-21  Bruno Haible  <bruno@clisp.org>
8958
8959         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
8960         patch.
8961
8962 2005-10-19  Simon Josefsson  <jas@extundo.com>
8963
8964         * tests/test-gc-rijndael.c: New file.
8965
8966         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
8967
8968 2005-10-19  Simon Josefsson  <jas@extundo.com>
8969
8970         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
8971         interface too.
8972
8973 2005-10-19  Simon Josefsson  <jas@extundo.com>
8974
8975         * tests/test-gc-arcfour.c: New file.
8976
8977         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
8978
8979 2005-10-19  Simon Josefsson  <jas@extundo.com>
8980
8981         * modules/gc-md4, modules/gc-md4-tests: New file.
8982
8983         * tests/test-gc-md4.c: New file.
8984
8985 2005-10-19  Simon Josefsson  <jas@extundo.com>
8986
8987         * m4/gc-md4.m4: New file.
8988
8989 2005-10-19  Simon Josefsson  <jas@extundo.com>
8990
8991         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
8992         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
8993         <kasal@ucw.cz>.
8994
8995 2005-10-19  Simon Josefsson  <jas@extundo.com>
8996
8997         * m4/gc-arcfour.m4: New file.
8998
8999         * m4/gc-rijndael.m4: New file.
9000
9001 2005-10-19  Simon Josefsson  <jas@extundo.com>
9002
9003         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
9004
9005 2005-10-19  Simon Josefsson  <jas@extundo.com>
9006
9007         * lib/gc-gnulib.c: Support ARCFOUR.
9008
9009 2005-10-19  Simon Josefsson  <jas@extundo.com>
9010
9011         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
9012         support.
9013
9014         * lib/gc.h: Add ECB enum type.
9015
9016         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
9017
9018 2005-10-18  Simon Josefsson  <jas@extundo.com>
9019
9020         * tests/test-md5.c: New file.
9021
9022         * modules/md5-tests: New file.
9023
9024 2005-10-18  Simon Josefsson  <jas@extundo.com>
9025
9026         * tests/test-md4.c: New file.
9027
9028         * modules/md4, modules/md4-tests: New files.
9029
9030 2005-10-18  Simon Josefsson  <jas@extundo.com>
9031
9032         * m4/md4.m4: New file.
9033
9034 2005-10-18  Simon Josefsson  <jas@extundo.com>
9035
9036         * lib/md4.h, lib/md4.c: New files, based on md5.?.
9037
9038 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
9039
9040         * gnulib-tool (func_create_testdir): Omit the second check whether
9041         BUILT_SOURCES in nonempty.
9042
9043 2005-10-17  Simon Josefsson  <jas@extundo.com>
9044
9045         * tests/test-rijndael.c: New file.
9046
9047 2005-10-17  Simon Josefsson  <jas@extundo.com>
9048
9049         * modules/sha1: Depend on stdint instead of md5.
9050
9051         * modules/md5: Depend on stdint, remove uint32_t.
9052
9053 2005-10-17  Simon Josefsson  <jas@extundo.com>
9054
9055         * modules/gc-sha1-tests: New file.
9056
9057         * tests/test-gc-sha1.c: New file.
9058
9059 2005-10-17  Simon Josefsson  <jas@extundo.com>
9060
9061         * m4/md5.m4: Remove call to uint32_t.m4.
9062
9063 2005-10-17  Simon Josefsson  <jas@extundo.com>
9064
9065         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
9066
9067         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
9068         md5.h.
9069
9070         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
9071
9072         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
9073
9074 2005-10-17  Simon Josefsson  <jas@extundo.com>
9075
9076         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
9077
9078 2005-10-17  Simon Josefsson  <jas@extundo.com>
9079
9080         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
9081
9082 2005-10-17  Simon Josefsson  <jas@extundo.com>
9083
9084         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
9085
9086         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
9087
9088 2005-10-17  Bruno Haible  <bruno@clisp.org>
9089
9090         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
9091         that it can also be used in a test.
9092
9093 2005-10-16  Bruno Haible  <bruno@clisp.org>
9094
9095         * gnulib-tool (func_emit_tests_Makefile_am): Also define
9096         TESTS_ENVIRONMENT, so that individual tests can augment it.
9097
9098         * gnulib-tool (func_create_testdir): Use an intermediate target for
9099         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
9100         macros, like $(ALLOCA_H), which cannot be passed through the command
9101         line.
9102
9103 2005-10-15  Simon Josefsson  <jas@extundo.com>
9104
9105         * modules/rijndael-tests: New file.
9106
9107         * modules/rijndael: New file.
9108
9109 2005-10-15  Simon Josefsson  <jas@extundo.com>
9110
9111         * m4/rijndael.m4: New file.
9112
9113 2005-10-15  Simon Josefsson  <jas@extundo.com>
9114
9115         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
9116
9117         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
9118
9119 2005-10-14  Simon Josefsson  <jas@extundo.com>
9120
9121         * tests/test-arcfour.c: New file.
9122
9123         * modules/arcfour, modules/arcfour-tests: New files.
9124
9125 2005-10-14  Simon Josefsson  <jas@extundo.com>
9126
9127         * m4/arcfour.m4: New file.
9128
9129 2005-10-14  Simon Josefsson  <jas@extundo.com>
9130
9131         * lib/arcfour.h, lib/arcfour.c: New files.
9132
9133 2005-10-14  Roland McGrath  <roland@redhat.com>
9134
9135         Import from libc.  [BZ #1331]
9136         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
9137         macro argument.
9138         Reported by Matej Vela <vela@debian.org>.
9139
9140 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9141
9142         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
9143         include <wchar.h>; no longer needed.
9144
9145 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9146
9147         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
9148
9149 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
9150         and  Ulrich Drepper  <drepper@redhat.com>
9151
9152         Import from libc.
9153         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
9154         instead of inline stream orientation test and two separate
9155         function calls.  Pay no attention to USE_IN_LIBIO.
9156
9157 2005-10-13  Simon Josefsson  <jas@extundo.com>
9158
9159         * modules/gc-hmac-md5-tests: New file.
9160
9161         * tests/test-gc-hmac-sha1.c: New file.
9162
9163         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
9164
9165         * modules/gc-hmac-md5-tests: New file.
9166
9167         * tests/test-gc-md5.c: New file.
9168
9169         * modules/gc-md5-tests: New file.
9170
9171 2005-10-13  Simon Josefsson  <jas@extundo.com>
9172
9173         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
9174         Move memory allocation outside of loop.
9175
9176 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
9177
9178         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
9179         intermediate directory is in a read-only file system.  Problem
9180         reported by Eric Blake.
9181
9182 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
9183
9184         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
9185
9186 2005-10-12  Simon Josefsson  <jas@extundo.com>
9187
9188         * tests/test-hmac-sha1.c: New file.
9189
9190         * modules/hmac-sha1-tests: New file.
9191
9192         * modules/hmac-sha1: New file.
9193
9194 2005-10-12  Simon Josefsson  <jas@extundo.com>
9195
9196         * modules/gc-sha1: New file.
9197
9198 2005-10-12  Simon Josefsson  <jas@extundo.com>
9199
9200         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
9201
9202         * tests/test-gc-pbkdf2-sha1.c: New file.
9203
9204 2005-10-12  Simon Josefsson  <jas@extundo.com>
9205
9206         * modules/gc-md5, modules/gc-hmac-md5: New files.
9207
9208         * modules/gc (Files): Remove md5, memxor and hmac files.
9209
9210 2005-10-12  Simon Josefsson  <jas@extundo.com>
9211
9212         * m4/gc-pbkdf2-sha1.m4: New file.
9213
9214         * m4/gc-hmac-sha1.m4: New file.
9215
9216         * m4/gc-sha1: New file.
9217
9218         * m4/hmac-sha1.m4: New file.
9219
9220 2005-10-12  Simon Josefsson  <jas@extundo.com>
9221
9222         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
9223
9224         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
9225
9226 2005-10-12  Simon Josefsson  <jas@extundo.com>
9227
9228         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
9229         suggested by Bruno Haible <bruno@clisp.org>.
9230
9231 2005-10-12  Simon Josefsson  <jas@extundo.com>
9232
9233         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
9234
9235 2005-10-12  Simon Josefsson  <jas@extundo.com>
9236
9237         * lib/gc-pbkdf2-sha1.c: New file.
9238
9239         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
9240
9241 2005-10-12  Simon Josefsson  <jas@extundo.com>
9242
9243         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
9244
9245         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
9246
9247 2005-10-12  Simon Josefsson  <jas@extundo.com>
9248
9249         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
9250         GC_USE_HMAC_MD5, respectively.
9251
9252         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
9253         (gc_md5): Fix typo.
9254
9255         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
9256
9257         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
9258
9259         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
9260
9261 2005-10-12  Bruno Haible  <bruno@clisp.org>
9262
9263         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
9264         Reported by Stepan Kasal <kasal@ucw.cz>.
9265
9266 2005-10-11  Simon Josefsson  <jas@extundo.com>
9267
9268         * tests/test-crc.c: New file.
9269
9270         * modules/crc, modules/crc-tests: New files.
9271
9272 2005-10-11  Simon Josefsson  <jas@extundo.com>
9273
9274         * m4/crc.m4: New file.
9275
9276 2005-10-11  Simon Josefsson  <jas@extundo.com>
9277
9278         * lib/gc.h: Add gc_hash and gc_hash_buffer.
9279
9280         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
9281
9282         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
9283
9284 2005-10-11  Simon Josefsson  <jas@extundo.com>
9285
9286         * lib/crc.h, lib/crc.c: New files.
9287
9288         * lib/gc.h (gc_hash_buffer): Add doc.
9289
9290 2005-10-11  Bruno Haible  <bruno@clisp.org>
9291
9292         * modules/c-strcasestr: New file.
9293         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
9294
9295 2005-10-11  Bruno Haible  <bruno@clisp.org>
9296
9297         * modules/c-strcase: New file.
9298         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
9299
9300 2005-10-11  Bruno Haible  <bruno@clisp.org>
9301
9302         * lib/strcasecmp.c: Include limits.h.
9303         (strcasecmp): Avoid integer overflow on exotic platforms.
9304         * lib/strncasecmp.c: Include limits.h.
9305         (strncasecmp): Avoid integer overflow on exotic platforms.
9306         Reported by Paul Eggert.
9307
9308 2005-10-11  Bruno Haible  <bruno@clisp.org>
9309
9310         * lib/c-strcasestr.h: New file, from GNU gettext.
9311         * lib/c-strcasestr.c: New file, from GNU gettext.
9312
9313 2005-10-11  Bruno Haible  <bruno@clisp.org>
9314
9315         * lib/c-strcase.h: New file, from GNU gettext.
9316         * lib/c-strcasecmp.c: New file, from GNU gettext.
9317         * lib/c-strncasecmp.c: New file, from GNU gettext.
9318
9319 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9320
9321         * modules/mempcpy (License): GPL -> LGPL.
9322         * modules/strchrnul (License): Likewise.
9323         * modules/sysexits (License): Likewise.
9324
9325 2005-10-08  Simon Josefsson  <jas@extundo.com>
9326
9327         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
9328
9329 2005-10-07  Simon Josefsson  <jas@extundo.com>
9330
9331         * m4/memxor.m4: Remove gl_C_RESTRICT call.
9332
9333 2005-10-06  Simon Josefsson  <jas@extundo.com>
9334
9335         * tests/test-hmac-md5.c: New file.
9336
9337         * modules/hmac-md5-tests: New file.
9338
9339         * modules/hmac-md5: New file.
9340
9341 2005-10-06  Simon Josefsson  <jas@extundo.com>
9342
9343         * m4/hmac-md5.m4: New file.
9344
9345         * m4/memxor.m4: Require gl_C_RESTRICT.
9346
9347 2005-10-06  Simon Josefsson  <jas@extundo.com>
9348
9349         * lib/memxor.c (memxor): Avoid casts and warnings.
9350
9351 2005-10-06  Simon Josefsson  <jas@extundo.com>
9352
9353         * lib/hmac-md5.c: New file.
9354
9355         * lib/hmac.h: New file.
9356
9357 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9358
9359         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
9360         promotes to int, not unsigned int, to catch the AIX 5.3
9361         compiler bug.
9362
9363 2005-10-05  Simon Josefsson  <jas@extundo.com>
9364
9365         * modules/memxor: New file.
9366
9367         * modules/iconv (Files): Move config.rpath to havelib, it is used
9368         there.
9369
9370         * modules/havelib (Files): Add config.rpath.
9371
9372 2005-10-05  Simon Josefsson  <jas@extundo.com>
9373
9374         * m4/memxor.m4: New file.
9375
9376 2005-10-05  Simon Josefsson  <jas@extundo.com>
9377
9378         * lib/memxor.c (memxor): Fix compiler error.
9379
9380         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
9381         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
9382
9383         * lib/memxor.h, lib/memxor.c: New files.
9384
9385         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
9386         we assume all systems have it, suggested by Jim Meyering
9387         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
9388         any systems lack sys/socket.h; mingw32 is known to lack it, but we
9389         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
9390         same reasons.
9391
9392 2005-10-05  Simon Josefsson  <jas@extundo.com>
9393
9394         * config/srclist.txt: Add glibc bug 1423 for md5.h.
9395
9396 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9397
9398         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
9399         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
9400         needed, since the source code now assumes these .h files.
9401
9402 2005-10-05  Derek Price  <derek@ximbiot.com>
9403
9404         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
9405
9406 2005-10-05  Bruno Haible  <bruno@clisp.org>
9407
9408         * modules/stdint (License): Change to LGPL.
9409
9410 2005-10-04  Simon Josefsson  <jas@extundo.com>
9411
9412         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
9413         D. Baushke" <mdb@gnu.org>.
9414
9415 2005-10-04  Bruno Haible  <bruno@clisp.org>
9416
9417         * lib/verify.h (verify_true): Provide alternative definition for C++.
9418
9419 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
9420
9421         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
9422         (SSIZE_MAX): New macro, if not already defined.
9423         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
9424         than 2 GiB.
9425
9426 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9427
9428         Sync from coreutils.
9429         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
9430         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
9431         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
9432         ULLONG_MAX doesn't work with 2.7.2.1.
9433
9434 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9435
9436         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
9437         From Ben Pfaff.
9438
9439         * modules/exclude (Depends-on): Depend on verify.
9440         * modules/strtoimax (Depends-on): Likewise.
9441         * modules/utimecmp (Depends-on): Likewise.
9442
9443 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9444
9445         * lib/exclude.c: Include verify.h.
9446         (verify): Remove.  All callers changed to use verify.h's version.
9447         * lib/strtoimax.c: Likewise.
9448         * lib/utimecmp.c: Likewis.e
9449
9450         Sync from coreutils.
9451         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
9452         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
9453         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
9454         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
9455         bother returning ENOSYS if settimeofday or stime fails; just let
9456         them return whatever errno they want to return.
9457         * lib/utimens.c: Include unistd.h, for dup2.
9458         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
9459         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
9460
9461 2005-10-02  Jim Meyering  <jim@meyering.net>
9462
9463         Sync from coreutils.
9464         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
9465         from glibc-2.2.5 that fails for read-only files.
9466
9467 2005-10-02  Jim Meyering  <jim@meyering.net>
9468
9469         Sync from coreutils.
9470         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
9471         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
9472         `#if HAVE_CONFIG_H'.
9473         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
9474         Remove AT_FDCWD test.
9475         Do not consume the fd unless successful.
9476         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
9477         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
9478         block, so that we don't even try to compile it if settimeofday is
9479         available.  This works around a compilation failure on OSF1 V5.1,
9480         due to stime requiring a `long int*' while tv_sec is `int'.
9481
9482 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
9483
9484         Sync from coreutils.
9485         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
9486         against `yes', rather than just testing for nonempty.
9487
9488 2005-10-01  Simon Josefsson  <jas@extundo.com>
9489
9490         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
9491         and Darwin.
9492
9493         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
9494         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
9495         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
9496         freeaddrinfo and gai_strerror are declared by the POSIX headers.
9497         Check if struct addrinfo is declared.
9498
9499 2005-10-01  Simon Josefsson  <jas@extundo.com>
9500
9501         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
9502         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
9503         AI_* and EAI_* definitions.  Protect function declarations.
9504
9505 2005-10-01  Jim Meyering  <jim@meyering.net>
9506
9507         Sync from coreutils.
9508
9509         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
9510         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
9511         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
9512         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9513         in the inet and nsl libraries.  Required on Solaris 5.7.
9514
9515 2005-10-01  Jim Meyering  <jim@meyering.net>
9516
9517         Sync from coreutils.
9518         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9519         in the inet and nsl libraries.  Required on Solaris 5.7.
9520
9521 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
9522
9523         * lib/getdelim.c (getdelim): Remove unused variables.
9524
9525 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9526
9527         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
9528         so that the code works even with ancient cpp.  Portability problem
9529         with GCC 2.7.2.1 reported by Thomas M.Ott.
9530
9531 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9532
9533         * modules/regex (Depends-on): Add strcase.
9534
9535         * modules/gethostname (Licence): Change from GPL to LGPL, since
9536         gethostname.c is a trivial implementation of a standard library
9537         function.
9538         * modules/poll (License): Change from GPL to LGPL, since it's
9539         derived from LGPL code.
9540
9541 2005-09-27  Jim Meyering  <jim@meyering.net>
9542
9543         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
9544         HAVE_CONFIG_H.
9545
9546         * lib/intprops.h (signed_type_or_expr__): Define.
9547         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
9548         for unsigned types.
9549
9550 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9551
9552         * lib/verify.h (verify_expr): Remove, replacing with:
9553         (verify_true): New macro that returns true instead of void.
9554         (verify_type__): Remove.
9555         (verify): Use verify_true rather than verify_type__.
9556
9557 2005-09-26  Bruno Haible  <bruno@clisp.org>
9558
9559         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
9560         is necessary.
9561         (lib_SOURCES): Remove mbchar.c.
9562         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
9563         (Files): Add m4/mbrtowc.m4.
9564         * modules/mbiter: Likewise.
9565         * modules/mbuiter: Likewise.
9566
9567 2005-09-26  Bruno Haible  <bruno@clisp.org>
9568
9569         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
9570         compile mbchar.c if they are not both present.
9571         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
9572         * m4/mbiter.m4 (gl_MBITER): Likewise.
9573         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
9574         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
9575         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
9576
9577 2005-09-25  Jim Meyering  <jim@meyering.net>
9578
9579         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
9580         also uses socklen_t.
9581
9582 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
9583
9584         * lib/utimens.c (ENOSYS): Define if not already defined.
9585         (futimens): Support having a null PATH if the file descriptor
9586         is nonnegative.
9587
9588         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
9589         Remove.
9590         (__attribute): Define to empty unless GCC 3.1 or later.
9591         This works around a core dump on OpenBSD 3.4, which has GCC
9592         2.95.3, which dumps core when given __attribute__(()).  It also
9593         simplifies other tests, since we really don't want to bother with
9594         worrying about which ancient version of GCC supported what.
9595         Original problem reported by Yoann Vandoorselaere, with part of
9596         the fix suggested by Derek Price.
9597
9598 2005-09-24  Jim Meyering  <jim@meyering.net>
9599
9600         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
9601         so we can once again use a positive bitfield width of 1 -- now we
9602         don't have to explain why we were using a bitfield width of 2.
9603
9604 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9605
9606         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
9607         and similarly for the other external symbols.  Problem reported
9608         by James Gallager.
9609
9610         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
9611         bug reported by Jim Meyering.
9612
9613         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
9614         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
9615         not needed, since socklen is a prerequisite module.
9616
9617 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9618
9619         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
9620         Problem reported by Eric Blake.
9621         (getaddrinfo): Initialize se so that it's not garbage.
9622         Redo internal storage allocation so that it doesn't make unportable
9623         assumptions about alignment.
9624         Fix a memory leak.
9625
9626         * lib/utimens.c (futimens): Use futimesat if available.
9627         Prefer it to futimes since it doesn't have the futimes bug.
9628
9629         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
9630         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
9631         Instead, declare a function that returns a pointer to an array,
9632         and use verify_type__ to declare the size of the array.
9633         Problem and germ of a solution reported by Bruno Haible.
9634         (verify_type__): Use 2, not 1, for bitfield size, to avoid
9635         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
9636
9637 2005-09-23  Jim Meyering  <jim@meyering.net>
9638
9639         Sync from coreutils.
9640         Correct build failure (socklen_t not defined) on at least
9641         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
9642         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
9643
9644 2005-09-23  Jim Meyering  <jim@meyering.net>
9645
9646         * modules/getaddrinfo (Depends-on): Add socklen.
9647
9648 2005-09-23  Bruno Haible  <bruno@clisp.org>
9649
9650         * tests/test-verify.c: New file.
9651
9652 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9653
9654         Sync from coreutils.
9655
9656         * modules/argmatch (Depends-on): Add verify.
9657         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
9658         unistd-safer.
9659         * modules/save-cwd (Depends-on): Likewise.
9660
9661         * modules/openat (Files): Add lib/openat-die.c.
9662         (Depends-on): Remove error, exitfail.
9663         Add dirname.
9664
9665         * modules/verify: New file.
9666         * MODULES.html.sh (Diagnostics <assert.h>): New section,
9667         with "verify" module.
9668
9669 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9670
9671         Sync from coreutils.
9672
9673         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
9674         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
9675         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
9676         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
9677         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
9678         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
9679         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
9680         Don't bother checking for string.h, stdlib.h, unistd.h.
9681         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
9682         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
9683         module's job.
9684         * m4/jm-macros.m4 (gl_MACROS): Likewise.
9685         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
9686
9687         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
9688         (gl_GETDATE): Use it.
9689
9690         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
9691
9692 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9693
9694         Sync from coreutils.
9695
9696         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
9697         stat-time.h.
9698         * lib/argmatch.h: Include verify.h
9699         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
9700         (ARGMATCH_ASSERT): Remove; unused.
9701         * lib/canonicalize.c: Assume STDC_HEADERS.
9702         * lib/exclude.c: Include "strcase.h".
9703         * lib/regex_internal.h [!defined _LIBC]: Likewise.
9704         * lib/getusershell.c: Include stdio--.h rather than stdio.h
9705         and stdio-safer.h.
9706         (getusershell): Call fopen, not fopen_safer.
9707         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
9708         Do not include unistd-safer.h.
9709         (save_cwd): Don't call fd_safer; no longer needed
9710         now that we include fcntl--.h.
9711
9712         * lib/getdate.y (relative_time): New type.
9713         (RELATIVE_TIME_0): New constant.
9714         (parser_control): Use relative_time instead of doing it ourselves.
9715         (%union): Add new relative_time rel member.
9716         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
9717         Now typeless.
9718         (relunit, relunit_snumber): Now of type rel.
9719         (zone, rel, relunit, get_date): Adjust to above changes.
9720
9721         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
9722         Do not include unistd-safer.h.
9723         (getloadavg): Don't call fd_safer; no longer needed
9724         now that we include fcntl--.h.
9725
9726         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
9727         (make_dir_parents): Treat ENOSYS like EEXIST.
9728
9729         Improve quality of diagnostics on restore_cwd failure.
9730         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
9731         (make_dir_parents): Last arg is now int * (for errno), not bool *.
9732         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
9733         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
9734         each time through the loop.  Do not diagnose restore_cwd failure;
9735         that is the caller's job (and perhaps the caller does not care).
9736
9737         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
9738         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
9739         If the file already exists but is not a directory, don't bother
9740         to try to make its parents.
9741         Close potential file descriptor leak if we can't chdir("/") (!).
9742         Don't always return true if chdir($PWD) fails; return true only
9743         if the requested action was done successfully (except for the
9744         chdir($PWD)).
9745         Don't log final directory unless we actually made it.
9746         Refactor to avoid duplicate code to fix up permissions.
9747         Don't attempt to fix up parent permissions if chdir($PWD) fails.
9748
9749         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
9750         to make it a bit faster and (I hope) clearer.
9751         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
9752         Fix bug in formats like %2N.
9753
9754         * lib/verify.h: New file.
9755
9756 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9757
9758         Sync from coreutils.
9759         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
9760
9761 2005-09-22  Jim Meyering  <jim@meyering.net>
9762
9763         Sync from coreutils.
9764
9765         * m4/lstat.m4 (gl_FUNC_LSTAT):
9766         Use AC_LIBSOURCES to require lstat.c and lstat.h.
9767         Remove obsolete comment.
9768         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
9769         * m4/xstrtod.m4: Likewise.
9770
9771         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
9772
9773 2005-09-22  Jim Meyering  <jim@meyering.net>
9774
9775         Sync from coreutils.
9776
9777         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
9778
9779         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
9780         the .tm_year member, since otherwise gcc-4.0 would now warn about
9781         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
9782
9783         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
9784         order to avoid an unsuppressible warning from gcc on 64-bit systems.
9785
9786         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
9787         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
9788         when run in a time zone for which daylight savings time is in effect
9789         for the starting date.
9790
9791         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
9792         stop us from restricting permissions of just-created absolute-named
9793         directories.
9794         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
9795         to restore initial working directory.
9796         * lib/mkdir-p.c (make_dir_parents): New parameter:
9797         different_working_dir, to tell caller if/when we change the working
9798         directory and are unable to return to the initial one.
9799         * lib/mkdir-p.h (make_dir_parents): Update prototype.
9800         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
9801         `return false'.  This fixes a bug introduced on 2004-07-30.
9802
9803         * lib/openat.c (fdopendir): Be sure to close the supplied
9804         file descriptor before returning.  This makes our replacement
9805         implementation a little closer to Solaris's, where fdopendir
9806         ties the file descriptor to the returned DIR* pointer.
9807         * lib/openat.c (unlinkat): New function.
9808         * lib/openat.h (unlinkat): Add prototype.
9809         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
9810         (openat_restore_fail): Rename from openat_restore_die.
9811         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
9812
9813         Provide an alternative to exiting immediately upon save_cwd or
9814         restore_cwd failure.  Now, an application can arrange e.g.,
9815         to perform a longjump in that case.
9816         * lib/openat.c: Include dirname.h.
9817         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
9818         (rpl_openat, fdopendir, fstatat): Call openat_save_die
9819         and openat_restore_die rather than calling error directly.
9820         Don't include "error.h" or "exitfail.h"; they're no longer needed.
9821
9822         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
9823         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
9824         define.
9825
9826         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
9827         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
9828                             int utc, int nanoseconds);
9829         Background:
9830         date should not have to allocate a megabyte of virtual memory to
9831         handle a format argument like +%1048575T.  When implemented with
9832         strftime, it must allocate such a buffer, use strftime to fill it
9833         in, print it, then free it.
9834         With fprintftime, it simply prints everything and exits.
9835         With no need for memory allocation, that's one fewer way to fail.
9836         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
9837         optional field width, not before, so we accept %9:z, not %:9z.
9838         (my_strftime): Be sure to use L_('x') for literals.
9839
9840         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
9841         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
9842         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
9843         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
9844         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
9845         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
9846         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
9847         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
9848         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
9849         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
9850         * lib/xgethostname.c, lib/xreadlink.c:
9851         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
9852
9853         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
9854         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
9855         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
9856         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
9857         and don't include <sys/file.h>).
9858
9859 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
9860
9861         Sync from coreutils.
9862
9863         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
9864         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
9865         [!LDAV_DONE]: Avoid unused variable warning.
9866
9867 2005-09-21  Bruno Haible  <bruno@clisp.org>
9868
9869         * lib/unicodeio.h (unicode_to_mb): New declaration.
9870
9871 2005-09-20  Derek Price  <derek@ximbiot.com>
9872
9873         * lib/getaddrinfo.c: Don't include <netdb.h> included from
9874         getaddrinfo.h.
9875
9876 2005-09-20  Bruno Haible  <bruno@clisp.org>
9877
9878         * gnulib-tool: Remove trailing slashes from the values specified for
9879         --source-base, --m4-base, --tests-base, --aux-dir.
9880         Suggested by Simon Josefsson <jas@extundo.com>.
9881
9882 2005-09-20  Bruno Haible  <bruno@clisp.org>
9883
9884         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
9885         func_modules_to_filelist, func_import, func_create_testdir): Make all
9886         sorting results locale-independent, so that gnulib-cache.m4 doesn't
9887         change when gnulib-tool is invoked in a different locale.
9888
9889 2005-09-19  Simon Josefsson  <jas@extundo.com>
9890
9891         * m4/socklen.m4: Fix typo.
9892
9893 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9894
9895         Use a consistent style for including <config.h>.
9896         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
9897         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
9898         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
9899         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
9900         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
9901         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
9902         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
9903         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
9904         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
9905         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
9906         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
9907         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
9908         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
9909         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
9910         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
9911         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
9912         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
9913         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
9914         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
9915         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
9916         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
9917         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
9918         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
9919         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
9920         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
9921         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
9922         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
9923         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
9924         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
9925         lib/xstrtoumax.c, lib/yesno.c:
9926         Standardize inclusion of config.h.
9927         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
9928         lib/inttostr.h:  Removed inclusion of config.h from header files.
9929         * lib/inttostr.c:  Adjusted in-tree users.
9930         * lib/timespec.h: Remove superfluous warning to include config.h.
9931         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
9932         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
9933         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
9934         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
9935         config.h with HAVE_CONFIG_H.
9936
9937 2005-09-19  Jim Meyering  <jim@meyering.net>
9938
9939         * modules/pathmax (License): Change to LGPL.
9940
9941 2005-09-19  Derek Price  <derek@ximbiot.com>
9942
9943         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
9944
9945 2005-09-19  Bruno Haible  <bruno@clisp.org>
9946
9947         * gnulib-tool (import): Provide default for --tests-base.
9948
9949 2005-09-19  Bruno Haible  <bruno@clisp.org>
9950
9951         * doc/quote.texi: New file, extracted from gnulib.texi.
9952         * doc/ctime.texi: New file, extracted from gnulib.texi.
9953         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
9954         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
9955         * doc/gnulib.texi: Include them.
9956
9957 2005-09-18  Bruno Haible  <bruno@clisp.org>
9958
9959         Portability fix.
9960         * gnulib-tool (func_readlink): New function.
9961         (func_ln_if_changed): Use it.
9962
9963 2005-09-18  Bruno Haible  <bruno@clisp.org>
9964
9965         * gnulib-tool: Support --with-tests also with --import.
9966         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
9967         (func_import): Use variables $testsbase and $inctests. Emit a
9968         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
9969         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
9970         SUBDIRS += $testsdir.
9971         (func_create_testdir): Update.
9972
9973 2005-09-18  Bruno Haible  <bruno@clisp.org>
9974
9975         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
9976         instead of $dry_run.
9977         (func_cp_if_changed, func_mv_if_changed): Remove functions.
9978         (func_ln_if_changed): Don't handle dry-run here.
9979         (func_import): In dry-run mode, detect more precisely which actions
9980         would be performed, and don't use "...ing" verbs.
9981
9982 2005-09-18  Bruno Haible  <bruno@clisp.org>
9983
9984         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
9985         (func_import): Use join on two temporary files instead of three nested
9986         loops, in order to determine which files are new or old.
9987
9988 2005-09-18  Bruno Haible  <bruno@clisp.org>
9989
9990         * gnulib-tool (func_import): Comment out code that spits out the
9991         new files with --dry-run.
9992
9993 2005-09-18  Bruno Haible  <bruno@clisp.org>
9994
9995         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
9996
9997 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9998
9999         * lib/stat-time.h: New file.
10000         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
10001         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
10002         in a different way.
10003         (timespec_cmp): New function.
10004         * lib/utimecmp.c: Include stat-time.h.
10005         (SYSCALL_RESOLUTION): Depend on whether various struct stat
10006         members exist, not on the obsolescent ST_MTIM_NSEC.
10007         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
10008
10009 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10010
10011         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
10012
10013 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10014
10015         * MODULES.html.sh (File system functions): Add stat-time.
10016         * modules/stat-time: New file.
10017         * modules/timespec (Files): Remove m4/st_mtim.m4; this
10018         is now done in a different way, by the stat-time module.
10019         * modules/utimecmp (Depends-on): Add stat-time.
10020
10021 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10022
10023         * m4/st_mtim.m4: Remove.  Superseded by...
10024         * m4/stat-time.m4: New file.
10025         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
10026         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
10027
10028 2005-09-15  Derek Price  <derek@ximbiot.com>
10029
10030         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
10031
10032 2005-09-15  Derek Price  <derek@ximbiot.com>
10033
10034         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
10035         * lib/regex_internal.c: Ditto, using this...
10036         (__GNUC_PREREQ): ...new macro.
10037         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
10038         using...
10039         (__GNUC_PREREQ): ...this new macro.
10040
10041         * lib/strstr.h: Include string.h. Define strstr as a macro here.
10042
10043 2005-09-15  Derek Price  <derek@ximbiot.com>
10044             Paul Eggert  <eggert@cs.ucla.edu>
10045
10046         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
10047         changes, consolidating in...
10048         * lib/regex_internal.h: ...this file.
10049
10050 2005-09-13  Jim Meyering  <jim@meyering.net>
10051
10052         * lib/canon-host.c: Filter through gnu indent and reword comments
10053         slightly.
10054         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
10055
10056 2005-09-13  Derek Price  <derek@ximbiot.com>
10057
10058         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
10059         failure.
10060         Reported by Jim Meyering  <jim@meyering.net>.
10061
10062 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10063
10064         * lib/base64.c: Typo.
10065         (base64_encode): Put b64str in initialized data section.
10066
10067 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
10068
10069         Merge glibc and coreutils changes into gnulib, plus a few
10070         extra fixes.
10071         * lib/md5.c: Use #error rather than a string.
10072         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
10073         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
10074         (__attribute__): Define to empty for non recent-GCC.
10075         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
10076         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
10077         Renamed from their non-__ counterparts, with new macros replacing
10078         them if not _LIBC.  Add __THROW attribute.
10079         (rol): Remove.
10080         (struct md5_ctx): Align buffer if using GCC.
10081         * lib/sha1.h (struct sha1_ctx): Likewise.
10082         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
10083         The old name was backwards.
10084         (NOTSWAP): Remove; not used.
10085         (rol): New macro, moved here from md5.h.
10086         (sha1_process_block): Remove a FIXME that doesn't make sense.
10087
10088 2005-09-12  Derek Price  <derek@ximbiot.com>
10089
10090         Return usable errors from canon-host.
10091         * lib/canon-host.h: New file.
10092         * lib/canon-host.c (canon_host): Wrap...
10093         (canon_host_r): ...this new function, which now relies exclusively on
10094         getaddrinfo.
10095         (ch_strerror): New function.
10096         (last_cherror): New global.
10097         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
10098         interface.
10099         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
10100         void *.
10101         (freeaddrinfo): Free ai->ai_canonname when set.
10102
10103 2005-09-12  Derek Price  <derek@ximbiot.com>
10104
10105         Make canon-host require getaddrinfo.
10106         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
10107         AC_LIBSOURCE canon-host.h.  Call...
10108         (gl_PREREQ_CANON_HOST): ...this new function, which requires
10109         gl_GETADDRINFO.
10110         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
10111
10112 2005-09-12  Derek Price  <derek@ximbiot.com>
10113
10114         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
10115         LGPL.
10116         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
10117
10118 2005-09-12  Derek Price  <derek@ximbiot.com>
10119
10120         * lib/gai_strerror.c: Include config.h when available.  Include
10121         getaddrinfo.h before other headers to test interface.
10122         Reported by Larry Jones <lawrence.jones@ugs.com>.
10123
10124 2005-09-12  Derek Price  <derek@ximbiot.com>
10125             Paul Eggert  <eggert@cs.ucla.edu>
10126
10127         * modules/glob (Files): Add glob-libc.h.
10128
10129 2005-09-12  Derek Price  <derek@ximbiot.com>
10130             Paul Eggert  <eggert@cs.ucla.edu>
10131
10132         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
10133         glob_.h, glob-libc.h.
10134         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
10135
10136 2005-09-12  Derek Price  <derek@ximbiot.com>
10137             Paul Eggert  <eggert@cs.ucla.edu>
10138
10139         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
10140         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
10141         protecting things that should be done only in gnulib contexts.
10142         * lib/glob_.h: New file, containing only the glob things needed for
10143         gnulib.
10144         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
10145         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
10146         (glob, globfree, glob_pattern_p): Now defined simply in terms of
10147         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
10148         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
10149         and to respect the namespace rules better.
10150
10151 2005-09-08  Simon Josefsson  <jas@extundo.com>
10152
10153         * modules/socklen: New file.
10154
10155 2005-09-08  Simon Josefsson  <jas@extundo.com>
10156
10157         * m4/socklen.m4: New file.
10158
10159 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10160
10161         * modules/utimens (Files): Add m4/utimbuf.m4, since
10162         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
10163         Reported by Sergey Poznyakoff.
10164
10165 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10166
10167         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
10168         definitions, since that's the preferred style in glibc.
10169         Fix a minor spacing issue, and update copyright notice to match
10170         glibc's.
10171
10172 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10173
10174         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
10175
10176 2005-09-06  Simon Josefsson  <jas@extundo.com>
10177
10178         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
10179         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
10180
10181 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10182
10183         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
10184         warning.
10185
10186 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10187
10188         * config/srclist.txt: Add glibc bug 1302.
10189
10190 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
10191
10192         Change bitset word type from unsigned int to unsigned long int,
10193         as this has better performance on typical 64-bit hosts.
10194         Port bitset code to hosts with unusual word sizes.
10195         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
10196         (build_collating_symbol):
10197         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
10198         argument is a bitset.  This is merely a style issue, but it makes
10199         it clearer that an entire array is expected.
10200         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
10201         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
10202         Port to the case where bitset_word is not the same as unsigned int.
10203         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10204         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
10205         Likewise.
10206         * lib/regexec.c (check_dst_limits_calc_pos_1,
10207         check_subexp_matching_top):
10208         (build_trtable, group_nodes_into_DFAstates):
10209         Likewise.
10210         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
10211         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
10212         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
10213         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
10214         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
10215         * lib/regcomp.c (optimize_subexps, lower_subexp):
10216         Work even if bitset_word has holes in its bitwise representation.
10217         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
10218         * lib/regexec.c (check_dst_limits_calc_pos_1,
10219         check_subexp_matching_top):
10220         Likewise.
10221         * lib/regex_internal.c (re_string_reconstruct):
10222         Don't assume UCHAR_MAX == 255.
10223         * lib/regex_internal.h (bitset_set_all): Likewise.
10224         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
10225         All uses changed.
10226         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
10227         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
10228         All uses changed.
10229         (BITSET_WORD_MAX): New macro.
10230         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
10231         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
10232         (bitset_empty, bitset_copy):
10233         Prefer sizeof (bitset) to multiplying it out ourselves.
10234         (bitset_not_merge): Remove; unused.
10235         (bitset_contain): Return bool, not unsigned int with one bit on.
10236         All callers changed.
10237         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
10238         alignment than re_node_set; do this by defining a new internal
10239         type struct dests_alloc and using it to allocate memory.
10240
10241 2005-09-05  Bruno Haible  <bruno@clisp.org>
10242
10243         * gnulib-tool (func_import): Fix comparison in handling of symbolic
10244         links.
10245
10246 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
10247
10248         * modules/size_max (Makefile.am): Add size_max.h
10249
10250 2005-09-04  Derek Price  <derek@ximbiot.com>
10251
10252         * gnulib-tool (func_import): Fix reversed $symbolic logic.
10253
10254 2005-09-03  Simon Josefsson  <jas@extundo.com>
10255
10256         * gnulib-tool: Fix typo.
10257
10258 2005-09-03  Simon Josefsson  <jas@extundo.com>
10259
10260         * config/srclist.txt: Add glibc bug 1293.
10261
10262 2005-09-03  Derek Price  <derek@ximbiot.com>
10263
10264         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
10265         From Larry Jones <lawrence.jones@ugs.com>.
10266
10267 2005-09-02  Simon Josefsson  <jas@extundo.com>
10268
10269         * modules/socklen: New file.
10270
10271 2005-09-02  Simon Josefsson  <jas@extundo.com>
10272
10273         * modules/havelib: New module.
10274
10275         * modules/gettext, modules/iconv, modules/lock, modules/readline:
10276         Use havelib.
10277
10278 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10279
10280         Check for arithmetic overflow when calculating sizes, to prevent
10281         some buffer-overflow issues.  These patches are conservative, in the
10282         sense that when I couldn't determine whether an overflow was possible,
10283         I inserted a run-time check.
10284         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
10285         macros.
10286         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
10287         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
10288         (re_xnrealloc, re_x2nrealloc): New inline functions.
10289         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
10290         parse_bracket_exp):
10291         (build_equiv_class, build_charclass): Check for arithmetic overflow
10292         in size expression calculations.
10293         * lib/regex_internal.c (re_string_realloc_buffers):
10294         (build_wcs_upper_buffer, re_node_set_add_intersect):
10295         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
10296         (re_dfa_add_node, register_state): Likewise.
10297         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
10298         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
10299         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
10300         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
10301
10302 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10303
10304         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
10305         m4/ulonglong.m4.  Problem reported by Martin Lambers.
10306
10307 2005-09-02  Bruno Haible  <bruno@clisp.org>
10308
10309         Support for lib vs. lib64 distinction on biarch platforms.
10310         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
10311         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
10312         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
10313
10314 2005-09-02  Bruno Haible  <bruno@clisp.org>
10315
10316         * gnulib-tool (import): In the other first-use case, provide defaults
10317         as well.
10318
10319 2005-09-02  Bruno Haible  <bruno@clisp.org>
10320
10321         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
10322         patches not yet found in the latest gettext release.
10323
10324 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10325
10326         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
10327         to avoid a collision with bits/local_lim.h in glibc.
10328         All uses changed.  Problem reported by Dmitry V. Levin in
10329         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
10330
10331         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
10332         bugs in int versus size_t comparisons.
10333         (re_string_context_at): Fix bug where the code assumed that
10334         Idx is signed.
10335
10336         Use bool where appropriate.
10337         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
10338         All callers changed.
10339         (calc_eclosure_iter): Likewise, for ROOT arg.
10340         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
10341         (build_charclass_op): Likewise, for NON_MATCH arg.
10342         * lib/regex_internal.c (re_string_allocate, re_string_construct):
10343         (re_string_construct_common): Likewise, for ICASE arg.
10344         * lib/regexec.c (re_search_2_stub, re_search_stub):
10345         Likewise, for RET_LEN arg.
10346         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
10347         (set_regs): Likewise, for FL_BACKTRACK arg.
10348         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
10349         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
10350         (calc_eclosure_iter, parse_bracket_exp):
10351         Use bool for internal variables that are booleans.
10352         * lib/regexec.c (re_search_internal, check_matching,
10353         proceed_next_node):
10354         (set_regs, build_sifted_states, sift_states_bkref):
10355         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
10356         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
10357         (find_collation_sequence_value):
10358         Likewise.
10359         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
10360         (re_node_set_compare):
10361         Return bool, not int. All callers changed.
10362         * lib/regexec.c (check_halt_node_context, check_dst_limits):
10363         (build_trtable, check_node_accept): Likewise.
10364         * lib/regex_internal.h: Include stdbool.h.
10365
10366         Fix bugs uncovered when converting to bool.
10367         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
10368         failure instead of charging ahead blindly.
10369         * lib/regex_internal.c (register_state): Likewise.
10370         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
10371         for freeing internal storage.
10372         (group_nodes_into_DFA_states): Use unsigned int, not int, for
10373         bitset pieces used as boolean, to avoid undefined behavior
10374         on hosts that do int overflow checking.
10375
10376 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10377
10378         * config/srclist.txt: Add glibc bugs 1285-1287.
10379
10380 2005-09-01  Jim Meyering  <jim@meyering.net>
10381
10382         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
10383         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
10384         Require gl_STAT_MACROS, too.
10385
10386 2005-09-01  Bruno Haible  <bruno@clisp.org>
10387
10388         * gnulib-tool (import): In the first-use case, provide defaults.
10389
10390 2005-09-01  Bruno Haible  <bruno@clisp.org>
10391
10392         * gnulib-tool (func_import): Remove the .tmp files.
10393
10394 2005-09-01  Bruno Haible  <bruno@clisp.org>
10395
10396         * gnulib-tool (func_import): Fix handling of symbolic links.
10397
10398 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10399
10400         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
10401         old glibc regex code mishandles strings longer than 2**31 bytes.
10402         This patch fixes this when the regex code is used in gnulib
10403         (i.e., outside glibc).
10404
10405         This patch should not affect the use of the regex code inside
10406         glibc.  No doubt this problem also needs to be handled for glibc
10407         as well, but the result will be an incompatible change to the
10408         glibc ABI, and the old ABI will have to be supported too.  That
10409         can be the the subject for another patch.
10410
10411         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
10412         governing whether the rest of this patch is active.  By default,
10413         the macro is disabled and the patch has no effect.
10414         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
10415         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
10416         (struct re_pattern_buffer, re_search, re_search_2, re_match):
10417         (re_match_2, re_set_registers): Use the new types.
10418         * lib/regex_internal.h (Idx, re_hashval_t): New types.
10419         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
10420         New macros.
10421         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
10422         (re_string_context_at, bin_tree_t, re_dfastate_t):
10423         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
10424         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
10425         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
10426         (re_string_char_size_at, re_string_wchar_at):
10427         (re_string_elem_size_at):
10428         Use the new types and macros to port to 64-bit hosts.
10429         Use unsigned types for internal values, so that the code
10430         mostly works even for arrays larger than SSIZE_MAX.
10431         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
10432         (search_duplicated_node, calc_eclosure_iter, fetch_number):
10433         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
10434         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
10435         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
10436         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
10437         (calc_inveclosure, parse_dup_op, build_range_exp):
10438         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
10439         (fetch_number, create_token_tree, mark_opt_subexp):
10440         Likewise.
10441         * lib/regex_internal.c (re_string_construct_common,
10442         create_ci_newstate):
10443         (create_cd_newstate, re_string_allocate, re_string_construct):
10444         (re_string_realloc_buffers, build_wcs_upper_buffer):
10445         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
10446         (re_string_reconstruct, re_string_peek_byte_case):
10447         (re_string_fetch_byte_case, re_string_context_at):
10448         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
10449         (re_node_set_init_copy, re_node_set_add_intersect):
10450         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10451         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10452         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
10453         (re_acquire_state, re_acquire_state_context, register_state):
10454         Likewise.
10455         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
10456         search_cur_bkref_entry):
10457         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
10458         (re_search_internal, re_search_2_stub, re_search_stub)
10459         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
10460         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
10461         (update_cur_sifted_state, check_dst_limits):
10462         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10463         (check_subexp_limits, sift_states_bkref, merge_state_array):
10464         (check_subexp_matching_top, get_subexp, get_subexp_sub):
10465         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
10466         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
10467         (expand_bkref_cache, check_node_accept_bytes):
10468         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
10469         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
10470         (acquire_init_state_context, check_halt_node_context):
10471         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
10472         (sift_states_backward, clean_state_log_if_needed):
10473         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
10474         (find_recover_state, transit_state_sb, transit_state_mb):
10475         (transit_state_bkref, build_trtable, match_ctx_clean):
10476         Likewise.
10477         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
10478         to work around an assumption that REG_MISSING is negative.
10479
10480         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
10481         (seek_collating_symbol_entry) [defined _LIBC]:
10482         (lookup_collation_sequence_value) [defined _LIBC]:
10483         (build_range_exp, build_collating_symbol) [defined _LIBC]:
10484         Use prototypes rather than old-style function definitions.
10485         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
10486         (transit_state_sb) [0]:
10487         (find_collation_sequence_value) [defined _LIBC]: Likewise.
10488
10489         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
10490         rm_eo.
10491
10492         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
10493         (optimize_subexps, lower_subexp):
10494         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
10495         since the signed shift might overflow.  Use 1u<<31 instead.
10496         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10497         Likewise.
10498         * lib/regexec.c (check_dst_limits_calc_pos_1,
10499         check_subexp_matching_top): Likewise.
10500
10501         * lib/regcomp.c (optimize_subexps, lower_subexp):
10502         Use CHAR_BIT rather than 8, for clarity.
10503         * lib/regexec.c (check_dst_limits_calc_pos_1):
10504         (check_subexp_matching_top): Likewise.
10505         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
10506         have to worry about portability issues when shifting it left.
10507         Remove no-longer-needed test for table_size > 0.
10508         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
10509         in a word, as the resulting behavior is undefined.
10510         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
10511         in one case, a <= should have been an <, and in another case the
10512         whole test was missing.
10513         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
10514         the standard name CHAR_BIT.
10515         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
10516         this is not true on one's complement and signed-magnitude hosts.
10517
10518         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
10519         next_last_offset.
10520         (struct re_dfa_t): Remove unused member states_alloc.
10521         * lib/regcomp.c (init_dfa): Don't initialize unused members.
10522
10523 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10524
10525         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
10526         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
10527         and large-file glibc and in 32-bit large-file Solaris.
10528
10529 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10530
10531         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
10532         lengths fit in regoff_t; this isn't true if regoff_t is the same
10533         width as size_t.
10534         * lib/regex.c (re_search_internal): 5th arg is LAST_START
10535         (= START + RANGE) instead of RANGE.  This avoids overflow
10536         problems when regoff_t is the same width as size_t.
10537         All callers changed.
10538         (re_search_2_stub): Check for overflow when adding the
10539         sizes of the two strings.
10540         (re_search_stub): Check for overflow when adding START
10541         to RANGE; if it occurs, substitute the extreme value.
10542
10543 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10544
10545         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
10546
10547 2005-08-31  Jim Meyering  <jim@meyering.net>
10548
10549         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
10550         a pointer-to-const.
10551         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
10552         (register_state): Likewise.
10553         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
10554         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10555         (group_nodes_into_DFAstates): Likewise.
10556
10557 2005-08-31  Jim Meyering  <jim@meyering.net>
10558
10559         * check-module: Add a FIXME comment.
10560
10561 2005-08-31  Eric Blake  <ebb9@byu.net>
10562
10563         * modules/unistd-safer (Files): Add unistd--.h.
10564         * modules/stdio-safer (Files): Add stdio--.h.
10565
10566 2005-08-31  Derek Price  <derek@ximbiot.com>
10567
10568         * lib/getdelim.c (getdelim): Return EOF on EOF.
10569         Reported by Larry Jones <lawrence.jones@ugs.com>.
10570
10571 2005-08-31  Bruno Haible  <bruno@clisp.org>
10572
10573         Avoid unnecessary diffs in the generated lib/Makefile.am.
10574         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
10575         the generated files.
10576         (func_import): Don't set cmd.
10577
10578 2005-08-31  Bruno Haible  <bruno@clisp.org>
10579
10580         * lib/strstr.c: Include <stddef.h>, for NULL.
10581         * lib/strcasestr.c: Likewise.
10582         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10583
10584 2005-08-31  Bruno Haible  <bruno@clisp.org>
10585
10586         * gnulib-tool: New option --macro-prefix.
10587         (func_import): Use macro_prefix.
10588         (import): Handle option --macro-prefix.
10589
10590 2005-08-31  Bruno Haible  <bruno@clisp.org>
10591
10592         * gnulib-tool (import): Rename most ac_* variables to cached_*.
10593         Also use new variables cached_lgpl, cached_libtool.
10594
10595 2005-08-31  Bruno Haible  <bruno@clisp.org>
10596
10597         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
10598         always instantiating them.
10599
10600 2005-08-31  Bruno Haible  <bruno@clisp.org>
10601
10602         * gnulib-tool (func_import): Read the previous cached settings
10603         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
10604         earlier added by gnulib but are now dropped. Warn when a gnulib file
10605         overwrites a non-gnulib file.
10606
10607 2005-08-31  Bruno Haible  <bruno@clisp.org>
10608
10609         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
10610         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
10611         projects that don't keep autogenerated files in CVS. Put into
10612         actioncmd only the specified modules, not the transitive closure.
10613
10614 2005-08-31  Bruno Haible  <bruno@clisp.org>
10615
10616         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
10617         Create directories that shall be filled.
10618         (import): Don't look for gl_* macros in configure.ac. Recurse across
10619         all directories containing a gnulib-cache.m4 files, if meaningful.
10620
10621 2005-08-31  Bruno Haible  <bruno@clisp.org>
10622
10623         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
10624         (import): Set seen_libtool when we see gl_LIBTOOL.
10625
10626 2005-08-31  Bruno Haible  <bruno@clisp.org>
10627
10628         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
10629         declaration macro definitions from generated gnulib.m4.
10630
10631 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
10632
10633         * lib/iconvme.h: Add prototype for iconv_alloc.
10634
10635 2005-08-29  Simon Josefsson  <jas@extundo.com>
10636
10637         * lib/iconvme.c: Fix errno.
10638
10639 2005-08-29  Bruno Haible  <bruno@clisp.org>
10640
10641         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
10642         that it works when the directory contains spaces.
10643
10644 2005-08-29  Bruno Haible  <bruno@clisp.org>
10645
10646         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
10647
10648 2005-08-29  Bruno Haible  <bruno@clisp.org>
10649
10650         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
10651         Emit more advice.
10652
10653 2005-08-29  Bruno Haible  <bruno@clisp.org>
10654         and Stepan Kasal  <kasal@ucw.cz>
10655
10656         * check-module: If more parameters are given, check each of them
10657         separately; add more exceptions, as noted by Jim Meyering.
10658         (check_module): New procedure.
10659         (%exempt_header): Now contains all exceptions.
10660
10661 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
10662
10663         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
10664
10665 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
10666
10667         * lib/iconvme.c: Split iconv_string into iconv_alloc.
10668
10669 2005-08-28  Bruno Haible  <bruno@clisp.org>
10670
10671         * m4/gnulib-tool.m4: New file.
10672
10673 2005-08-27  Jim Meyering  <jim@meyering.net>
10674
10675         * modules/unistd-safer (Files): Add pipe-safer.c.
10676         * modules/fcntl-safer (Files): Add creat-safer.c.
10677
10678 2005-08-27  Jim Meyering  <jim@meyering.net>
10679
10680         * m4/stdlib-safer.m4: New file.  From coreutils.
10681         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
10682         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
10683         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
10684         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
10685         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
10686
10687 2005-08-27  Jim Meyering  <jim@meyering.net>
10688
10689         * lib/fopen-safer.c: Merge minor changes from coreutils.
10690         * lib/dup-safer.c: Likewise.
10691         * lib/fd-safer.c: Likewise.
10692
10693         Merge from coreutils.
10694         * lib/stdio--.h: New file.
10695         * lib/stdlib--.h: New file.
10696         * lib/mkstemp-safer.c: New file.
10697
10698         GNU tar needs these.
10699         * lib/pipe-safer.c: New file.
10700         * lib/creat-safer.c: New file.
10701         * lib/fcntl--.h (creat): Define to creat_safer.
10702         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
10703         * lib/unistd--.h (pipe): Define to pipe_safer.
10704         * lib/unistd-safer.h: Declare pipe_safer.
10705
10706 2005-08-26  Simon Josefsson  <jas@extundo.com>
10707
10708         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
10709         Haible <bruno@clisp.org>.
10710
10711 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
10712
10713         * lib/regex_internal.h: Remove all references to
10714         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
10715         or better.
10716         (bitset_not, bitset_merge, bitset_not_merge):
10717         (bitset_mask, re_string_allocate, re_string_construct):
10718         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
10719         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
10720         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
10721         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
10722         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10723         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10724         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
10725         (re_acquire_state_context):
10726         Remove unnecessary forward decls.
10727         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
10728         Put __attribute at function definition,
10729         now that the function decl has been removed.
10730         * lib/regex_internal.c (re_string_peek_byte_case):
10731         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
10732         Likewise.
10733
10734 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
10735
10736         * m4/regex.m4: Add AC_PREREQ(2.50).
10737         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
10738
10739 2005-08-25  Simon Josefsson  <jas@extundo.com>
10740
10741         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
10742         __fsetlocking.
10743
10744 2005-08-25  Simon Josefsson  <jas@extundo.com>
10745
10746         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
10747         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
10748         GLIBC specific code.
10749
10750 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10751
10752         Make regex safe for g++.  This fixes one real bug (an "err"
10753         that should have been "*err").  g++ problem reported by
10754         Sam Steingold.
10755         * lib/regex_internal.h (re_calloc): New macro, consistent with
10756         re_malloc etc.  All callers of calloc changed to use re_calloc.
10757         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
10758         not int.  All callers changed.
10759         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
10760         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
10761         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
10762         (find_recover_state): Change "err" to "*err"; this fixes what
10763         appears to be a real bug.
10764         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
10765         versus int.
10766
10767 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10768
10769         * modules/regex (Depends-on): Add malloc, since the code
10770         assumes that !malloc(0) means failure.
10771
10772 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10773
10774         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
10775
10776         alloca modernization/simplification for regex.
10777         * lib/regex.c: Remove portability cruft for alloca.  This no longer
10778         needs to be at the start of the file, and can be moved into
10779         regex_internal.h and simplified.
10780         * lib/regex_internal.h: Include <alloca.h>.
10781         (__libc_use_alloca) [!defined _LIBC]: New macro.
10782         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
10783         now works outside glibc.
10784
10785 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10786
10787         * config/srclist.txt: Add glibc bugs 1241, 1245.
10788
10789 2005-08-25  Jim Meyering  <jim@meyering.net>
10790
10791         * lib/open-safer.c: Include <config.h>.
10792         Otherwise, we'd lose LARGEFILE support in any file using
10793         e.g. "fcntl--.h"
10794
10795 2005-08-25  Bruno Haible  <bruno@clisp.org>
10796
10797         * m4/minmax.m4: Require autoconf 2.52.
10798         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
10799         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
10800         alternatives of translit over the alphabet.
10801         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
10802
10803 2005-08-24  Simon Josefsson  <jas@extundo.com>
10804
10805         * tests/test-getpass.c: New file.
10806
10807 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10808
10809         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
10810         for GNU regex features.
10811
10812 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10813
10814         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
10815         * lib/regex.h (regerror): Likewise.
10816
10817         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
10818         requires this.  (The code never needed it.)
10819
10820         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
10821         All uses of recently-renamed identifiers changed to use the new,
10822         POSIX-compliant names.  The code will build and run just fine
10823         without these changes, but it's better to eat our own dog food
10824         and use the standard-conforming names.
10825
10826         * lib/regex.h: Fix a multitude of POSIX name space violations.
10827         These changes have an effect only for programs that define
10828         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
10829         do not change anything for programs compiled in the normal way.
10830         Also, there is no effect on the ABI.
10831
10832         (_REGEX_SOURCE): New macro.
10833         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
10834         defined and _GNU_SOURCE is not; this fixes a name space violation.
10835
10836         Rename the following macros to obey POSIX requirements.
10837         The old names are still visible as macros if _REGEX_SOURCE is defined.
10838         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
10839         RE_BACKSLASH_ESCAPE_IN_LISTS.
10840         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
10841         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
10842         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
10843         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
10844         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
10845         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
10846         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
10847         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
10848         (REG_INTERVALS): renamed from RE_INTERVALS.
10849         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
10850         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
10851         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
10852         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
10853         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
10854         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
10855         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
10856         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
10857         RE_UNMATCHED_RIGHT_PAREN_ORD.
10858         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
10859         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
10860         (REG_DEBUG): renamed from RE_DEBUG.
10861         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
10862         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
10863         unusual, since we can't clash with the POSIX REG_ICASE.
10864         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
10865         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
10866         (REG_NO_SUB): renamed from RE_NO_SUB.
10867         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
10868         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
10869         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
10870         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
10871         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
10872         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
10873         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
10874         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
10875         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
10876         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
10877         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
10878         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
10879         RE_SYNTAX_POSIX_MINIMAL_BASIC.
10880         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
10881         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
10882         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
10883         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
10884         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
10885         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
10886         (REG_FIXED): Renamed from REGS_FIXED.
10887         (REG_NREGS): Renamed from RE_NREGS.
10888
10889         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
10890         of other REG_* macros, since POSIX says the user is allowed to
10891         #undef these macros selectively.
10892
10893         (reg_errcode_t): Update comment stating what other tables need
10894         to be consistent.
10895
10896         Rename the following enum values to obey POSIX requirements.
10897         The old names are still visible as macros.
10898         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
10899         is not defined, since GNU is supposed to be a superset of POSIX as
10900         much as possible, and since we want reg_errcode_t to be a signed
10901         type for implementation consistency.
10902         (_REG_NOERROR): Renamed from REG_NOERROR.
10903         (_REG_NOMATCH): Renamed from REG_NOMATCH.
10904         (_REG_BADPAT): Renamed from REG_BADPAT.
10905         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
10906         (_REG_ECTYPE): Renamed from REG_ECTYPE.
10907         (_REG_EESCAPE): Renamed from REG_EESCAPE.
10908         (_REG_ESUBREG): Renamed from REG_ESUBREG.
10909         (_REG_EBRACK): Renamed from REG_EBRACK.
10910         (_REG_EPAREN): Renamed from REG_EPAREN.
10911         (_REG_EBRACE): Renamed from REG_EBRACE.
10912         (_REG_BADBR): Renamed from REG_BADBR.
10913         (_REG_ERANGE): Renamed from REG_ERANGE.
10914         (_REG_ESPACE): Renamed from REG_ESPACE.
10915         (_REG_BADRPT): Renamed from REG_BADRPT.
10916         (_REG_EEND): Renamed from REG_EEND.
10917         (_REG_ESIZE): Renamed from REG_ESIZE.
10918         (_REG_ERPAREN): Renamed from REG_ERPAREN.
10919         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
10920         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
10921         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
10922         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
10923
10924         (_REG_RE_NAME, _REG_RM_NAME): New macros.
10925         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
10926         changed.  But support the old name if the new one is not defined
10927         and if _REGEX_SOURCE.
10928
10929         Change the following member names in struct re_pattern_buffer.
10930         The old names are still supported if !_REGEX_SOURCE.
10931         The new names are always supported, regardless of _REGEX_SOURCE.
10932         (re_buffer): Renamed from buffer.
10933         (re_allocated): Renamed from allocated.
10934         (re_used): Renamed from used.
10935         (re_syntax): Renamed from syntax.
10936         (re_fastmap): Renamed from fastmap.
10937         (re_translate): Renamed from translate.
10938         (re_can_be_null): Renamed from can_be_null.
10939         (re_regs_allocated): Renamed from regs_allocated.
10940         (re_fastmap_accurate): Renamed from fastmap_accurate.
10941         (re_no_sub): Renamed from no_sub.
10942         (re_not_bol): Renamed from not_bol.
10943         (re_not_eol): Renamed from not_eol.
10944         (re_newline_anchor): Renamed from newline_anchor.
10945
10946         Change the following member names in struct re_registers.
10947         The old names are still supported if !_REGEX_SOURCE.
10948         The new names are always supported, regardless of _REGEX_SOURCE.
10949         (rm_num_regs): Renamed from num_regs.
10950         (rm_start): Renamed from start.
10951         (rm_end): Renamed from end.
10952
10953         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
10954         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
10955         Prepend __ to parameter names.
10956
10957         Undo yesterday's changes.
10958
10959 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10960
10961         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
10962         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
10963         lib/regex.c.
10964
10965 2005-08-24  Jim Meyering  <jim@meyering.net>
10966
10967         Sync from coreutils.
10968         * m4/fcntl-safer.m4: New file.
10969
10970         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
10971         and object files for this module.
10972
10973 2005-08-24  Jim Meyering  <jim@meyering.net>
10974
10975         Sync from coreutils.
10976         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
10977
10978 2005-08-24  Jim Meyering  <jim@meyering.net>
10979
10980         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
10981         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
10982
10983 2005-08-24  Jim Meyering  <jim@meyering.net>
10984
10985         * modules/fcntl-safer: New module.
10986         * modules/fts (Depends-on): Add fcntl-safer.
10987         * MODULES.html.sh (File descriptor based Input/Output):
10988         Add fcntl-safer.
10989
10990 2005-08-24  Bruno Haible  <bruno@clisp.org>
10991
10992         Support for unit test modules.
10993         * modules/README: Mention tests modules.
10994         * modules/TEMPLATE-TESTS: New file.
10995         * gnulib-tool: New options --extract-tests-module, --with-tests and
10996         --tests-base (unused for the moment).
10997         (testsbase, inctests): New variables.
10998         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
10999         (func_verify_module): Exclude TEMPLATE-TESTS.
11000         (func_verify_nontests_module, func_verify_tests_module): New functions.
11001         (func_get_dependencies): Add implicit dependency for tests modules.
11002         (func_get_tests_module): New function.
11003         (func_modules_transitive_closure): When --with-tests was specified,
11004         include the unit tests as well, unless explicitly avoided.
11005         (func_emit_lib_Makefile_am): Ignore the tests modules here.
11006         (func_emit_tests_Makefile_am): New function.
11007         (func_create_testdir): When --with-tests was specified, emit a
11008         tests/ directory.
11009         * MODULES.html.sh (Future developments): Update.
11010
11011 2005-08-24  Bruno Haible  <bruno@clisp.org>
11012
11013         * modules/tls-tests: New file.
11014         * tests/test-tls.c: New file, from GNU gettext.
11015
11016 2005-08-24  Bruno Haible  <bruno@clisp.org>
11017
11018         * modules/lock-tests: New file.
11019         * tests/test-lock.c: New file, from GNU gettext.
11020
11021 2005-08-24  Bruno Haible  <bruno@clisp.org>
11022
11023         * lib/lock.h: Add multiple inclusion guard.
11024         * lib/tls.h: Add multiple inclusion guard.
11025
11026 2005-08-24  Bruno Haible  <bruno@clisp.org>
11027
11028         * gnulib-tool: Add support for the --aux-dir option to
11029         --create-testdir, --create-megatestdir, --test, --megatest.
11030         (func_create_testdir, func_create_megatestdir): Optionally emit a
11031         AC_CONFIG_AUX_DIR directive.
11032         (create-testdir, create-megatestdir, test, megatest): Provide a
11033         default value for $auxdir.
11034
11035 2005-08-24  Bruno Haible  <bruno@clisp.org>
11036
11037         * gnulib-tool (import): Use compound statement instead of subshell
11038         where possible.
11039
11040 2005-08-24  Bruno Haible  <bruno@clisp.org>
11041
11042         * gnulib-tool (import): Change --aux-dir default to "build-aux".
11043
11044 2005-08-24  Bruno Haible  <bruno@clisp.org>
11045
11046         * gnulib-tool (func_version): Update.
11047
11048 2005-08-24  Bruno Haible  <bruno@clisp.org>
11049
11050         * gnulib-tool (func_import, func_create_testdir,
11051         func_create_megatestdir): Quote all autoconf macro arguments.
11052
11053 2005-08-24  Bruno Haible  <bruno@clisp.org>
11054
11055         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
11056         option --force, because --force causes the aclocal.m4 of each
11057         subdirectory to be newer than the corresponding config.h.in.
11058
11059 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11060
11061         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
11062         All contents moved to gl_REGEX.
11063         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
11064         assume that it does.
11065
11066 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11067
11068         * lib/regex.h (REG_NOSYS)
11069         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
11070         Define, since POSIX requires it as of 2001.
11071         (_REG_ENOSYS)
11072         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
11073         New private symbol, used to keep the enum signed in all cases.
11074         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
11075         Youngman in
11076         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
11077
11078         * lib/regex_internal.c (re_string_skip_chars, register_state):
11079         (calc_state_hash):
11080         Remove forward decls; no longer needed now that we use prototypes.
11081         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
11082         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
11083         (clean_state_log_if_needed): Likewise.
11084
11085 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11086
11087         * config/srclist.txt: Add glibc bugs 1231-1233.
11088
11089 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11090
11091         Fix problems reported by Sam Steingold in
11092         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
11093         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
11094         assumed that reg_errcode_t is a signed type, which is not
11095         necessarily true if _XOPEN_SOURCE is not defined.
11096         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
11097         since some compilers warn about it otherwise.
11098
11099 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11100
11101         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
11102         (init_word_char, create_initial_state, duplicate_node_closure):
11103         (fetch_token, peek_token_bracket, build_range_exp):
11104         (build_collating_symbol): Remove forward decls; no longer needed
11105         now that we use prototypes.
11106
11107         * lib/regcomp.c:
11108         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
11109         (re_compile_fastmap_iter, regcomp, regerror, regfree):
11110         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
11111         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
11112         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
11113         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
11114         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
11115         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
11116         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
11117         (build_range_exp, build_collating_symbol, parse_bracket_exp):
11118         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
11119         (build_charclass, build_charclass_op, fetch_number, create_tree):
11120         (create_token_tree, mark_opt_subexp, duplicate_tree):
11121         Use prototypes rather than old-style definitions.
11122
11123         * lib/regex_internal.c:
11124         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
11125         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
11126         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11127         (re_string_reconstruct, re_string_peek_byte_case):
11128         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
11129         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11130         (re_node_set_init_copy, re_node_set_add_intersect):
11131         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11132         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11133         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11134         (re_acquire_state, re_acquire_state_context, register_state):
11135         (create_ci_newstate, create_cd_newstate, free_state):
11136         Likewise.
11137         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
11138         re_search_2):
11139         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
11140         (re_search_internal, prune_impossible_nodes):
11141         (acquire_init_state_context, check_matching, static):
11142         (check_halt_node_context, check_halt_state_context, proceed_next_node):
11143         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
11144         (update_regs, sift_states_backward, build_sifted_states):
11145         (clean_state_log_if_needed, merge_state_array):
11146         (update_cur_sifted_state, add_epsilon_src_nodes):
11147         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
11148         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
11149         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
11150         (find_recover_state, check_subexp_matching_top, transit_state_mb):
11151         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
11152         (check_arrival, check_arrival_add_next_nodes):
11153         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11154         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11155         (check_node_accept_bytes, check_node_accept, extend_buffers):
11156         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
11157         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
11158         (sift_ctx_init):
11159         Likewise.
11160
11161         * lib/regex_internal.h:
11162         (re_string_allocate, re_string_construct, re_string_reconstruct):
11163         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
11164         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
11165         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
11166         (re_string_context_at, re_string_peek_byte_case):
11167         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
11168         is defined, since we now use prototypes always.
11169
11170         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
11171         C89 or better.  All uses removed.
11172
11173 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11174
11175         * config/srclist.txt: Add glibc bugs 1220-1227.
11176
11177 2005-08-20  Jim Meyering  <jim@meyering.net>
11178
11179         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
11180         of unused local, dfa.
11181
11182 2005-08-20  Bruno Haible  <bruno@clisp.org>
11183
11184         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
11185
11186 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11187
11188         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
11189         (re_node_set_insert_last, re_dfa_add_node):
11190         Rename local variables to avoid GCC shadowing warnings.
11191
11192 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11193
11194         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
11195         [defined lint]: Suppress bogus uninitialized-variable warnings.
11196
11197         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
11198         and let the caller return REG_ESPACE if out of space.  This
11199         removes an uninitialied-variable warning with GCC 4.0.1, and also
11200         avoids taking the address of a local variable.  All callers
11201         changed.
11202
11203 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11204
11205         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
11206         $LIBCSRC/posix/regexec.c.
11207         Add glibc bug 1217 for regcomp.c.
11208
11209 2005-08-19  Jim Meyering  <jim@meyering.net>
11210
11211         * lib/regexec.c (proceed_next_node): Redo local variables to
11212         avoid GCC shadowing warnings.
11213
11214 2005-08-18  Bruno Haible  <bruno@clisp.org>
11215
11216         * lib/strstr.c (strstr): Fix return value in multibyte case.
11217         * lib/strcasestr.c (strcasestr): Likewise.
11218
11219 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11220
11221         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
11222
11223 2005-08-17  Jim Meyering  <jim@meyering.net>
11224
11225         Make the %s format (seconds since the epoch) work for a negative
11226         number and when used with a zero-padded field width, e.g. %015s.
11227
11228         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
11229         label so that it precedes the code to set `digits'.  Otherwise,
11230         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
11231         print `00-22'.  Now, it prints `-0022', as it should.
11232
11233 2005-08-17  Bruno Haible  <bruno@clisp.org>
11234
11235         * modules/strstr (Files): Add m4/mbrtowc.m4.
11236         (Depends-on): Add mbuiter.
11237
11238 2005-08-17  Bruno Haible  <bruno@clisp.org>
11239
11240         * modules/strcasestr: New file.
11241         * MODULES.html.sh (String handling, based on ANSI C 89): Add
11242         strcasestr.
11243
11244 2005-08-17  Bruno Haible  <bruno@clisp.org>
11245
11246         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
11247
11248 2005-08-17  Bruno Haible  <bruno@clisp.org>
11249
11250         * modules/mbuiter: New file.
11251         * MODULES.html.sh (Extended multibyte and wide character utilities):
11252         Add mbuiter.
11253
11254 2005-08-17  Bruno Haible  <bruno@clisp.org>
11255
11256         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
11257         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
11258
11259 2005-08-17  Bruno Haible  <bruno@clisp.org>
11260
11261         * m4/strcasestr.m4: New file.
11262
11263 2005-08-17  Bruno Haible  <bruno@clisp.org>
11264
11265         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
11266         * lib/strstr.c: Completely rewritten, with multibyte locale support.
11267
11268 2005-08-17  Bruno Haible  <bruno@clisp.org>
11269
11270         * lib/strcasestr.h: New file.
11271         * lib/strcasestr.c: New file.
11272
11273 2005-08-17  Bruno Haible  <bruno@clisp.org>
11274
11275         * lib/strcasecmp.c: Use mbuiter.h.
11276
11277 2005-08-17  Bruno Haible  <bruno@clisp.org>
11278
11279         * lib/mbuiter.h: New file.
11280
11281 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11282
11283         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
11284         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
11285         and gl_GETOPT are both invoked via different paths (as happens
11286         with GNU tar CVS because it uses both argp and getopt), the former
11287         wins.
11288
11289 2005-08-16  Bruno Haible  <bruno@clisp.org>
11290
11291         * modules/tls: New file.
11292         * MODULES.html.sh (Multithreading): Add tls.
11293
11294 2005-08-16  Bruno Haible  <bruno@clisp.org>
11295
11296         * modules/strnlen1: New file.
11297         * MODULES.html.sh (String handling): Add strnlen1.
11298
11299 2005-08-16  Bruno Haible  <bruno@clisp.org>
11300
11301         * modules/strcase (Files): Add m4/mbrtowc.m4.
11302         (Depends-on): Add strnlen1, mbchar.
11303
11304 2005-08-16  Bruno Haible  <bruno@clisp.org>
11305
11306         * modules/mbiter: New file.
11307         * MODULES.html.sh (Extended multibyte and wide character utilities):
11308         Add mbiter.
11309
11310 2005-08-16  Bruno Haible  <bruno@clisp.org>
11311
11312         * modules/mbfile: New file.
11313         * MODULES.html.sh (Extended multibyte and wide character utilities):
11314         Add mbfile.
11315
11316 2005-08-16  Bruno Haible  <bruno@clisp.org>
11317
11318         * modules/mbchar: New file.
11319         * MODULES.html.sh (Extended multibyte and wide character utilities):
11320         New section.
11321
11322 2005-08-16  Bruno Haible  <bruno@clisp.org>
11323
11324         * m4/tls.m4: New file, from GNU gettext.
11325
11326 2005-08-16  Bruno Haible  <bruno@clisp.org>
11327
11328         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
11329         always.
11330         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
11331
11332 2005-08-16  Bruno Haible  <bruno@clisp.org>
11333
11334         * m4/mbiter.m4: New file.
11335
11336 2005-08-16  Bruno Haible  <bruno@clisp.org>
11337
11338         * m4/mbfile.m4: New file.
11339
11340 2005-08-16  Bruno Haible  <bruno@clisp.org>
11341
11342         * m4/mbchar.m4: New file.
11343
11344 2005-08-16  Bruno Haible  <bruno@clisp.org>
11345
11346         * lib/tls.h: New file, from GNU gettext.
11347         * lib/tls.c: New file, from GNU gettext.
11348
11349 2005-08-16  Bruno Haible  <bruno@clisp.org>
11350
11351         * lib/strnlen1.h: New file.
11352         * lib/strnlen1.c: New file.
11353
11354 2005-08-16  Bruno Haible  <bruno@clisp.org>
11355
11356         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
11357         (mbi_init): Update.
11358         (mbi_avail, mbi_advance): Let the iteration end before the terminating
11359         NUL byte, not after it.
11360
11361 2005-08-16  Bruno Haible  <bruno@clisp.org>
11362
11363         * lib/strcase.h (strcasecmp): Add note in comments.
11364         * lib/strncasecmp.c: Use code from strcasecmp.c.
11365         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
11366         (strcasecmp): Work correctly in multibyte locales.
11367
11368 2005-08-16  Bruno Haible  <bruno@clisp.org>
11369
11370         * lib/mbiter.h: New file.
11371
11372 2005-08-16  Bruno Haible  <bruno@clisp.org>
11373
11374         * lib/mbfile.h: New file.
11375
11376 2005-08-16  Bruno Haible  <bruno@clisp.org>
11377
11378         * lib/mbchar.h: New file.
11379         * lib/mbchar.c: New file.
11380
11381 2005-08-16  Bruno Haible  <bruno@clisp.org>
11382
11383         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
11384         the valid ones. Makes the comparison operations transitive:
11385         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
11386         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
11387
11388 2005-08-15  Simon Josefsson  <jas@extundo.com>
11389
11390         * modules/ssize_t (License): Change to 'unlimited'.
11391
11392         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
11393
11394 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11395
11396         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
11397         Add comments for each pending glibc patch.
11398
11399 2005-08-15  Bruno Haible  <bruno@clisp.org>
11400
11401         * lib/regex.h (__restrict_arr): Don't define to __restrict if
11402         __cplusplus is defined.
11403
11404 2005-08-14  Jim Meyering  <jim@meyering.net>
11405
11406         Sync from coreutils.
11407
11408         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
11409         Use the hash-table-based cycle-detection code not just when
11410         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
11411         Reported by James Youngman in
11412         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
11413         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
11414         FTS_TIGHT_CYCLE_CHECK.
11415         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
11416         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
11417         once again.
11418         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
11419         * lib/fts.c (fd_safer): Remove decl.
11420         Include fcntl--.h rather than unistd-safer.h
11421         (fts_safe_changedir): Don't call fd_safer; no longer needed
11422         now that we include fcntl--.h.
11423
11424 2005-08-12  Simon Josefsson  <jas@extundo.com>
11425
11426         * modules/getndelim2: Use ssize_t module.
11427         * modules/getnline: Likewise.
11428         * modules/safe-read: Likewise.
11429         * modules/xreadlink: Likewise.
11430
11431         * modules/ssize_t: New file.
11432
11433 2005-08-12  Simon Josefsson  <jas@extundo.com>
11434
11435         * m4/readline.m4: Look for termcap, curses or ncurses if required.
11436
11437 2005-08-12  Simon Josefsson  <jas@extundo.com>
11438
11439         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11440         ssize_t.
11441
11442 2005-08-12  Simon Josefsson  <jas@extundo.com>
11443
11444         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
11445         readline, getdelim and check_version.
11446         (Support for systems lacking ISO C 99: Sizes of integer types):
11447         Add size_max.
11448
11449 2005-08-12  Bruno Haible  <bruno@clisp.org>
11450
11451         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
11452
11453 2005-08-11  Simon Josefsson  <jas@extundo.com>
11454
11455         * modules/readline: New file.
11456
11457         * modules/strnlen (Files): Add strnlen.h.
11458
11459 2005-08-11  Simon Josefsson  <jas@extundo.com>
11460
11461         * m4/readline.m4: New file.
11462
11463 2005-08-11  Simon Josefsson  <jas@extundo.com>
11464
11465         * lib/readline.h, readline.c: New file.
11466
11467 2005-08-11  Simon Josefsson  <jas@extundo.com>
11468
11469         * doc/gnulib.texi (Initial import, Finishing touches): Mention
11470         gl_AVOID.
11471
11472 2005-08-11  Bruno Haible  <bruno@clisp.org>
11473
11474         * lib/strnlen.h (strnlen): Change parameter name to match comment.
11475
11476 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
11477
11478         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
11479
11480 2005-08-10  Simon Josefsson  <jas@extundo.com>
11481
11482         * tests/test-iconvme.c: New file.
11483
11484 2005-08-10  Simon Josefsson  <jas@extundo.com>
11485
11486         * m4/strnlen.m4: New file.
11487
11488         * m4/strndup.m4: Don't check for strnlen declaration, done in
11489         strnlen.m4.
11490
11491 2005-08-10  Simon Josefsson  <jas@extundo.com>
11492
11493         * lib/strndup.c: Use strnlen.h.
11494
11495         * lib/strnlen.h: New file.
11496
11497 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11498
11499         * README: Typos.
11500
11501 2005-08-02  Simon Josefsson  <jas@extundo.com>
11502
11503         * modules/readline: New file.
11504
11505 2005-08-02  Simon Josefsson  <jas@extundo.com>
11506
11507         * modules/getdelim: New file.
11508
11509         * modules/getline: Rewrite, don't use getndelim2.
11510
11511 2005-08-02  Simon Josefsson  <jas@extundo.com>
11512
11513         * m4/getline.m4: Separate out getdelim stuff into separate module.
11514
11515         * m4/getdelim.m4: New file.
11516
11517 2005-08-02  Simon Josefsson  <jas@extundo.com>
11518
11519         * lib/getline.h, getline.c: Rewrite.
11520
11521         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
11522
11523 2005-07-31  Bruno Haible  <bruno@clisp.org>
11524
11525         * lib/lock.h (gl_lock_initializer): New macro.
11526         (gl_lock_define_initialized): Use it.
11527         (gl_rwlock_initializer): New macro.
11528         (gl_rwlock_define_initialized): Use it.
11529         (gl_recursive_lock_initializer): New macro.
11530         (gl_recursive_lock_define_initialized): Use it.
11531
11532 2005-07-30  Karl Berry  <karl@gnu.org>
11533
11534         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
11535         Report from Ben Pfaff, regarding getopt.
11536
11537 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
11538
11539         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
11540         normal way.
11541         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
11542         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
11543         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
11544         (gl_GETOPT): Use the new macros.  Most of the implementation
11545         is moved to the new macros.  This is for programs like Emacs
11546         that don't want all the functionality of gl_GETOPT.
11547
11548 2005-07-26  Bruno Haible  <bruno@clisp.org>
11549
11550         * m4/lock.m4: Update from GNU gettext.
11551
11552 2005-07-26  Bruno Haible  <bruno@clisp.org>
11553
11554         * lib/lock.h: Update from GNU gettext.
11555         * lib/lock.c: Update from GNU gettext.
11556
11557 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
11558
11559         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
11560         obsolescent AC_TRY_RUN.  Include the default includes files, for
11561         'exit'.
11562
11563 2005-07-24  Bruno Haible  <bruno@clisp.org>
11564
11565         * modules/visibility: New file.
11566         * MODULES.html.sh (Misc): Add visibility.
11567
11568 2005-07-24  Bruno Haible  <bruno@clisp.org>
11569
11570         * m4/visibility.m4: New file.
11571
11572 2005-07-24  Bruno Haible  <bruno@clisp.org>
11573
11574         * doc/visibility.texi: New file.
11575
11576 2005-07-22  Bruno Haible  <bruno@clisp.org>
11577
11578         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
11579         $(ALLOCA_H), redundant through BUILT_SOURCES.
11580         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
11581         redundant through BUILT_SOURCES.
11582         * modules/byteswap (Makefile.am): Remove explicit dependency on
11583         $(BYTESWAP_H), redundant through BUILT_SOURCES.
11584         * modules/fnmatch (Makefile.am): Remove explicit dependency on
11585         $(FNMATCH_H), redundant through BUILT_SOURCES.
11586         * modules/getopt (Makefile.am): Remove explicit dependency on
11587         $(GETOPT_H), redundant through BUILT_SOURCES.
11588         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
11589         redundant through BUILT_SOURCES.
11590         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
11591         redundant through BUILT_SOURCES.
11592         * modules/stdbool (Makefile.am): Remove explicit dependency on
11593         $(STDBOOL_H), redundant through BUILT_SOURCES.
11594         * modules/stdint (Makefile.am): Remove explicit dependency on
11595         $(STDINT_H), redundant through BUILT_SOURCES.
11596         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
11597         Remove explicit dependency on $(SYSEXITS_H).
11598         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
11599
11600 2005-07-18  Simon Josefsson  <jas@extundo.com>
11601
11602         * lib/check-version.c (check_version): Accept identical versions too.
11603
11604 2005-07-18  Bruno Haible  <bruno@clisp.org>
11605
11606         * modules/lock: New file.
11607         * MODULES.html.sh (Multithreading): New section.
11608
11609 2005-07-18  Bruno Haible  <bruno@clisp.org>
11610
11611         * m4/lock.m4: New file, from GNU gettext.
11612
11613 2005-07-18  Bruno Haible  <bruno@clisp.org>
11614
11615         * lib/lock.h: New file, from GNU gettext.
11616         * lib/lock.c: New file, from GNU gettext.
11617
11618 2005-07-18  Bruno Haible  <bruno@clisp.org>
11619
11620         * lib/lock.h (gl_once_t): New type.
11621         (gl_once_define, gl_once): New macros.
11622         * lib/lock.c (fresh_once): New variable.
11623         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
11624         functions.
11625
11626 2005-07-16  Simon Josefsson  <jas@extundo.com>
11627
11628         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
11629         workaround, suggested by Bruno.
11630
11631 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11632
11633         * modules/xalloc (Depends-on): Add xalloc-die.
11634         * modules/xvasprintf (Depends-on): Add xalloc-die.
11635
11636 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11637
11638         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
11639         with a minor change.
11640
11641 2005-07-15  Bruno Haible  <bruno@clisp.org>
11642
11643         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
11644         When using lib/poll.c, define poll as rpl_poll.
11645
11646 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
11647
11648         * modules/argp (Depends-on): Remove unlocked-io.
11649
11650 2005-07-14  Derek Price  <derek@ximbiot.com>
11651
11652         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
11653         for glob symlink bug.
11654
11655 2005-07-14  Bruno Haible  <bruno@clisp.org>
11656
11657         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
11658         Instead, test for *_unlocked function declarations directly.
11659
11660 2005-07-11  Simon Josefsson  <jas@extundo.com>
11661
11662         * modules/size_max: New file.
11663
11664         * modules/xsize: Depend on size_max module for size_max.m4.
11665
11666 2005-07-11  Simon Josefsson  <jas@extundo.com>
11667
11668         * lib/size_max.h: New file.
11669
11670 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
11671
11672         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
11673         copyright symbol and the year.
11674         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
11675         (version_etc_va): Use parameterized copyright notice.
11676         Reword to conform to the current GNU coding standards.
11677
11678 2005-07-11  Karl Berry  <karl@gnu.org>
11679
11680         * doc/gnulib.texi (Quoting): new node.
11681         (Initial import): more info, from Patrice.
11682
11683 2005-07-11  Bruno Haible  <bruno@clisp.org>
11684
11685         * gnulib-tool (func_usage): Document option --avoid.
11686         (Command line options): Handle --avoid.
11687         (func_acceptable): New function.
11688         (func_modules_transitive_closure): Use it.
11689
11690 2005-07-11  Bruno Haible  <bruno@clisp.org>
11691
11692         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
11693         Reported by Jim Meyering.
11694
11695 2005-07-10  Bruno Haible  <bruno@clisp.org>
11696
11697         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
11698         Needed when size_t is smaller than 'unsigned int'.
11699         Reported by Paul Eggert.
11700
11701 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11702
11703         * modules/argp (Depends-on): Add unlocked-io
11704
11705 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11706
11707         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
11708         block of defines.
11709
11710 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11711
11712         * config/srclist.txt: Comment out regcomp.c, since we have a porting
11713         fix now.
11714
11715 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
11716         and Paul Eggert  <eggert@cs.ucla.edu>
11717
11718         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
11719         in wint_t, not wchar_t.  Remove now-unnecessary cast.
11720
11721 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11722
11723         * modules/regex (Files): Add lib/regex_internal.c,
11724         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
11725         (Depends-on): Add extensions.
11726         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
11727
11728 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11729
11730         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
11731         pathconf.
11732         * m4/same.m4 (gl_SAME): Likewise.
11733         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
11734
11735         * m4/regex.m4: Adjust to new libc regex implementation.
11736         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
11737         all the .c and .h parts of (the new) regex.
11738         Quote the m4 stuff better.
11739         Check for RE_ICASE bug of old gnulib.
11740         Check for REG_STARTEND of recent libc.
11741         Rename local variables from jm_* to gl_*.
11742         Quote operand of "test -f".
11743         Say "recent enough" version of libc, not "version 2".
11744         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
11745         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
11746         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
11747         Remove check for btowc, isascii.
11748         Require AM_LANGINFO_CODESET.
11749
11750 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11751
11752         * lib/regex.c, regex.h: Sync from libc.
11753         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
11754         * lib/regexec.c:
11755         New files, synced from libc, except that regex_internal.h
11756         currently has a small porting fix.
11757
11758 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11759
11760         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
11761         regex_internal.c, regexec.c.
11762         Add regex_internal.h too, but as a comment, since the libc version
11763         is currently broken in gnulib mode.
11764
11765 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11766
11767         Support programs like Emacs that use gnulib but not gettext.
11768         * MODULES.html.sh (Internationalization functions): Add gettext-h.
11769         * modules/gettext-h: New file.
11770         * modules/gettext (Files): Remove lib/gettext.h.
11771         (Depends-on): Add gettext-h.
11772         (Makefile.am): Remove lib_SOURCES.
11773         * modules/argmatch, modules/c-stack, modules/closeout:
11774         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
11775         * modules/execute, modules/file-type, modules/getaddrinfo:
11776         * modules/getopt, modules/human, modules/javacomp:
11777         * modules/javaexec, modules/mkdir-p, modules/obstack:
11778         * modules/openat, modules/pagealign_alloc, modules/pipe:
11779         * modules/quotearg, modules/regex, modules/rpmatch:
11780         * modules/unicodeio, modules/userspec, modules/version-etc:
11781         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
11782         * modules/xsetenv:
11783         Depend on gettext-h, not gettext.
11784
11785 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11786
11787         * gnulib-tool (func_import): Add support for 'public domain' license.
11788         * modules/alloca, modules/atexit, modules/memmove:
11789         Now public domain, not GPL.
11790         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
11791         * modules/realloc, modules/strerror, modules/strtod:
11792         Now LGPL, not GPL.
11793
11794 2005-07-05  Bruno Haible  <bruno@clisp.org>
11795
11796         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
11797         autoconf CVS. Needed for mingw.
11798
11799 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11800
11801         Remove the dependency of the strftime module on the tzset module.
11802         * modules/strftime (Depends-on): Remove dependency on tzset.
11803
11804 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11805
11806         Remove the dependency of the strftime module on the tzset module.
11807         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
11808         gl_FUNC_TZSET_CLOBBER.
11809
11810 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11811
11812         Remove the dependency of the strftime module on the tzset module.
11813         * lib/strftime.c (my_strftime)
11814         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
11815         Copy the input structure, to work around some of the bug with
11816         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
11817         Solaris releases, you should also use the tzset module, but we won't
11818         require it as a dependency any more since we don't want LGPLed code
11819         to depend on GPLed code.
11820
11821 2005-07-02  Jim Meyering  <jim@meyering.net>
11822
11823         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
11824         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
11825         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
11826         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
11827
11828 2005-07-02  Jim Meyering  <jim@meyering.net>
11829
11830         * lib/backupfile.c (backup_args): Change a `0' to NULL.
11831
11832 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11833
11834         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
11835         declares only 'struct timespec;' (!).
11836
11837 2005-07-01  Jim Meyering  <jim@meyering.net>
11838
11839         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
11840         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
11841         * lib/save-cwd.c, tempname.c:
11842         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
11843         and don't include <sys/file.h>).
11844
11845 2005-06-29  Jim Meyering  <jim@meyering.net>
11846
11847         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
11848         type name.  Use the variable name instead.
11849         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
11850         Likewise.
11851
11852 2005-06-28  Simon Josefsson  <jas@extundo.com>
11853
11854         * modules/check-version (Files): Add check-version.m4.
11855
11856 2005-06-28  Simon Josefsson  <jas@extundo.com>
11857
11858         * m4/check-version.m4: New file, suggested by Jim Meyering
11859         <jim@meyering.net>.
11860
11861 2005-06-28  Simon Josefsson  <jas@extundo.com>
11862
11863         * lib/check-version.h, lib/check-version.c: New files.
11864
11865 2005-06-28  Simon Josefsson  <jas@extundo.com>
11866
11867         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
11868         collision with global variable.  Better indentation.  Don't
11869         increment buffer pointer beyond buffer end.  Based on comments
11870         from Paul Eggert <eggert@cs.ucla.edu>.
11871
11872         * lib/base64.h: Indent.
11873
11874 2005-06-28  Simon Josefsson  <jas@extundo.com>
11875
11876         * doc/gnulib.texi (Library version handling): New section.
11877
11878 2005-06-28  Jim Meyering  <jim@meyering.net>
11879
11880         * check-module (find_included_lib_files): Hard-code another
11881         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
11882         but modules/fts-lgpl (correctly) does not list those files.
11883
11884         * modules/canonicalize (Files): Add lib/pathmax.h.
11885
11886 2005-06-25  Simon Josefsson  <jas@extundo.com>
11887
11888         * modules/check-version: New file.
11889
11890 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
11891
11892         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
11893         initializer of struct addrinfo, as an indication that we don't
11894         care how many members the structure has.
11895
11896 2005-06-24  Derek Price  <derek@ximbiot.com>
11897         and Bruno Haible  <bruno@clisp.org>
11898
11899         Remove stat module & update lstat.
11900         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
11901         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
11902         * m4/stat.m4: Remove this file.
11903
11904 2005-06-24  Derek Price  <derek@ximbiot.com>
11905         and Bruno Haible  <bruno@clisp.org>
11906
11907         Remove stat module & update lstat.
11908         * lib/stat.c: Remove this file...
11909         (slash_aware_lstat): ...moving this content and its support...
11910         * lib/lstat.c (rpl_lstat): ...into here.
11911         * lib/lstat.h: New file.
11912
11913 2005-06-24  Derek Price  <derek@ximbiot.com>
11914         and Bruno Haible  <bruno@clisp.org>
11915
11916         Remove stat module & update lstat.
11917         * config/srclist.txt (libc sources): Remove stat.
11918
11919 2005-06-24  Derek Price  <derek@ximbiot.com>
11920         and Bruno Haible  <bruno@clisp.org>
11921
11922         Remove stat module & update lstat.
11923         * MODULES.html.sh (stat): Remove.
11924         * MODULES.html: Regenerated.
11925         * modules/lstat (Description): Correct function name.
11926         (Files): Add "lstat.h".
11927         (Depends-on): Remove stat, add xalloc, stat-macros.
11928         * modules/stat: Remove this file.
11929         (Include): Add "lstat.h", remove <sys/stat.h>.
11930
11931 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
11932
11933         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
11934         (ranged_convert): Don't save conversion in a temporary struct.
11935         This causes a warning with GCC 4.0.0, and anyway in the typical
11936         case it's not worth the extra 100 bytes or so of code.
11937         (ranged_convert, __mktime_internal): When calling a function via a
11938         pointer P, use P () rather than (*P) (), as we now assume C89 or
11939         better.
11940
11941 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
11942
11943         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
11944         "who -r" failed to give output.  Problem reported by Tim Waugh.
11945
11946         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
11947         (xcalloc): Use it to avoid needless tests.
11948         Problem reported by Jim Meyering.
11949
11950 2005-06-20  Derek Price  <derek@ximbiot.com>
11951
11952         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
11953         unnecessary for Autoconfs > 2.59c.
11954
11955 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11956
11957         * lib/argp.h (__option_is_short): Check upper limit of
11958         __key. Isprint() requires its argument to have the value
11959         of an unsigned char or EOF.
11960
11961 2005-06-16  Jim Meyering  <jim@meyering.net>
11962
11963         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
11964         when either N or S is zero.
11965
11966 2005-06-16  Derek Price  <derek@ximbiot.com>
11967
11968         * m4/bison.m4: Declare YACC & YFLAGS precious.
11969
11970 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
11971
11972         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
11973         multibyte string or pattern, fall back on unibyte matching.
11974         Problem reported by James Youngman.
11975
11976 2005-06-08  Bruno Haible  <bruno@clisp.org>
11977
11978         * modules/csharpcomp: New file.
11979         * MODULES.html.sh (C#): Add csharpcomp.
11980
11981 2005-06-08  Bruno Haible  <bruno@clisp.org>
11982
11983         * m4/csharpcomp.m4: New file, from GNU gettext.
11984
11985 2005-06-08  Bruno Haible  <bruno@clisp.org>
11986
11987         * lib/csharpcomp.h: New file, from GNU gettext.
11988         * lib/csharpcomp.c: New file, from GNU gettext.
11989         * lib/csharpcomp.sh.in: New file, from GNU gettext.
11990
11991 2005-06-08  Bruno Haible  <bruno@clisp.org>
11992
11993         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
11994         warning on mingw.
11995
11996 2005-06-07  Derek Price  <derek@ximbiot.com>
11997
11998         Sync from CVS.
11999         * lib/glob_.h: Indent nested #ifdef.
12000
12001 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12002
12003         Sync from coreutils.
12004         Use "file name" when talking about file names, instead of "filename"
12005         or "path", as per the GNU coding standards.
12006         * lib/mkdir-p.c: Renamed from makepath.c.
12007         (make_dir_parents): Renamed from make_path.  All callers changed.
12008         * lib/mkdir-p.h: Likewise.  All includers changed.
12009         * lib/filenamecat.c: Renamed from path-concat.c.
12010         (file_name_concat): Renamed from path_concat.  All callers changed.
12011         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
12012         * lib/filenamecat.h: Likewise.  All includers changed.
12013         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
12014         in comments or local variable names.
12015         * lib/basename.c: Likewise.
12016         * lib/canonicalize.c, canonicalize.h: Likewise.
12017         * lib/dirname.c, dirname.h: Likewise.
12018         * lib/euidaccess.c: Likewise.
12019         * lib/exclude.c: Likewise
12020         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
12021         * lib/fsusage.c, fsuage.h: Likewise.
12022         * lib/fts.c, fts_.h: Likewise.
12023         * lib/getcwd.c: Likewise.
12024         * lib/getloadavg.c: Likewise.
12025         * lib/mkstemp.c: Likewise.
12026         * lib/mountlist.c, mountlist.h: Likewise.
12027         * lib/openat.c, openat.h: Likewise.
12028         * lib/readlink-stub.c: Likewise.
12029         * lib/readutmp.c, readutmp.h: Likewise.
12030         * lib/rename.c: Likewise.
12031         * lib/rmdir.c: Likewise.
12032         * lib/same.c: Likewise.
12033         * lib/savedir.c: Likewise.
12034         * lib/stripslash.c: Likewise.
12035         * lib/tempname.c: Likewise.
12036         * lib/xreadlink.c: Likewise.
12037         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
12038         All uses changed.
12039         * lib/exclude.h: Likewise.
12040
12041         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
12042         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12043         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
12044         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12045         * lib/pathmax.h: Include <limits.h> unconditionally, since other
12046         files have been getting away with it for years (MORE/BSD 4.3
12047         is extinct now).
12048         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
12049         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12050
12051         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
12052         Define to 256, not 255, as per modern POSIX.
12053
12054 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12055
12056         Sync from coreutils.
12057         Use "file name" when talking about file names, instead of "filename"
12058         or "path", as per the GNU coding standards.
12059         * MODULES.html.sh: mkdir-p renamed from makepath.
12060         filenamecat renamed from path-concat.
12061         * modules/filenamecat: Renamed from modules/path-concat.
12062         (Files): filenamecat.h and filenamecat.c renamed from
12063         path-concat.h and path-concat.c.
12064         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
12065         (Include): filenamecat.h, not path-concat.h.
12066         * modules/mkdir-p: Renamed from modules/makepath.
12067         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
12068         makepath.c.
12069         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
12070         (Include): mkdir-p.h, not makepath.h.
12071
12072 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12073
12074         Sync from coreutils.
12075         * m4/mkdir-p.m4: Renamed from makepath.m4.
12076         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
12077         Rename files from makepath.c to mkdir-p.c, and from
12078         makepath.h to mkdir-p.h.
12079         * m4/filenamecat.m4: Renamed from path-concat.m4.
12080         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
12081         Rename files from path-concat.c to filenamecat.c,
12082         and from path-concat.h to filenamecat.h.
12083         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
12084         "file name" in local variables or comments.
12085         * m4/rename.m4: Likewise.
12086
12087 2005-06-01  Bruno Haible  <bruno@clisp.org>
12088
12089         * modules/csharpexec: New file.
12090         * MODULES.html.sh (C#): New section.
12091
12092 2005-06-01  Bruno Haible  <bruno@clisp.org>
12093
12094         * m4/csharp.m4: New file, from GNU gettext.
12095         * m4/csharpexec.m4: New file, from GNU gettext.
12096
12097 2005-06-01  Bruno Haible  <bruno@clisp.org>
12098
12099         * lib/csharpexec.h: New file, from GNU gettext.
12100         * lib/csharpexec.c: New file, from GNU gettext.
12101         * lib/csharpexec.sh.in: New file, from GNU gettext.
12102
12103 2005-05-31  Derek Price  <derek@ximbiot.com>
12104             Paul Eggert  <eggert@cs.ucla.edu>
12105
12106         Sync from cvs.
12107         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12108
12109 2005-05-31  Derek Price  <derek@ximbiot.com>
12110             Paul Eggert  <eggert@cs.ucla.edu>
12111
12112         Sync from cvs.
12113         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12114
12115 2005-05-29  Derek Price  <derek@ximbiot.com>
12116
12117         * config/srclist.txt (glob_.h, glob.c): Add these files.
12118
12119 2005-05-29  Derek Price  <derek@ximbiot.com>
12120
12121         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
12122         * modules/glob: New file.
12123         * modules/getlogin_r: Add link to POSIX spec in description.
12124
12125 2005-05-29  Derek Price  <derek@ximbiot.com>
12126             Paul Eggert  <eggert@cs.ucla.edu>
12127
12128         * m4/glob.m4: New file.
12129
12130 2005-05-29  Derek Price  <derek@ximbiot.com>
12131             Paul Eggert  <eggert@cs.ucla.edu>
12132
12133         * lib/glob_.h, lib/glob.c: New files.
12134
12135 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12136
12137         * modules/fts (Files): Remove m4/inttypes-pri.m4.
12138         * modules/fts-lgpl (Depends-on): Remove gettext.
12139
12140 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12141
12142         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
12143         and don't require gt_INTTYPES_PRI.
12144
12145 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12146
12147         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
12148
12149         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
12150         the configuration hassle isn't worth it.
12151         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
12152         (LONGEST_MODIFIER, PRIuMAX): Remove.
12153
12154 2005-05-27  Bruno Haible  <bruno@clisp.org>
12155
12156         * lib/getlogin_r.h: Remove second include of <stddef.h>.
12157
12158 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
12159
12160         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
12161         _POSIX_PTHREAD_SEMANTICS for Solaris.
12162
12163 2005-05-25  Derek Price  <derek@ximbiot.com>
12164
12165         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
12166
12167 2005-05-25  Derek Price  <derek@ximbiot.com>
12168             Paul Eggert  <eggert@cs.ucla.edu>
12169
12170         * modules/getlogin_r, m4/getlogin_r.m4: New files.
12171         * lib/getlogin_r.c, getlogin_r.h: New files.
12172
12173 2005-05-25  Bruno Haible  <bruno@clisp.org>
12174             Derek Price  <derek@ximbiot.com>
12175
12176         * lib/getlogin_r.h: Simplify API documentation.
12177
12178 2005-05-23  Derek Price  <derek@ximbiot.com>
12179
12180         * modules/minmax (Files): Add m4/minmax.m4.
12181         (configure.ac): Add gl_MINMAX.
12182
12183 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
12184
12185         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
12186         so that unistd-safer.h (GPL'ed code) need not be included.
12187
12188 2005-05-22  Bruno Haible  <bruno@clisp.org>
12189
12190         * m4/minmax.m4: New file.
12191         Based on a patch by Derek Price <derek@ximbiot.com>.
12192
12193 2005-05-22  Bruno Haible  <bruno@clisp.org>
12194
12195         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
12196         (INT64_MIN): Fix definition.
12197         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
12198
12199         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
12200         NEED_SIGNED_INT_TYPES.
12201
12202         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
12203         HAVE_SYSTEM_INTTYPES.
12204
12205 2005-05-22  Bruno Haible  <bruno@clisp.org>
12206
12207         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
12208         Also include <sys/param.h> if it defines MIN, MAX.
12209         Based on a patch by Derek Price <derek@ximbiot.com>.
12210
12211 2005-05-21  Jim Meyering  <jim@meyering.net>
12212
12213         * modules/fts (Files): Add m4/inttypes-pri.m4.
12214         (Depends-on): Add lstat and remove gettext.  Alphabetize.
12215
12216 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12217
12218         New fts module.
12219         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
12220         (setup_dir, free_dir): New functions.
12221         (enter_dir, leave_dir): Define trivial
12222         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
12223         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
12224         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
12225         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
12226         Move to fts-cycle.c.
12227         (fts_open): Use setup_dir.
12228         (fts_close): Use free_dir.
12229         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
12230         This adds a label and some gotos, but the alternatives were messier.
12231         Check for memory allocation failure when entering a dir.
12232         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
12233         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
12234         (FTS): New member fts_cycle, that is a union that contains the
12235         old active_dir_ht and cycle_state.  All uses changed to mention
12236         fts_cycle.ht and fts_cycle.state.
12237         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
12238         fts.c, with the following changes:
12239         (setup_dir, free_dir): New functions.
12240         (enter_dir): Now returns bool.  Return true if successful, false
12241         if memory exhausted.  All callers changed.
12242         Do not bother partly cleaning up on
12243         memory allocation failure; that is free_dir's job.
12244         However, free ad if hash_insert fails, to avoid memory leak.
12245         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
12246         fts->fts_options to see which union member to use.
12247
12248 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12249
12250         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
12251         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
12252
12253 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12254
12255         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
12256
12257 2005-05-20  Jim Meyering  <jim@meyering.net>
12258
12259         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
12260         Now a macro, to pacify GCC.
12261
12262 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12263
12264         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
12265         of -1.
12266
12267 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12268
12269         * lib/chown.c (rpl_chown): Return -1 on failure.
12270
12271 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12272
12273         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
12274         Don't check for stddef.h.
12275         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
12276         don't use its results.
12277         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
12278         since we include them unconditionally.  Don't require
12279         AM_STDBOOL_H, since stdbool is a prerequisite.
12280         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
12281         since we assume C89 or better.
12282         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
12283         as we don't use their results.
12284         Don't check for fchdir, memmove, memset, strrchr, as we use
12285         them unconditionally.
12286         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
12287         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
12288
12289 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12290
12291         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
12292         Include <stddef.h> unconditionally, since we assume C89 now.
12293         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
12294         * lib/fts.c: Include fts_.h first, to check interface.
12295         Do not include intprops.h; no longer needed.
12296         Include cycle-check.h and hash.h, since fts_.h no longer does.
12297         Remove unnecessary casts of closedir to void.
12298         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
12299         decide whether to decrement nlinks.
12300         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
12301         (FTS): Use struct hash_table * instead of Hash_table, so that
12302         we no longer need to include hash.h here.
12303
12304 2005-05-18  Jim Meyering  <jim@meyering.net>
12305
12306         * modules/dirfd (License): Change to LGPL.  Most of the code
12307         is already in the public domain.
12308
12309 2005-05-18  Jim Meyering  <jim@meyering.net>
12310
12311         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
12312         Reported by Yoann Vandoorselaere.
12313
12314 2005-05-17  Jim Meyering  <jim@meyering.net>
12315
12316         * m4/fts.m4: New file, from coreutils.
12317
12318 2005-05-17  Jim Meyering  <jim@meyering.net>
12319
12320         * lib/fts.c, lib/fts_.h: New files, from coreutils.
12321
12322 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12323
12324         Sync from coreutils.
12325         * m4/unlinkdir.m4: New file.
12326
12327 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12328
12329         Sync from coreutils.
12330         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
12331         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
12332         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
12333         White space changes only.
12334         * lib/makepath.c (make_path): Port to hosts where leading "//" is
12335         special.
12336         * lib/yesno.c: Include getline.h, not ctype.h.
12337         (yesno): Don't remove leading white space; POSIX doesn't allow it.
12338         Use getline to remove arbitrary restriction on response length.
12339
12340 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12341
12342         * config/srclist-update: Spell out "Street" in FSF postal
12343         mail address; this is the style the FSF seems to prefer.
12344
12345         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
12346         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
12347         this updates FSF postal mail address.
12348
12349         Sync from coreutils.
12350         * modules/unlinkdir: New file.
12351         * modules/yesno (Depends-on): Add getline.
12352         * MODULES.html.sh (File system functions): Add unlinkdir.
12353
12354 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12355
12356         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
12357         lib/strsep.h:
12358         Change the initial comment to refer to GPL, not LGPL.
12359         gnulib-tool will change it to LGPL as needed.
12360
12361         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
12362         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
12363         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
12364         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
12365         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
12366         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
12367         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
12368         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
12369         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
12370         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
12371         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
12372         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
12373         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
12374         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
12375         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
12376         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
12377         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
12378         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
12379         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
12380         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
12381         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
12382         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
12383         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
12384         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
12385         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
12386         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
12387         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
12388         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
12389         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
12390         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
12391         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
12392         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
12393         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
12394         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
12395         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
12396         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
12397         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
12398         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
12399         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
12400         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
12401         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
12402         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
12403         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
12404         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
12405         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
12406         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
12407         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
12408         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
12409         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
12410         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
12411         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12412         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
12413         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
12414         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
12415         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
12416         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
12417         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
12418         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
12419         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
12420         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
12421         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
12422         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
12423         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
12424         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
12425         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
12426         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
12427         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
12428         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
12429         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
12430         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
12431         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
12432         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
12433         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
12434         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
12435         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
12436         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
12437         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
12438         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
12439         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
12440         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
12441         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
12442         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
12443         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
12444         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
12445         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
12446         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
12447         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
12448         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
12449         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
12450         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
12451         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
12452         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
12453         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
12454         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
12455         lib/yesno.c, lib/yesno.h:
12456         Update FSF postal mail address.
12457
12458 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12459
12460         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
12461         tests/test-memmem.c, tests/test-stpncpy.c:
12462         Update FSF postal mail address.
12463
12464 2005-05-13  Bruno Haible  <bruno@clisp.org>
12465
12466         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
12467         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
12468         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
12469         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
12470         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
12471         Add support for 64-bit integers in the MSVC compiler.
12472
12473 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12474
12475         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
12476
12477 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
12478
12479         * gnulib-tool (func_import): Sort and uniquify recommended includes.
12480
12481 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
12482
12483         * doc/getdate.texi (General date syntax): Don't say that date
12484         date --iso-8601=ns generates acceptable dates; it doesn't yet.
12485         Problem reported by Nic Ferrier.
12486
12487 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12488
12489         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
12490         specified in ai_socktype. Fix invalid ai_protocol
12491         check. ai_protocol is usually set to 0 or depending on
12492         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
12493         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
12494         ai_socktype / ai_protocol in the returned addrinfo structure.
12495
12496 2005-05-10  Simon Josefsson  <jas@extundo.com>
12497
12498         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
12499         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12500
12501 2005-05-10  Karl Berry  <karl@gnu.org>
12502
12503         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
12504         (from http://www.gnu.org/licenses).
12505         * doc/COPYING.LIB: also rename to COPYING.LESSER.
12506         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
12507         fdl.texi suffices.
12508
12509 2005-05-10  Karl Berry  <karl@gnu.org>
12510
12511         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
12512         (COPYING.DOC): remove.
12513
12514         * config/srclist-update: new FSF address.
12515
12516 2005-05-10  Derek Price  <derek@ximbiot.com>
12517
12518         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
12519         possible.
12520
12521 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12522             Bruno Haible  <bruno@clisp.org>
12523
12524         * modules/inet_ntop: New file.
12525         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12526         inet_ntop.
12527
12528 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12529             Bruno Haible  <bruno@clisp.org>
12530
12531         * m4/inet_ntop.m4: New file.
12532
12533 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12534             Bruno Haible  <bruno@clisp.org>
12535
12536         * lib/inet_ntop.h: New file.
12537         * lib/inet_ntop.c: New file, from glibc with modifications.
12538
12539 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
12540
12541         * modules/time_r (License): Change to LGPL.
12542         * modules/extensions (License): Change to LGPL.  Actually,
12543         the license is more permissive than that, but currently gnulib-tool
12544         doesn't know how to handle more-permissive licenses.
12545
12546         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
12547         Problem reported by Dave Love.
12548
12549 2005-05-08  Jim Meyering  <jim@meyering.net>
12550
12551         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
12552         blank.
12553
12554 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12555
12556         * modules/argmatch (Depends-on): Add stdbool.
12557         * modules/backupfile (Depends-on): Likewise.
12558         * modules/chdir-long (Depends-on): Likewise.
12559         * modules/closeout (Depends-on): Likewise.
12560         * modules/cycle-check (Depends-on): Likewise.
12561         * modules/dirname (Depends-on): Likewise.
12562         * modules/fnmatch (Depends-on): Likewise.
12563         * modules/fsusage (Depends-on): Likewise.
12564         * modules/fwriteerror (Depends-on): Likewise.
12565         * modules/getcwd (Depends-on): Likewise.
12566         * modules/getloadavg (Depends-on): Likewise.
12567         * modules/hard-locale (Depends-on): Likewise.
12568         * modules/makepath (Depends-on): Likewise.
12569         * modules/mountlist (Depends-on): Likewise.
12570         * modules/nanosleep (Depends-on): Likewise.
12571         * modules/posixtm (Depends-on): Likewise.
12572         * modules/quotearg (Depends-on): Likewise.
12573         * modules/readtokens (Depends-on): Likewise.
12574         * modules/readtokens0 (Depends-on): Likewise.
12575         * modules/readutmp (Depends-on): Likewise.
12576         * modules/save-cwd (Depends-on): Likewise.
12577         * modules/strftime (Depends-on): Likewise.
12578         * modules/userspec (Depends-on): Likewise.
12579         * modules/utimecmp (Depends-on): Likewise.
12580         * modules/xgetcwd (Depends-on): Likewise.
12581         * modules/xnanosleep (Depends-on): Likewise.
12582         * modules/xstrtod (Depends-on): Likewise.
12583         * modules/yesno (Depends-on): Likewise.
12584
12585 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
12586
12587         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
12588         needless checks.
12589
12590 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12591
12592         Merge from coreutils.  Among other things,
12593         add bulletproofing for cases where stdin, stdout, or stderr are closed.
12594         * lib/fd-safer.c: New file.
12595         * lib/fcntl-safer.h, open-safer.c: Remove.
12596         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
12597         * lib/dup-safer.c: Include unistd-safer.h first.
12598         Don't include errno.h.
12599         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
12600         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
12601         * lib/file-type.c: Rely on file-type.h change.
12602         * lib/getloadavg.c: Include unistd-safer.h.
12603         (getloadavg): Use safer open.
12604         * lib/getusershell.c: Include "stdio-safer.h".
12605         (getusershell): Use safer fopen.
12606         * lib/long-options.c (long_options): Use NULL rather than 0.
12607         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
12608         'free'.
12609         * lib/modechange.c: Likewise.
12610         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
12611         (MODE_DONE): New constant.
12612         (struct mode_change): Remove 'next' member.
12613         (make_node_op_equals): New function; like the old one of the
12614         same name, except it allocates an array.
12615         (mode_compile, mode_create_from_ref): Use it.
12616         (mode_compile): Allocate result as an array, not a linked list.
12617         Parse octal string ourself, so that we catch mistakes like "+0".
12618         (mode_adjust): Arg is an array, not a linked list.
12619         * lib/modechange.c: Include stat-macros.h, xalloc.h.
12620         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
12621         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
12622         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
12623         Remove.  This is now stat-macros.h's job.
12624         (talloc): Remove.  All callers replaced by xalloc, so that
12625         our invokers don't have to worry about reporting memory failures.
12626         (make_node_op_equals): Remove.
12627         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12628         New constants.
12629         (struct mode_change): Moved here from modechange.h.
12630         (mode_append_entry): Remove.
12631         (mode_compile): Remove MASKED_OPS arg, since it encouraged
12632         apps to have incorrect behavior.  Use simpler algorithm for head
12633         and tail.  Don't futz with umask; that's now the job of mode_adjust.
12634         Detect more invalid usages rather than having somewhat-random behavior.
12635         Don't insert an "a=" action, as that leads to incorrect behavior.
12636         (mode_compile, mode_create_from_ref): Return NULL on error instead
12637         of an enum, since now there's only one way to have an error.  All
12638         callers changed.
12639         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
12640         at the correct time.  Simplify calculation of "+u" and its ilk.
12641         Don't mishandle "+X".
12642         (mode_free): Remove "register" and localize decls.
12643         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12644         (struct mode_change): Move to modechange.c; callers don't
12645         need to see this stuff.
12646         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
12647         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
12648         (mode_change, mode_adjust): Reflect the new signatures noted above.
12649         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
12650         that might redefine system include files.
12651         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
12652         (my_usleep): Use NULL rather than (void *) 0.
12653         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
12654         Use siginterrupt to specify that system calls should be interrupted.
12655         (rpl_nanosleep): Move initialization of suspended closer to call of
12656         my_usleep.
12657         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
12658         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
12659         (desirable_utmp_entry): New function.
12660         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
12661         using x2nrealloc, to simplify logic.
12662         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
12663         size calculation.  Do not assume utmp file is a regular file.
12664         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
12665         (READ_UTMP_CHECK_PIDS): New constant.
12666         * lib/save-cwd.c: Include unistd-safer.h.
12667         (save_cwd): Use fd_safer.
12668         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
12669         [!_LIBC] Include "stat-macros.h" instead.
12670         * lib/unistd-safer.h (fd_safer): New decl.
12671
12672 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12673
12674         * modules/getloadavg (Depends-on): Add unistd-safer.
12675         * modules/getusershell (Depends-on): Add stdio-safer.
12676         * modules/lstat (Depends-on): Remove xalloc.
12677         * modules/mkstemp (Depends-on): Add stat-macros.
12678         * modules/modechange (Depends-on): Remove xstrtol.
12679         Add stat-macros, xalloc.
12680         * modules/save-cwd (Depends-on): Add unistd-safer.
12681         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
12682         * modules/unistd-safer (Files): Add lib/fd-safer.c
12683         (Makefile.am): Remove lib_SOURCES.
12684
12685         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
12686         Remove fcntl-safer; unistd-safer supersedes it.
12687
12688 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12689
12690         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
12691         AC_HEADER_STAT.
12692         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
12693         (gl_PREREQ_CHOWN): Remove.
12694         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
12695         it.  Don't require AC_HEADER_STAT.
12696         (gl_PREREQ_LSTAT): Remove.
12697         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
12698         Don't require AC_HEADER_STAT.
12699         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
12700         (gl_PREREQ_RMDIR): Remove.
12701         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
12702         mention stat-macros.h or AC_HEADER_STAT, since we'll make
12703         the stat-macros module a prerequisite.
12704         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
12705         * m4/filemode.m4 (gl_FILEMODE): Likewise.
12706         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
12707         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
12708         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
12709         variable names.
12710         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
12711         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
12712         variable prefixes.
12713         * m4/fcntl-safer.m4: Remove.
12714         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
12715         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
12716         Invoke gl_PREREQ_FD_SAFER.
12717         (gl_PREREQ_FD_SAFER): New macro.
12718         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
12719         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
12720         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
12721         Remove duplicate call to AC_LIBOBJ(readutmp).
12722         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
12723
12724         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
12725         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
12726
12727 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12728
12729         * MODULES.html.sh (Misc): Add byteswap.
12730
12731 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12732
12733         * modules/getcwd (Depends-on): Add extensions.
12734         * modules/openat (Depends-on): Likewise.
12735
12736 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12737
12738         * modules/byteswap: New file.
12739
12740 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12741
12742         * m4/byteswap.m4: New file.
12743
12744 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12745
12746         * lib/byteswap_.h: New file.
12747
12748 2005-04-25  Karl Berry  <karl@gnu.org>
12749
12750         * m4/gettext.m4: Update from GNU gettext 0.14.4.
12751
12752 2005-04-25  Albert Chin  <china@thewrittenword.com>
12753
12754         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
12755         Toolkit C bug.
12756
12757 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
12758
12759         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
12760         (func_ln_if_changed) Remove forcibly for no error message
12761         in case file does not exist.
12762
12763 2005-04-19  Simon Josefsson  <jas@extundo.com>
12764
12765         * gnulib-tool (Options): Make --symlink mean --symbolic.
12766
12767 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
12768
12769         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
12770
12771 2005-04-16  Simon Josefsson  <jas@extundo.com>
12772
12773         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
12774
12775 2005-04-15  Simon Josefsson  <jas@extundo.com>
12776
12777         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
12778
12779 2005-04-15  Simon Josefsson  <jas@extundo.com>
12780
12781         * gnulib-tool: Rename --symlink to --symbolic.
12782
12783 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
12784
12785         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
12786         symbolic links to files instead of copying/moving.  Add --aux-dir,
12787         specifying directory relative --dir where auxiliary build tools
12788         are placed.
12789
12790 2005-04-14  Bruno Haible  <bruno@clisp.org>
12791
12792         * modules/allocsa (License): Change to LGPL.
12793         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
12794
12795 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12796
12797         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
12798         that "UTC +1 second" continues to work.  Problem reported
12799         by Dmitry V. Levin.
12800         (relunit_snumber): New rule.
12801         (relunit): Use it.
12802
12803 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
12804
12805         * lib/getdate.y (universal_time_zone_table): New constant.
12806         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
12807         universal_time_zone_table.
12808         (lookup_zone): Prefer universal_time_zone_table to
12809         local_time_zone_table, so that "GMT" time stamps are allowed in
12810         London during the summer.  Problem reported by Ian Abbott.
12811
12812 2005-04-12  Jim Meyering  <jim@meyering.net>
12813
12814         * lib/human.c (humblock): Set *options even when returning due to
12815         xstrtoumax conversion failure.  Thanks to a used-uninitialized
12816         warning from gcc-4.
12817
12818 2005-04-09  Jim Meyering  <jim@meyering.net>
12819
12820         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
12821         -Wuninitialized: initialize tm0.tm_year.
12822
12823 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
12824
12825         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
12826         count, since there's no maximum.  All uses changed.
12827         Add member dsts_seen.
12828         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
12829         not being INT_MAX.
12830         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
12831         Use pc_rels_seen to decide whther a date is absolute.
12832
12833         * lib/getdate.y (number): Don't overwrite year.
12834         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
12835         check.
12836
12837 2005-04-02  Simon Josefsson  <jas@extundo.com>
12838
12839         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
12840         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
12841
12842 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
12843
12844         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
12845         where no absolute path name can be longer than PATH_MAX.
12846
12847 2005-03-27  Jim Meyering  <jim@meyering.net>
12848
12849         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
12850
12851 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
12852
12853         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
12854         "one's complement" -> "ones' complement" in comment, as per Knuth.
12855         "value of type" -> "type or expression" in comment.
12856         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
12857
12858 2005-03-26  Jim Meyering  <jim@meyering.net>
12859
12860         Comment nits.
12861         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
12862         Correct typos: s/or/of/.
12863
12864 2005-03-26  Jim Meyering  <jim@meyering.net>
12865
12866         * modules/check-include-files: Move to ../ and rename to...
12867         * check-module: ...this.
12868
12869 2005-03-25  Jim Meyering  <jim@meyering.net>
12870
12871         * modules/xvasprintf (Files): Add xalloc.h.
12872
12873 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
12874
12875         * modules/gettext (Files): config/config.rpath ->
12876         build-aux/config.rpath
12877         * modules/iconv (Files): Likewise.
12878         Problem reported by Oskar Liljeblad.
12879
12880 2005-03-23  Jim Meyering  <jim@meyering.net>
12881
12882         * modules/check-include-files: New script to check for
12883         missing dependencies, multiple includes, etc.
12884
12885         * modules/c-strtold (Depends-on): Add xalloc.
12886         * modules/c-strtod (Depends-on): Add xalloc.
12887         * modules/hash (Depends-on): Add xalloc.
12888         (Files): Remove lib/xalloc.h.
12889
12890         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
12891         * modules/userspec (Files): Add lib/inttostr.h.
12892
12893 2005-03-23  Jim Meyering  <jim@meyering.net>
12894
12895         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
12896
12897 2005-03-22  Jim Meyering  <jim@meyering.net>
12898
12899         * modules/stat-macros: New module.
12900         * modules/canonicalize, modules/euidaccess, modules/file-type,
12901         * modules/filemode, modules/lchown, modules/makepath,
12902         * modules/rmdir, modules/stat: Depend on new stat-macros module
12903         rather than listing lib/stat-macros.h manually.
12904         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
12905
12906 2005-03-22  Jim Meyering  <jim@meyering.net>
12907
12908         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
12909
12910 2005-03-22  Bruno Haible  <bruno@clisp.org>
12911
12912         * config/srclist.txt: Replace target directory 'config' with
12913         'build-aux'.
12914         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
12915         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
12916         ../build-aux/.
12917
12918 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
12919
12920         * modules/chdir-long (Depends-on): Add mempcpy.
12921
12922         * modules/acl, modules/backupfile, modules/c-strtod,
12923         modules/c-strtold, modules/canon-host, modules/canonicalize,
12924         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
12925         modules/exclude, modules/exitfail, modules/file-type,
12926         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
12927         modules/getdate, modules/getline, modules/getpagesize,
12928         modules/getpass, modules/getugroups, modules/group-member,
12929         modules/hard-locale, modules/hash, modules/human, modules/idcache,
12930         modules/inttostr, modules/long-options, modules/makepath,
12931         modules/md5, modules/memcasecmp, modules/memcoll,
12932         modules/modechange, modules/mountlist, modules/path-concat,
12933         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
12934         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
12935         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
12936         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
12937         modules/strftime, modules/strndup, modules/strverscmp,
12938         modules/timespec, modules/unlocked-io, modules/userspec,
12939         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
12940         modules/yesno:
12941         Remove lib_SOURCES line from Makefile.am section, as this is now
12942         done automatically by the corresponding Autoconf macro.
12943
12944 2005-03-21  Jim Meyering  <jim@meyering.net>
12945
12946         Changes imported from coreutils.
12947
12948         * lib/cycle-check.c: Don't include xalloc.h.
12949
12950         * lib/path-concat.c: Don't include assert.h.
12951         (path_concat): Remove assertion that would have triggered
12952         for ABASE starting with more than one slash.
12953         Reported by Andreas Schwab.
12954
12955         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
12956         properly when ABASE is an absolute file name.
12957         Correct the description of this function.
12958         Include <assert.h>.
12959         Add an assertion and a test driver.
12960         This fixes a bug introduced on 2004-07-02.
12961         Andreas Schwab reported the resulting failure of cp --parents:
12962         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
12963
12964 2005-03-21  Jim Meyering  <jim@meyering.net>
12965
12966         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
12967         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
12968
12969 2005-03-21  Jim Meyering  <jim@meyering.net>
12970         and  Paul Eggert  <eggert@cs.ucla.edu>
12971
12972         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
12973         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
12974         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
12975         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
12976         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
12977         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
12978         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
12979         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
12980         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
12981         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
12982         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
12983         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
12984         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
12985         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
12986         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
12987         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
12988         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
12989         for these modules.
12990
12991 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
12992
12993         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
12994         (which shouldn't happen), generate nothing instead of returning 0
12995         immediately, so that nstrftime (NULL, ...) doesn't return 0.
12996
12997 2005-03-16  Bruno Haible  <bruno@clisp.org>
12998
12999         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
13000         HAVE_LONGLONG_64BIT.
13001
13002 2005-03-16  Bruno Haible  <bruno@clisp.org>
13003
13004         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
13005         HAVE_LONGLONG_64BIT.
13006
13007 2005-03-16  Bruno Haible  <bruno@clisp.org>
13008
13009         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
13010         HAVE_LONGLONG_64BIT.
13011
13012 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13013
13014         * lib/strftime.c (my_strftime): Prepend space to format so that we can
13015         reliably distinguish strftime failure from empty output on POSIX
13016         hosts.
13017
13018 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13019
13020         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
13021         (iconv_string): Don't guess a size-zero buffer, as that might cause
13022         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
13023         result would be 'too large', where 'too large' is (heuristically)
13024         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
13025         overflow concerns.  This will prevent some unwanted malloc failures
13026         when the inputs are very large.
13027
13028 2005-03-15  Karl Berry  <karl@gnu.org>
13029
13030         * config/srclist.txt (config.rpath): from gettext.
13031         * config/config.rpath: update.
13032
13033 2005-03-15  Bruno Haible  <bruno@clisp.org>
13034
13035         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
13036         to 'negate'.
13037
13038         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
13039         variable.
13040
13041         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
13042         results.
13043
13044 2005-03-14  Simon Josefsson  <jas@extundo.com>
13045
13046         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
13047         <fx@gnu.org>.
13048
13049 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
13050
13051         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
13052         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
13053         intprops.h.
13054         * lib/strtol.c: Likewise.
13055
13056 2005-03-14  Jim Meyering  <jim@meyering.net>
13057
13058         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
13059         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
13060         to be nonzero so that we (and caller) can detect the difference
13061         between a valid zero-length expansion and an error return, even
13062         when the underlying strftime fails before writing anything into
13063         that location.
13064
13065 2005-03-14  Bruno Haible  <bruno@clisp.org>
13066
13067         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
13068         Update from GNU gettext 0.14.3.
13069
13070 2005-03-10  Jim Meyering  <jim@meyering.net>
13071
13072         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
13073
13074 2005-03-10  Jim Meyering  <jim@meyering.net>
13075
13076         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
13077         so that this module works on systems without fchdir.
13078
13079 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
13080
13081         Factor int-properties macros into a single file, except for
13082         glibc-related files.
13083         * lib/intprops.h: New file.
13084         * lib/getloadavg.c: Include it instead of limits.h.
13085         (INT_STRLEN_BOUND): Remove.
13086         * lib/human.c: Include intprops.h.
13087         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
13088         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
13089         302/1000.
13090         * lib/inttostr.h: Include intprops.h instead of limits.h.
13091         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
13092         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
13093         for consistency with intprops.h.
13094         (time_t_is_integer, twos_complement_arithmetic): Use them.
13095         * lib/sig2str.h: Include <signal.h>, intprops.h.
13096         (INT_STRLEN_BOUND): Remove.
13097         * lib/strftime.c (TYPE_SIGNED): Remove.
13098         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
13099         * lib/strtol.c: Adjust comments to match intprops.h.
13100         * lib/userspec.c: Include intprops.h.
13101         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
13102         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
13103         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
13104         instead of rolling our own expressions.
13105         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
13106
13107         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
13108         instead of int.
13109         (my_strftime): Do not mishandle years close to INT_MAX, by doing
13110         the right thing even if adding 1900 would overflow.  Similarly
13111         for tm_mon + 1 and tm_yday + 1.
13112         Make %Y always equivalent to %C%y, and similarly for %G and %g.
13113         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
13114         (DO_SIGNED_NUMBER): New macro.
13115         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
13116
13117 2005-03-07  Bruno Haible  <bruno@clisp.org>
13118
13119         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
13120
13121 2005-03-07  Bruno Haible  <bruno@clisp.org>
13122
13123         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
13124
13125 2005-03-04  Derek R. Price  <derek@ximbiot.com>
13126
13127         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
13128         (func_import): Only replace files via --import when they have actually
13129         changed.
13130
13131 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13132
13133         * m4/mmap-anon.m4: New file.
13134         * m4/pagealign_alloc.m4: New file.
13135
13136 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13137             Bruno Haible  <bruno@clisp.org>
13138
13139         * modules/pagealign_alloc: New file.
13140         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
13141
13142 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13143             Bruno Haible  <bruno@clisp.org>
13144
13145         * lib/pagealign_alloc.h: New file.
13146         * lib/pagealign_alloc.c: New file.
13147
13148 2005-03-03  Bruno Haible  <bruno@clisp.org>
13149
13150         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
13151         Use an all-permissive copyright notice, recommended by RMS.
13152
13153 2005-03-02  Bruno Haible  <bruno@clisp.org>
13154
13155         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
13156         of AIX, the replacement has to be done only after <string.h> is
13157         included, therefore not in config.h. stpncpy.h does the replacement,
13158         and stpncpy.c uses it.
13159
13160 2005-03-02  Bruno Haible  <bruno@clisp.org>
13161
13162         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
13163         stpncpy.c uses it.
13164
13165 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13166
13167         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
13168         The workaround isn't strictly needed for POSIX conformance, and
13169         it's too much of a pain to configure and maintain.  We'll ask
13170         people to fix their kernels instead.
13171         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
13172         (NANOSLEEP_BUG_WORKAROUND): Remove.
13173         (xnanosleep): Remove the workaround.
13174
13175 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13176
13177         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
13178         Reported by Derek Price.
13179         (Include): Add "timespec.h".
13180
13181         * modules/xnanosleep (Depends-on): Remove gethrxtime.
13182
13183 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13184
13185         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
13186         to detect nanosleep bug.
13187
13188 2005-03-01  Bruno Haible  <bruno@clisp.org>
13189
13190         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
13191
13192 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13193
13194         * modules/gethrxtime: New file.
13195         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
13196         (Depends-on): Add gethrxtime.
13197         (configure.ac): Add gl_XNANOSLEEP.
13198         (Makefile.am): Remove lib_SOURCES line.
13199
13200 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13201
13202         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
13203         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
13204
13205 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13206
13207         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
13208         * lib/timespec.h (gettime): Return void, since it always
13209         succeeds now.  All uses changed.
13210         * lib/gettime.c (gettime) Likewise.
13211         [HAVE_NANOTIME]: Prefer nanotime.
13212         Assume gettimeofday succeeds, as POSIX requires.
13213         Assime time () succeeds, since other code already does.
13214         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
13215         (timespec_subtract): Remove.
13216         (NANOSLEEP_BUG_WORKAROUND): New constant.
13217         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
13218         things considerably.  Use it only on GNU/Linux hosts, since the
13219         workaround shouldn't be needed elsewhere.
13220
13221 2005-02-24  Bruno Haible  <bruno@clisp.org>
13222
13223         * modules/gettext (Files): Add m4/glibc2.m4.
13224
13225 2005-02-24  Bruno Haible  <bruno@clisp.org>
13226
13227         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
13228         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
13229         * m4/progtest.m4:
13230         Update from GNU gettext 0.14.2.
13231         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
13232
13233 2005-02-24  Bruno Haible  <bruno@clisp.org>
13234
13235         * lib/localcharset.c: Update from GNU gettext 0.14.2.
13236         * lib/config.charset: Update from GNU gettext 0.14.2.
13237
13238 2005-02-24  Bruno Haible  <bruno@clisp.org>
13239
13240         * lib/gettext.h: Update from GNU gettext 0.14.2.
13241
13242 2005-02-23  Simon Josefsson  <jas@extundo.com>
13243
13244         * m4/iconvme.m4: New file.
13245
13246 2005-02-23  Jim Meyering  <jim@meyering.net>
13247
13248         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
13249         change.
13250         Thanks to Bruno Haible for catching it.
13251
13252 2005-02-22  Simon Josefsson  <jas@extundo.com>
13253
13254         * modules/iconvme: New file.
13255
13256         * MODULES.html.sh: Add iconvme.
13257
13258 2005-02-22  Simon Josefsson  <jas@extundo.com>
13259
13260         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
13261
13262 2005-02-22  Simon Josefsson  <jas@extundo.com>
13263
13264         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
13265
13266 2005-02-22  Jim Meyering  <jim@meyering.net>
13267
13268         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
13269         s/ifndef/ifdef/.
13270
13271 2005-02-20  Neil Conway  <neilc@samurai.com>
13272
13273         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
13274         returned by OSX/Darwin if the specified buffer is not large
13275         enough for the hostname.
13276
13277 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13278
13279         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
13280         pass it to _help, otherwise the latter coredumps trying to
13281         dereference state.root_argp.
13282
13283 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13284
13285         * modules/chdir-long (Depends-on): Add memrchr.
13286         * modules/memrchr (Files): Add lib/memrchr.h.
13287         (Include): "memrchr.h".
13288
13289 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13290
13291         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
13292
13293 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13294
13295         * lib/memrchr.h: New file.
13296         * lib/chdir-long.c: Include it.
13297         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
13298         Don't bother including stddef.h.
13299
13300 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
13301
13302         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
13303         inclusion.
13304         Include <sys/types.h>, for dev_t.
13305         (ME_DUMMY, ME_REMOTE): Move from here....
13306         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
13307         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
13308         Dmitry V. Levin.
13309         Include mountlist.h first, to test the interface.
13310
13311 2005-01-29  Bruno Haible  <bruno@clisp.org>
13312
13313         * lib/progname.c (program_name): Initialize.
13314         Needed when linking statically on MacOS X.
13315
13316 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13317
13318         Sync from coreutils.
13319         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
13320         (Depends-on): Add c-strtod.
13321         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
13322
13323 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13324
13325         Sync from coreutils.
13326         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
13327
13328         Remove files that are specific to coreutils.
13329         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
13330
13331 2005-01-28  Bruno Haible  <bruno@clisp.org>
13332
13333         * modules/javacomp: New file.
13334         * MODULES.html.sh (Java): Add javacomp.
13335
13336 2005-01-28  Bruno Haible  <bruno@clisp.org>
13337
13338         * m4/javacomp.m4: New file, from GNU gettext.
13339
13340 2005-01-28  Bruno Haible  <bruno@clisp.org>
13341
13342         * lib/javacomp.sh.in: New file, from GNU gettext.
13343         * lib/javacomp.h: New file, from GNU gettext.
13344         * lib/javacomp.c: New file, from GNU gettext.
13345
13346 2005-01-26  Simon Josefsson  <jas@extundo.com>
13347
13348         * lib/gai_strerror.c: Use GPL in header.
13349
13350 2005-01-26  Bruno Haible  <bruno@clisp.org>
13351
13352         * modules/javaexec: New file.
13353         * MODULES.html.sh (Java): Add javaexec.
13354
13355 2005-01-26  Bruno Haible  <bruno@clisp.org>
13356
13357         * m4/javaexec.m4: New file, from GNU gettext.
13358
13359 2005-01-26  Bruno Haible  <bruno@clisp.org>
13360
13361         * lib/javaexec.sh.in: New file, from GNU gettext.
13362         * lib/javaexec.h: New file, from GNU gettext.
13363         * lib/javaexec.c: New file, from GNU gettext.
13364
13365 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13366
13367         * modules/lchown (Depends-on): Remove lchown.h
13368
13369 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13370
13371         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
13372         must be defined if the header file was not found, in order
13373         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
13374
13375 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13376
13377         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
13378         initializers for struct pentry_state.
13379         (__argp_error): Check return value of __asprintf
13380         (__argp_failure): Translate error message
13381
13382         * lib/argp-parse.c: Removed braces around the expansion of N_()
13383
13384 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13385
13386         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
13387         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
13388         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
13389         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
13390         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
13391         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
13392         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
13393         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
13394         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
13395         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
13396         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
13397         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
13398         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
13399         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
13400         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
13401         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
13402         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
13403         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
13404         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
13405         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
13406         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
13407         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
13408         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
13409         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
13410         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
13411         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
13412         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
13413         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
13414         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
13415         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
13416         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
13417         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
13418         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
13419         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
13420         xstrtol.m4, xstrtoumax.m4, yesno.m4:
13421         Use an all-permissive copyright notice, recommended by RMS.
13422
13423 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
13424
13425         * modules/chdir-long (Depends-on): Remove mempcpy.
13426
13427 2005-01-21  Jim Meyering  <jim@meyering.net>
13428
13429         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
13430         same value as for Solaris 9.
13431
13432         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
13433         component length.  This included changing the parameter to be
13434         of type `char *' rather than `char const *'.
13435         * lib/chdir-long.h (chdir_long): Update prototype.
13436
13437         * lib/openat.c (fdopendir, fstatat): New functions.
13438         * lib/openat.h: Include headers required for use of DIR and struct
13439         stat.
13440         [AT_SYMLINK_NOFOLLOW]: Define.
13441         (fdopendir, fstatat): Add prototypes.
13442
13443 2005-01-21  Bruno Haible  <bruno@clisp.org>
13444
13445         * modules/classpath: New file.
13446         * MODULES.html.sh (Java): Add classpath.
13447
13448 2005-01-21  Bruno Haible  <bruno@clisp.org>
13449
13450         * lib/classpath.h: New file, from GNU gettext.
13451         * lib/classpath.c: New file, from GNU gettext.
13452
13453 2005-01-20  Simon Josefsson  <jas@extundo.com>
13454
13455         * modules/version-etc-fsf: New file.
13456
13457 2005-01-20  Simon Josefsson  <jas@extundo.com>
13458
13459         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
13460         * lib/version-etc.c: Remove version_etc_copyright.
13461         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
13462         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
13463
13464 2005-01-20  Simon Josefsson  <jas@extundo.com>
13465
13466         * lib/base64.h (isbase64): Add.
13467
13468         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
13469         using a unsigned prototype, don't inline.
13470         (base64_decode): Use it.
13471
13472 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13473
13474         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
13475         it.
13476
13477 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13478
13479         * lib/save-cwd.c (save_cwd): Remove code to support the case
13480         where fchdir is missing or flaky.
13481
13482 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13483
13484         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
13485
13486 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
13487
13488         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
13489         AC_LIBSOURCES now does this.
13490         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
13491         with new ullong_max module.
13492
13493 2005-01-19  Bruno Haible  <bruno@clisp.org>
13494
13495         * modules/sh-quote: New file.
13496         * MODULES.html.sh (Executing programs): Add sh-quote.
13497
13498 2005-01-19  Bruno Haible  <bruno@clisp.org>
13499
13500         * lib/sh-quote.h: New file, from GNU gettext.
13501         * lib/sh-quote.c: New file, from GNU gettext.
13502
13503 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13504
13505         Merge from coreutils.
13506         * m4/ullong_max.m4: New file.
13507         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
13508         (gl_MACROS): Assume localeconv exists.
13509
13510 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13511
13512         Merge changes from coreutils, as described below in several
13513         changelogs dated today.
13514
13515         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
13516         (O_DIRECTORY): Remove; not needed here, since "." must be
13517         a directory.  All uses removed.
13518         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
13519         universal on Suns, and we also need to test for IRIX.
13520         Revamp code to use 'if' rather than '#if'.
13521         Avoid unnecessary comparison of cwd->desc to 0.
13522
13523         * lib/utimens.c (futimens): Robustify the previous patch, by checking
13524         for known valid error numbers rather than observed invalid ones.
13525
13526 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13527
13528         * modules/ullong_max: New file.
13529
13530         * modules/chdir-long, modules/openat: New files.
13531         * modules/save-cwd (Depends-on): Depend on chdir-long.
13532         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
13533
13534 2005-01-18  Jim Meyering  <jim@meyering.net>
13535
13536         Merge from coreutils.
13537         * m4/chdir-long.m4, m4/openat.m4: New files.
13538         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
13539         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
13540         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
13541         is sane and DOES follow symlinks.  Besides, testing 20 different
13542         systems found no broken chown implementations.
13543         Prompted by a change in rsync's copy of this macro.
13544         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
13545
13546         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
13547
13548         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
13549         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
13550         NULL-means-set-to-current-time semantics.
13551         Remove temporary file immediately, rather than waiting
13552         for configure's at-exit trap code to do it.
13553
13554 2005-01-18  Jim Meyering  <jim@meyering.net>
13555
13556         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13557
13558         * lib/utimens.c (futimens): Account for the fact that futimes
13559         can also fail with errno == ENOSYS or errno == ENOENT.
13560         Patch from Dmitry V. Levin.
13561
13562         Change the name of the robust chdir function from chdir to chdir_long.
13563         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
13564         (restore_cwd): Use chdir_long, not chdir.
13565         * lib/chdir-long.c: Renamed from chdir.c.
13566         * lib/chdir-long.h: Renamed from chdir.h.
13567         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
13568         Hurd.
13569
13570 2005-01-18  Bruno Haible  <bruno@clisp.org>
13571
13572         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
13573         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
13574         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
13575         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
13576         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
13577         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
13578         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
13579         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
13580         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
13581         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
13582         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
13583         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
13584         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
13585         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
13586         Use an all-permissive copyright notice, recommended by RMS.
13587
13588 2005-01-18  Bob Proulx  <bob@proulx.com>
13589
13590         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
13591         simplify offsetof() macro construct to avoid compile failure with
13592         native HP-UX 11.0 ANSI C compiler.
13593
13594 2005-01-17  Bruno Haible  <bruno@clisp.org>
13595
13596         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
13597         redundant because stpncpy.m4 takes care of it.
13598
13599 2005-01-17  Bruno Haible  <bruno@clisp.org>
13600
13601         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
13602
13603 2005-01-17  Bruno Haible  <bruno@clisp.org>
13604
13605         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
13606         used.
13607
13608 2005-01-17  Bruno Haible  <bruno@clisp.org>
13609
13610         * lib/fwriteerror.h (fwriteerror): Change specification to include
13611         fclose.
13612         * lib/fwriteerror.c: Include <stdbool.h>.
13613         (fwriteerror): At the end, close the file stream. Record whether
13614         stdout was already closed.
13615
13616 2005-01-17  Bruno Haible  <bruno@clisp.org>
13617
13618         * lib/execute.c (environ): Declare if needed.
13619         * lib/pipe.c (environ): Likewise.
13620         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
13621
13622 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13623
13624         * modules/argp: Depend on vsnprintf
13625
13626 2005-01-10  Jim Meyering  <jim@meyering.net>
13627
13628         * modules/closeout (Depends-on): Add atexit.
13629
13630 2005-01-06  Bruno Haible  <bruno@clisp.org>
13631
13632         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
13633
13634 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13635
13636         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
13637         definitions to be after all include files, to avoid collisions.
13638         Problem reported by Bob Proulx.
13639
13640 2005-01-04  Jim Meyering  <jim@meyering.net>
13641
13642         Changes imported from coreutils.
13643         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
13644         as the mkstemp template, use a temporary directory and an
13645         8.3-friendly template to avoid trouble on systems like DJGPP.
13646         Reported by Juan M. Guerrero via Stepan Kasal.
13647         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
13648         close. Remove the temporary directory right away, rather than waiting
13649         for configure's at-exit trap code to do it.
13650         Suggestion from Stepan Kasal.
13651
13652 2005-01-01  Simon Josefsson  <jas@extundo.com>
13653
13654         * gnulib-tool: Print #include directives when --import'ing.
13655
13656 2004-12-28  Simon Josefsson  <jas@extundo.com>
13657
13658         * tests/test-base64.c: Include required header files.  Remove
13659         unused variables.
13660
13661 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13662
13663         * modules/error (Depends-on): Remove gettext.
13664
13665 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13666
13667         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
13668         not needed.  This removes a dependency on the gettext module.
13669         [defined _LIBC]: Do not include <libintl.h>; not needed.
13670
13671 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13672
13673         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
13674         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
13675
13676 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13677
13678         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
13679         HAVE_DECL_STRTOLD.
13680
13681 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13682
13683         * modules/getdate (Depends-on): Remove alloca-opt.
13684
13685 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13686
13687         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
13688
13689 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13690
13691         * lib/argp-parse.c: Include <stddef.h>.
13692         (alignof, alignto): New macros.
13693         (parser_init): Don't assume that void * is aligned sufficiently
13694         for struct option.
13695
13696         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
13697         need to extend the stack.
13698         (YYINITDEPTH): New macro, so that the initial stack isn't overly
13699         large.
13700
13701 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13702
13703         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
13704
13705 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13706
13707         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
13708         (2004-10-24) change.  Apparently this was a false alarm.
13709
13710         * modules/getdate: Depend on alloca-opt, not alloca.
13711
13712 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13713
13714         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
13715         Remove now-obsolete comment about AIX.
13716         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
13717         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
13718         (YYMAXDEPTH): New macro.
13719
13720 2004-12-18  Simon Josefsson  <jas@extundo.com>
13721
13722         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
13723
13724 2004-12-18  Bruno Haible  <bruno@clisp.org>
13725
13726         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
13727
13728 2004-12-18  Bruno Haible  <bruno@clisp.org>
13729
13730         * lib/fatal-signal.c (fatal_signals): Make non-const.
13731         (init_fatal_signals): New function.
13732         (uninstall_handlers, install_handlers): Ignore signals that were set to
13733         SIG_IGN.
13734         (at_fatal_signal): Call init_fatal_signals.
13735         (init_fatal_signal_set): Likewise. Ignore signals that were set to
13736         SIG_IGN.
13737         Reported by Paul Eggert.
13738
13739 2004-12-18  Bruno Haible  <bruno@clisp.org>
13740
13741         * doc/alloca.texi: New file.
13742         * doc/alloca-opt.texi: New file.
13743
13744 2004-12-17  Jim Meyering  <jim@meyering.net>
13745
13746         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
13747         Otherwise, install-sh could exit with improper exit status when
13748         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
13749
13750 2004-12-16  Simon Josefsson  <jas@extundo.com>
13751
13752         * tests/test-base64.c: Add license.
13753
13754 2004-12-15  Stepan Kasal  <address@hidden>
13755
13756         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
13757
13758 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
13759
13760         * modules/getcwd (Files): Add m4/d-ino.m4.
13761         Suggested by Mark D. Baushke.
13762
13763 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13764
13765         * lib/getdate.y (textint): New member "negative".
13766         (time_zone_hhmm): New function.
13767         Expect 14 shift-reduce conflicts, not 13.
13768         (o_colon_minutes): New rule.
13769         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
13770         (yylex): Set the "negative" member of signed numbers.
13771
13772 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13773
13774         * doc/getdate.texi (Time of day items, Time zone items):
13775         Describe new formats +00:00, UTC+00:00.
13776
13777 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13778
13779         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
13780         spurious "-l"s.  Problem reported by Stepan Kasal.
13781
13782 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
13783
13784         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
13785         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
13786
13787 2004-12-04  Simon Josefsson  <jas@extundo.com>
13788
13789         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
13790         Vandoorselaere <yoann@prelude-ids.org>.
13791
13792 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13793
13794         Changes imported from coreutils.
13795         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
13796         exist.
13797         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
13798
13799 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13800
13801         Changes imported from coreutils.
13802         * lib/hard-locale.c: Assume <locale.h> exists.
13803         Include "strdup.h".
13804         (GLIBC_VERSION): New macro.
13805         (hard_locale): Assume setlocale exists.
13806         Rewrite to avoid #ifdef.
13807         Use strdup rather than malloc + strcpy.
13808         * lib/human.c: Assume <locale.h> exists.
13809         (human_readable): Assume localeconv exists.
13810
13811 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13812
13813         * modules/hard-locale (Depends-on): Add strdup.
13814
13815 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
13816
13817         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
13818         convert T2, not T.  (Imported from libc.)
13819
13820 2004-11-30  Simon Josefsson  <jas@extundo.com>
13821
13822         * modules/restrict (License): Change to LGPL.
13823
13824 2004-11-30  Simon Josefsson  <jas@extundo.com>
13825
13826         * m4/restrict.m4: Add copyright and copying conditions.
13827
13828 2004-11-30  Simon Josefsson  <jas@extundo.com>
13829
13830         * m4/base64.m4: New file.
13831
13832 2004-11-30  Simon Josefsson  <jas@extundo.com>
13833
13834         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
13835         base64.
13836
13837         * tests/test-base64.c: New file.
13838
13839         * modules/base64: New file.
13840
13841 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13842
13843         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
13844         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
13845
13846         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
13847
13848 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13849
13850         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
13851         (__getcwd.c): Don't restore errno; glibc doesn't.
13852         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
13853         first, falling back to our code only if its results look suspicious.
13854         Ensure that the resulting buffer is only as large as necessary.
13855
13856         * lib/readutmp.c: Include readutmp.h first.
13857         Include <errno.h>, since readutmp.h no longer does that.
13858         * lib/readutmp.h: Don't include <errno.h>,
13859         <sys/param.h>, <time.h>; not needed to establish interface.
13860         (errno): Remove decl.
13861         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
13862         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
13863         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
13864
13865 2004-11-28  Simon Josefsson  <jas@extundo.com>
13866
13867         * lib/base64.h, base64.c: New file.
13868
13869 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
13870
13871         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
13872
13873 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
13874
13875         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
13876         (Depends-on): Remove pathmax, same.  Add mempcpy.
13877         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
13878         (Makefile.am): Append getcwd.h to lib_SOURCES.
13879         (Include): Add getcwd.h.
13880         (Maintainer): Change from Jim Meyering to "all, glibc",
13881         since getdate now uses intended-for-glibc code.
13882         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
13883         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
13884
13885 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13886
13887         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
13888         HP's ANSI C compiler.
13889         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
13890         Declaring int functions causes warnings on some modern systems and
13891         shouldn't be needed to compile on ancient ones.
13892         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
13893         defined.
13894
13895         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
13896         with the following changes.
13897         (__set_errno): Parenthesize properly.
13898         Include <stdbool.h>.
13899         (MIN, MAX, MATCHING_INO): New macros.
13900         (__getcwd): Define with prototype, not K&R form.
13901         Use heuristics to allocate default buffer on stack if possible.
13902         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
13903         behavior, and to avoid the PATH_MAX limit when computing
13904         ../../../../...
13905         Use MATCHING_INO to compare inode number to file.
13906         Check for arithmetic overflow in size calculations.
13907         Fix bug in reallocation of dot array that caused getcwd to fail
13908         on directories nested deeper than 75.
13909         Be more careful about saving errno on error.
13910         Do not use realloc; use only free+malloc, as this is a bit
13911         more flexible and avoids a needless copy operation.
13912         Do not inspect st_dev and st_ino for symbolic links; POSIX
13913         doesn't specify the latter.
13914         Check for closedir errors.
13915         Avoid needless casts.
13916         Use "#ifdef weak_alias" around weak_alias, to be like other
13917         glibc code.
13918         The following changes to getcwd.c have effect only when used in
13919         gnulib; they have no effect inside glibc proper.
13920         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
13921         as alloca isn't used.
13922         (alloca, __alloca): Likewise.
13923         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
13924         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
13925         unconditionally, as gnulib assumes C89 or better.
13926         Do not include <sys/param.h>.
13927         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
13928         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
13929         better.
13930         (NULL) [!defined NULL]: Remove; we assume C89 or better.
13931         Include <dirent.h> in a way that is compatible with modern Autoconf.
13932         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
13933         New macros, if not already defined.
13934         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
13935         Use "_LIBC", not "defined _LIBC", for consistency.
13936         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
13937         a mempcpy module.
13938         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
13939         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
13940         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
13941         credit only to Jim Meyering and adjust the copyright dates.
13942         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
13943         <stdlib.h>, <unistd.h>, "pathmax.h".
13944         Instead, include "xgetcwd.h" (first) and "getcwd.h".
13945         (INITIAL_BUFFER_SIZE): Remove.
13946         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
13947
13948 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13949
13950         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
13951         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
13952         Use the _ONCE methods, for efficiency.
13953         Check for fcntl.h.  In test program, include <errno.h>
13954         and <fcntl.h> if available.  Remove old K&R cruft from
13955         test program.  Check for common errors in GNU/Linux,
13956         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
13957         don't do AC_LIBOBJ, as that's getcwd.m4's job.
13958         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
13959         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
13960         name accordingly.
13961         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
13962         accommodate new getcwd.c.
13963         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
13964         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
13965         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
13966         that's all we need now.
13967
13968 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13969
13970         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
13971         argp-parse.c depends on getopt internals, that means we should
13972         always use our getopt, to be on the safe side.
13973         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
13974         order not to spoil the result of an eventual previous invocation
13975         of gl_GETOPT_SUBSTITUTE.
13976
13977 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13978
13979         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
13980         redefinition warnings. To avoid them, include the defines
13981         in `#if !defined __need_getopt ... #endif'. The only place
13982         where __getopt_argv_const is used is in definitions
13983         of getopt_long and getopt_long_only below, which are as well
13984         protected by `#ifndef __need_getopt'.
13985         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
13986         __need_getopt after including <stdio.h> and <unistd.h> These
13987         headers might have defined it.
13988
13989 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
13990
13991         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
13992
13993 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
13994
13995         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
13996         (futimens): New function, which uses futimes if available.
13997         (futimens, utimens): Support timespec==NULL, with same semantics
13998         as utime and utimens.
13999         * lib/utimens.h (futimens): New decl.
14000
14001 2004-11-23  Jim Meyering  <jim@meyering.net>
14002
14003         * lib/getopt_.h: Remove trailing blanks.
14004
14005 2004-11-23  Jim Meyering  <jim@meyering.net>
14006
14007         * lib/__fpending.c: Add comment.
14008
14009 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
14010
14011         * modules/canonicalize (Depends-on): Add xreadlink.
14012         Problem reported by James Youngman.
14013
14014 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
14015
14016         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
14017         New macros.
14018         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
14019         optopt): Use them instead of invoking ## directly; otherwise, the
14020         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
14021
14022 2004-11-19  Bruno Haible  <bruno@clisp.org>
14023
14024         * lib/strtok_r.c: Move comments from here...
14025         * lib/strtok_r.h: ... to here.
14026
14027 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14028
14029         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
14030         implementations that mishandle size_t overflow.
14031
14032 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14033
14034         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
14035         might fail.  Problem reported by Yoann Vandoorselaere.
14036         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
14037         implementations that mishandle size_t overflow.
14038
14039 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14040
14041         * modules/canon-host (Depends-on): Add strdup.
14042
14043 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14044
14045         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
14046
14047 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14048
14049         * lib/canon-host.c: Include "strdup.h".
14050         (canon_host): Use getaddrinfo if available, so that IPv6 works.
14051         Use strdup instead of malloc/strcpy to duplicate strings.
14052
14053         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
14054         (human_space_before_unit): New constant.
14055         * lib/human.c (human_readable): Support it.
14056
14057         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
14058         (xgetcwd): Set errno correctly when failing.
14059         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
14060         the failure is actually due to a PATH_MAX problem.
14061
14062         Further getopt changes to make it more likely that glibc will
14063         buy the changes back.
14064         * lib/getopt.c (POSIXLY_CORRECT): New constant.
14065         (getopt): Use it, so to preserve glibc semantic
14066         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
14067         when compiling for libc.
14068         * lib/getopt_.h (__getopt_argv_const): Bring it back.
14069         (getopt_long, getopt_long_only): Use it.
14070
14071         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14072         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
14073         (getopt): Argv is now char * const *, as per standard.
14074         (_getopt_internal_r, _getopt_internal): Argv is now char **,
14075         not char *__getopt_argv_const *.
14076         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14077         _getopt_long_only_r): Likewise.
14078         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
14079         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14080         _getopt_long_r, _getopt_long_only_r): Likewise.
14081         * lib/getopt_.h (__getopt_argv_const): Remove.
14082         (getopt): Argv is now char * const *, as per standard.
14083
14084         * lib/getdate.y (tORDINAL): New token.
14085         (day, relunit): Allow it for relative times.
14086         (relative_time_table): Use tORDINAL for ordinals.
14087
14088 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14089
14090         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
14091         Document that "second" isn't allowed as an ordinal number.
14092
14093 2004-11-16  Jim Meyering  <jim@meyering.net>
14094
14095         * modules/closeout (Depends-on): Add fpending.
14096
14097 2004-11-15  Jim Meyering  <jim@meyering.net>
14098
14099         * lib/closeout.c: Include "__fpending.h" once again.
14100         Include <stdbool.h>.
14101         (close_stdout): Don't fail just because stdout was closed initially,
14102         since some programs don't write to stdout in the normal course of
14103         operation (other than --version and --help), and we don't want this
14104         function to make e.g. `touch file >&-' fail.
14105         But do fail if it was closed and someone has tried to write to it.
14106         E.g., `printf foo >&-' must fail.
14107
14108 2004-11-13  Jim Meyering  <jim@meyering.net>
14109
14110         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
14111
14112 2004-11-12  Simon Josefsson  <jas@extundo.com>
14113
14114         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
14115         small doc fix is still pending.
14116
14117 2004-11-11  Simon Josefsson  <jas@extundo.com>
14118
14119         * modules/strtok_r: New file.
14120
14121         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14122         strtok_r.
14123
14124 2004-11-11  Simon Josefsson  <jas@extundo.com>
14125
14126         * m4/strtok_r.m4: New file.
14127
14128         * m4/getopt.m4: Replace opterr.
14129
14130 2004-11-11  Simon Josefsson  <jas@extundo.com>
14131
14132         * lib/strtok_r.h, strtok_r.c: New file.
14133
14134 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14135
14136         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
14137         of replacing opterr, getopt, etc.  This should handle the
14138         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
14139
14140 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14141
14142         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
14143         we can stop lying to compilers about the constness of argv when we
14144         are compiled outside glibc.
14145         (getopt, getopt_long, getopt_long_only): Use it.
14146         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14147         _getopt_internal, getopt): Likewise.
14148         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14149         _getopt_long_only_r): Likewise.
14150         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14151         _getopt_long_r, _getopt_long_only_r): Likewise.
14152
14153         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
14154         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
14155         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
14156         the other external symbols.
14157         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
14158         declaration, since the above renaming now works around collisions.
14159
14160 2004-11-11  Jim Meyering  <jim@meyering.net>
14161
14162         * lib/linebreak.c: Remove trailing blanks.
14163         * lib/alloca_.h: Likewise.
14164         * lib/acosl.c: Likewise.
14165         * lib/euidaccess.c: Likewise.
14166         * lib/allocsa.h: Likewise.
14167
14168 2004-11-10  Simon Josefsson  <jas@extundo.com>
14169
14170         * m4/getaddrinfo.m4: New file.
14171
14172 2004-11-10  Simon Josefsson  <jas@extundo.com>
14173
14174         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
14175
14176 2004-11-10  Simon Josefsson  <jas@extundo.com>
14177
14178         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14179         getaddrinfo.
14180
14181         * modules/getaddrinfo: New file.
14182
14183 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14184
14185         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
14186
14187 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14188
14189         * lib/mktime.c (SHR): New macro, which is a portable
14190         substitute for >> that should work even on Crays.
14191         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
14192         Problem reported by Mark D. Baushke in
14193         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
14194         * lib/getdate.y (SHR): Likewise.
14195         (tm_diff): Use it.
14196         * lib/strftime.c (SHR): Likewise.
14197         (tm_diff): Use it.
14198         * lib/quotearg.c (struct quoting_options): Use unsigned int for
14199         quote_these_too, so that right shifts are well defined.  All uses
14200         changed.
14201
14202 2004-11-10  Jim Meyering  <jim@meyering.net>
14203
14204         Ensure that no close failure goes unreported.
14205         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
14206         return early when it seems there's nothing to flush.
14207         Don't include __fpending.h.
14208
14209 2004-11-10  Jim Meyering  <jim@meyering.net>
14210
14211         * modules/closeout (Depends-on): Remove fpending.
14212
14213 2004-11-10  Jim Meyering  <jim@meyering.net>
14214
14215         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
14216
14217 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14218
14219         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
14220         gl_FUNC_STRFTIME.
14221         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
14222         and AC_REQUIRE when possible, to avoid duplicate checks.
14223         Check for <wchar.h>.
14224
14225 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14226
14227         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
14228
14229 2004-11-09  Bruno Haible  <bruno@clisp.org>
14230
14231         * m4/sockpfaf.m4: New file.
14232
14233 2004-11-05  Bruno Haible  <bruno@clisp.org>
14234
14235         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
14236         Reported by Mark D. Baushke <mdb@cvshome.org>.
14237
14238 2004-11-04  Bruno Haible  <bruno@clisp.org>
14239
14240         2004-09-11  Bruno Haible  <bruno@clisp.org>
14241                 * allocsa.valgrind: New file.
14242         2004-02-06  Bruno Haible  <bruno@clisp.org>
14243                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
14244                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
14245                 Reported by Christopher Seip <chris.seip@hp.com>.
14246
14247 2004-11-04  Bruno Haible  <bruno@clisp.org>
14248
14249         * modules/allocsa (Files): Add lib/allocsa.valgrind.
14250         (Makefile.am): Distribute it.
14251
14252 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
14253
14254         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
14255         with errno == ERANGE if the buffer is too small.
14256         Problem reported by Mark D. Baushke.
14257
14258 2004-11-03  Albert Chin  <china@thewrittenword.com>
14259             Paul Eggert  <eggert@cs.ucla.edu>
14260
14261         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
14262         equivalent, substitute $ac_type for equivalent type rather than
14263         blindly using uint32_t *always* which won't work if uint32_t is not
14264         available.  Define _UINT32_T to work around typedef of uint32_t if
14265         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
14266         2.5.1.
14267
14268 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14269
14270         * m4/jm-macros.m4: Sync from coreutils.
14271         (gl_MACROS): Check for mbrlen, for pathchk.
14272         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
14273
14274 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14275
14276         * lib/xreadlink.c (MAXSIZE): New macro.
14277         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
14278         size does not exceed MAXSIZE.  Avoid cast.
14279         As suggested by Mark D. Baushke in
14280         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
14281         if readlink fails with buffer size just under MAXSIZE, try again
14282         with MAXSIZE.
14283
14284 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14285
14286         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
14287
14288 2004-11-02  Derek R. Price  <derek@ximbiot.com>
14289         and  Paul Eggert  <eggert@cs.ucla.edu>
14290
14291         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
14292         (get_date): Overparenthesize to avoid GCC warning.
14293
14294 2004-11-02  Bruno Haible  <bruno@clisp.org>
14295
14296         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
14297         returns void.
14298
14299 2004-11-02  Bruno Haible  <bruno@clisp.org>
14300
14301         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
14302         function returns void.
14303
14304 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14305
14306         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
14307         fflush_unlocked, flockfile, funlockfile, funlockfile,
14308         fputs_unlocked, putc_unlocked.
14309
14310 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14311
14312         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14313         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
14314         already declared.
14315
14316 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14317
14318         * modules/getdate (Files): Add doc/getdate.texi.
14319         (Depends-on): Add setenv, xalloc.
14320
14321 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14322
14323         * lib/getdate.y: Add support for TZ="foo" within a date string.
14324         Fix some bugs near time_t boundaries.  Reject dates with
14325         out-of-range components, e.g., "Sept 31".
14326         Include <stdlib.h>, "setenv.h", "xalloc.h".
14327         (ISDIGIT_LOCALE): Remove; unused.
14328         Note that the TZ and time functions used here are not reentrant.
14329         (mktime_ok, get_tz): New functions.
14330         (TZBUFSIZE): New constant.
14331         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
14332         This requires that we sometimes generate our own TZ="XXX..." setting.
14333
14334 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14335
14336         * doc/getdate.texi: New file, from coreutils with modifications for
14337         the new TZ parsing.
14338
14339 2004-10-27  Derek R. Price  <derek@ximbiot.com>
14340
14341         * lib/mktime.c (not_equal_tm): Remove redundant check.
14342
14343 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14344
14345         * modules/regex (lib_SOURCES): Add regex.c.
14346         Reported by James Youngman in
14347         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
14348
14349 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14350
14351         * lib/getdate.y: Use Bison 1.875 features, and some minor
14352         code cleanups.  This change does not affect semantics.
14353         Don't include <stdlib.h>; no longer needed.
14354         Don't include unlocked-io.h; only the "#if TEST" code uses
14355         stdio, and performance isn't crucial there.
14356         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
14357         Bison 1.875 features as described below.
14358         All uses of "PC." replaced by "pc->".
14359         (YYSTYPE): Add a forward declaration.
14360         (yylex, yyerror): Use full prototypes in forward decls.
14361         Use "%pure-parser" rather than obsolescent "%pure_parser".
14362         Use %parse-param and %lex-param instead of obsolescent
14363         YYPARSE_PARAM and YYLEX_PARAM.
14364         (meridian_table, month_and_day_table, time_units_table,
14365         relative_time_table, time_zone_table, military_table,
14366         lookup_zone, lookup_word, get_date):
14367         Use NULL instead of 0 where appropriate.
14368         (to_hour): Avoid abort (), to avoid a dependency on
14369         stdlib.h.
14370         (yyerror, yylex): Now accepts parser_control * arg.
14371         (main) [TEST]: Use '\0' rather than 0 for char.
14372
14373 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14374
14375         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
14376
14377 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14378
14379         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
14380         It's now the caller's responsibility to handle the case where
14381         !HAVE_GETPAGESIZE && !defined getpagesize.
14382
14383         * lib/mktime.c (leapyear): Arg is long int, not int.
14384
14385 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
14386
14387         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
14388
14389 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
14390
14391         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
14392         missing.  Problem reported by James Youngman.
14393
14394 2004-10-16  Simon Josefsson  <jas@extundo.com>
14395
14396         * gnulib-tool: Fix comments.  Fix parse problem.
14397         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
14398
14399 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
14400
14401         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
14402         implementation of getopt_long.  Problem reported by Alexander Taler in:
14403         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
14404
14405 2004-10-15  Bruno Haible  <bruno@clisp.org>
14406
14407         * gnulib-tool: Untabify. Initialize supplied_libname.
14408         (func_usage): More homogenous output.
14409         (func_modules_transitive_closure, func_modules_to_filelist,
14410         func_emit_lib_Makefile_am): New functions.
14411         (func_import): New function, extracted from big case statement. Use
14412         func_get_license, func_modules_transitive_closure,
14413         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
14414         opt_lgpl. Don't use test -a, as it's not portable.
14415         (func_create_testdir): Use func_modules_transitive_closure,
14416         func_modules_to_filelist, func_emit_lib_Makefile_am.
14417
14418 2004-10-15  Bruno Haible  <bruno@clisp.org>
14419
14420         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
14421
14422 2004-10-15  Bruno Haible  <bruno@clisp.org>
14423
14424         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
14425         the portions belonging to each module.
14426         Suggested by Derek Robert Price <derek@ximbiot.com>.
14427
14428 2004-10-12  Simon Josefsson  <jas@extundo.com>
14429
14430         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14431         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
14432         to real functions.
14433
14434 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14435
14436         * modules/vsnprintf: New file.
14437
14438 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14439
14440         * m4/vsnprintf.m4: New file.
14441
14442 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14443
14444         * lib/vsnprintf.h: New file.
14445         * lib/vsnprintf.c: New file.
14446
14447 2004-10-11  Bruno Haible  <bruno@clisp.org>
14448
14449         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
14450         vsnprintf.
14451
14452 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14453
14454         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
14455
14456 2004-10-07  Bruno Haible  <bruno@clisp.org>
14457
14458         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
14459         fits into the provided buffer.
14460
14461 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14462
14463         * lib/diacrit.c, diacrit.h: Add GPL notice.
14464
14465         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
14466         notice.
14467         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
14468         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
14469         This avoids a potential constant-folding bug.
14470
14471 2004-10-05  Bruno Haible  <bruno@clisp.org>
14472
14473         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
14474         for the declaration of strsep.
14475
14476 2004-10-05  Bruno Haible  <bruno@clisp.org>
14477
14478         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
14479
14480 2004-10-04  Simon Josefsson  <jas@extundo.com>
14481
14482         * modules/memmem: New file.
14483         * tests/test-memmem.c: New file.
14484         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
14485
14486 2004-10-04  Simon Josefsson  <jas@extundo.com>
14487
14488         * m4/memmem.m4: New file.
14489
14490 2004-10-04  Simon Josefsson  <jas@extundo.com>
14491
14492         * lib/memmem.h: New file.
14493         * lib/memmem.c: New file, taken from glibc.
14494
14495 2004-10-04  Simon Josefsson  <jas@extundo.com>
14496
14497         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
14498         '#ifdef USE_UNLOCKED_IO'.
14499
14500 2004-10-04  Simon Josefsson  <jas@extundo.com>
14501
14502         * config/srclist.txt: Add memmem from glibc.
14503
14504 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14505
14506         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
14507
14508         * modules/argmatch, modules/argp, modules/closeout, modules/error,
14509         modules/exclude, modules/getdate, modules/getline,
14510         modules/getndelim2, modules/getpass, modules/getpass-gnu,
14511         modules/getusershell, modules/linebuffer, modules/md5,
14512         modules/mountlist, modules/posixtm, modules/readtokens,
14513         modules/readutmp, modules/regex, modules/sha1,
14514         modules/version-etc, modules/yesno:
14515         Remove dependency on unlocked-io.
14516
14517 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14518
14519         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
14520
14521         * m4/unlocked-io.m4: Add copyright notice.
14522         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
14523
14524 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14525
14526         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
14527         * lib/xmalloc.c (xmemdup): Likewise.
14528         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
14529         XFREE): Remove these long-obsolescent macros.
14530         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
14531         * lib/xstrdup.c: Remove.
14532
14533         * lib/regex.c (re_comp): Cast gettext return value to char *,
14534         Problem reported by Martin Neitzel via Mark D. Baushke.
14535
14536 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14537
14538         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
14539         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
14540         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
14541         regex.c, sha1.c, version-etc.c, yesno.c:
14542         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
14543         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
14544         the includer's responsibility.
14545
14546         Sync from coreutils.
14547
14548         * lib/modechange.c (mode_compile): Don't decrement a pointer that
14549         points to the start of a string, as the C Standard says the
14550         resulting behavior is undefined.
14551
14552         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
14553         simple -> simple_backups, numbered_existing ->
14554         numbered_existing_backups, numbered -> numbered_backups
14555         to avoid shadowing problems.  All uses changed.
14556         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
14557         * lib/backupfile.c (check_extension, numbered_backup):
14558         Rename locals to avoid shadowing 'basename'.
14559         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
14560         once.
14561
14562         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
14563         * lib/.cvsignore: Add getopt.h.
14564
14565 2004-10-04  Bruno Haible  <bruno@clisp.org>
14566
14567         * modules/README: New file.
14568         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
14569         not a module.
14570
14571 2004-10-02  Jim Meyering  <jim@meyering.net>
14572
14573         * lib/dirfd.h, getpagesize.h: Add copyright notice.
14574
14575 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14576
14577         * modules/strsep: New file.
14578
14579 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14580
14581         * m4/strsep.m4: New file.
14582
14583 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14584
14585         * lib/strsep.h: New file.
14586         * lib/strsep.c: New file.
14587
14588 2004-10-01  Simon Josefsson  <jas@extundo.com>
14589
14590         * lib/snprintf.c (snprintf): Handle size==0.
14591
14592 2004-10-01  Simon Josefsson  <jas@extundo.com>
14593             Bruno Haible  <bruno@clisp.org>
14594
14595         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
14596         (snprintf): Declare 'args'.
14597
14598 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
14599
14600         * lib/snprintf.c: Remove comments as to why each header is needed.
14601
14602 2004-10-01  Bruno Haible  <bruno@clisp.org>
14603
14604         * MODULES.html.sh: Add strsep.
14605
14606 2004-09-30  Simon Josefsson  <jas@extundo.com>
14607
14608         * modules/snprintf: New file.
14609
14610 2004-09-30  Simon Josefsson  <jas@extundo.com>
14611
14612         * m4/snprintf.m4: New file.
14613
14614 2004-09-30  Simon Josefsson  <jas@extundo.com>
14615
14616         * lib/snprintf.h, lib/snprintf.c: New files.
14617
14618 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14619
14620         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
14621         (hol_entry_help): Never translate an empty string.
14622         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
14623         * lib/argp.h (OPTION_NO_TRANS): New option.
14624
14625 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14626
14627         * modules/argp (Maintainer): Replace Simon Josefsson
14628         by Sergey Poznyakoff.
14629
14630 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14631
14632         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
14633         changes merged back into glibc.
14634
14635 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14636
14637         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
14638
14639 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14640
14641         * lib/xvasprintf.c: Include xalloc.h.
14642         (xvasprintf): Use xalloc_die, not xmalloc_die.
14643
14644 2004-09-29  Bruno Haible  <bruno@clisp.org>
14645
14646         * modules/alloca-opt: New file, derived from modules/alloca.
14647         * modules/allocsa: Depend on alloca-opt instead of alloca.
14648         * modules/setenv: Likewise.
14649         * modules/vasnprintf: Likewise.
14650         * MODULES.html.sh: Add alloca-opt.
14651
14652 2004-09-28  Simon Josefsson  <jas@extundo.com>
14653
14654         * gnulib-tool: New parameter --lgpl, to asseert that modules are
14655         LGPL, and to replace license template from GPL to LGPL.
14656
14657 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14658
14659         * modules/dummy: Change license to LGPL.
14660
14661 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14662
14663         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
14664
14665 2004-09-24  Simon Josefsson  <jas@extundo.com>
14666
14667         * modules/minmax (License): Change from GPL to LGPL.
14668
14669 2004-09-23  Simon Josefsson  <jas@extundo.com>
14670
14671         * gnulib-tool (--import): Typo.
14672
14673 2004-09-23  Simon Josefsson  <jas@extundo.com>
14674
14675         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
14676
14677 2004-09-22  Bruno Haible  <bruno@clisp.org>
14678
14679         * modules/*: Add 'License' field.
14680         * gnulib-tool: Accept --extract-license option.
14681         (func_get_license): New function.
14682
14683 2004-09-21  Bruno Haible  <bruno@clisp.org>
14684
14685         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
14686         Reported by Simon Josefsson.
14687
14688 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14689
14690         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
14691         gl_AC_TYPE_LONG_LONG.
14692
14693 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14694
14695         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
14696
14697 2004-09-18  Simon Josefsson  <jas@extundo.com>
14698         and  Paul Eggert  <eggert@cs.ucla.edu>
14699
14700         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
14701         calls with autoreconf.  Define GL_LIB.
14702
14703 2004-09-14  Karl Berry  <karl@gnu.org>
14704
14705         * config/srclist.txt: unsync setenv.c, sigh.
14706
14707 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14708
14709         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
14710         Problem reported by Bruno Haible in:
14711         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
14712
14713 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14714
14715         * config/srclist.txt: Comment out argp-pvh.c.
14716
14717 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
14718
14719         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
14720         in case some system header has #define'd it.  Problem reported by
14721         Soeren D. Schulze in
14722         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
14723
14724 2004-09-09  Karl Berry  <karl@gnu.org>
14725
14726         * regex.[ch]: delete from the root.  These were supposed to be
14727                 synced with emacs cvs, but this has not happened for about
14728                 a year, and anyway nothing else uses emacs regex.[ch].
14729                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
14730                 lib/regex[.ch] is untouched.
14731
14732 2004-09-09  Bruno Haible  <bruno@clisp.org>
14733
14734         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
14735
14736 2004-09-09  Bruno Haible  <bruno@clisp.org>
14737
14738         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
14739         modifications.
14740         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
14741
14742 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14743
14744         * modules/xvasprintf: New file.
14745         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
14746
14747 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14748
14749         * lib/xvasprintf.h: New file.
14750         * lib/xvasprintf.c: New file.
14751         * lib/xasprintf.c: New file.
14752
14753 2004-09-08  Bruno Haible  <bruno@clisp.org>
14754
14755         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
14756
14757 2004-09-08  Bruno Haible  <bruno@clisp.org>
14758
14759         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
14760         length is > INT_MAX.
14761         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
14762         more.
14763
14764 2004-09-08  Bruno Haible  <bruno@clisp.org>
14765
14766         * lib/stdint_.h: New file, taken from GNU clisp.
14767
14768 2004-09-08  Bruno Haible  <bruno@clisp.org>
14769             Oskar Liljeblad  <oskar@osk.mine.nu>
14770
14771         * modules/stdint: New file.
14772         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
14773
14774 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14775
14776         Import from coreutils.
14777         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
14778         strings on unbounded length.  alloca's performance benefits aren't
14779         that important here.
14780         (V_STRDUP): Remove.
14781         (parse_with_separator): New function, with most of the internals
14782         of the old parse_user_spec.  Allow user to omit both user and group,
14783         for compatibility with FreeBSD.
14784         Clone only the user name, not the entire spec.
14785         Do not set *uid, *gid unless entirely successful.
14786         Avoid memory leak in some failing cases.
14787         Fix regression for USER.GROUP reported by Dmitry V. Levin in
14788         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
14789         (parse_user_spec): Rewrite to use parse_with_separator.
14790
14791 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14792
14793         * modules/userspec: Don't depend on alloca.
14794
14795 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14796
14797         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
14798
14799 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
14800
14801         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
14802         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
14803         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
14804
14805 2004-08-16  Simon Josefsson  <jas@extundo.com>
14806
14807         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
14808         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
14809         Add --dry-run for --import.
14810         Let user provided command line parameters override configure.ac
14811         settings.
14812
14813 2004-08-12  Simon Josefsson  <jas@extundo.com>
14814
14815         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
14816         as discussed with Paul Eggert in threads rooted at
14817         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
14818         and
14819         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
14820         Before, the test was empty, and relied on ELIDE_CODE in source
14821         code.)
14822         (gl_PREREQ_GETOPT): New macro.
14823         (gl_GETOPT): Use them.
14824
14825 2004-08-12  Simon Josefsson  <jas@extundo.com>
14826
14827         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
14828         * lib/getopt_.h: Renamed from getopt.h.
14829
14830 2004-08-12  Simon Josefsson  <jas@extundo.com>
14831
14832         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
14833         Change default library name from libfoo to libgnu.
14834         Now, if you have a configure.ac that says:
14835                 gl_SOURCE_BASE(gl)
14836                 gl_M4_BASE(gl/m4)
14837                 gl_MODULES(error getopt etcetera)
14838                 gl_INIT
14839         you can import all you need by running:
14840                 ../gnulib/gnulib-tool --import
14841
14842         * modules/getopt (Files): Rename getopt.h to getopt_.h.
14843         (Makefile.am): Rewrite, use logic from argz.
14844         (Include): Use <getopt.h> instead of "getopt.h".
14845
14846 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14847
14848         * modules/argp (Files): Add m4/unlocked-io.m4.
14849         (Depends-on): Add extensions.
14850
14851 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14852
14853         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
14854         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
14855         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
14856         Check for program_invocation_name, program_invocation_short_name,
14857         flockfile, funlockfile, features.h, _getopt_long_only_r.
14858
14859 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14860
14861         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
14862         its complicated substitute.
14863         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
14864         and program_invocation_name.
14865         (__argp_basename) [!_LIBC]: Remove; the only use was
14866         replaced by its body.
14867         (__argp_short_program_name): Change condition from
14868         !defined __argp_short_program_name to
14869         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
14870         to match argp-namefrob.h.
14871         (__argp_failure): Don't assume strerror_r returns char *.
14872         * lib/argp-parse.c (N_): Define unconditionally.
14873         (argp_default_options): Fill out initializers with 0 to avoid
14874         gcc warnings.
14875
14876 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14877
14878         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
14879         getopt1.c.
14880
14881 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14882
14883         Merge from coreutils.
14884
14885         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
14886
14887         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
14888         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
14889
14890 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14891
14892         Merge from coreutils.
14893
14894         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
14895         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
14896         for Reliant Unix 5.43.
14897
14898         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
14899         (union fooround): Use uintmax_t, not long int.
14900         The rest is a merge from libc:
14901         [defined _LIBC]: Include <shlib-compat.h>.
14902         (_obstack) [defined _LIBC]: Remove after 2.3.4.
14903
14904         * lib/settime.c (settime): Recode to avoid warning with
14905         Sun Forte C 6U2.
14906
14907         * lib/strverscmp.c: Convert to UTF-8.
14908
14909 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14910
14911         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14912         m4/uintmax_t.m4.
14913
14914 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14915
14916         * modules/xalloc-die: New file.
14917         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
14918
14919         * modules/md5 (Files): Add m4/uint32_t.m4.
14920         * modules/sha1: Renamed from modules/sha.
14921         (Files):
14922         Rename lib/sha.h to lib/sha1.h.
14923         Rename lib/sha.c to lib/sha1.c.
14924         Rename m4/sha.m4 to m4/sha1.m4.
14925         (lib_SOURCES): Likewise.
14926         (configure.ac): Rename gl_SHA to gl_SHA1.
14927         (Include): sha.h -> sha1.h.
14928
14929 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14930
14931         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
14932         * m4/sha1.m4: Renamed from sha.m4.
14933         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
14934
14935 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14936
14937         * lib/obstack.h (obstack_empty_p):
14938         Don't assume that chunk->contents is suitably aligned.
14939         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
14940         Likewise. Problem reported by Benno in
14941         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
14942
14943         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
14944         readable.  This could be improved further but it'd take some work.
14945
14946 2004-08-08  Simon Josefsson  <jas@extundo.com>
14947
14948         * modules/xgethostname (Depends-on): Remove exit and error (not
14949         used).
14950
14951         * modules/getpass-gnu: Add getpass.h.
14952         (Depends-on): Add stdbool.
14953         * modules/getpass: Add getpass.h.
14954
14955 2004-08-08  Simon Josefsson  <jas@extundo.com>
14956
14957         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
14958         Check getpass declaration.
14959
14960 2004-08-08  Simon Josefsson  <jas@extundo.com>
14961
14962         * lib/xgethostname.c: Don't include error.h (not used).
14963
14964         * lib/getpass.h: Add.
14965         * lib/getpass.c: Include getpass.h first.
14966
14967 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
14968
14969         * lib/xalloc-die.c: New file.
14970         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
14971         All uses removed.
14972         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
14973         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
14974         xalloc-die.c.
14975         (_, N_, xalloc_die): Move to xalloc-die.c.
14976         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
14977         so that we needn't mess with xalloc_msg_memory_exhausted.
14978
14979         * lib/sha1.h: Renamed from sha.h.
14980         (SHA1_H): Renamed from _SHA_H.
14981         (sha1_ctx): Renamed from sha_ctx.
14982         (sha1_init_ctx): Renamed from sha_init_ctx.
14983         (sha1_process_block): Renamed from sha_process_block.
14984         (sha1_process_bytes): Renamed from sha_process_bytes.
14985         (sha1_finish_ctx): Renamed from sha_finish_ctx.
14986         (sha1_read_ctx): Renamed from sha_read_ctx.
14987         (sha1_stream): Renamed from sha_stream.
14988         (sha1_buffer): Renamed from sha_buffer.
14989         * lib/sha1.c: Likewise; renamed from sha.c.
14990         Do not include <sys/types.h>.
14991         Include <stddef.h> rather than <stdlib.h>.
14992
14993 2004-08-08  Bruno Haible  <bruno@clisp.org>
14994
14995         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
14996         FILESYSTEM_PREFIX_LEN.
14997         * lib/progreloc.c: Likewise.
14998         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
14999
15000 2004-08-06  Simon Josefsson  <jas@extundo.com>
15001
15002         * modules/progname (Depends-on): Don't depend on stdbool.
15003
15004 2004-08-06  Simon Josefsson  <jas@extundo.com>
15005
15006         * modules/getsubopt: New file.
15007         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15008         getsubopt.
15009
15010 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15011
15012         More merge from coreutils.
15013
15014         * m4/utimens.m4, m4/utimecmp.m4: New files.
15015         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
15016         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
15017         prereq.m4, sha.m4: Import changes from coreutils.
15018
15019 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15020
15021         More merge from coreutils.
15022         * modules/raise, modules/readtokens0, modules/utimens:
15023         * modules/utimecmp, module/xnanosleep: New files.
15024         * modules/strftime: Add lib/strftime.h.
15025         Change include from <time.h> to "strftime.h".
15026         * modules/yesno: Add lib/yesno.h.
15027         * modules/backupfile: Remove lib/addext.c.
15028         * modules/euidaccess: Add stat-macros.h.
15029         * modules/canonicalize, modules/euidaccess,
15030         modules/filemode, modules/lchown, modules/makepath,
15031         modules/rmdir, modules/stat: Likewise.
15032
15033 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15034
15035         Merge from tar.
15036         * lib/argp-help.c (make_hol, hol_append): Don't assume that
15037         SIZE_MAX is a valid preprocessor constant.
15038         (__argp_basename): Change from "#ifndef _LIBC"
15039         to "#ifndef __argp_short_program_name", so that
15040         we don't compile these functions for tar.
15041
15042         More merges from coreutils.
15043         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
15044         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
15045         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
15046         * lib/addext.c: Remove; no longer needed.
15047         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
15048         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
15049         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
15050         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
15051         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
15052         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
15053         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
15054         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
15055         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
15056         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15057         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
15058         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
15059         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
15060         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
15061         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
15062         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
15063         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
15064         Import changes from coreutils.
15065
15066 2004-08-05  Simon Josefsson  <jas@extundo.com>
15067
15068         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
15069
15070 2004-08-05  Simon Josefsson  <jas@extundo.com>
15071
15072         * m4/getsubopt.m4: New file.
15073
15074 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15075
15076         Merge from coreutils.
15077
15078         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
15079         * m4/getcwd-path-max.m4: New files.
15080
15081         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
15082         FILESYSTEM_PREFIX_LEN ->
15083         FILE_SYSTEM_PREFIX_LEN.
15084         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
15085         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
15086         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
15087         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
15088
15089         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
15090         prerequisite modules now handle the DOS stuff.
15091         Don't check for unistd.h.
15092
15093 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15094
15095         Merge from coreutils.
15096
15097         * lib/.gdb-history: Remove; this doesn't belong here.
15098
15099         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
15100         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
15101         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
15102         * lib/getcwd.c: New files.
15103
15104         * lib/dirname.h: Include <stdbool.h>.
15105         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
15106         for consistency with POSIX terminology.  All uses changed.
15107         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
15108         (strip_trailing_slashes): Use bool for booleans.
15109         * lib/stripslash.c (strip_trailing_slashes): Likewise.
15110
15111         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
15112         sometimes returns a positive errno value even when it succeeds.
15113         (print_errno_message) [!LIBC]: Fall back on strerror if
15114         __strerror_r fails.
15115
15116         * lib/path-concat.c (mempcpy): Don't define if a system header defines
15117         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
15118         (longest_relative_suffix): New function.
15119         (path_concat): Use it.  Assume first argument is not NULL.
15120         Port to DOS.  Omit redundant separators.
15121         Report an error instead of returning NULL.
15122         Use mempcpy instead of memcpy.
15123         (xpath_concat): Remove: not declared or used.
15124
15125         * lib/same.h: Include <stdbool.h>
15126         (same_name): Return bool, not int.
15127         * lib/same.c (same_name): Likewise.
15128         (errno): Don't declare; we assume C89 or better now.
15129
15130         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
15131         if not already defined.
15132
15133         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
15134         * lib/dup-safer.c (errno): Likewise.
15135
15136 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15137
15138         Merge from coreutils.
15139         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
15140         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
15141         * modules/path-concat: Don't depend on strdup.
15142
15143 2004-08-03  Simon Josefsson  <jas@extundo.com>
15144
15145         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
15146         * lib/progname.h: Don't include stdbool.h.
15147
15148 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15149
15150         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
15151         * MODULES.html.sh (func_all_modules): Remove fatal.
15152
15153 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15154
15155         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
15156
15157 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15158
15159         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
15160         working.
15161
15162 2004-08-02  Simon Josefsson  <jas@extundo.com>
15163
15164         * lib/getsubopt.h: New file, with comments from Bruno Haible.
15165         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
15166         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
15167
15168 2004-08-01  Simon Josefsson  <jas@extundo.com>
15169
15170         * lib/xgetdomainname.c: Include stdlib.h, for free().
15171
15172 2004-07-19  Bruno Haible  <bruno@clisp.org>
15173
15174         * MODULES.html.sh (func_all_modules): Add dummy.
15175
15176 2004-07-16  Simon Josefsson  <jas@extundo.com>
15177
15178         * modules/dummy: New file.
15179
15180 2004-07-16  Simon Josefsson  <jas@extundo.com>
15181
15182         * lib/dummy.c: New file.
15183
15184 2004-07-16  Bruno Haible  <bruno@clisp.org>
15185
15186         * lib/backupfile.h: Add extern "C" for C++.
15187         * lib/closeout.h: Likewise.
15188         * lib/copy-file.h: Likewise.
15189         * lib/findprog.h: Likewise.
15190         * lib/full-write.h: Likewise.
15191         * lib/pathname.h: Likewise.
15192         * lib/progname.h: Likewise.
15193         * lib/stpcpy.h: Likewise.
15194         * lib/stpncpy.h: Likewise.
15195         * lib/strcase.h: Likewise.
15196         * lib/strstr.h: Likewise.
15197         * lib/xalloc.h: Likewise.
15198
15199         * lib/mbswidth.h: Add extern "C" for C++.
15200         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
15201
15202 2004-07-13  Robert Millan  <robertmh@gnu.org>
15203
15204         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
15205
15206 2004-07-09  Simon Josefsson  <jas@extundo.com>
15207
15208         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
15209         failed without this.)
15210
15211 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15212
15213         * modules/chown (Files): Add lib/fchown-stub.c, since
15214         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
15215
15216 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15217
15218         * lib/fchown-stub.c: New file.
15219
15220 2004-06-24  Jim Meyering  <jim@meyering.net>
15221
15222         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
15223
15224 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15225
15226         * modules/argz: Omit "#include".
15227
15228         * MODULES.html.sh (func_all_modules): Add calloc, to match
15229         2004-06-01 addition of calloc module.
15230
15231 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15232
15233         * m4/argz.m4: New file, which is autoupdated from libtool.
15234
15235 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15236
15237         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
15238         libtool.
15239
15240 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15241
15242         * config/srclist-update: Don't insist on "USA." before the
15243         close-comment, as libtool omits the period and puts the */ on a
15244         separate line.
15245         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
15246         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
15247
15248 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
15249
15250         * modules/argz: New file.
15251         * MODULES.html.sh (func_all_modules): Add argz.
15252
15253 2004-06-12  Jim Meyering  <jim@meyering.net>
15254         and  Paul Eggert  <eggert@cs.ucla.edu>
15255
15256         * modules/hash (Files): Add lib/xalloc.h.
15257         * modules/pipe (Depends-on): Add wait-process.
15258         * modules/stat (Depends-on): Add xalloc.
15259         * modules/userspec (Files): Add lib/userspec.h.
15260         * modules/xstrto
15261
15262         Upgrade from gettext-0.13.
15263         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
15264         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
15265         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
15266
15267 2004-06-10  Jim Meyering  <jim@meyering.net>
15268
15269         * lib/calloc.c: New file.
15270
15271 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
15272
15273         * lib/getdate.y (yylex): Allow space between sign and number.
15274         Problem reported by Dan Jacobson.
15275
15276 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15277
15278         Merge from coreutils CVS.
15279
15280         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
15281         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
15282         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
15283         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
15284         xstrtol.m4: Fix copyright date and/or serial number.
15285
15286         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
15287         See if we need an fchown replacement.
15288         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
15289         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
15290         and use the replacement function if we detect either defect.
15291
15292         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
15293         gl_UTIMECMP.
15294
15295 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15296         and  Jim Meyering  <jim@meyering.net>
15297
15298         Merge from coreutils CVS.
15299
15300         * lib/stat-macros.h: New file, with contents from file-type.h
15301         and coreutils' system.h.
15302         * lib/file-type.c: Include "stat-macros.h".
15303         * lib/file-type.h (file_type): Move all macro definitions to new file,
15304         stat-macros.h.
15305
15306         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
15307         Wrap old code with this conditional.
15308         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
15309         function that does not dereference symlinks.
15310         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
15311
15312         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
15313         dependency problems.
15314         (xreadlink): Accept new arg SIZE, for efficiency.
15315         All decls and uses changed.
15316         * lib/xreadlink.h: Include <stddef.h>, for size_t.
15317
15318         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
15319         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
15320
15321         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
15322         sysexits.h.
15323
15324 2004-06-01  Jim Meyering  <jim@meyering.net>
15325
15326         * m4/calloc.m4: New file.
15327
15328 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
15329
15330         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
15331         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
15332         Also, fix a typo in a diagnostic.
15333
15334 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15335
15336         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
15337         or AC_FUNC_REALLOC.
15338
15339 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15340
15341         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
15342         macros to be defined.
15343         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
15344         the allocator returns NULL because the requested size is zero.
15345
15346 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15347
15348         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
15349         var.  Add comment explaining why libc still defines it.  This
15350         merges the following patch from glibc:
15351         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
15352
15353 2004-05-20  Andreas Schwab  <schwab@suse.de>
15354
15355         * m4/free.m4: Replace free if it not known to work, not the other
15356         way round.
15357
15358 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
15359
15360         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
15361         present in glibc since revision 1.1 of this file.
15362         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
15363         obstack_alignment_mask, obstack_alloc, obstack_base,
15364         obstack_blank, obstack_blank_fast, obstack_chunk_size,
15365         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
15366         obstack_grow0, obstack_init, obstack_int_grow,
15367         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
15368         obstack_next_free, obstack_object_size, obstack_ptr_grow,
15369         obstack_ptr_grow_fast, obstack_room): Remove declarations of
15370         nonexistent functions.
15371
15372 2004-05-18  Karl Berry  <karl@gnu.org>
15373
15374         * config/srclist.txt: break link for vasnprintf.c.
15375
15376 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15377
15378         Port obstack to the AS/400, where pointers are 16 bytes wide and
15379         you cannot cast an integer to a valid pointer.  This patch is
15380         currently waiting to be integrated into glibc; see
15381         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
15382
15383         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
15384         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
15385         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
15386         (struct obstack): temp member is now a union of a pointer and
15387         an integer, instead of an integer.  All integer uses changed.
15388         This does not affect the physical layout of struct obstack,
15389         except on hosts (like the AS/400) where the size or alignment of
15390         void * is greater than that of ptrdiff_t.
15391         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
15392         __STDC__)]: Store temporary in pointer member of union, not
15393         integer member.
15394         * lib/obstack.c: Include <stddef.h>, for offsetof.
15395         (struct fooalign): Remove; it doesn't need a name.
15396         (union fooround): Change double to long double, and add void *.
15397         (DEFAULT_ALIGNMENT): Use offsetof to compute.
15398         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
15399         not a macro.  Hence the values are always int; so remove all
15400         casts-to-int in uses.
15401
15402 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15403
15404         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
15405         we can get this patch merged into glibc.
15406
15407 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15408             Paul Eggert  <eggert@cs.ucla.edu>
15409
15410         * m4/argp: Depend on alloca.
15411
15412 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15413             Paul Eggert  <eggert@cs.ucla.edu>
15414
15415         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
15416         freecoding.
15417
15418 2004-05-17  Bruno Haible  <bruno@clisp.org>
15419
15420         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
15421         precision that consists of a '.' followed by an empty digit string.
15422         Patch by Tor Lillqvist <tml@iki.fi>.
15423
15424 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15425
15426         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
15427         for backward compatibility with older code.  We need our own
15428         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
15429         it under some other name, and our alloca.h will define it.
15430
15431 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15432             Derek Price  <derek@ximbiot.com>
15433
15434         * lib/alloca.c: Include <alloca.h>, to get our interface.
15435         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
15436         include <alloca.h> first.  Use C89 prototype for alloca; this
15437         requires including <stddef.h> for size_t.  Use extern "C" if C++.
15438         Use #elif for simplicity, since we can assume C89 now.
15439         Don't try to source the system alloca.h since it will not be found
15440         and to prevent recursively including its replacement.
15441         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
15442         * lib/regex.c: Likewise.
15443
15444 2004-05-16  Derek Price  <derek@ximbiot.com>
15445             Paul Eggert  <eggert@cs.ucla.edu>
15446
15447         getline cleanup.  This changes the getndelim2 API: both order of
15448         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
15449         no delimiter).
15450
15451         * lib/getline.c: Don't include stddef.h or stdio.h, since our
15452         interface does that.
15453         (getline): Always use getdelim, so that we don't have two
15454         copies of this code.
15455         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
15456         if available.
15457         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
15458         (GETNDELIM2_MAXIMUM): New macro.
15459         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
15460         instead of the old practice of delim2==0.  All callers changed.
15461         Return -1 on overflow, instead of returning junk.
15462         Do not set *linesize unless allocation succeeds.
15463         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
15464         that we include sys/types.h.
15465         * lib/getnline.h: Likewise.
15466         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
15467         (getndelim2): Reorder arguments.
15468         * lib/getnline.c (getnline, getndelim):
15469         Don't discard the NMAX argument.
15470         (getnline): Invoke getndelim, to avoid code duplication.
15471         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
15472         of (size_t) -1 by callers of the getnline family.
15473
15474 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15475
15476         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
15477         Check for gettimeofday.
15478         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
15479         Check for settimeofday, stime.
15480
15481 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15482
15483         * lib/nanosleep.c (suspended): Change its type from int to
15484         sig_atomic_t volatile.
15485         (first_call): Make it private to rpl_nanosleep, and have it
15486         be zero initially as that's a bit faster.
15487         (my_usleep): Round up fractional times instead of truncating them,
15488         as this is the usual meaning for 'sleep'.
15489
15490         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
15491         doesn't work.
15492         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
15493         (ENOSYS): Define if not defined.
15494         (settime): Fall back on stime if it exists and settimeofday fails.
15495         But don't bother with fallbacks if a method fails with errno == EPERM.
15496
15497 2004-05-11  Jim Meyering  <jim@meyering.net>
15498
15499         Prior to this change, the save_cwd caller required read access to the
15500         current directory on most systems (ones with the fchdir function).
15501
15502         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
15503         fails, try write-only, and finally, resort to using xgetcwd.
15504
15505 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15506
15507         * lib/obstack.c, obstack.h: Import changes from libc.
15508
15509 2004-04-28  Bruno Haible  <bruno@clisp.org>
15510
15511         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
15512         also implicitly appends .exe to executables.
15513         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
15514         accepts Windows pathnames.
15515         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15516         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15517         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15518         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15519         Reported by Derek Robert Price <derek@ximbiot.com>.
15520
15521 2004-04-21  Karl Berry  <karl@gnu.org>
15522
15523         * config/srclist.txt (localcharset.c): break sync.
15524
15525 2004-04-20  Paul Eggert  <eggert@twinsun.com>
15526
15527         * m4/host-os.m4: Add a copyright notice.
15528
15529 2004-04-20  Jim Meyering  <jim@meyering.net>
15530
15531         Change UTILS_ to gl_ in AC_DEFINE'd names.
15532         Change utils_- and jm_-prefixed variables, too.
15533         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
15534         UTILS_FUNC_MKDIR_TRAILING_SLASH.
15535         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
15536
15537         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
15538         Don't emit trailing blanks.
15539         Also rename jm_-prefixed variables to have gl_ prefix.
15540
15541         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
15542         Also rename jm_-prefixed variables to have gl_ prefix.
15543
15544         * m4/jm-macros.m4: Reflect the renamings.
15545         * m4/prereq.m4: Likewise.
15546
15547 2004-04-20  Jim Meyering  <jim@meyering.net>
15548
15549         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
15550         memory.
15551
15552 2004-04-20  Jim Meyering  <jim@meyering.net>
15553             Bruno Haible  <bruno@clisp.org>
15554
15555         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
15556         memory when realloc fails.
15557
15558 2004-04-19  Jim Meyering  <jim@meyering.net>
15559
15560         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
15561         now that readutmp.c may call `free (0)'.
15562
15563 2004-04-19  Bruno Haible  <bruno@clisp.org>
15564
15565         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
15566         * m4/inttypes_h.m4: Likewise.
15567         * m4/stdint_h.m4: Likewise.
15568         * m4/intmax_t.m4: Likewise.
15569         * m4/uintmax_t.m4: Likewise.
15570
15571 2004-04-18  Jim Meyering  <jim@meyering.net>
15572
15573         * m4/prereq.m4: Don't forbid jm_ prefix.
15574
15575         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
15576         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
15577         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
15578         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
15579         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
15580         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
15581         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
15582         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
15583         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
15584         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
15585         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
15586         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
15587         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
15588         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
15589         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
15590         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
15591         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
15592         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
15593         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
15594
15595 2004-04-18  Jim Meyering  <jim@meyering.net>
15596
15597         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
15598         failure, don't leak memory and do call END_UTMP_ENT.
15599
15600 2004-04-16  Jim Meyering  <jim@meyering.net>
15601
15602         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
15603         coreutils' stat program.
15604         (gl_PREREQ): Don't require jm_PREREQ_STAT.
15605
15606 2004-04-11  Paul Eggert  <eggert@twinsun.com>
15607
15608         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
15609         C89.
15610         (CHAR_BIT): Remove, since we assume C89.
15611         Include <stdint.h> if available, as per current Autoconf CVS advice.
15612
15613 2004-03-31  Jim Meyering  <jim@meyering.net>
15614
15615         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
15616         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
15617         * m4/xalloc.m4: Likewise.
15618
15619 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15620
15621         Merge from coreutils.
15622
15623         * m4/inttostr.m4: New file.
15624         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
15625         Require AM_STDBOOL_H and gl_TIMESPEC instead.
15626         Require gl_CLOCK_TIME.
15627         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
15628
15629 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15630
15631         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
15632         not bool, to be more consistent with Unix conventions.
15633         Suggested by Bruno Haible.
15634
15635         Merge from coreutils.
15636
15637         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
15638         * lib/umaxtostr.c: New files.
15639
15640         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
15641         the usual <time.h> dance.
15642         (get_date): Change signature to support fractional time stamps.
15643         All callers changed.
15644         * lib/getdate.y: Include "getdate.h" first, as we can now
15645         assume C89 and don't need to worry about 'const'.
15646         Similarly, include "unlocked-io.h" near start, not in middle.
15647         Include <limits.h>.
15648         (textint.value): Use long int rather than int.
15649         (textint.digits): Use size_t rather than int.
15650         (BILLION, LOG10_BILLION): New constants.
15651         (parser_control): New member rel_ns.  Members day_ordinal,
15652         time_zone, month, day, hour, minutes, rel_year, rel_month,
15653         rel_day, rel_hour, rel_minutes, rel_seconds
15654         are now long int, not int.  Member seconds is now struct timespec,
15655         not int.  New member timespec_seen.  Members dates_seen, days_seen,
15656         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
15657         not int.
15658         (%union.intval): Now long int, not int.
15659         New member timespec.
15660         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
15661         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
15662         (spec): Now is a timespec or an item list.
15663         (timespec, items): New nonterminals.
15664         (time, rel, relunit, number, get_date):
15665         Add support for fractional seconds.
15666         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
15667         (gmtime, localtime, mktime): Remove decls; not needed with C89.
15668         (to_hour): First arg is now long int, not int.
15669         (to_year): Returns long int, not int.
15670         Don't treat year -70 like 70.
15671         (tm_diff): Returns long int, not int.
15672         (lookup_word): Use bool instead of int when appropriate.
15673         (yylex): Use size_t for count, not int.
15674         Detect overflow when parsing large integer constants.
15675         Add support for fractions.
15676         (get_date): Make pointers 'const' if possible.
15677         Use more-portable code to detect integer overflow.
15678         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
15679         Don't use ctime; it's not reliable if the year has >4 digits.
15680
15681         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
15682         This is for compatibility with BSD.
15683
15684         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
15685         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
15686         From coreutils' system.h.
15687
15688         * lib/userspec.c: Don't include "posixver.h".
15689         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
15690         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
15691         compatible extension.  Simplify code by removing a boolean int
15692         that was always nonzero if a string was nonnull.
15693
15694 2004-03-30  Jim Meyering  <jim@meyering.net>
15695
15696         Merge from coreutils.
15697
15698         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
15699         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
15700         on some systems one must include <grp.h> before it.
15701         Reported by Christian Krackowizer.
15702
15703 2004-03-30  Jim Meyering  <jim@meyering.net>
15704
15705         Merge from coreutils.
15706
15707         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
15708
15709         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
15710         an empty input stream.
15711
15712         * lib/readtokens.c: Include <stdbool.h>.
15713         (readtoken): Use `size_t' rather than int/long.
15714         All callers adjusted.
15715         Use `bool' rather than `int' where appropriate.
15716         Use memset rather than an explicit loop.
15717         Use x2nrealloc rather than xrealloc.
15718         Allow the use of `\0' as a delimiter.
15719         (readtokens): Likewise.
15720         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
15721
15722 2004-03-30  Jim Meyering  <jim@meyering.net>
15723
15724         * m4/realloc.m4: Remove file, since now it does no more than
15725         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
15726         the `configure.ac' section of module/realloc.
15727         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
15728
15729 2004-03-30  Bruno Haible  <bruno@clisp.org>
15730
15731         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
15732         nonnull.
15733
15734 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15735
15736         Merge changes to getloadavg.c from coreutils and Emacs.
15737
15738         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
15739         Define to an expression, not to the empty string.
15740         Include cloexec.h and xalloc.h.
15741         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
15742         Use set_cloexec_flag rather than rolling our own.
15743         * lib/cloexec.c, lib/cloexec.h: New files.
15744
15745 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15746
15747         * m4/cloexec.m4: New file.
15748
15749 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15750
15751         * lib/getopt.h: Sync with libc CVS.
15752
15753 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15754             Bruno Haible  <bruno@clisp.org>
15755
15756         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
15757         mbswidth.
15758
15759 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15760             Bruno Haible  <bruno@clisp.org>
15761
15762         * lib/mbswidth.h: Include <wchar.h> only if
15763         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
15764         <wchar.h>.
15765         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
15766
15767 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15768
15769         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
15770         Sync with libc CVS.
15771         * lib/getopt_int.h: New file, also synced from libc.
15772
15773 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15774
15775         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
15776         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
15777         Bring back getopt.c, getopt.h, getopt1.c.
15778
15779 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15780
15781         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
15782         All uses changed.  Check for sa_sigaction member; this fixes
15783         a bug first reported by Jason Andrade in
15784         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15785
15786 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15787
15788         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
15789         '#if' expressions.  Unlike the code it replaces, it does not
15790         depend on (defined _SC_PAGESIZE).  However, it does depend on
15791         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
15792         first reported by Jason Andrade in
15793         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15794
15795 2004-02-25  Simon Josefsson  <jas@extundo.com>
15796
15797         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
15798
15799 2004-02-25  Simon Josefsson  <jas@extundo.com>
15800
15801         * lib/strdup.h: New file.
15802         * lib/strdup.c: Include it.
15803         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
15804         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
15805
15806 2004-02-23  Karl Berry  <karl@gnu.org>
15807
15808         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
15809         (from fencepost.gnu.org:/gd/gnuorg).
15810
15811 2004-02-23  Karl Berry  <karl@gnu.org>
15812
15813         * config/srclistvars.sh (GNUORG) [karl]: redefine.
15814         * config/srclist.txt: add maintain/standards documents.
15815
15816 2004-02-18  Bruno Haible  <bruno@clisp.org>
15817
15818         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
15819         Reported by Derek Robert Price <derek@ximbiot.com>.
15820
15821 2004-02-16  Karl Berry  <karl@gnu.org>
15822
15823         * config/mkinstalldirs, install-sh: update from automake.
15824
15825 2004-02-06  Karl Berry  <karl@gnu.org>
15826
15827         * m4/po.m4: update from gettext 0.14.1.
15828
15829 2004-02-06  Karl Berry  <karl@gnu.org>
15830
15831         * lib/config.charset: update from gettext 0.14.1.
15832
15833 2004-02-05  Paul Eggert  <eggert@twinsun.com>
15834
15835         Add comments and code, prompted by suggestions from Bruno Haible
15836         for sh-quote.
15837         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
15838         describing the enum quoting_style values.
15839         * lib/quotearg.c (quotearg_alloc): New function.
15840         (quotearg_buffer_restyled): Treat lone { and } as special.
15841         Treat = as special.  Work around bug with older shells
15842         that "see" a '\' that is really the 2nd byte of a multibyte char.
15843         Quote empty string with shell_quoting_style.
15844
15845 2004-02-03  Bruno Haible  <bruno@clisp.org>
15846
15847         * m4/pipe.m4: New file, from GNU gettext.
15848
15849 2004-02-03  Bruno Haible  <bruno@clisp.org>
15850
15851         * lib/pipe.h: New file, from GNU gettext.
15852         * lib/pipe.c: New file, from GNU gettext.
15853
15854 2004-01-27  Bruno Haible  <bruno@clisp.org>
15855
15856         * m4/execute.m4: New file, from GNU gettext.
15857
15858 2004-01-27  Bruno Haible  <bruno@clisp.org>
15859
15860         * lib/execute.h: New file, from GNU gettext.
15861         * lib/execute.c: New file, from GNU gettext.
15862         * lib/w32spawn.h: New file, from GNU gettext.
15863
15864 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15865
15866         Merge from diffutils.
15867
15868         * lib/file-type.c (file_type): Add typed memory objects.
15869         * lib/file-type.h (S_TYPEISTMO): New macro.
15870
15871         * lib/c-stack.h (c_stack_action): Remove argv argument.
15872         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
15873         (die): Don't calculate message unless segv_action returns.
15874         (get_stack_location, min_address_from_argv, max_address_from_argv,
15875         volatile stack_base, volatile_stack_size): Remove.
15876         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
15877         that every segmentation violation is a stack overflow.  (Ouch!)
15878         See Debian bug 136249 (still outstanding) for more info about why
15879         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
15880
15881 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15882
15883         Exit-status fix from coreutils.
15884
15885         Use exit_failure consistently in place of EXIT_FAILURE,
15886         so that program exit statuses are consistent on failure.
15887
15888         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
15889         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
15890         * lib/argmatch.h: Comment fix to match the above.
15891         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
15892         Now a macro referring to exit_failure, instead of a separate
15893         variable.  Include "exitfail.h" to get it.
15894         * lib/xstrtol.h: Include "exitfail.h".
15895         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
15896
15897         * lib/long-options.c (parse_long_options): Use prototype
15898         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
15899         for clarity.
15900
15901 2004-01-21  Jim Meyering  <jim@meyering.net>
15902
15903         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
15904         so as not to conflict with a different-sized __mktime_internal
15905         function in GNU libc.
15906         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
15907         Problem building statically-linked `ls' reported by Michael Brunnbauer.
15908
15909 2004-01-20  Karl Berry  <karl@gnu.org>
15910
15911         * config/config.guess: update from config.
15912
15913         * config/srclistvars.sh: GNUWWWLICENSES for karl.
15914
15915 2004-01-20  Bruno Haible  <bruno@clisp.org>
15916
15917         Safer stack allocation.
15918         * lib/setenv.c: Include allocsa.h.
15919         (alloca): Remove fallback definition.
15920         (freea): Remove macro.
15921         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
15922         instead of freea.
15923
15924 2004-01-20  Bruno Haible  <bruno@clisp.org>
15925
15926         * m4/eealloc.m4: New file, from GNU gettext.
15927
15928 2004-01-20  Bruno Haible  <bruno@clisp.org>
15929
15930         * m4/allocsa.m4: New file, from GNU gettext.
15931
15932 2004-01-20  Bruno Haible  <bruno@clisp.org>
15933
15934         * lib/xallocsa.h: New file, from GNU gettext.
15935         * lib/xallocsa.c: New file, from GNU gettext.
15936
15937 2004-01-20  Bruno Haible  <bruno@clisp.org>
15938
15939         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
15940
15941 2004-01-20  Bruno Haible  <bruno@clisp.org>
15942
15943         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
15944         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
15945         specially.
15946
15947 2004-01-20  Bruno Haible  <bruno@clisp.org>
15948
15949         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
15950         patch.
15951
15952 2004-01-20  Bruno Haible  <bruno@clisp.org>
15953
15954         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
15955
15956 2004-01-20  Bruno Haible  <bruno@clisp.org>
15957
15958         * lib/eealloc.h: New file.
15959
15960 2004-01-20  Bruno Haible  <bruno@clisp.org>
15961
15962         * lib/binary-io.h: Avoid warnings on Cygwin.
15963
15964 2004-01-20  Bruno Haible  <bruno@clisp.org>
15965
15966         * lib/allocsa.h: New file, from GNU gettext.
15967         * lib/allocsa.c: New file, from GNU gettext.
15968
15969 2004-01-18  Karl Berry  <karl@gnu.org>
15970
15971         * doc/gpl.texi, doc/lgpl.texi: new files.
15972
15973 2004-01-18  Karl Berry  <karl@gnu.org>
15974
15975         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
15976         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
15977
15978 2004-01-15  Paul Eggert  <eggert@twinsun.com>
15979
15980         Merge from coreutils.
15981
15982         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
15983         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
15984         (gl_DEFAULT_POSIX2_VERSION): Move
15985         the documentation from 'configure' into 'config.hin',
15986         so that 'configure --help' isn't burdened by it and
15987         we don't have to worry about its formatting there.
15988         Reword the documentation so that it's more succinct
15989         and can be run together into a single paragraph.
15990         * m4/same.m4 (gl_SAME): Check for pathconf.
15991
15992 2004-01-15  Paul Eggert  <eggert@twinsun.com>
15993
15994         Merge from coreutils.
15995
15996         * lib/posixver.c: Include posixver.h.
15997
15998         * lib/same.c: Include <stdbool.h>, <limits.h>.
15999         (_POSIX_NAME_MAX): Define if not defined.
16000         (MIN): New macro.
16001         (same_name): If file names are silently truncated, report
16002         that the file names are the same if they are the same after
16003         the silent truncation.
16004
16005         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
16006         conversion function.
16007         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
16008         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
16009         longer needed.
16010
16011 2004-01-15  Jim Meyering  <jim@meyering.net>
16012
16013         Merge from coreutils.
16014
16015         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
16016         if no library is required.
16017         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
16018         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
16019         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
16020         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
16021         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
16022         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
16023         value, $ac_cv_search_crypt, if it's "none required".
16024         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
16025         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
16026         not gl_FUNC_GETLOADAVG.
16027         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
16028         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
16029
16030 2004-01-15  Jim Meyering  <jim@meyering.net>
16031
16032         Merge from coreutils.
16033
16034         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
16035         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
16036         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
16037
16038         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
16039         optional configure-time default.
16040
16041         * lib/version-etc.c (version_etc_copyright): Update copyright date.
16042
16043         * lib/xreadlink.c (xreadlink): Correct outdated comment.
16044
16045 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
16046
16047         Merge from coreutils.
16048
16049         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
16050         value, $ac_cv_search_nanosleep, if it's "none required".
16051
16052 2004-01-14  Paul Eggert  <eggert@twinsun.com>
16053
16054         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
16055         with like-named macro in fnmatch.c.
16056         (EXT): Use an internal constant instead.
16057
16058         Merge fnmatch patches from glibc.
16059         * lib/fnmatch.c (mbsinit): Remove define.
16060         Add libc_hidden_ver (__fnmatch, fnmatch).
16061         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
16062         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
16063
16064 2004-01-14  Karl Berry  <karl@gnu.org>
16065
16066         * config/install-sh: update from automake.
16067
16068 2004-01-13  Karl Berry  <karl@gnu.org>
16069
16070         * config/install-sh: update from automake.
16071
16072 2004-01-09  Karl Berry  <karl@gnu.org>
16073
16074         * config/install-sh: update from automake.
16075
16076 2004-01-05  Karl Berry  <karl@gnu.org>
16077
16078         * config/config.{sub,guess}: update from config.
16079
16080 2003-12-31  Karl Berry  <karl@gnu.org>
16081
16082         * config/depcomp: update from automake.
16083
16084 2003-12-14  Karl Berry  <karl@gnu.org>
16085
16086         * lib/config.charset: update from gettext-runtime.
16087
16088 2003-12-03  Paul Eggert  <eggert@twinsun.com>
16089
16090         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
16091         Bug reported by Alfred M. Szmidt.
16092
16093 2003-12-03  Bruno Haible  <bruno@clisp.org>
16094
16095         * m4/gettext.m4: Upgrade from gettext-0.13.
16096         * m4/po.m4: Upgrade from gettext-0.13.
16097         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
16098         * m4/intmax.m4: New file, from gettext-0.13.
16099         * m4/printf-posix.m4: New file, from gettext-0.13.
16100
16101 2003-11-29  Karl Berry  <karl@gnu.org>
16102
16103         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
16104
16105 2003-11-25  Paul Eggert  <eggert@twinsun.com>
16106             Bruno Haible  <bruno@clisp.org>
16107
16108         * lib/printf-parse.h: Don't include sys/types.h.
16109         (ARG_NONE): New macro.
16110         (char_directive): Change type of *arg_index fields to size_t.
16111         * lib/printf-parse.c: Don't include sys/types.h.
16112         (SSIZE_MAX): Remove macro.
16113         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
16114         Remove unnecessary overflow check.
16115         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
16116         fields.
16117
16118 2003-11-25  Bruno Haible  <bruno@clisp.org>
16119
16120         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
16121
16122 2003-11-25  Bruno Haible  <bruno@clisp.org>
16123
16124         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
16125         gt_TYPE_SSIZE_T.
16126
16127 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16128
16129         * modules/alloca: Remove dependency on xalloc.
16130
16131 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16132
16133         * lib/alloca.c: Remove dependency on xalloc module.
16134         (xalloc_die): Remove.
16135         (memory_full) [!defined emacs]: New macro.
16136         [!defined emacs]: Don't include xalloc.h.
16137         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
16138         address arithmetic overflows.  Change datatypes a bit to avoid
16139         unnecessary casts.
16140
16141 2003-11-22  Jim Meyering  <jim@meyering.net>
16142
16143         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
16144         s/size/size_t/.
16145
16146 2003-11-21  Karl Berry  <karl@gnu.org>
16147
16148         * config/config.{sub,guess}: update from config.
16149
16150 2003-11-18  Karl Berry  <karl@gnu.org>
16151
16152         * config/config.{sub,guess}: update from config.
16153
16154         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
16155
16156 2003-11-17  Paul Eggert  <eggert@twinsun.com>
16157
16158         * README: Mention that S+T cannot overflow if S is the size of
16159         an existing object and T is sufficiently small.
16160
16161 2003-11-17  Jim Meyering  <jim@meyering.net>
16162
16163         On systems without utime and without a utimes function capable of
16164         dealing with a NULL struct utimbuf* argument, this utime replacement
16165         could -- in unusual circumstances -- leak a file descriptor.
16166         * lib/utime.c: Include <unistd.h> and <errno.h>.
16167         (utime_null): Be sure to close `fd' and to preserve errno.
16168         Reported by Geoff Collyer via Arnold Robbins.
16169
16170 2003-11-17  Bruno Haible  <bruno@clisp.org>
16171
16172         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
16173         (Depends-on): Add xsize.
16174
16175 2003-11-17  Bruno Haible  <bruno@clisp.org>
16176
16177         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
16178
16179 2003-11-17  Bruno Haible  <bruno@clisp.org>
16180
16181         * lib/vasnprintf.c (alloca): Remove fallback definition.
16182         (freea): Remove definition.
16183         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
16184         Reported by Paul Eggert.
16185
16186 2003-11-16  Paul Eggert  <eggert@twinsun.com>
16187             Bruno Haible  <bruno@clisp.org>
16188
16189         Protect against address arithmetic overflow.
16190         * lib/printf-args.h: Include stddef.h.
16191         (arguments): Change type of field 'count' to size_t.
16192         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
16193         'unsigned int' where appropriate.
16194         * lib/printf-parse.h: Include sys/types.h.
16195         (char_directive): Change type of *arg_index fields to ssize_t.
16196         (char_directives): Change type of fields 'count', max_*_length to
16197         size_t.
16198         * lib/printf-parse.c: Include sys/types.h and xsize.h.
16199         (SSIZE_MAX): Define fallback value.
16200         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
16201         instead of 'int' where appropriate. Check a_allocated, d_allocated
16202         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
16203         * lib/vasnprintf.c: Include xsize.h.
16204         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
16205         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
16206         overflow. Avoid wraparound when converting a width or precision from
16207         decimal to binary.
16208
16209 2003-11-16  Bruno Haible  <bruno@clisp.org>
16210
16211         Update from GNU gettext.
16212         * lib/printf-parse.c: Generalize to it can be compiled for wide
16213         strings.
16214         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
16215         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
16216         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
16217         SNPRINTF): New macros.
16218         Don't include <alloca.h> if the file is used inside libintl.
16219         (local_wcslen): New function, for Solaris 2.5.1.
16220         (VASNPRINTF): Use it instead of wcslen.
16221
16222 2003-11-16  Bruno Haible  <bruno@clisp.org>
16223
16224         * lib/xsize.h (xmax): New function.
16225         (xsum, xsum3, xsum4): Declare as "pure" functions.
16226
16227 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16228
16229         * modules/xalloc (Files): Undo latest change, since xalloc.h
16230         no longer needs SIZE_MAX or PTRDIFF_MAX.
16231
16232 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16233
16234         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
16235         gl_PTRDIFF_MAX.
16236
16237 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16238
16239         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
16240         "return", to pacify some unknown compiler.  Problem reported
16241         by Joerg Schilling.
16242
16243 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16244
16245         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
16246         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
16247         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
16248         heuristic is just as accurate as far as we know, and it removes a
16249         dependency on size_max.m4 and ptrdiff_max.m4.
16250
16251 2003-11-11  Bruno Haible  <bruno@clisp.org>
16252
16253         * modules/xsize (Files): Add m4/size_max.m4.
16254         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
16255
16256 2003-11-11  Bruno Haible  <bruno@clisp.org>
16257
16258         * m4/size_max.m4: New file.
16259         * m4/ptrdiff_max.m4: New file.
16260         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
16261         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
16262         (gl_XALLOC): Invoke it.
16263
16264 2003-11-11  Bruno Haible  <bruno@clisp.org>
16265
16266         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
16267         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
16268         defined.
16269
16270 2003-11-10  Paul Eggert  <eggert@twinsun.com>
16271
16272         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
16273         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
16274         rejected some allocations of exactly SIZE_MAX - 2 bytes.
16275         From Bruno Haible.
16276         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
16277         not (size_t) -1, since it's defined here.
16278
16279 2003-11-09  Karl Berry  <karl@gnu.org>
16280
16281         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
16282
16283 2003-11-06  Paul Eggert  <eggert@twinsun.com>
16284
16285         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
16286         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
16287         Reject sizes of exactly SIZE_MAX bytes.
16288         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
16289         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
16290
16291 2003-11-05  Bruno Haible  <bruno@clisp.org>
16292
16293         * lib/xsize.h: Include limits.h, to avoid a possible collision with
16294         SIZE_MAX defined in <limits.h> on Solaris.
16295
16296 2003-11-04  Jim Meyering  <jim@meyering.net>
16297
16298         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
16299         variable names, rather than @VAR@.
16300         * modules/poll: Likewise.
16301
16302 2003-11-04  Bruno Haible  <bruno@clisp.org>
16303
16304         * modules/xsize: New file.
16305         * modules/linebreak: Depend on xsize.
16306         * MODULES.html.sh (func_all_modules): Add xsize.
16307
16308 2003-11-04  Bruno Haible  <bruno@clisp.org>
16309
16310         * m4/xsize.m4: New file.
16311
16312 2003-11-04  Bruno Haible  <bruno@clisp.org>
16313
16314         * lib/xsize.h: New file.
16315         * lib/linebreak.c: Include xsize.h.
16316         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
16317         argument for overflow.
16318         Suggested by Paul Eggert.
16319
16320 2003-11-03  Karl Berry  <karl@gnu.org>
16321
16322         * config/config.{guess,sub}: update from config.
16323
16324 2003-11-03  Jim Meyering  <jim@meyering.net>
16325
16326         * modules/userspec (lib_SOURCES): Add userspec.h.
16327         (Include): Add "userspec.h".
16328         Improve description.
16329
16330 2003-11-03  Jim Meyering  <jim@meyering.net>
16331
16332         * lib/userspec.c: Include "userspec.h".
16333         * lib/userspec.h: New file.
16334
16335 2003-11-03  Bruno Haible  <bruno@clisp.org>
16336
16337         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
16338
16339 2003-11-03  Bruno Haible  <bruno@clisp.org>
16340
16341         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
16342         available, to avoid (extremely rare) race condition.
16343         Suggested by Paul Eggert.
16344
16345 2003-11-02  Karl Berry  <karl@gnu.org>
16346
16347         * config/srclist.txt (vasprintf.c): sync broken, sigh.
16348
16349 2003-10-31  Paul Eggert  <eggert@twinsun.com>
16350
16351         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
16352         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
16353         (read_filesystem_list): Set and use me_type_malloced.
16354         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
16355         whatever the type happens to be), for brevity and consistency.
16356         Check for size calculation overflow on Alphas running OSF/1.
16357
16358 2003-10-31  Jim Meyering  <jim@meyering.net>
16359
16360         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
16361
16362         * lib/linebuffer.c: Include <string.h> for declaration of memset.
16363
16364 2003-10-30  Paul Eggert  <eggert@twinsun.com>
16365             Bruno Haible  <bruno@clisp.org>
16366
16367         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
16368         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
16369
16370 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16371
16372         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
16373         netbsd*-gnu*.  Suggested by Robert Millan.
16374
16375 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16376
16377         * modules/group-member: Depend on stdbool.
16378
16379 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16380
16381         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
16382
16383 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16384
16385         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
16386         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
16387         after the 'gnu' in these cases.  This fixes some bugs in the
16388         previous change, and is based on suggestions by Robert Millan.
16389
16390 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16391
16392         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
16393         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
16394         no longer needed.
16395         * lib/quotearg.c (quotearg_n_options): Use it.
16396         * lib/group-member.c: Include <stdbool.h>.
16397         (free_group_info): Arg is now const *; don't free arg.
16398         (get_group_info): Now returns bool and accepts struct group_info *,
16399         rather than returning a malloc'ed struct group_info *.
16400         All uses changed.  Check for overflow in internal size calculation.
16401
16402         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
16403         rather than xmalloc/xrealloc.
16404         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
16405         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
16406         conformance bug: the old code used a pointer after freeing the
16407         storage that it addressed.
16408         * lib/hash.c (hash_initialize): Simplify the code by using
16409         xalloc_oversized rather than doing it by hand.
16410         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
16411         the buffer preserved.  Use free and xmalloc instead.
16412         * lib/quotearg.c (quotearg_n_options): Likewise.
16413         Use a simpler test for size overflow.  Don't use xalloc_oversized
16414         because unsigned int might be wider than size_t (!); this suggests
16415         that we should switch from unsigned int to size_t for slot numbers.
16416
16417 2003-10-28  Paul Eggert  <eggert@twinsun.com>
16418
16419         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
16420         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
16421         NetBSD kernels.  Requested by Richard Stallman.
16422
16423 2003-10-27  Paul Eggert  <eggert@twinsun.com>
16424
16425         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
16426         to allocate the returned structure.  Do not allocate a subarray,
16427         as x2nrealloc will do that.
16428         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
16429         instead of xnrealloc.
16430         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
16431
16432 2003-10-27  Bruno Haible  <bruno@clisp.org>
16433
16434         * lib/stdbool_.h: Better support for BeOS.
16435
16436 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16437
16438         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
16439         now uses inline.
16440
16441 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16442
16443         * lib/xalloc.h (xalloc_oversized): New static inline function, for
16444         callers that want to do their own size-overflow checking.  Include
16445         <stdbool.h>, since xalloc_oversized returns bool.
16446         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
16447         to use xalloc_oversized.
16448
16449         Add two functions x2realloc, x2nrealloc, for programs that grow
16450         arrays dynamically by doubling their sizes.
16451         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
16452         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
16453         New functions.
16454
16455         Port to C99 semantics for 'inline' of external functions.
16456         Bug reported by Bruno Haible.
16457         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
16458         with the old contents of xnmalloc.
16459         (xnmalloc, xmalloc): Use it.
16460         (xnrealloc_inline): New static inline function,
16461         with the old contents of xnrealloc.
16462         (xnrealloc, xrealloc): Use it.
16463
16464         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
16465         that.
16466
16467 2003-10-26  Karl Berry  <karl@gnu.org>
16468
16469         * config/srclist.txt (COPYING.DOC): no longer available from
16470         /gd/gnuorg; don't know where the ultimate source is.
16471
16472 2003-10-25  Paul Eggert  <eggert@twinsun.com>
16473
16474         Fix several address-calculation bugs in the hash modules,
16475         plus some minor code cleanup.
16476
16477         * lib/hash.h: Include <stdbool.h>, for bool.
16478         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
16479         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
16480         hash_get_n_entries, hash_get_max_bucket_length,
16481         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
16482         hash_rehash): Use size_t rather than unsigned.
16483         * lib/hash.c (struct hash_table, hash_get_n_buckets,
16484         hash_get_n_buckets_used, hash_get_n_entries,
16485         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
16486         hash_get_entries, hash_do_for_each, hash_string, is_prime,
16487         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
16488         Likewise.
16489         (SIZE_MAX): Define if not defined.
16490         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
16491         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
16492         hash_print):
16493         Use const * when possible.
16494         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
16495         (check_tuning): Fix bug: if tuning parameters were very close to
16496         0 or 1, rounding errors could have caused subscript violations.
16497         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
16498         (hash_initialize): Add 'fail:' label
16499         to free table and return NULL, and use it to simplify code.
16500         Use calloc rather than clearing the storage ourself.
16501         (hash_initialize, hash_rehash): Check for arithmetic overflow in
16502         buffer size calculations.
16503         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
16504         Include <stddef.h>, for size_t.
16505         * lib/hash-pjw.c (hash_pjw): Likewise.
16506         Switch to method described by Bruno Haible.
16507         Include <limits.h>, for CHAR_BIT.
16508         (SIZE_BITS): New macro.
16509
16510 2003-10-23  Paul Eggert  <eggert@twinsun.com>
16511
16512         * m4/getline.m4 (AM_FUNC_GETLINE):
16513         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
16514         hosts.  Problem reported by Derek Robert Price in
16515         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
16516         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
16517         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
16518
16519 2003-10-21  Paul Eggert  <eggert@twinsun.com>
16520
16521         * lib/getndelim2.c (getndelim2): When size calculation overflows,
16522         ceiling the allocation at NMAX bytes rather than silently
16523         discarding input bytes before NMAX is reached.  This makes
16524         a difference only if NMAX exceeds SIZE_MAX / 2.
16525
16526         * lib/obstack.c: Merge from glibc.
16527         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
16528         Add libc_hidden_def (_obstack_newchunk).
16529         (_obstack_free) [! defined _LIBC]: Remove.
16530         [defined _LIBC]: Make a strong alias from obstack_free, rather than
16531         a clone of the function body.
16532         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
16533         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
16534
16535         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
16536         glibc.
16537         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
16538         arg to memcpy.
16539
16540         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
16541         (obstack_ptr_grow_fast, obstack_int_grow_fast):
16542         Don't use lvalue casts, as GCC plans to remove support for them
16543         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
16544         was also present in the non-GCC version, indicating that this
16545         code had always been buggy and had never been widely used.
16546         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
16547         Use the fast variant of each macro, rather than copying the
16548         definiens of the fast variant; that way, we'll be more likely to
16549         catch future bugs in the fast variants.
16550
16551 2003-10-20  Bruno Haible  <bruno@clisp.org>
16552
16553         * modules/wait-process: New file.
16554         * MODULES.html.sh (func_all_modules): Add wait-process.
16555
16556 2003-10-20  Bruno Haible  <bruno@clisp.org>
16557
16558         * m4/wait-process.m4: New file.
16559
16560 2003-10-20  Bruno Haible  <bruno@clisp.org>
16561
16562         * lib/wait-process.h: New file, from GNU gettext.
16563         * lib/wait-process.c: New file, from GNU gettext.
16564
16565 2003-10-19  Jim Meyering  <jim@meyering.net>
16566
16567         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
16568         HPUX 10.20.
16569
16570 2003-10-18  Karl Berry  <karl@gnu.org>
16571
16572         * config/config.guess: update from config.
16573
16574 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16575
16576         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
16577         (getgroups): First arg is int, not size_t.
16578         Don't let 'free' mangle errno.
16579
16580 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16581
16582         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
16583
16584 2003-10-16  Karl Berry  <karl@gnu.org>
16585
16586         * config/config.{guess,sub}: update from config.
16587
16588 2003-10-16  Jim Meyering  <jim@meyering.net>
16589
16590         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
16591         memcpy.
16592
16593 2003-10-15  Paul Eggert  <eggert@twinsun.com>
16594
16595         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
16596         (SIZE_MAX): Remove.
16597         (new_exclude, add_exclude_file): Initial size no longer needs to
16598         be a power of 2.
16599         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
16600         our own address arithmetic overflow checking.
16601
16602         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
16603         (fnmatch): Do not alloca more than 2000 wide characters;
16604         instead, use malloc for large buffers.
16605         Check for address arithmetic overflow, and return -1
16606         with errno set to ENOMEM in that case.
16607         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
16608         (NEW_PATTERN): Do not alloca more than 8000 bytes;
16609         instead, return -1.  Check for address arithmetic overflow.
16610
16611 2003-10-14  Paul Eggert  <eggert@twinsun.com>
16612
16613         Handle invalid suffixes and overflow independently, so that
16614         callers can treat them independently as needed.  Fix some bugs in
16615         suffix handling, e.g., "100k@" was not diagnosed as an invalid
16616         suffix for a human-readable blocksize.  The major caller-visible
16617         change is the addition of a new
16618         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
16619         that both overflow and suffix chars were found.
16620
16621         * lib/human.c (humblock): Don't check separately for invalid suffix
16622         char; that is xstrtoumax's job (now that its bug is fixed).
16623         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
16624         INTMAX_MAX]: New macros.
16625         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
16626         TYPE_MAXIMUM): New macros.
16627         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
16628         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
16629         if overflow occurs, as it's what __strtol does and it's more useful
16630         in practice.
16631         (__xstrtol): If __strtol reports some error other than ERANGE,
16632         reflect it to the caller as LONGINT_INVALID.  If it reports
16633         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
16634         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
16635         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
16636         value.
16637         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
16638         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
16639         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
16640         [defined UINTMAX_MAX]: New macros.
16641
16642 2003-10-14  Bruno Haible  <bruno@clisp.org>
16643
16644         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
16645
16646 2003-10-14  Bruno Haible  <bruno@clisp.org>
16647
16648         * m4/sig_atomic_t: New file, from GNU gettext.
16649         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
16650
16651 2003-10-14  Bruno Haible  <bruno@clisp.org>
16652
16653         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
16654         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
16655         Also use volatile where needed.
16656
16657 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16658
16659         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
16660         Change maintainer from Bruno Haible to 'all'.
16661
16662 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16663
16664         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
16665
16666 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16667
16668         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
16669         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
16670         and define in terms of the other primitives.
16671         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
16672         (SIZE_MAX): Define if not already defined.
16673         (array_size_overflow): New function.
16674         (xalloc_die): Abort instead of exiting if 'error' returns.
16675         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
16676         (xmalloc, xrealloc): Use them.
16677         (xcalloc): Check for address arithmetic overflow.
16678         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
16679         a bit faster than strcpy.
16680
16681 2003-10-10  Simon Josefsson  <jas@extundo.com>
16682
16683         * modules/argp (Depends-on): Add restrict and strcase.
16684
16685 2003-10-10  Simon Josefsson  <jas@extundo.com>
16686
16687         * m4/argp.m4: Add AC_C_INLINE.
16688
16689 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16690
16691         Merge getpass from libc, plus a few fixes.
16692
16693         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
16694         Include <stdbool.h>.
16695         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
16696         __fsetlocking to empty.
16697         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
16698         do include <bits/libc-lock.h>.
16699         Do not include <fcntl.h>; not needed.
16700         [_LIBC]: Include <wchar.h>.
16701         (NOTCANCEL_MODE): New macro.
16702         (flockfile, funlockfile) [_LIBC]: New macros.
16703         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
16704         [!_LIBC]: New macros.
16705         (call_fclose): New function.
16706         (getpass): Use it.  Save tty stream separately; this simplifies the
16707         code and makes it more reliable if stdin happens to equal stdout.
16708         Invoke __fsetlocking on tty.
16709         Handle thread cancellation if needed.
16710         Namespace cleanup (use __tcgetattr, __getline).
16711         Use bool for Booleans.
16712         [USE_IN_LIBIO]: Handle wide streams.
16713         [!_LIBC]: Unconditionally do the fseek, since we don't know what
16714         stream might go where.
16715
16716         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
16717         doesn't have to include <stdio.h> before us.
16718         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
16719         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
16720         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
16721         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
16722         if not declared, so that we can use getpass.c code from libc without
16723         rewriting it.
16724         (flockfile, ftrylockfile, funlockfile): New macros.
16725
16726 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16727
16728         * modules/getpass: Depend on stdbool.
16729
16730 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16731
16732         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
16733
16734 2003-10-07  Karl Berry  <karl@gnu.org>
16735
16736         * config/config.{guess,sub}: update from config.
16737
16738 2003-10-06  Jim Meyering  <jim@meyering.net>
16739             Bruno Haible  <bruno@clisp.org>
16740
16741         This lets translators provide better translations for the
16742         "Written by ..." part of --version output.
16743         * lib/version-etc.h: Include stdarg.h.
16744         (version_etc_copyright): Declare as readonly.
16745         (version_etc): Make this function variadic with a NULL-terminated list
16746         of author name strings.
16747         (version_etc_va): New declaration.
16748         * lib/version-etc.c: Include stdarg.h, stdlib.h.
16749         (version_etc_copyright): Declare as readonly.
16750         (version_etc_va): New function. Provide a different translatable string
16751         for each possible number of authors < 10. Abbreviate when there are 10
16752         authors or more.
16753         (version_etc): Make this function variadic. Call version_etc_va.
16754         Suggestion from Gary V. Vaughan.
16755
16756         * lib/long-options.h (parse_long_options): Change prototype: the
16757         authors string is moved to the end and becomes variadic.
16758         * lib/long-options.c: Include stdarg.h.
16759         (parse_long_options): Make this function variadic, too.
16760         Call version_etc_va, not version_etc.
16761
16762 2003-10-06  Bruno Haible  <bruno@clisp.org>
16763
16764         * modules/version-etc-2: Remove file.
16765         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
16766
16767 2003-10-06  Bruno Haible  <bruno@clisp.org>
16768
16769         * modules/fatal-signal: New file.
16770         * MODULES.html.sh (func_all_modules): Add fatal-signal.
16771
16772 2003-10-06  Bruno Haible  <bruno@clisp.org>
16773
16774         * m4/fatal-signal.m4: New file.
16775         * m4/signalblocking.m4: New file, from GNU gettext.
16776
16777 2003-10-06  Bruno Haible  <bruno@clisp.org>
16778
16779         * lib/version-etc-2.h: Remove file.
16780         * lib/version-etc-2.c: Remove file.
16781
16782 2003-10-06  Bruno Haible  <bruno@clisp.org>
16783
16784         * lib/fatal-signal.h: New file, from GNU gettext.
16785         * lib/fatal-signal.c: New file, from GNU gettext.
16786
16787 2003-10-05  Paul Eggert  <eggert@twinsun.com>
16788
16789         * README: Rework advice for preventing empty .o files.
16790         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
16791         not <sys/types.h>.
16792
16793 2003-10-04  Karl Berry  <karl@gnu.org>
16794
16795         * lib/argp*: update from libc.
16796
16797 2003-10-04  Karl Berry  <karl@gnu.org>
16798
16799         * config/config.{guess,sub}: update from config.
16800
16801 2003-10-02  Bruno Haible  <bruno@clisp.org>
16802
16803         * modules/lchown (Include): Add lchown.h.
16804         * modules/time_r (Include): Use "..." syntax.
16805         * modules/xgetdomainname (Include): Add xgetdomainname.h.
16806
16807 2003-10-01  Simon Josefsson  <jas@extundo.com>
16808
16809         * MODULES.html.sh (func_all_modules): Move gethostname from section
16810         'based on' to section 'lacking' POSIX:2001.
16811
16812 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
16813
16814         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
16815         to output mode on the same stream.
16816
16817 2003-09-29  Paul Eggert  <eggert@twinsun.com>
16818
16819         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
16820         Fix arg typo in previous patch.
16821
16822 2003-09-28  Jim Meyering  <jim@meyering.net>
16823
16824         * lib/error.c: Correct cpp indentation.
16825
16826 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16827
16828         * modules/free: New file.
16829
16830 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16831
16832         * m4/free.m4: New file.
16833
16834 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16835
16836         * lib/minmax.h (MIN, MAX)
16837         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
16838         Omit the special code that used __typeof__, since we worry that
16839         it could be more trouble than it's worth.  See:
16840         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
16841         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
16842
16843         * lib/free.c: New file.
16844
16845 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
16846
16847         Trivial fixes to Makefile.am parts of module listings.
16848         * modules/strstr: Append strstr.h to lib_SOURCES.
16849         * modules/strcase: Likewise, for strcase.h.
16850
16851 2003-09-27  Karl Berry  <karl@gnu.org>
16852
16853         * config/mkinstalldirs: update from automake.
16854
16855 2003-09-26  Paul Eggert  <eggert@twinsun.com>
16856
16857         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
16858         (error_tail): Do not loop, reallocating temporary buffer, since
16859         the output cannot contain more wide characters than the input
16860         contains bytes, the size must be big enough already.  This avoids
16861         one potential size overflow calculation.  Check for size overflow
16862         when calculating temporary buffer size.  Free temporary buffer
16863         when done, if it was allocated with malloc; this plugs a memory
16864         leak.  Remove casts from void * to pointers, that are no longer
16865         needed now that we're assuming C89 or better.
16866
16867         Merge error changes from glibc.
16868
16869         * lib/error.c, error.h: Update copyright notice header to match glibc.
16870         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
16871         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
16872         Disable cancellation while printing error.
16873         * lib/error.h: Prepend __ to parameter names.
16874
16875 2003-09-26  Jim Meyering  <jim@meyering.net>
16876
16877         * lib/error.c (error_tail): Move some declarations
16878         into inner scope where the local variables are used.
16879
16880 2003-09-26  Bruno Haible  <bruno@clisp.org>
16881
16882         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
16883         stpncpy().
16884         Don't define stpncpy through config.h; it's now done through stpncpy.h.
16885
16886 2003-09-26  Bruno Haible  <bruno@clisp.org>
16887
16888         * lib/stpncpy.h (gnu_stpncpy): New declaration.
16889         (stpncpy): Define as alias for gnu_stpncpy.
16890         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
16891
16892 2003-09-25  Simon Josefsson  <jas@extundo.com>
16893
16894         * lib/xgetdomainname.h: New file.
16895         * lib/xgetdomainname.c: New file.
16896
16897 2003-09-25  Simon Josefsson  <jas@extundo.com>
16898             Bruno Haible  <bruno@clisp.org>
16899
16900         * modules/getdomainname: New file.
16901         * modules/xgetdomainname: New file.
16902         * MODULES.html.sh (func_all_modules): Add getdomainname,
16903         xgetdomainname.
16904
16905 2003-09-25  Simon Josefsson  <jas@extundo.com>
16906             Bruno Haible  <bruno@clisp.org>
16907
16908         * m4/getdomainname.m4: New file.
16909
16910 2003-09-25  Simon Josefsson  <jas@extundo.com>
16911             Bruno Haible  <bruno@clisp.org>
16912
16913         * lib/getdomainname.h: New file.
16914         * lib/getdomainname.c: New file.
16915
16916 2003-09-25  Karl Berry  <karl@gnu.org>
16917
16918         * lib/argp-fmtstream.c, argp-help.c: update from libc.
16919
16920 2003-09-25  Karl Berry  <karl@gnu.org>
16921
16922         * config/install-sh: update from automake.
16923
16924 2003-09-25  Bruno Haible  <bruno@clisp.org>
16925
16926         * modules/version-etc-2: New file, from modules/version-etc with
16927         modifications.
16928         * MODULES.html.sh (func_all_modules): Add version-etc-2.
16929
16930 2003-09-25  Bruno Haible  <bruno@clisp.org>
16931
16932         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
16933         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
16934
16935 2003-09-24  Simon Josefsson  <jas@extundo.com>
16936
16937         * modules/xgethostname: Add xgethostname.h.
16938
16939 2003-09-24  Paul Eggert  <eggert@twinsun.com>
16940
16941         * lib/linebuffer.c (freebuffer): Don't free the argument, just
16942         the buffer associated with the argument.  Bug reported by
16943         Simon Josefsson.
16944
16945 2003-09-24  Paul Eggert  <eggert@twinsun.com>
16946
16947         * README: Document assumptions that 'int' is at least 32 bits
16948         wide, that integer arithmetic is 2's complement without overflow,
16949         that there are no holes in integer values, that adding sizes of
16950         two nonoverlapping objects can't overflow, and that all-bits-zero
16951         yields scalar zero.  Fix spelling and capitalization typos.
16952
16953 2003-09-19  Karl Berry  <karl@gnu.org>
16954
16955         * lib/argp.h: update from libc.
16956
16957 2003-09-17  Paul Eggert  <eggert@twinsun.com>
16958
16959         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
16960         to avoid spurious warnings like "AC_RUN_IFELSE was called before
16961         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
16962
16963 2003-09-17  Paul Eggert  <eggert@twinsun.com>
16964
16965         * gnulib-tool: Use "test -h", not "test -L", for portability
16966         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
16967         (tags_regexp): Remove, since \| doesn't conform to POSIX.
16968         (sed_extract_prog): Issue s commands one-by-one, rather than
16969         using \| in one s command.
16970
16971 2003-09-16  Paul Eggert  <eggert@twinsun.com>
16972
16973         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
16974         input error, instead of returning NULL the next time we are called
16975         (and therefore losing track of errno).
16976
16977 2003-09-16  Bruno Haible  <bruno@clisp.org>
16978
16979         * gnulib-tool (func_create_testdir): Warn about duplicated
16980         dependencies.
16981
16982 2003-09-15  Paul Eggert  <eggert@twinsun.com>
16983
16984         * modules/argmatch, modules/fatal, modules/obstack,
16985         modules/xalloc, modules/xgethostname: Sort dependencies by
16986         importance, not alphabetically.
16987
16988 2003-09-15  Paul Eggert  <eggert@twinsun.com>
16989
16990         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
16991         fails, so that the caller gets the proper errno.
16992
16993         * lib/readutmp.c (read_utmp): Likewise.
16994         Check for fstat error.  Close stream and free storage
16995         when failing.
16996
16997 2003-09-14  Karl Berry  <karl@gnu.org>
16998
16999         * config/srclist.txt (strdup.c): disable for c89 changes.
17000
17001 2003-09-14  Jim Meyering  <jim@meyering.net>
17002
17003         * lib/getloadavg.c: Correct cpp indentation.
17004         * lib/strdup.c: Likewise.
17005         * lib/vasnprintf.c: Likewise.
17006
17007 2003-09-14  Bruno Haible  <bruno@clisp.org>
17008
17009         * modules/fwriteerror: New file.
17010         * MODULES.html.sh (func_all_modules): Add fwriteerror.
17011
17012 2003-09-14  Bruno Haible  <bruno@clisp.org>
17013
17014         * lib/fwriteerror.h: New file.
17015         * lib/fwriteerror.c: New file.
17016
17017 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17018
17019         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
17020         modules/xgethostname, modules/xalloc: Depend on exit.
17021
17022 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17023
17024         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
17025
17026         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
17027         and AC_MINIX, too, so that their extensions are available.
17028
17029         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
17030         This macro has been superseded by gl_BACKUPFILE.
17031
17032         More patches to assume C89 or better.
17033
17034         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
17035
17036         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
17037         unconditionally.
17038         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
17039         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
17040         Include <string.h>, <stdlib.h> unconditionally.
17041         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
17042         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
17043         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
17044         headers or for string.h.
17045         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
17046         or strtoul.
17047
17048         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
17049         headers.
17050         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
17051         * m4/userspec.m4 (gl_USERSPEC): Likewise.
17052         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
17053         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
17054         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
17055         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
17056         memcpy, memset.
17057         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
17058         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
17059         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
17060         strtol.
17061         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
17062         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
17063         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
17064         strtoul.
17065
17066 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17067
17068         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
17069         * lib/obstack.c [!defined _LIBC]: Likewise.
17070         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
17071         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
17072         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
17073
17074         More changes to assume C89 or better.
17075
17076         * lib/error.c (error_tail): Assume vprintf.
17077
17078         * lib/argmatch.c (getenv): Remove decl.
17079         * lib/progreloc.c (get_full_program_name): Define via prototype.
17080         * lib/setenv.c (clearenv): Likewise.
17081         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
17082         needed.
17083         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
17084         (malloc, memcpy): Remove decls.
17085         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
17086         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
17087         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17088         (memcpy): Remove macro.
17089         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
17090         (__P): Remove.  All uses removed.
17091         (PTR): Remove.  All uses changed to void *.
17092         (CHAR_BIT, NULL): Remove.
17093         (spaces, zeros, memset_space, memset_zero)
17094         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
17095         Remove.
17096         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
17097         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
17098         Define with prototype.
17099         Remove now-unnecessary prototype decl.
17100         (extra_args_spec): Assume ANSI C.  All uses changed.
17101         (extra_args_spec_iso): Remove.
17102         (my_strftime, emacs_strftimeu): Define via prototype.
17103         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
17104         unconditionally.
17105         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
17106         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
17107         (strtoul, strtol): Remove decls.
17108         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
17109         LONG_MAX): Remove.
17110         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17111         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
17112         (LOCALE_PARAM_PROTO): New macro.
17113         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
17114         (INTERNAL (strtol), strtol): Define with a prototype.
17115         (PARAMS): Remove.  All uses removed.
17116         * lib/tempname.c: Include <string.h> unconditionally.
17117         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
17118         * lib/xgethostname.c (main): Define with a prototype.
17119         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
17120         Include <stdlib.h> unconditionally.
17121         (calloc, malloc, realloc, free): Remove decls.
17122         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
17123         Include <stdlib.h> unconditionally.  Sort include file names.
17124         (strtod): Remove.
17125         (xstrtod): Define with a prototype.
17126         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
17127         (strtol, strtoul): Remove decls.
17128
17129 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17130
17131         More patches to assume C89 or better.
17132         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
17133         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
17134         string.h, memchr, STDC_HEADERS.
17135
17136 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17137
17138         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
17139         Include <stdlib.h>, <string.h> unconditionally.
17140         Remove now-unnecessary cast to char *.
17141         * lib/strnlen.c: Include <string.h> unconditionally.
17142         * lib/yesno.c (yesno): Define with a prototype.
17143
17144 2003-09-11  Bruno Haible  <bruno@clisp.org>
17145
17146         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
17147
17148 2003-09-10  Jim Meyering  <jim@meyering.net>
17149
17150         * lib/error.c: Correct indentation of cpp directives.
17151
17152 2003-09-10  Bruno Haible  <bruno@clisp.org>
17153
17154         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
17155         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
17156         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
17157         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
17158         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
17159         <stdlib.h> and <string.h> checks.
17160         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
17161         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
17162
17163 2003-09-10  Bruno Haible  <bruno@clisp.org>
17164
17165         * lib/strcspn.c: Include <string.h> unconditionally.
17166         * lib/strpbrk.c: Include <string.h> unconditionally.
17167         * lib/strstr.c: Include <string.h> unconditionally.
17168         * lib/unicodeio.c: Include <string.h> unconditionally.
17169         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
17170         * lib/unsetenv.c: Likewise.
17171         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
17172         * lib/yesno.c: Include <stdlib.h> unconditionally.
17173         (rpmatch): Add prototype.
17174
17175 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17176
17177         More patches to assume C89 or better.
17178         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
17179         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
17180         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
17181         or for string.h.
17182         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
17183         stdlib.h.
17184         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
17185         C headers.
17186         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
17187         string.h.
17188         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
17189         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
17190         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
17191         or for string.h.
17192         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
17193         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
17194         C headers.
17195         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
17196         memcpy.
17197         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
17198         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
17199         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
17200         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
17201         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
17202         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
17203         string.h, free.
17204         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
17205         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
17206         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
17207         C headers, or for string.h.
17208         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
17209         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
17210         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
17211         headers, memory.h, stdlib.h, string.h, strings.h.
17212         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
17213         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
17214         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
17215         strchr.
17216         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
17217         headers, memory.h, string.h.
17218         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
17219         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
17220         free.
17221         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
17222         headers.
17223         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
17224         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
17225         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
17226         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
17227         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
17228
17229 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17230
17231         More K&R removal.
17232
17233         * lib/acosl.c (main): Use a prototype.
17234         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
17235         tanl.c: Likewise.
17236
17237         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
17238
17239         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
17240         (getopt, etopt_long, getopt_long_only, _getopt_internal)
17241         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
17242         with a prototype.
17243         * lib/getopt.c (const): Remove macro.
17244         Include <string.h> unconditionally.
17245         (my_index): Remove; all uses changed to strchr.
17246         (strlen): Remove decl.
17247         (exchange): Remove forward decl; no longer needed.
17248         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
17249         Define with prototype.
17250         * lib/getopt1.c (const): Remove macro.
17251         (getopt_long, getopt_long_only, main): Define with prototype.
17252
17253         * lib/getugroups.c: Include <string.h> unconditionally.
17254
17255         * lib/getusershell.c: Include <stdlib.h> unconditionally.
17256         (getusershell, setusershell, endusershell, readname, main):
17257         Define with prototypes.
17258
17259         * lib/group-member.c: Include group-member.h first.
17260         Include <stdlib.h> unconditionally.
17261
17262         * lib/hard-locale.c: Include hard-locale.h first.
17263         Include <stdlib.h>, <string.h> unconditionally.
17264
17265         * lib/hash.c (free, malloc): Remove decls.
17266         Include <stdlib.h> unconditionally.
17267
17268         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
17269         (getenv): Do not declare.
17270
17271         * lib/idcache.c: Include <string.h> unconditionally.
17272
17273         * lib/long-options.c: Include long-options.h first, to test interface.
17274         Include <stdlib.h> unconditionally.
17275
17276         * lib/makepath.c: Include makepath.h first, to test interface.
17277         Include <stdlib.h> and <string.h> unconditionally.
17278
17279         * lib/linebuffer.c: Include <stdlib.h>.
17280         (free): Remove decl.
17281
17282         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
17283         stddef.h. rpl_malloc returns void *, not char *.
17284         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
17285         prototype.
17286
17287         * lib/md5.h: Include <limits.h> unconditionally.
17288         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
17289         (__P): Remove; all uses removed.
17290         * lib/md5.c: Include "md5.h" first.
17291         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
17292         md5_buffer, md5_process_bytes, md5_process_block):
17293         Define with prototypes.
17294         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
17295         * lib/sha.c: Include "sha.h" first.
17296         Include <stdlib.h>, <string.h> unconditionally.
17297
17298         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
17299         * lib/memcmp.c (__ptr_t): Likewise.
17300         * lib/memrchr.c (__ptr_t): Likewise.
17301         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
17302         Include <string.h> unconditionally.
17303         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
17304         * lib/memchr.c: Include <stdlib.h> unconditionally.
17305         * lib/memchr.c (LONG_MAX): Remove.
17306         * lib/memrchr.c (LONG_MAX): Likewise.
17307         * lib/memchr.c (__memchr): Define via a prototype.
17308         * lib/memrchr.c (__memrchr): Likewise.
17309         * lib/memcmp.c (__P): Remove, and remove all uses.
17310         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
17311         Remove forward decls; no longer needed.
17312         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
17313         Use types required by C89 in prototype.
17314
17315         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
17316         * lib/savedir.c: Likewise.
17317         * lib/mkdir.c (free): Remove decl.
17318         * lib/rmdir.c (rmdir): Define with a prototype.
17319         * lib/savedir.c: Include savedir.h first, to test interface.
17320
17321         * lib/mktime.c (STDC_HEADERS): Remove.
17322         Include <stdlib.h>, <string.h> unconditionally.
17323
17324         * lib/modechange.c: Include <stdlib.h> unconditionally.
17325         (malloc): Remove decl.
17326
17327         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
17328         (free): Remove decl.
17329
17330         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
17331         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
17332         (This type really should be intptr_t, but that's a C99ism.)
17333         (_obstack_memcpy): Remove: all uses changed to memcpy.
17334         Include <string.h> unconditionally.
17335         (struct obstack): Assume __STDC__ for types of members
17336         chunkfun, freefun, extra_arg.
17337         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
17338         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
17339         obstack_begin, obstack_specify_allocation,
17340         obstack_specify_allocation_with_arg, obstack_chunkfun,
17341         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
17342         Remove unprototyped decls and the macros that use them.
17343         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
17344         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
17345         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
17346         (defined __STDC__ && __STDC__)]:
17347         Remove nonprototyped code.
17348         Include <stdlib.h> unconditionally.
17349         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
17350         _obstack_allocated_p, _obstack_free, obstack_free,
17351         _obstack_memory_used, print_and_abort):
17352         Define using prototypes.
17353         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
17354         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
17355         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
17356         obstack_next_free, obstack_object_size, obstack_room) [0]:
17357         Remove unused, unprototyped code.
17358
17359         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
17360
17361         * lib/physmem.c (physmem_total, physmem_available, main): Define
17362         with prototypes.
17363
17364         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
17365         (main): Define with a prototype.
17366
17367         * lib/posixver.c (getenv): Remove decl.
17368
17369         * lib/putenv.c (malloc): Returns void *, not char *.
17370         Include <string.h> unconditionally.
17371         (strchr, memcpy, NULL): Do not define.
17372
17373         * lib/readtokens.c: Include readtokens.h first, to test interface.
17374         Include <stdlib.h>, <string.h> unconditionally.
17375         (init_tokenbuffer): Define with a prototype.
17376
17377         * lib/regex.c (PARAMS): Remove.  All uses removed.
17378         All uses of _RE_ARGS removed, too.
17379         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17380         unconditionally.
17381         (bzero): Assume memset exists.
17382         (memcmp, memcpy, NULL): Remove.
17383         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
17384         char, or assignments to local vars of type signed char.
17385         (init_syntax_once, PREFIX(extract_number_and_incr),
17386         PREFIX(print_partial_compiled_pattern),
17387         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
17388         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
17389         PREFIX(regex_grow_registers), PREFIX(regex_compile),
17390         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
17391         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
17392         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
17393         wcs_compile_range, byte_compile_range, truncate_wchar,
17394         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
17395         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
17396         count_mbs_length, wcs_re_match_2_internal,
17397         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
17398         PREFIX(alt_match_null_string_p),
17399         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
17400         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
17401         regfree, PREFIX(extract_number)): Define with prototype.  Remove
17402         now-unnecessary declaration, if any.
17403         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
17404         regcomp, regexec):
17405         Remove now-unnecessary casts among pointer types.
17406         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
17407
17408         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
17409         (free): Remove decl.
17410
17411         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
17412
17413         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
17414         (free): Remove decl.
17415
17416         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
17417         * lib/xgetcwd.c: Likewise.
17418
17419         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
17420         (free): Remove decl.
17421
17422         * lib/strchrnul.c (strchrnul): Define with a prototype.
17423         Fix bug: c_in was not converted to char before searching.
17424
17425         The following changes are not K&R related:
17426
17427         * lib/group-member.h: Include <sys/types.h>, so that this file is
17428         self-contained.
17429         * lib/makepath.h: Likewise.
17430
17431         * lib/getusershell.c (readname, default_index, line_size, readname):
17432         Use size_t, not int, for sizes.
17433         (readname): If the size overflows, report an error instead of
17434         looping forever.
17435
17436 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17437
17438         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
17439         libc.
17440
17441 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17442
17443         * README: New section: portability guidelines.
17444
17445 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17446
17447         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
17448         C89 spec.
17449
17450 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17451
17452         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
17453
17454 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17455
17456         Assume C89 or better; remove K&R cruft.
17457         A few of these changes were first proposed by Derek Robert Price
17458         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
17459
17460         * lib/addext.c: Include <string.h> unconditionally.
17461         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
17462         Don't declare getenv or malloc.
17463
17464         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
17465         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
17466         (NULL): Remove.
17467         (find_stack_direction, alloca): Use prototypes.
17468
17469         * lib/atexit.c (atexit): Define using a prototype.
17470
17471         * lib/basename.c, dirname.c, stripslash.c:
17472         Include <string.h> unconditionally.
17473
17474         * lib/bcopy.c: Include <stddef.h>.
17475         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
17476
17477         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
17478
17479         * lib/error.h (error, error_at_line, error_print_progname)
17480         [! (defined (__STDC__) && __STDC__)]: Remove decls.
17481         * lib/error.c: Include error.h first, to check interface.
17482         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17483         (VA_START): Remove; all uses changeed to va_start.
17484         (exit, strerror): Remove decls.
17485         (error_print_progname): Prototype uncondionally.
17486         Don't include <errno.h>; no longer needed.
17487         (private_strerror): Remove.
17488         (error_tail): Always define.
17489         (error, error_at_line): Assume C89 or better; always use prototypes.
17490         * lib/fatal.c: Include "fatal.h" first, to test interface.
17491         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17492         (VA_START): Remove; all uses changed to va_start.
17493         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
17494         this case.
17495         (exit): Remove decl.
17496         (fatal): Prototype unconditionally.  Assume va_start works.
17497         Abort at end, to pacify gcc.
17498
17499         * lib/euidaccess.c (main): Define with a prototype.
17500
17501         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
17502
17503         * lib/exitfail.c: Include <stdlib.h> unconditionally.
17504
17505         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
17506         prototypes.
17507         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
17508         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
17509         (getenv): Remove decl.
17510         (fnmatch): Define using a prototype.
17511         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
17512         (FCT): Define using a prototype.
17513
17514         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
17515
17516         * lib/gethostname.c: Include <stddef.h>.
17517         (gethostname): Define with prototype.  Length is size_t, not int.
17518
17519 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17520
17521         Assume C89 or better; remove K&R cruft.
17522         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
17523         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
17524         string.h, getenv, malloc.
17525         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
17526         headers.
17527         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
17528         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
17529         do not check for strerror.
17530         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
17531         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
17532         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
17533         do not check for doprnt or vprintf.
17534         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
17535         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
17536
17537 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17538
17539         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
17540         getversion.c should have been removed then, but was accidentally
17541         preserved.
17542
17543         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
17544         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
17545
17546 2003-09-08  Karl Berry  <karl@gnu.org>
17547
17548         * config/config.sub, config.guess, srclistvars.sh: update from savannah
17549                 config, forget about prep.
17550
17551         * config/depcomp, missing: update from automake.
17552
17553 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17554
17555         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
17556         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17557
17558 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17559
17560         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
17561         copy_tm_result.  Bug reported by Simon Josefsson in
17562         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17563
17564 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17565
17566         * m4/time_r.m4: New file.
17567         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
17568         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
17569         is. Check for timegm declaration.
17570         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
17571         Do not check for gmtime_r.
17572         Replace mktime if __mktime_internal does not exist and if mktime
17573         hasn't been replaced already.
17574
17575 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17576
17577         * lib/time_r.c, lib/time_r.h: New files.
17578
17579         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
17580         __localtime_r.
17581         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
17582         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
17583
17584         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
17585         __gmtime_r.
17586         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
17587         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
17588         Include <time_r.h>.
17589
17590         * lib/timegm.c: Switch to glibc implementation, with the following
17591         changes:
17592         [defined HAVE_CONFIG_H]: Include <config.h>.
17593         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
17594         (__mktime_internal) [!defined _LIBC]: New decl.
17595         (__gmtime_r) [!defined _LIBC]: New macro and function.
17596         (timegm): Use a prototype, since gnulib assumes C89.
17597         Do not bother declaring tmp to be const, as it's not really usefu.
17598         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
17599         (timegm): Declare only if HAVE_DECL_TIMEGM.
17600
17601 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17602
17603         * MODULES.html.sh (func_all_modules): Add time_r.
17604         * modules/time_r: New file.
17605         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
17606         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
17607
17608 2003-09-03  Paul Eggert  <eggert@twinsun.com>
17609
17610         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
17611         Bug reported by Lute Kamstra in
17612         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
17613
17614         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
17615         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
17616         course with correspondingly smaller numbers for tomorrow and
17617         yesterday.  From Tadayoshi Funaba.  Originally installed into
17618         sh-utils on 1999-08-07, but the patch got lost (I guess during the
17619         coreutils merge?).
17620
17621 2003-08-31  Simon Josefsson  <jas@extundo.com>
17622
17623         * modules/timegm: New file.
17624         * MODULES.html.sh (func_all_modules): Add timegm.
17625
17626 2003-08-31  Simon Josefsson  <jas@extundo.com>
17627
17628         * m4/timegm.m4: New file.
17629
17630 2003-08-31  Simon Josefsson  <jas@extundo.com>
17631
17632         * lib/timegm.h: New file.
17633         * lib/timegm.c: New file.  Based on
17634         wget-1.8.2/src/http.c:mktime_from_utc.
17635
17636 2003-08-31  Karl Berry  <karl@gnu.org>
17637
17638         * lib/argp.h: update from libc.
17639
17640 2003-08-28  Bruno Haible  <bruno@clisp.org>
17641
17642         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
17643         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
17644         followed by '#define fnmatch fnmatch_posix' gives an error.
17645
17646 2003-08-28  Bruno Haible  <bruno@clisp.org>
17647
17648         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
17649         warning on QNX, which defines O_BINARY to 000000.
17650
17651 2003-08-27  Jim Meyering  <jim@meyering.net>
17652
17653         * m4/mkstemp.m4: Require that the system mkstemp be able to create
17654         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
17655         would fail after 32.  Reported by Danny Levinson.  Details here:
17656         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
17657
17658 2003-08-24  Bruno Haible  <bruno@clisp.org>
17659
17660         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
17661         MSVC7 <stdio.h> is included later.
17662
17663 2003-08-22  Simon Josefsson  <jas@extundo.com>
17664
17665         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
17666
17667 2003-08-20  Karl Berry  <karl@gnu.org>
17668
17669         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
17670
17671 2003-08-20  Bruno Haible  <bruno@clisp.org>
17672
17673         * modules/progname: New file.
17674         * MODULES.html.sh (func_all_modules): Add progname.
17675
17676 2003-08-20  Bruno Haible  <bruno@clisp.org>
17677
17678         * lib/progname.h: New file, from GNU gettext.
17679         * lib/progname.c: New file, from GNU gettext.
17680         * lib/progreloc.c: New file, from GNU gettext.
17681
17682 2003-08-19  Jim Meyering  <jim@meyering.net>
17683
17684         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
17685         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
17686
17687 2003-08-19  Bruno Haible  <bruno@clisp.org>
17688
17689         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
17690         more.
17691
17692 2003-08-19  Bruno Haible  <bruno@clisp.org>
17693
17694         * lib/xstrdup.c: Assume <string.h> exists.
17695
17696 2003-08-18  Paul Eggert  <eggert@twinsun.com>
17697
17698         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
17699         in makefile rules.
17700
17701 2003-08-18  Jim Meyering  <jim@meyering.net>
17702
17703         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
17704         * m4/lib-ld.m4: Likewise.
17705
17706 2003-08-18  Jim Meyering  <jim@meyering.net>
17707
17708         * lib/setenv.h: Indent nested cpp directive.
17709         * lib/vasnprintf.c: Remove trailing blanks.
17710
17711 2003-08-17  Simon Josefsson  <jas@extundo.com>
17712
17713         * modules/xstrndup: New file.
17714         * MODULES.html.sh (func_all_modules): Add xstrndup.
17715
17716 2003-08-17  Simon Josefsson  <jas@extundo.com>
17717
17718         * modules/argp: Fix autoconf macro name. Add more dependencies.
17719
17720 2003-08-17  Simon Josefsson  <jas@extundo.com>
17721
17722         * m4/xstrndup.m4: New file.
17723
17724 2003-08-17  Simon Josefsson  <jas@extundo.com>
17725
17726         * m4/argp.m4: New file.
17727
17728 2003-08-17  Simon Josefsson  <jas@extundo.com>
17729             Bruno Haible  <bruno@clisp.org>
17730
17731         * lib/xstrndup.h: New file.
17732         * lib/xstrndup.c: New file.
17733
17734 2003-08-17  Bruno Haible  <bruno@clisp.org>
17735
17736         * modules/strndup (Files, Include): Add lib/strndup.h.
17737
17738 2003-08-17  Bruno Haible  <bruno@clisp.org>
17739
17740         * modules/euidaccess (Files): Add lib/euidaccess.h.
17741
17742 2003-08-17  Bruno Haible  <bruno@clisp.org>
17743
17744         * lib/strndup.h: New file.
17745
17746 2003-08-17  Bruno Haible  <bruno@clisp.org>
17747
17748         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
17749         like AC_GNU_SOURCE.
17750         * modules/extensions (configure.ac): Comment out the invocation of
17751         gl_USE_SYSTEM_EXTENSIONS.
17752
17753 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17754
17755         Merges from coreutils, etc.
17756         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
17757         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
17758         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
17759         fixing a typo.
17760         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
17761         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
17762
17763 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17764
17765         Document merge from coreutils.
17766         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
17767         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
17768         * modules/utime: Add m4/utimes-null.m4.
17769
17770 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17771
17772         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
17773         space, undoing this 2003-08-12 change:
17774         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17775
17776 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17777
17778         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
17779         strtoul.c from libc, undoing this 2003-08-12 change:
17780         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17781
17782 2003-08-16  Jim Meyering  <jim@meyering.net>
17783
17784         Merges from coreutils.
17785         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
17786         prefix.  Adjust cache variables similarly.  Create 500 rather than
17787         just 300 files, to exercise bug on Darwin6.5, too.
17788         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
17789         $missing_dir.
17790         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
17791         AM_SYS_POSIX_TERMIOS.
17792         Reported by mkc@mathdogs.com.
17793         Also change use of $am_cv_sys_posix_termios
17794         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
17795         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
17796         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
17797         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
17798         in /proc/mounts until it finds one with matching device number.  This
17799         is unnecessary when the FILE argument *is* a mount point.  No stat call
17800         is necessary in that case.  So, disable the statvfs-testing code on
17801         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
17802         as RedHat bug# 84846.
17803         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17804         to 1MB, so as not to render systems with no stack size limit (e.g.,
17805         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17806         Include <unistd.h>.  On some systems,
17807         it is required for the definition of _SC_PAGESIZE.
17808
17809 2003-08-16  Jim Meyering  <jim@meyering.net>
17810
17811         Merge from coreutils.
17812         * lib/xstrtoimax.c: #else #if -> #elif.
17813         * lib/xstrtoumax.c: Likewise.
17814
17815 2003-08-16  Jim Meyering  <jim@meyering.net>
17816
17817         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
17818         * m4/utimes.m4: Removed.
17819         * m4/utimes-null.m4: Renamed from utimes.m4.
17820
17821         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17822         to 1MB, so as not to render systems with no stack size limit (e.g.,
17823         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17824         Include <unistd.h>.  On some systems,
17825         it is required for the definition of _SC_PAGESIZE.
17826
17827 2003-08-16  Jim Meyering  <jim@meyering.net>
17828         and Paul Eggert  <eggert@cs.ucla.edu>
17829
17830         Merges from coreutils, etc.
17831
17832         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
17833         using the latest version from cvs.  This avoids problems with #line
17834         directives using a vendor (Sun) compiler.
17835         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
17836         Don't set GETGROUPS_LIB here; now it's
17837         done via getgroups.m4's wrapper function.
17838         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
17839         rather than just in sh-util/configure.in, so that the
17840         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
17841         same.
17842         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
17843         AC_FUNC_GETLOADAVG where to find getloadavg.c.
17844         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
17845         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
17846         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
17847         Remove code that is now done by the newly-required macros.
17848         Append $(EXEEXT) to DF_PROG.
17849         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
17850         Do not invoke or require the following here,
17851         since prereq.m4 or some gnulib .m4 now does this for us:
17852         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
17853         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
17854         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
17855         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
17856         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
17857         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
17858         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
17859         AC_FUNC_OBSTACK.
17860         Do not replace the following functions, as this is now the job
17861         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
17862         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
17863         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
17864         atexit getpass, strdup, getpagesize.
17865         Replace 'raise'.
17866         Do not check for the following functions, as this is now the job
17867         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
17868         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
17869         setregid.
17870         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
17871         Check for sys/sysctl.h.
17872         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
17873         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
17874         of checking for ssize_t ourselves.
17875
17876         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
17877         Require every macro that gnulib/modules/* suggests for us.
17878         (jm_PREREQ_ADDEXT): New macro.
17879         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
17880         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
17881
17882         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
17883         (gl_PHYSMEM): Use it.
17884         Also check for `table' function.
17885         Check for new headers and functions.
17886         Add check for sys/sysmp.h.
17887         With suggestions from Kaveh Ghazi.
17888         Ignore headers that are present but cannot be compiled.  This
17889         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
17890         C 5.4.
17891
17892 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17893
17894         Document merge from coreutils.
17895         * modules/userspec: Depend on posixver.
17896         * modules/strftime: Depend on tzset.
17897
17898 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17899
17900         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
17901         rather than tab, after '#' in shell-script copyright notices.
17902         Suggested by Bruno Haible.
17903
17904 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17905
17906         * config/srclist-update: Use three spaces, rather than tab, after '#'
17907         in shell-script copyright notices.  Suggested by Bruno Haible.
17908         Remove unnecessary parenthesization in regular expression.
17909
17910 2003-08-15  Jim Meyering  <jim@meyering.net>
17911
17912         Merge from coreutils.
17913         * lib/xgethostname.c: Include <stdlib.h>.
17914         (xghostname): Don't exit for anything other than memory-related
17915         failure; just return NULL.
17916         * lib/userspec.c: Include "posixver.h".
17917         (parse_user_spec): Accept `.' as a separator only
17918         in pre-POSIX-200112 mode.
17919         * lib/strtoimax.c: Use #elif rather than #else #if.
17920         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
17921         Remove function, now that we can rely on a working tzset function.
17922         [!_LIBC]: Ensure that the required autoconf test has been run.
17923         [!defined _NL_CURRENT && HAVE_STRFTIME]:
17924         Use underlying_strftime for %r.
17925         * lib/sha.c: Merge in some clean-up and optimization changes from
17926         glibc.
17927         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
17928         Ensure that it is a multiple of 64.
17929         Rearrange loop exit tests so as to avoid performing an
17930         additional fread after encountering an error or EOF.
17931         * lib/realloc.c: Update copyright date.
17932
17933 2003-08-15  Jim Meyering  <jim@meyering.net>
17934         and Paul Eggert  <eggert@twinsun.com>
17935
17936         Merge from coreutils.
17937         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
17938         member but strut utmpx does not.  Needed for AIX 4.3.3.
17939         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
17940
17941 2003-08-15  Jim Meyering  <jim@meyering.net>
17942         and Paul Eggert  <eggert@cs.ucla.edu>
17943
17944         Merges from coreutils, etc.
17945         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
17946         Require gl_FUNC_TZSET_CLOBBER.
17947         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
17948         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
17949         members.
17950
17951 2003-08-14  Paul Eggert  <eggert@twinsun.com>
17952
17953         Help the merge from coreutils.
17954         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
17955         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
17956         * m4/tzset.m4: Use it too.
17957
17958 2003-08-14  Paul Eggert  <eggert@twinsun.com>
17959
17960         * modules/tzset: New file.
17961
17962 2003-08-14  Jim Meyering  <jim@meyering.net>
17963
17964         Merges from coreutils.
17965         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
17966         variable names, rather than @FNMATCH_H@.
17967         * modules/alloca: Likewise for $(ALLOCA_H).
17968
17969         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
17970         the three copies of the literal target, `fnmatch.h'.
17971         * modules/alloca (alloca.h): Likewise.
17972
17973 2003-08-14  Jim Meyering  <jim@meyering.net>
17974
17975         Merge from coreutils.
17976         * m4/tzset.m4: New file.
17977         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
17978         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
17979         otherwise, AIX 5.1 systems would end up using the latter.
17980         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
17981         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
17982         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
17983         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
17984
17985 2003-08-14  Jim Meyering  <jim@meyering.net>
17986
17987         Merge from coreutils.
17988         * lib/obstack.h: Whitespace changes.
17989         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
17990         and xcalloc return values.
17991         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
17992         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
17993         hang on OSF/1 5.1 for DIR on both local and remote file systems.
17994         Reported by (and fix confirmed by) Nelson H. F. Beebe.
17995         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
17996         error from mntctl.
17997         Use mntctl's return value to drive the entry-processing loop, since
17998         we can't rely on the value of the vmt_length member in the last
17999         entry.  On some systems doing so could result in exhausting
18000         virtual memory.  Based in part on a patch from Mike Jetzer.
18001
18002 2003-08-14  Jim Meyering  <jim@meyering.net>
18003         and Paul Eggert  <eggert@twinsun.com>
18004
18005         Merges from coreutils, plus other fixes.
18006         * lib/physmem.c: Merge in portability changes from gcc/libiberty
18007         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
18008         for credits and details.  Thanks to Kaveh Ghazi for helping
18009         to keep these files in sync.
18010         (ARRAY_SIZE): Define it.
18011         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
18012         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
18013         (memcasecmp): Don't assume size_t fits in unsigned int.
18014         Remove casts and duplicate code.
18015         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
18016         (memcpy): Remove definition.
18017         Merge in some clean-up and optimization changes from glibc.
18018         [BLOCKSIZE]: Move definition to top of file.
18019         Ensure that it is a multiple of 64.
18020         Rearrange loop exit tests so as to avoid performing an
18021         additional fread after encountering an error or EOF.
18022         * lib/md5.h (md5_uintptr): Define.
18023         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
18024         return to the initial working directory.  Preserve errno
18025         for caller.
18026         * lib/idcache.c: Include "xalloc.h".
18027         (xmalloc, xrealloc): Remove decls.
18028         (getuser): Remove casts no longer required in C89.
18029         * lib/human.c: Include stdio.h, for sprintf.
18030         * lib/group-member.c: Include "xalloc.h".
18031         (xmalloc, xrealloc): Remove decls.
18032         (get_group_info): Remove casts no longer required in C89.
18033         * lib/getusershell.c (readname): Remove casts no longer required in
18034         C89.
18035         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
18036         * lib/getline.c: Whitespace fix, from coreutils.
18037
18038 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18039
18040         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
18041         Check for isascii.
18042
18043         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18044         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18045         Undo previous (whitespace-only) change.
18046
18047 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18048
18049         * lib/exclude.c: Include <ctype.h>
18050         (IN_CTYPE_DOMAIN): New macro.
18051         (is_space): New fn.
18052         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
18053         and empty lines.
18054
18055         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18056         Undo previous (whitespace-only) change.
18057
18058 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18059
18060         * config/srclist-update: Change update back to the old behavior,
18061         leaving whitespace alone.  Use one 'sed' command rather than a
18062         pipeline.
18063         (fixlicense): Now a variable, not a function.
18064         (remove_trailing_blanks): Remove.
18065         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
18066         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18067         Undo previous (whitespace-only) change.
18068
18069 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18070
18071         Merge from coreutils.
18072         * modules/euidaccess: Add lib_SOURCES, include for new
18073         file euidaccess.h
18074
18075 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18076
18077         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18078         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18079         Normalize leading white space and remove trailing white space.
18080
18081         Merge from coreutils
18082         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
18083
18084         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
18085         0.12.1.  These files are now being upgraded automatically by
18086         ../config/srclist-update.
18087
18088 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18089
18090         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18091         Normalize leading white space and remove trailing white space.
18092         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
18093         notice, as per ../config/srclist-update.
18094
18095         Merge from coreutils.
18096         * lib/euidaccess.h: New file.
18097         * lib/euidaccess.c: Include it.
18098         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
18099         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
18100         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
18101
18102 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18103
18104         * config/srclist-update: Add copyright notice.
18105         (remove_id_lines, remove_trailing_blanks): New constants.
18106         (fixfile): Use them to normalize spacing a bit in copied files.
18107         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18108         Normalize leading white space and remove trailing white space.
18109
18110         * config/texinfo.tex: Sync with texinfo.
18111
18112         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
18113         strtoul.c from libc, to merge coreutils whitespace changes.
18114
18115         * config/srclist.txt: Get the following m4 files from gettext:
18116         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
18117         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
18118         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
18119         wint_t.m4.
18120
18121 2003-08-12  Karl Berry  <karl@gnu.org>
18122
18123         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
18124         been made.
18125
18126 2003-08-11  Paul Eggert  <eggert@twinsun.com>
18127
18128         * modules/gnu-source, m4/gnu-source.m4:
18129         Remove; we're assuming Autoconf 2.54 or later now.
18130         Suggested by Bruno Haible.
18131         * MODULES.html.sh (func_all_modules): Remove gnu-source.
18132
18133 2003-08-11  Bruno Haible  <bruno@clisp.org>
18134
18135         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
18136
18137 2003-08-11  Bruno Haible  <bruno@clisp.org>
18138
18139         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
18140         (vasnprintf): Use it instead of wcslen.
18141
18142 2003-08-11  Bruno Haible  <bruno@clisp.org>
18143
18144         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
18145         value to ensure that _Bool promotes to int. Use #define for _Bool when
18146         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
18147
18148 2003-08-10  Karl Berry  <karl@gnu.org>
18149
18150         * lib/regex.h: update from libc (whitespace fix).
18151
18152 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18153
18154         Merge some files from coreutils.  These changes were
18155         originally made by Jim Meyering.
18156         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
18157         many older Unixes require this.
18158         * lib/alloca.c (alloca): Remove cast to argument of free;
18159         no longer needed in C89.
18160         * lib/alloca_.h, regex.h: Fix white space to match
18161         what GNU indent does.
18162
18163 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18164
18165         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
18166         apparently Emacs's Unicode mode got confused before my 2003-08-05
18167         checkin.
18168
18169 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18170
18171         * m4/extensions.m4: New file.
18172         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
18173         Require gl_USE_SYSTEM_EXTENSIONS.
18174         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
18175         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
18176
18177 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18178
18179         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
18180         * modules/extensions, modules/gnu-source: New files.
18181         * modules/timespec, modules/unlocked-io: Depend on extensions.
18182
18183 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18184
18185         * modules/restrict: New file.
18186         * MODULES.html.sh (func_all_modules): Add restrict.
18187         * modules/regex: Depend on restrict.
18188
18189 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18190
18191         * m4/restrict.m4: New file.
18192         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
18193
18194 2003-08-07  Bruno Haible  <bruno@clisp.org>
18195
18196         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
18197         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
18198
18199 2003-08-07  Bruno Haible  <bruno@clisp.org>
18200
18201         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
18202         makes the module 'getndelim2' compatible with the module 'getline'.
18203
18204 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18205
18206         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
18207         byte with "\201" to avoid glitches when editing that source file
18208         with multi-gnome-terminal.
18209
18210 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18211
18212         * lib/bumpalloc.h: Remove.
18213
18214 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18215
18216         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
18217         * modules/bumpalloc: Remove.
18218
18219 2003-08-04  Paul Eggert  <eggert@twinsun.com>
18220
18221         * lib/getloadavg.c: Change copyright notice and spacing to conform to
18222         GNU coding style.
18223
18224         Merge from coreutils.
18225         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
18226         1. From glibc.
18227         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
18228         from Karl Berry, implemented by Jim Meyering.
18229         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
18230         from Dmitry V. Levin.
18231         Remove anachronistic cast of xrealloc.
18232         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
18233         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
18234         type. Otherwise, it wouldn't compile with at least /bin/cc on
18235         ymp-cray-unicos9.0.2.X.
18236         Combine two mostly-identical uses of alloca into one.
18237         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
18238
18239 2003-08-04  Dave Love  <d.love@dl.ac.uk>
18240
18241         [From Emacs.]
18242
18243         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
18244         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
18245         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
18246         obsolete NLIST_NAME_UNION.
18247         [__GNU__]: Undef BSD and FSCALE.
18248         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
18249
18250 2003-08-03  Paul Eggert  <eggert@twinsun.com>
18251
18252         * lib/stdbool_.h (_Bool): Make it signed char, instead of
18253         an enum type, so that it's guaranteed to promote to int.  See:
18254         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
18255
18256 2003-08-03  Karl Berry  <karl@gnu.org>
18257
18258         * config/depcomp: update from automake.
18259
18260 2003-07-31  Paul Eggert  <eggert@twinsun.com>
18261
18262         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
18263         (strerror): Don't assume that a printable int fits in 14 bytes.
18264
18265 2003-07-31  Bruno Haible  <bruno@clisp.org>
18266
18267         * modules/getpass-gnu: New file.
18268         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
18269
18270 2003-07-31  Bruno Haible  <bruno@clisp.org>
18271
18272         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
18273
18274 2003-07-24  Karl Berry  <karl@gnu.org>
18275
18276         * config/missing: update from automake.
18277
18278 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
18279             Bruno Haible  <bruno@clisp.org>
18280
18281         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
18282         * lib/getline.c (getline, getdelim): Likewise.
18283         Remove _GNU_SOURCE define; now it's defined in config.h through
18284         m4/getline.m4.
18285
18286 2003-07-23  Karl Berry  <karl@gnu.org>
18287
18288         * config/config.sub: update from prep.
18289
18290 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18291
18292         * modules/xalloc (Depends-on): Add exitfail.
18293         * modules/xmemcoll: Likewise.
18294
18295 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18296
18297         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
18298         over-parenthesization in macros.
18299
18300         Sync with coreutils.
18301
18302         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
18303         required by C99.
18304
18305         Use `exit_failure' for xalloc and xmemcoll instead of their own
18306         private exit-failure variables.
18307         * lib/xalloc.h (xalloc_exit_failure): Remove.
18308         * lib/xmalloc.c: Likewise.  Include exitfail.h.
18309         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
18310         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
18311         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
18312         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
18313
18314 2003-07-20  Jim Meyering  <jim@meyering.net>
18315
18316         * modules/closeout (Depends-on): Add exitfail.
18317         Suggestion from Bruno Haible.
18318
18319 2003-07-19  Karl Berry  <karl@gnu.org>
18320
18321         * config/config.sub: update from prep.
18322
18323 2003-07-18  Paul Eggert  <eggert@twinsun.com>
18324
18325         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
18326         Remove.
18327         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
18328         to test that it can stand by itself.  Include "exitfail.h".
18329         Clients should set exit_failure instead.
18330         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
18331
18332 2003-07-18  Bruno Haible  <bruno@clisp.org>
18333
18334         * modules/getndelim2: New file.
18335         * modules/getline: Share files with module getndelim2.
18336         * modules/getnline: Depend on getndelim2 instead of sharing files with
18337         it. Add getnline.c to lib_SOURCES.
18338         * MODULES.html.sh (func_all_modules): Add getndelim2.
18339
18340 2003-07-18  Bruno Haible  <bruno@clisp.org>
18341
18342         * m4/getndelim2.m4: New file.
18343         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
18344         invoke gl_PREREQ_GETNDELIM2.
18345         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
18346         gl_PREREQ_GETNDELIM2.
18347         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
18348         gl_GETNDELIM2.
18349
18350 2003-07-18  Bruno Haible  <bruno@clisp.org>
18351
18352         * lib/getndelim2.h: New file.
18353         * lib/getndelim2.c: Make into a module of its own. Include config.h,
18354         getndelim2.h.
18355         (getndelim2): Make non-static. Change return type to ssize_t.
18356         * lib/getline.h: Change argument names.
18357         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
18358         * lib/getnline.c: Include getndelim2.h.
18359
18360 2003-07-18  Andreas Schwab  <schwab@suse.de>
18361
18362         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
18363
18364 2003-07-17  Karl Berry  <karl@gnu.org>
18365
18366         * config/config.sub: update from prep.
18367
18368 2003-07-17  Bruno Haible  <bruno@clisp.org>
18369
18370         * modules/getnline: New file.
18371         * modules/getline: Add lib/getndelim2.c to source file list.
18372         * MODULES.html.sh (func_all_modules): Add getnline.
18373
18374 2003-07-17  Bruno Haible  <bruno@clisp.org>
18375
18376         * m4/getnline.m4: New file.
18377
18378 2003-07-17  Bruno Haible  <bruno@clisp.org>
18379
18380         * m4/Makefile.am.in: Remove file.
18381         * m4/Makefile.am: Remove file.
18382         * m4/Makefile.in: Remove file.
18383
18384 2003-07-17  Bruno Haible  <bruno@clisp.org>
18385
18386         * lib/getnline.h: New file.
18387         * lib/getnline.c: New file.
18388         * lib/getndelim2.c: New file, extracted from getline.c.
18389         (getndelim2): Renamed from getdelim2, with added nmax argument.
18390         * lib/getline.c: Include getndelim2.c.
18391         (getdelim2): Moved out to getndelim2.c.
18392         (getline, getdelim): Update.
18393
18394 2003-07-17  Bruno Haible  <bruno@clisp.org>
18395
18396         * lib/Makefile.am: Remove file.
18397         * lib/Makefile.in: Remove file.
18398
18399 2003-07-17  Bruno Haible  <bruno@clisp.org>
18400
18401         * configure.in: Remove file.
18402         * Makefile.in: Remove file.
18403
18404 2003-07-17  Bruno Haible  <bruno@clisp.org>
18405
18406         * MODULES.html.sh: Put the </BODY> right before </HTML>.
18407
18408 2003-07-16  Karl Berry  <karl@gnu.org>
18409
18410         * config/srclist-update: was running fixlicense twice, which caused
18411                 texinfo.tex to be nullified for some reason.  Simplify,
18412                 $gplsrc is no longer needed as far as I can see?
18413
18414 2003-07-16  Jim Meyering  <jim@meyering.net>
18415
18416         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
18417
18418 2003-07-15  Paul Eggert  <eggert@twinsun.com>
18419
18420         * config/srclist.txt: Get the following files from gettext-runtime/intl
18421         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
18422         ref-del.sin.  From Bruno Haible.
18423         * config/srclist-update (fixfile): Change grep pattern again, since the
18424         previous fix didn't work (there was another trailing $).  Use
18425         '[$]' to escape the $s.
18426
18427 2003-07-15  Karl Berry  <karl@gnu.org>
18428
18429         * lib/vasnprintf.c: update from gettext.
18430
18431 2003-07-15  Karl Berry  <karl@gnu.org>
18432
18433         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
18434         gets expanded when surrounded by '$'.
18435
18436 2003-07-15  Jim Meyering  <jim@meyering.net>
18437
18438         * modules/save-cwd: Don't depend on error.  From Derek Price.
18439
18440 2003-07-15  Jim Meyering  <jim@meyering.net>
18441
18442         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
18443
18444 2003-07-14  Simon Josefsson  <jas@extundo.com>
18445
18446         * modules/mempcpy: New file.
18447         * MODULES.html.sh (func_all_modules): Add mempcpy.
18448
18449 2003-07-14  Simon Josefsson  <jas@extundo.com>
18450
18451         * m4/mempcpy.m4: New file.
18452
18453 2003-07-14  Simon Josefsson  <jas@extundo.com>
18454
18455         * lib/mempcpy.h: New file.
18456         * lib/mempcpy.c: New file.
18457
18458 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18459
18460         * modules/getdate, modules/posixtm: Depend on mktime.
18461
18462 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18463
18464         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
18465         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
18466         unicodeio.c, unicodeio.h, unlocked-io.h:
18467         Switch from LGPL to GPL.
18468
18469 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18470
18471         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
18472         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
18473         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
18474         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
18475         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
18476         updated automatically by ../config/srclist-update.  This changes
18477         their license from LPGL to GPL.
18478
18479 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18480
18481         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
18482         assumed to refer to the root of the most recent stable gettext version.
18483         * config/srclistvars.sh: Add defaults for eggert.
18484         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
18485         Match "This program" as well as "The program".  This is needed
18486         for gettext.
18487
18488 2003-07-14  Jim Meyering  <jim@meyering.net>
18489
18490         Don't emit diagnostics.  Let callers do that.
18491         * lib/save-cwd.c: Don't include "error.h".
18492         (save_cwd): Don't call error.  Ensure that errno is valid
18493         when returning nonzero.
18494
18495         * lib/save-cwd.h (restore_cwd): Update prototype.
18496         * lib/save-cwd.c (restore_cwd): Remove two parameters.
18497         Simplify.  Don't call error upon failure.  Let callers do that.
18498         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
18499         when auditing is enabled.  But don't bother updating the #if.
18500
18501 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
18502
18503         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
18504         it breaks C++ compilation.
18505         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
18506
18507 2003-07-10  Simon Josefsson  <jas@extundo.com>
18508
18509         * modules/strchrnul (Makefile.am): Add strchrnul.h.
18510
18511 2003-07-10  Jim Meyering  <jim@meyering.net>
18512
18513         * m4/clock_time.m4: Remove trailing blank.
18514         * m4/intmax_t.m4: Likewise.
18515
18516 2003-07-10  Jim Meyering  <jim@meyering.net>
18517
18518         * lib/vasnprintf.c: Remove trailing blanks.
18519         Make cpp indentation consistent.
18520
18521 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18522
18523         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
18524         posixver.c, strftime.c, strnlen.c, strverscmp.c:
18525         Switch from LGPL to GPL.
18526
18527 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18528
18529         * config/srclist.txt: Sort sublists.  Add
18530         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
18531         that differ from gnulib for one reason or another; we'd like this list
18532         to be smaller but for now let's document what we have.
18533
18534 2003-07-08  Paul Eggert  <eggert@twinsun.com>
18535
18536         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
18537         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
18538         and sweeter "eval x=$x".
18539         * config/srclist.txt: Get lib/argp* from glibc.
18540
18541 2003-07-07  Paul Eggert  <eggert@twinsun.com>
18542
18543         * lib/mktime.c: Fix some boundary cases and remove need for floating
18544         point.
18545
18546         Issue a compile-time diagnostic if time_t is floating point, or if
18547         two's complement arithmetic is not in effect, or if arithmetic
18548         right shift does not propagate the sign.  These assumptions were
18549         all in the original code but they weren't checked.
18550
18551         (TIME_T_MIDPOINT, verify): New macros.
18552         (__isleap): Remove; it has integer overflow problems.
18553         (leapyear): New function, without those problems.
18554         (ydhms_tm_diff): Remove; splitting into two parts.
18555         (ydhms_diff): New function, containing the arithmetic part of
18556         the old ydhms_tm_diff function.  Issue a compile-time
18557         diagnostic if we are not using C99 integer division.
18558         Avoid casts when possible.
18559         (guess_time_tm): New function, containing the checking part of
18560         the old ydhms_tm_diff function.  Return the new value, rather than
18561         the difference between it and the old.  Accept a new argument T
18562         so that *T specifies the old value.  Check for overflow in the result.
18563
18564         (__mktime_internal): Use a time_t offset, not a long int offset.
18565         This undoes the 2003-06-04 change, which is no longer needed now
18566         that we have better overflow checking.
18567         (localtime_offset): Likewise.
18568
18569         (__mktime_internal): Avoid harmful overflow on hosts where time_t
18570         and long are 64-bit but int is only 32-bit.
18571         (ydhms_diff): Use long int to store year1 and yday1.
18572         Issue a compile-time diagnostic if long int is not wide enough.
18573
18574         (__mktime_internal): Use long int to store adjusted year and yday.
18575         Use plain C rather than preprocessor commands, if that doesn't
18576         affect efficiency.
18577         Check for overflow (and try to repair) after each probe
18578         rather than checking only at the very end.  This avoids some bugs
18579         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
18580         does not equal GMT offset at maximum time).
18581         Use integer to check for overflow rather than floating point; this
18582         is more portable to non-IEEE hosts, and is a tad faster.
18583         When we detect that we are oscillating between two values,
18584         don't check whether tm_isdst has the requested value, since
18585         we already know the answer.  When tm_isdst has the wrong value,
18586         use a different heuristic to find the right one, based on the
18587         extreme values actually observed in practice in tz2003a,
18588         rather than the (overly optimistic) "previous 3 calendar quarters".
18589
18590         (not_equal_tm, print_tm, check_result): Use "const T" rather than
18591         "T const" to accommodate glibc style.
18592         (check_result): Use less-confusing report format.  "long" -> "long int.
18593         (main): Likewise.
18594         Don't loop if the iteration overflows time_t.
18595         Allow a negative step in the iteration.
18596
18597 2003-07-06  Karl Berry  <karl@gnu.org>
18598
18599         * config/depcomp: update from automake.
18600         * config/config.sub: update from prep.
18601
18602 2003-07-03  Karl Berry  <karl@gnu.org>
18603
18604         * config/config.guess: update from prep.
18605
18606 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18607
18608         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
18609         xreadlink.c now includes it unconditionally.
18610
18611 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18612
18613         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
18614         having it depend on HAVE_SYS_TYPES_H.
18615
18616 2003-07-01  Bruno Haible  <bruno@clisp.org>
18617
18618         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
18619         <sys/types.h> should be sufficient.
18620         Reported by Paul Eggert.
18621
18622 2003-06-26  Karl Berry  <karl@gnu.org>
18623
18624         * config/depcomp: update from automake.
18625
18626 2003-06-26  Bruno Haible  <bruno@clisp.org>
18627
18628         * modules/human: Depend on module stdbool.
18629
18630 2003-06-25  Bruno Haible  <bruno@clisp.org>
18631
18632         * modules/readlink: New file.
18633         * modules/xreadlink: Depend on it.
18634         * MODULES.html.sh (func_all_modules): Add readlink.
18635
18636 2003-06-25  Bruno Haible  <bruno@clisp.org>
18637
18638         * m4/readlink.m4: New file.
18639
18640 2003-06-25  Bruno Haible  <bruno@clisp.org>
18641
18642         * lib/readlink.c: New file.
18643
18644 2003-06-22  Karl Berry  <karl@gnu.org>
18645
18646         * config/srclist.txt: update mkinstalldirs from automake.
18647         * config/mkinstalldirs: update.
18648
18649 2003-06-22  Bruno Haible  <bruno@clisp.org>
18650
18651         Portability to mingw32.
18652         * m4/ssize_t.m4: New file, from GNU gettext.
18653         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
18654         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
18655
18656 2003-06-22  Bruno Haible  <bruno@clisp.org>
18657
18658         * modules/safe-read: Add m4/ssize_t.m4.
18659         * modules/xreadlink: Add m4/ssize_t.m4.
18660
18661 2003-06-20  Bruno Haible  <bruno@clisp.org>
18662
18663         Assume C89, so PARAMS isn't needed.
18664         * lib/unicodeio.h (PARAMS): Remove.
18665         * lib/unicodeio.c: Don't use PARAMS.
18666
18667 2003-06-18  Karl Berry  <karl@gnu.org>
18668
18669         * config/config.{guess,sub}: update from prep.
18670
18671 2003-06-18  Jim Meyering  <jim@meyering.net>
18672
18673         Merge changes from coreutils.
18674         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
18675         Remove explicit declarations of xmalloc and realloc.
18676         Include xalloc.h.
18677         (read_utmp): Remove anachronistic cast of xmalloc.
18678
18679 2003-06-17  Paul Eggert  <eggert@twinsun.com>
18680
18681         Assume C89, so PARAMS isn't needed.
18682         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
18683         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
18684         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
18685         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
18686         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
18687         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
18688         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
18689         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
18690         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
18691         lib/xstrtod.h, lib/xstrtol.h: Likewise.
18692         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
18693         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
18694         no longer needed. Anyway, config.h should always be included before any
18695         other file.
18696
18697 2003-06-11  Simon Josefsson  <jas@extundo.com>
18698
18699         * modules/sysexits: New file.
18700         * MODULES.html.sh (func_all_modules): Add sysexits.
18701
18702 2003-06-11  Simon Josefsson  <jas@extundo.com>
18703
18704         * lib/sysexit_.h: New file.
18705
18706 2003-06-11  Derek Price  <derek@ximbiot.com>
18707
18708         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
18709         necessary.
18710
18711 2003-06-11  Bruno Haible  <bruno@clisp.org>
18712
18713         * m4/sysexits.m4: New file.
18714
18715 2003-06-10  Simon Josefsson  <jas@extundo.com>
18716
18717         * lib/argp.h: New file, from glibc.
18718         * lib/argp-ba.c: New file, from glibc.
18719         * lib/argp-eexst.c: New file, from glibc.
18720         * lib/argp-fmtstream.c: New file, from glibc.
18721         * lib/argp-fmtstream.h: New file, from glibc.
18722         * lib/argp-fs-xinl.c: New file, from glibc.
18723         * lib/argp-help.c: New file, from glibc.
18724         * lib/argp-namefrob.h: New file, from glibc.
18725         * lib/argp-parse.c: New file, from glibc.
18726         * lib/argp-pv.c: New file, from glibc.
18727         * lib/argp-pvh.c: New file, from glibc.
18728         * lib/argp-xinl.c: New file, from glibc.
18729
18730 2003-06-10  Simon Josefsson  <jas@extundo.com>
18731
18732         * modules/strchrnul: New file.
18733
18734 2003-06-10  Simon Josefsson  <jas@extundo.com>
18735
18736         * modules/argp: New file.
18737
18738 2003-06-10  Simon Josefsson  <jas@extundo.com>
18739
18740         * m4/strchrnul.m4: New file.
18741
18742 2003-06-10  Simon Josefsson  <jas@extundo.com>
18743
18744         * lib/strchrnul.h: New file.
18745         * lib/strchrnul.c: New file.
18746
18747 2003-06-10  Bruno Haible  <bruno@clisp.org>
18748
18749         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
18750
18751 2003-06-07  Karl Berry  <karl@gnu.org>
18752
18753         * config/config.{guess,sub}: update from prep.
18754
18755 2003-06-07  Jim Meyering  <jim@meyering.net>
18756
18757         * modules/strtod: Use $(...) notation, not @...@ for
18758         AC_REPLACE'd variables.
18759         * modules/localcharset: Likewise.
18760
18761 2003-06-07  Jim Meyering  <jim@meyering.net>
18762
18763         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
18764         in place of my name in the copyright comment.
18765         Remove definition and uses of __P.
18766
18767         From coreutils.
18768         * lib/stat.c: Don't declare xmalloc explicitly.
18769         Instead, include "xalloc.h".
18770         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
18771         xrealloc, and xcalloc return values.
18772         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
18773         Improve comment.
18774         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
18775
18776 2003-06-07  Bruno Haible  <bruno@clisp.org>
18777
18778         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
18779         avoid AC_CONFIG_LINKS.
18780         * modules/fnmatch (Makefile.am): Use explicit creation rule for
18781         fnmatch.h, to avoid AC_CONFIG_LINKS.
18782         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
18783
18784 2003-06-07  Bruno Haible  <bruno@clisp.org>
18785
18786         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
18787         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
18788         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18789         directory.
18790         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
18791         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18792         directory.
18793
18794 2003-06-06  Jim Meyering  <jim@meyering.net>
18795
18796         Merge from coreutils.
18797         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
18798         Consolidate declarations and initializations of *_base* locals.
18799
18800         Merge from coreutils.
18801         This avoids a core dump on systems without GNU putenv,
18802         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
18803         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
18804         (unsetenv): New static function, from GNU libc.
18805         (rpl_putenv): Use it.
18806
18807         * lib/modechange.c: Remove trailing blanks.
18808
18809         Merge from coreutils.
18810         * lib/fsusage.c: Remove declaration of statfs.
18811         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
18812
18813         * lib/posixtm.c: Include <stdbool.h> unconditionally.
18814
18815 2003-06-06  Jim Meyering  <jim@meyering.net>
18816
18817         * lib/stdbool_.h: Renamed from stdbool.h.in.
18818
18819 2003-06-06  Jim Meyering  <jim@meyering.net>
18820             Bruno Haible  <bruno@clisp.org>
18821
18822         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
18823         Adjust Makefile.am snippet not to redirect directly to target.
18824         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
18825
18826 2003-06-05  Paul Eggert  <eggert@twinsun.com>
18827
18828         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
18829         mismatch, look in future quarters as well as past.  This fixes a
18830         bug when processing fall-backwards gaps immediately after a long
18831         period of daylight-saving time.
18832
18833         * lib/mktime.c: Assume freestanding C89 or better.
18834         (HAVE_LIMITS_H): Remove.  Assume it's 1.
18835         (__P): Remove; not used.
18836         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
18837         (mktime, not_equal_tm, print_tm, check_result,
18838         main): Use prototypes.  Use const * where appropriate.
18839         (main): Fix typo in testing code that uncovered by above changes.
18840         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
18841
18842 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18843
18844         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
18845         locale.h, localeconv.  This merges changes from coreutils.
18846
18847         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
18848         It can be removed after the next Autoconf is released.
18849         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
18850         needed.
18851
18852 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18853
18854         * lib/mktime.c: Fix Debian bug 177940
18855         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
18856         (localtime_offset): Now long int, not time_t, because we want it
18857         to be guaranteed to be signed.  All uses changed.
18858         (__mktime_internal): If overflow would occur when adding offset,
18859         don't add it.
18860
18861         Merge 'human' changes from coreutils.  Rewrite to support
18862         locale-specific notations like thousands separators.
18863         * lib/human.c: Simplify authorship notice.
18864         Include human.h immediately after config.h.
18865         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
18866         <limits.h>: Do not include, since human.h does.
18867         (SIZE_MAX, UINTMAX_MAX): New macros.
18868         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
18869         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
18870         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
18871         (power_letter): Renamed from suffixes.
18872         (generate_suffix_backwards): Remove.
18873         (adjust_value): Now takes int style (because of human.h changes)
18874         and long double value (for greater precision on some platforms).
18875         (group_number): New function.
18876         (human_readable): Use it.  Use integer options, not enum.
18877         Put the options before the sizes in the arg list.
18878         Support all the new options.
18879         The old human_readable function has been removed;
18880         use inttostr.h instead.
18881         (human_readable, default_block_size, humblock):
18882         Use uintmax_t, not int, for block sizes.
18883         (human_readable_inexact, block_size_types): Remove.
18884         (block_size_opts): New constant.
18885         (human_options): Renamed from human_block_size, with new signature
18886         that allows block sizes up to UINTMAX_MAX.  All callers changed.
18887         * lib/human.h: Add copyright and authorship notice.
18888         Include <limits.h> and <stdbool.h> unconditionally.
18889         (PARAMS): Remove.  All uses removed.
18890         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
18891         (enum human_inexact_style): Remove tag; now a nameless enum.
18892         (human_floor, human_ceiling, human_round_to_even): Now have
18893         values 2, 0, 1 rather than -1, 1, 0.
18894         (human_group_digits, human_suppress_point_zero, human_autoscale,
18895         human_base_1024, human_SI, human_B): New constants.
18896         (human_readable_inexact, human_block_size): Remove.
18897         (human_readable): Size args are now uintmax_t, not int.
18898         (human_options): New decl.
18899
18900         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
18901         unnecessary now that we assume C89 or better.  This change
18902         imported from coreutils.
18903
18904         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
18905         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
18906         in the 2003-05-30 sync from glibc.
18907
18908         .h files should stand alone, but we shouldn't include <sys/types.h>
18909         if we can get away with just <stddef.h>.
18910
18911         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
18912         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
18913         rather than <sys/types.h>, as we merely need size_t.
18914         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
18915         to get size_t.
18916         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
18917         Include <stdio.h>, to get FILE.
18918         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
18919         memcasecmp.h has included <stddef.h> and all we need is size_t.
18920         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
18921         our interface, instead of including <sys/types.h>
18922
18923 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18924
18925         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
18926         now, as glibc mktime is buggy on non-glibc systems.
18927
18928 2003-06-03  Karl Berry  <karl@gnu.org>
18929
18930         * config/config.sub: update from prep.
18931
18932 2003-06-02  Paul Eggert  <eggert@twinsun.com>
18933
18934         [from coreutils]
18935         Fix some minor time-related bugs with POSIX time arguments.
18936         Some valid time stamps were being rejected (notably -1, and
18937         time stamps before 1900 on 64-bit hosts).  And some invalid
18938         time stamps were being accepted, e.g. September 31.
18939
18940         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
18941         that we can return (time_t) -1 successfully.
18942         * lib/posixtm.c: Likewise.
18943         [HAVE_STDBOOL_H]: Include <stdbool.h>.
18944         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
18945         (t): Remove static var.
18946         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
18947         of static var.  All uses changed.
18948         (year): Do not reject years before 1900; they can occur with
18949         64-bit time_t.
18950         (posix_time_parse): Do not check for out-of-range components;
18951         that is now the caller's responsibility, since our checks were
18952         only approximations.
18953         (posixtime): Use mktime to check for out-of-range components,
18954         since it knows them exactly.
18955         If mktime returns (time_t) -1, check whether an error actually occurred
18956         by invoking localtime on -1.
18957         (main) [TEST_POSIXTIME]: Check for input data errors, and report
18958         posixtime failures better.
18959         Improve the test data (in comments only).
18960
18961 2003-06-02  Karl Berry  <karl@gnu.org>
18962
18963         * config/mkinstalldirs (version): new variable.
18964         (--version): new option.
18965         (usage): improve message.
18966
18967 2003-05-30  Karl Berry  <karl@gnu.org>
18968
18969         * lib/mktime.c: update from libc.
18970
18971 2003-05-30  Bruno Haible  <bruno@clisp.org>
18972
18973         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
18974         * config/config.rpath: Upgrade to gettext-0.12.1.
18975
18976 2003-05-30  Bruno Haible  <bruno@clisp.org>
18977
18978         * m4/gettext.m4: Upgrade to gettext-0.12.1.
18979         * m4/nls.m4: New file, from gettext-0.12.1.
18980         * m4/po.m4: New file, from gettext-0.12.1.
18981         * m4/progtest.m4: Upgrade to gettext-0.12.1.
18982
18983 2003-05-30  Bruno Haible  <bruno@clisp.org>
18984
18985         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
18986         * lib/localcharset.h: Likewise.
18987         * lib/localcharset.c: Likewise.
18988
18989 2003-05-29  Karl Berry  <karl@gnu.org>
18990
18991         * config/config.rpath: update from gettext.
18992
18993 2003-05-28  Paul Eggert  <eggert@twinsun.com>
18994
18995         Assume the headers required for C89 freestanding compilers.
18996         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
18997         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
18998         * m4/human.m4 (gl_HUMAN): Likewise.
18999         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
19000         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
19001         * m4/userspec.m4 (gl_USERSPEC): Likewise.
19002         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
19003         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
19004         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
19005
19006 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19007
19008         Assume the headers required for C89 freestanding compilers.
19009         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
19010         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
19011         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
19012         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
19013         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
19014         define, since <limits.h> is guaranteed to do that.
19015         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
19016         * lib/exclude.c: Include <stdbool.h> unconditionally.
19017         * lib/tempname.c: Include <stddef.h> unconditionally.
19018         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
19019         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
19020         <stddef.h> does that.
19021         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
19022         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
19023         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
19024         needed.
19025         * lib/xstrtol.c: Likewise.
19026         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
19027         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
19028
19029         * lib/addext.c (addext): Use assignment rather than cast, to avoid
19030         warnings on some platforms.
19031
19032         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19033         arbitrarily.
19034
19035 2003-05-26  Jim Meyering  <jim@meyering.net>
19036
19037         Merge in a change from coreutils:
19038         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
19039         that is guaranteed to be `no'.  Use `no_such_member' to indicate
19040         that condition, rather than `-1' which is slightly misleading.
19041         Change the name of the cache variable to have the gl_ prefix.
19042         Prompted by a patch from Richard Dawe for DJGPP.
19043
19044 2003-05-24  Karl Berry  <karl@gnu.org>
19045
19046         * config/config.guess: update from prep.
19047
19048 2003-05-22  Karl Berry  <karl@gnu.org>
19049
19050         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
19051
19052 2003-05-20  Karl Berry  <karl@gnu.org>
19053
19054         * config/config.guess: update from prep.
19055
19056 2003-05-18  Karl Berry  <karl@gnu.org>
19057
19058         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
19059         might actually be set by the user.
19060
19061         * config/depcomp, install-sh, mdate-sh: update from automake.
19062
19063 2003-05-17  Bruno Haible  <bruno@clisp.org>
19064
19065         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
19066         invalid expansion for AC_EGREP_CPP.
19067         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
19068         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
19069         Suggested by Akim Demaille <akim@epita.fr> in
19070         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
19071
19072 2003-05-12  Jim Meyering  <jim@meyering.net>
19073
19074         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
19075         the space-padded-by-default conversion specifiers, %e, %k, %l.
19076
19077 2003-05-12  Bruno Haible  <bruno@clisp.org>
19078
19079         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
19080         the string is longer than 4 KB.
19081
19082 2003-05-11  Karl Berry  <karl@gnu.org>
19083
19084         * config/config.{guess,sub}: update from prep.
19085
19086 2003-05-09  Bruno Haible  <bruno@clisp.org>
19087
19088         * modules/error: Add m4/strerror_r.m4 to file list.
19089
19090 2003-05-03  Bruno Haible  <bruno@clisp.org>
19091
19092         Upgrade to Unicode-4.0.
19093         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
19094         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
19095         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
19096         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
19097         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
19098         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
19099         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
19100         Change width of U+E0100..U+E01EF from 1 to 0.
19101
19102 2003-04-25  Jim Meyering  <jim@meyering.net>
19103
19104         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
19105         of type size_t, not int.
19106
19107 2003-04-25  Bruno Haible  <bruno@clisp.org>
19108
19109         * lib/copy-file.c: Include <stddef.h>, for size_t.
19110
19111 2003-04-21  Paul Eggert  <eggert@twinsun.com>
19112
19113         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
19114         code which expansion is under static control.  Patch imported from
19115         Akim Demaille's patch to Bison; see
19116         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
19117
19118 2003-04-14  Bruno Haible  <bruno@clisp.org>
19119
19120         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
19121
19122 2003-04-11  Jim Meyering  <jim@meyering.net>
19123
19124         Merge changes from Coreutils.
19125
19126         2003-03-22  Jim Meyering  <jim@meyering.net>
19127
19128         * lib/strftime.c (widen): Cast alloca return value to proper type.
19129
19130         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
19131
19132         From GNU libc.
19133         * lib/strftime.c (my_strftime): Handle very large width
19134         specifications for numeric values correctly.  Improve checks for
19135         overflow.
19136
19137         2003-01-19  Jim Meyering  <jim@meyering.net>
19138
19139         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
19140         definitions.
19141         (nl_get_alt_digit) [! defined my_strftime]: Define.
19142         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
19143         _nl_get_alt_digit and _nl_get_walt_digit.
19144
19145         * lib/strftime.c (my_strftime): Merge in locale-related changes from
19146         libc. These changes have no effect outside of _LIBC.
19147
19148 2003-04-10  Bruno Haible  <bruno@clisp.org>
19149
19150         * modules/findprog: New file.
19151         * MODULES.html.sh (func_all_modules): Add it.
19152
19153 2003-04-10  Bruno Haible  <bruno@clisp.org>
19154
19155         * m4/findprog.m4: New file.
19156         * m4/eaccess.m4: New file.
19157
19158 2003-04-10  Bruno Haible  <bruno@clisp.org>
19159
19160         * lib/findprog.h: New file, from GNU gettext.
19161         * lib/findprog.c: New file, from GNU gettext.
19162
19163 2003-04-05  Jim Meyering  <jim@meyering.net>
19164
19165         Merge changes from Coreutils.
19166
19167         * lib/exclude.h (PARAMS): Remove definition and uses.
19168         * lib/exclude.c: Remove uses of `PARAMS'.
19169
19170         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
19171         Add test-cases for DOS filenames. Declare program_name.
19172         (main): Set up program_name.  Patch by Rich Dawe.
19173
19174         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19175         error from mntctl.
19176         Use mntctl's return value to drive the entry-processing loop, since
19177         we can't rely on the value of the vmt_length member in the last
19178         entry.  On some systems doing so could result in exhausting
19179         virtual memory.  Based in part on a patch from Mike Jetzer.
19180
19181 2003-04-04  Bruno Haible  <bruno@clisp.org>
19182
19183         * modules/linebreak: New file.
19184         * MODULES.html.sh (func_all_modules): Add it.
19185
19186 2003-04-04  Bruno Haible  <bruno@clisp.org>
19187
19188         * m4/linebreak.m4: New file.
19189
19190 2003-04-04  Bruno Haible  <bruno@clisp.org>
19191
19192         * lib/linebreak.h: New file, from GNU gettext.
19193         * lib/linebreak.c: New file, from GNU gettext with slight
19194         modifications.
19195         * lib/lbrkprop.h: New file, from GNU gettext.
19196
19197 2003-04-03  Bruno Haible  <bruno@clisp.org>
19198
19199         * modules/utf8-ucs4: New file.
19200         * modules/utf16-ucs4: New file.
19201         * modules/ucs4-utf8: New file.
19202         * modules/ucs4-utf16: New file.
19203         * MODULES.html.sh (func_all_modules): Add them.
19204
19205 2003-04-03  Bruno Haible  <bruno@clisp.org>
19206
19207         * m4/utf-ucs4.m4: New file.
19208         * m4/ucs4-utf.m4: New file.
19209
19210 2003-04-03  Bruno Haible  <bruno@clisp.org>
19211
19212         * lib/utf8-ucs4.h: New file, from GNU gettext.
19213         * lib/utf16-ucs4.h: New file, from GNU gettext.
19214         * lib/ucs4-utf8.h: New file, from GNU gettext.
19215         * lib/ucs4-utf16.h: New file, from GNU gettext.
19216
19217 2003-04-02  Bruno Haible  <bruno@clisp.org>
19218
19219         * modules/binary-io: New file.
19220         * MODULES.html.sh (func_all_modules): Add it.
19221
19222 2003-04-02  Bruno Haible  <bruno@clisp.org>
19223
19224         * lib/binary-io.h: New file, from GNU gettext.
19225
19226 2003-04-01  Bruno Haible  <bruno@clisp.org>
19227
19228         * modules/pathname: New file.
19229         * MODULES.html.sh (func_all_modules): Add it.
19230
19231 2003-04-01  Bruno Haible  <bruno@clisp.org>
19232
19233         * lib/pathname.h: New file, from GNU gettext.
19234         * lib/concatpath.c: New file, from GNU gettext.
19235
19236 2003-03-30  Bruno Haible  <bruno@clisp.org>
19237
19238         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
19239
19240 2003-03-30  Bruno Haible  <bruno@clisp.org>
19241
19242         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
19243         function chown() doesn't exist.
19244
19245 2003-03-28  Bruno Haible  <bruno@clisp.org>
19246
19247         * modules/copy-file: New file.
19248         * MODULES.html.sh (func_all_modules): Add it.
19249
19250 2003-03-28  Bruno Haible  <bruno@clisp.org>
19251
19252         * m4/copy-file.m4: New file.
19253
19254 2003-03-28  Bruno Haible  <bruno@clisp.org>
19255
19256         * lib/copy-file.h: New file, from GNU gettext.
19257         * lib/copy-file.c: New file, from GNU gettext.
19258
19259 2003-03-18  Jim Meyering  <jim@meyering.net>
19260
19261         * lib/quote.c (quote_n): Fix typo in comment.
19262
19263 2003-03-18  Bruno Haible  <bruno@clisp.org>
19264
19265         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
19266         checking.
19267         * m4/onceonly_2_57.m4: Likewise.
19268
19269 2003-03-17  Bruno Haible  <bruno@clisp.org>
19270
19271         * m4/onceonly.m4: Require autoconf 2.54 or newer.
19272         (m4_quote): Remove macro.
19273         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
19274
19275 2003-03-14  Jim Meyering  <jim@meyering.net>
19276
19277         Merge changes from Coreutils.
19278         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
19279         to be const, in order to avoid warnings.
19280         (obstack_room): Likewise.
19281         (obstack_empty_p): Likewise.
19282
19283 2003-03-14  Bruno Haible  <bruno@clisp.org>
19284
19285         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
19286         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
19287
19288 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19289
19290         Merge changes from Bison.
19291         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
19292         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
19293         when compiling Bison 1.875's `bitset bset = obstack_alloc
19294         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
19295         * lib/hash.c: Include <stdbool.h> unconditionally.
19296
19297 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19298
19299         * m4/onceonly.m4 (m4_quote): New macro.
19300         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
19301         Quote AC_FOREACH variable-expansions properly.
19302
19303 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19304
19305         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
19306
19307 2003-03-09  Paul Eggert  <eggert@twinsun.com>
19308
19309         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
19310         Reported by Bruce Becker; see:
19311         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
19312
19313 2003-03-03  Paul Eggert  <eggert@twinsun.com>
19314             Bruno Haible  <bruno@clisp.org>
19315
19316         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
19317         Reported by John Hughes, see
19318         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
19319
19320 2003-02-20  Bruno Haible  <bruno@clisp.org>
19321
19322         * MODULES.html.sh (func_all_modules): Add poll.
19323
19324 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19325
19326         * modules/poll: New file.
19327
19328 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19329
19330         * lib/poll_.h: New file.
19331         * lib/poll.c: New file.
19332
19333 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19334
19335         * m4/poll.m4: New file.
19336
19337 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19338
19339         * modules/mathl: New file.
19340
19341 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19342
19343         * lib/mathl.h: New file.
19344         * lib/acosl.c: New file.
19345         * lib/asinl.c: New file.
19346         * lib/atanl.c: New file.
19347         * lib/ceill.c: New file.
19348         * lib/cosl.c: New file.
19349         * lib/expl.c: New file.
19350         * lib/floorl.c: New file.
19351         * lib/frexpl.c: New file.
19352         * lib/ldexpl.c: New file.
19353         * lib/logl.c: New file.
19354         * lib/sincosl.c: New file.
19355         * lib/sinl.c: New file.
19356         * lib/sqrtl.c: New file.
19357         * lib/tanl.c: New file.
19358         * lib/trigl.c: New file.
19359         * lib/trigl.h: New file.
19360
19361 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19362
19363         * m4/mathl.m4: New file.
19364
19365 2003-02-18  Bruno Haible  <bruno@clisp.org>
19366
19367         * MODULES.html.sh (func_all_modules): Add mathl.
19368
19369 2003-02-17  Bruno Haible  <bruno@clisp.org>
19370
19371         * modules/mkdtemp: New module.
19372         * MODULES.html.sh (func_all_modules): Add it.
19373
19374 2003-02-17  Bruno Haible  <bruno@clisp.org>
19375
19376         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
19377
19378 2003-02-17  Bruno Haible  <bruno@clisp.org>
19379
19380         * lib/mkdtemp.h: New file, from GNU gettext.
19381         * lib/mkdtemp.c: New file, from GNU gettext.
19382
19383 2003-02-02  Jim Meyering  <jim@meyering.net>
19384
19385         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
19386         e.g. glibc-2.2.93.
19387
19388 2003-01-31  Bruno Haible  <bruno@clisp.org>
19389
19390         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
19391         'rpl_rename'.
19392         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
19393         'rpl_strnlen'.
19394         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
19395         'rpl_strtod'.
19396         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
19397         'rpl_utime'.
19398
19399 2003-01-31  Bruno Haible  <bruno@clisp.org>
19400
19401         * lib/rename.c: #undef rename before defining rpl_rename.
19402         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
19403
19404 2003-01-30  Bruno Haible  <bruno@clisp.org>
19405
19406         * modules/vasnprintf, modules/vasprintf: New modules.
19407         * MODULES.html.sh (func_all_modules): Add them.
19408
19409 2003-01-30  Bruno Haible  <bruno@clisp.org>
19410
19411         * m4/signed.m4: New file, from GNU gettext.
19412         * m4/longdouble.m4: New file, from GNU gettext.
19413         * m4/wchar_t.m4: New file, from GNU gettext.
19414         * m4/wint_t.m4: New file, from GNU gettext.
19415         * m4/vasnprintf.m4: New file.
19416         * m4/vasprintf.m4: New file.
19417
19418 2003-01-30  Bruno Haible  <bruno@clisp.org>
19419
19420         * lib/printf-args.h: New file, from GNU gettext.
19421         * lib/printf-args.c: New file, from GNU gettext.
19422         * lib/printf-parse.h: New file, from GNU gettext.
19423         * lib/printf-parse.c: New file, from GNU gettext.
19424         * lib/vasnprintf.h: New file, from GNU gettext.
19425         * lib/vasnprintf.c: New file, from GNU gettext.
19426         * lib/asnprintf.c: New file, from GNU gettext.
19427         * lib/vasprintf.h: New file, from GNU gettext with modifications.
19428         * lib/vasprintf.c: New file, from GNU gettext.
19429         * lib/asprintf.c: New file, from GNU gettext.
19430
19431 2003-01-29  Bruno Haible  <bruno@clisp.org>
19432
19433         * modules/stpncpy: New module.
19434         * MODULES.html.sh (func_all_modules): Add it.
19435
19436 2003-01-29  Bruno Haible  <bruno@clisp.org>
19437
19438         * m4/stpncpy.m4: New file.
19439
19440 2003-01-29  Bruno Haible  <bruno@clisp.org>
19441
19442         * lib/stpncpy.h: New file, from GNU gettext with modifications.
19443         * lib/stpncpy.c: New file, from GNU gettext with modifications.
19444
19445 2003-01-28  Bruno Haible  <bruno@clisp.org>
19446
19447         * modules/c-ctype: New module.
19448         * MODULES.html.sh (func_all_modules): Add it.
19449
19450 2003-01-28  Bruno Haible  <bruno@clisp.org>
19451
19452         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
19453         Paul Eggert.
19454         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
19455         Paul Eggert.
19456
19457 2003-01-27  Bruno Haible  <bruno@clisp.org>
19458
19459         * modules/xsetenv: New module.
19460         * MODULES.html.sh (func_all_modules): Add it.
19461
19462 2003-01-27  Bruno Haible  <bruno@clisp.org>
19463
19464         * lib/xsetenv.h: New file, from GNU gettext.
19465         * lib/xsetenv.c: New file, from GNU gettext.
19466
19467 2003-01-23  Jim Meyering  <jim@meyering.net>
19468
19469         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
19470         from working on systems without dirfd (at least Irix and OSF1/Tru64).
19471
19472 2003-01-23  Bruno Haible  <bruno@clisp.org>
19473
19474         * modules/minmax: New module.
19475         * MODULES.html.sh (func_all_modules): Add it.
19476
19477 2003-01-23  Bruno Haible  <bruno@clisp.org>
19478
19479         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
19480         Eggert.
19481
19482 2003-01-22  Bruno Haible  <bruno@clisp.org>
19483
19484         * modules/exit: New module.
19485         * MODULES.html.sh (func_all_modules): Add it.
19486
19487 2003-01-22  Bruno Haible  <bruno@clisp.org>
19488
19489         * lib/exit.h: New file, from GNU gettext.
19490
19491 2003-01-19  Bruno Haible  <bruno@clisp.org>
19492
19493         * gnulib-tool: Recognize option --extract-maintainer.
19494         (func_get_maintainer): New function.
19495         * modules/*: Add Maintainer entry.
19496
19497 2003-01-16  Jim Meyering  <jim@meyering.net>
19498
19499         * m4/regex.m4: The `regex' struct is both input and output.
19500         Initialize it before each use.  Patch by Tim Waugh.
19501
19502 2003-01-16  Bruno Haible  <bruno@clisp.org>
19503
19504         * MODULES.html.sh: Add a table of contents. Add the module name as
19505         leftmost column. Add hyperlinks.
19506
19507 2003-01-15  Bruno Haible  <bruno@clisp.org>
19508
19509         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
19510
19511 2003-01-15  Bruno Haible  <bruno@clisp.org>
19512
19513         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
19514         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
19515         suffix.
19516
19517 2003-01-15  Bruno Haible  <bruno@clisp.org>
19518
19519         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
19520
19521 2003-01-15  Bruno Haible  <bruno@clisp.org>
19522
19523         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
19524         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
19525
19526 2003-01-14  Jim Meyering  <jim@meyering.net>
19527
19528         * lib/same.c (same_name): Tweak a comment.
19529
19530 2003-01-14  Bruno Haible  <bruno@clisp.org>
19531
19532         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
19533         when a string comparison is sufficient.
19534
19535 2003-01-14  Bruno Haible  <bruno@clisp.org>
19536
19537         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
19538         'unsigned int'.
19539
19540 2003-01-14  Bruno Haible  <bruno@clisp.org>
19541
19542         * lib/hash-pjw.c: Add comment about low quality of this function.
19543
19544 2003-01-13  Bruno Haible  <bruno@clisp.org>
19545
19546         * modules/stpcpy: Distribute lib/stpcpy.h.
19547         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
19548
19549 2003-01-13  Bruno Haible  <bruno@clisp.org>
19550
19551         * modules/*: Add a description.
19552         * modules/strpbrk: Fix Makefile.am snippet.
19553         * modules/strtoimax: Fix dependencies.
19554         * modules/strtoumax: Likewise.
19555
19556 2003-01-13  Bruno Haible  <bruno@clisp.org>
19557
19558         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
19559         * modules/alloca (Makefile.am): All object files depend on alloca.h.
19560         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
19561
19562 2003-01-13  Bruno Haible  <bruno@clisp.org>
19563
19564         * gnulib-tool (func_create_testdir): Store config/* files in the main
19565         directory.
19566         * config.rpath: Move to ...
19567         * config/config.rpath: ... here.
19568         * modules/gettext: Contains config/config.rpath, not config.rpath.
19569         * modules/iconv: Likewise.
19570
19571 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19572
19573         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19574         to avoid collisions with libcurses and libreadline.
19575
19576         * m4/getstr.m4: Remove.
19577         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
19578
19579 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19580
19581         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19582         to avoid collisions with libcurses and libreadline.
19583
19584         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
19585         * lib/getstr.h, getstr.c: Remove.
19586         * lib/getline.c: Include "getline.h", to check interface.
19587         Move body of old getstr.c here: this defines MIN_CHUNK and
19588         declares getdelim2, which is renamed from getstr.
19589         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
19590
19591         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
19592         All uses changed.
19593         * lib/linebuffer.h: Likewise.
19594         (readline): Remove backward-compatibility macro.
19595
19596 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19597
19598         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19599         to avoid collisions with libcurses and libreadline.
19600         * getstr: Remove.
19601         * MODULES.html.sh: Remove getstr.
19602         * modules/getline: Depend on unlocked-io, not getstr.
19603
19604 2003-01-12  Jim Meyering  <jim@meyering.net>
19605
19606         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
19607
19608 2003-01-10  Bruno Haible  <bruno@clisp.org>
19609
19610         * modules/alloca: Change Makefile.am requirements. Simplify Include
19611         requirements. Add lib/alloca_.h to file list.
19612
19613 2003-01-10  Bruno Haible  <bruno@clisp.org>
19614
19615         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
19616
19617 2003-01-10  Bruno Haible  <bruno@clisp.org>
19618
19619         * lib/alloca_.h: New file.
19620         * lib/getdate.y: Unconditionally include alloca.h.
19621         * lib/makepath.c: Likewise.
19622         * lib/setenv.c: Likewise.
19623         * lib/userspec.c: Likewise.
19624
19625 2003-01-09  Karl Berry  <karl@gnu.org>
19626
19627         * MODULES.html.sh: include `dirname $0` in PATH, to find
19628         gnulib-tool.
19629
19630 2003-01-09  Bruno Haible  <bruno@clisp.org>
19631
19632         * modules/stdbool: Change configure.ac, Makefile.am requirements.
19633         Simplify Include requirements. Add lib/stdbool.h.in to file list.
19634
19635 2003-01-09  Bruno Haible  <bruno@clisp.org>
19636
19637         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
19638
19639 2003-01-09  Bruno Haible  <bruno@clisp.org>
19640
19641         * lib/stdbool.h.in: New file.
19642
19643 2003-01-09  Bruno Haible  <bruno@clisp.org>
19644
19645         * gnulib-tool (func_all_modules): Ignore files ending in ~.
19646         * MODULES.html.sh: Likewise.
19647
19648 2003-01-08  Jim Meyering  <jim@meyering.net>
19649
19650         * lib/full-write.c: Undefine and define-away `const' after inclusion
19651         of errno.h, not before.  Suggestion from Bruno Haible.
19652
19653 2003-01-08  Bruno Haible  <bruno@clisp.org>
19654
19655         * modules/full-read: Depend on full-write.
19656
19657 2003-01-08  Bruno Haible  <bruno@clisp.org>
19658
19659         * lib/safe-read.c: Include specification header first, to ensure its
19660         selfcontainedness.
19661         * lib/full-write.c: Likewise.
19662
19663 2003-01-07  Jim Meyering  <jim@meyering.net>
19664
19665         * lib/full-write.c: Rework so that it may serve to define full_read,
19666         too.
19667         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
19668
19669 2003-01-07  Bruno Haible  <bruno@clisp.org>
19670
19671         * lib/strtoimax.c: Include <stdint.h> as an alternative to
19672         <inttypes.h>.
19673         * lib/xstrtol.h: Likewise.
19674         * lib/xstrtoimax.c: Likewise.
19675         * lib/xstrtoumax.c: Likewise.
19676         * lib/human.h: Likewise.
19677
19678         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
19679         on systems that have <inttypes.h> but not <stdint.h>.
19680
19681 2003-01-07  Bruno Haible  <bruno@clisp.org>
19682
19683         * MODULES.html.sh: Add copyright notice.
19684         (missed_files): Omit CVS directory entries.
19685         (func_module): Make it work with sed-3.02.
19686         * MODULES.txt: Remove file.
19687
19688 2003-01-06  Jim Meyering  <jim@meyering.net>
19689
19690         * lib/version-etc.c: Update year in translatable copyright string.
19691
19692 2003-01-03  Karl Berry  <karl@gnu.org>
19693
19694         * config/config.{guess,sub}: update from prep.
19695
19696 2003-01-02  Karl Berry  <karl@gnu.org>
19697
19698         * doc/COPYING.DOC: belatedly updated to 1.2.
19699
19700 2003-01-01  Karl Berry  <karl@gnu.org>
19701
19702         * gnulib-tool (func_verify_module): report module name $module in
19703         error message, not $1.
19704         * gnulib-tool (create-testdir): don't complain if destdir couldn't
19705         be created, only if it doesn't exist.
19706         * gnulib-tool (last_checkin_date): don't expand the $Date here.
19707
19708 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19709
19710         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
19711
19712 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19713
19714         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
19715         memcmp if strcoll doesn't work.
19716
19717 2002-12-31  Bruno Haible  <bruno@clisp.org>
19718
19719         * lib/utime.c (utime_null): No need to call ftruncate if the file was
19720         nonempty.
19721
19722 2002-12-31  Bruno Haible  <bruno@clisp.org>
19723
19724         * lib/memcoll.c (STRCOLL): New macro.
19725         (memcoll): Use it.
19726
19727 2002-12-31  Bruno Haible  <bruno@clisp.org>
19728
19729         * lib/localcharset.h: New file.
19730         * lib/localcharset.c: Include it.
19731         * lib/unicodeio.c: Likewise.
19732
19733 2002-12-31  Bruno Haible  <bruno@clisp.org>
19734
19735         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
19736         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
19737
19738 2002-12-31  Bruno Haible  <bruno@clisp.org>
19739
19740         * lib/getline.h: Include <stddef.h>, for size_t.
19741
19742         * lib/unicodeio.h: Include <stddef.h>, for size_t.
19743         * lib/unicodeio.c: Don't include <stddef.h>.
19744
19745 2002-12-31  Bruno Haible  <bruno@clisp.org>
19746
19747         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
19748         HAVE_TM_ZONE.
19749
19750 2002-12-24  Karl Berry  <karl@gnu.org>
19751
19752         * config/config.guess: update from prep.
19753
19754 2002-12-24  Bruno Haible  <bruno@clisp.org>
19755
19756         General infrasructure.
19757         * m4/README: Rewritten.
19758         * m4/onceonly.m4: New file.
19759         * m4/onceonly_2_57.m4: New file.
19760
19761         Module atexit.
19762         * m4/atexit.m4: New file.
19763
19764         Module strtod.
19765         * m4/strtod.m4: New file.
19766
19767         Module strtol.
19768         * m4/strtol.m4: New file.
19769
19770         Module strtoul.
19771         * m4/strtoul.m4: New file.
19772
19773         Module memchr.
19774         * m4/memchr.m4: New file.
19775
19776         Module memcmp.
19777         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
19778         (jm_FUNC_MEMCMP): Invoke it.
19779
19780         Module memcpy.
19781         * m4/memcpy.m4: New file.
19782
19783         Module memmove.
19784         * m4/memmove.m4: New file.
19785
19786         Module memset.
19787         * m4/memset.m4: New file.
19788
19789         Module strcspn.
19790         * m4/strcspn.m4: New file.
19791
19792         Module strpbrk.
19793         * m4/strpbrk.m4: New file.
19794
19795         Module strstr.
19796         * m4/strstr.m4: New file.
19797
19798         Module strerror.
19799         * m4/strerror.m4: New file.
19800
19801         Module mktime.
19802         * m4/mktime.m4: Renamed from jm-mktime.m4.
19803         (gl_PREREQ_MKTIME): New macro.
19804         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
19805
19806         Module malloc.
19807         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
19808         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
19809         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
19810
19811         Module realloc.
19812         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
19813         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
19814         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
19815
19816         Module strftime.
19817         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
19818         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
19819         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
19820         gl_TM_GMTOFF.
19821         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
19822
19823         Module xalloc.
19824         * m4/xalloc.m4: New file.
19825
19826         Module alloca.
19827         * m4/alloca.m4: New file.
19828
19829         Module putenv.
19830         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
19831         (jm_FUNC_PUTENV): Invoke it.
19832
19833         Module setenv.
19834         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
19835         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
19836         when invoked twice.
19837         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
19838         gt_FUNC_SETENV.
19839
19840         Module memrchr.
19841         * m4/memrchr.m4: New file.
19842
19843         Module stpcpy.
19844         * m4/stpcpy.m4: New file.
19845
19846         Module strcase.
19847         * m4/strcase.m4: New file.
19848
19849         Module strdup.
19850         * m4/strdup.m4: New file.
19851
19852         Module strnlen.
19853         * m4/strnlen.m4: New file.
19854
19855         Module strndup.
19856         * m4/strndup.m4: New file.
19857
19858         Module xstrtod.
19859         * m4/xstrtod.m4: New file.
19860
19861         Module xstrtol.
19862         * m4/xstrtol.m4: New file.
19863
19864         Module getdate.
19865         * m4/getdate.m4: New file.
19866
19867         Module unlocked-io.
19868         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
19869         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
19870         * m4/jm-glibc-io.m4n: Remove file.
19871
19872         Module long-options.
19873         * m4/long-options.m4: New file.
19874
19875         Module md5.
19876         * m4/md5.m4: New file.
19877
19878         Module sha.
19879         * m4/sha.m4: New file.
19880
19881         Module getstr.
19882         * m4/getstr.m4: New file.
19883
19884         Module getline.
19885         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
19886         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
19887         <sys/types.h>, for size_t. Use the function name gnu_getline, not
19888         simply getline. Infoke gl_PREREQ_GETLINE.
19889
19890         Module obstack.
19891         * m4/obstack.m4: New file.
19892
19893         Module hash.
19894         * m4/hash.m4: New file.
19895
19896         Module readtokens.
19897         * m4/readtokens.m4: New file.
19898
19899         Module strverscmp.
19900         * m4/strverscmp.m4: New file.
19901
19902         Module stdbool.
19903         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
19904         OSF/1.
19905
19906         Module strtoll.
19907         * m4/strtoll.m4: New file.
19908
19909         Module strtoull.
19910         * m4/strtoull.m4: New file.
19911
19912         Module strtoimax.
19913         * m4/strtoimax.m4: New file.
19914
19915         Module strtoumax.
19916         * m4/strtoumax.m4: New file.
19917
19918         Module xstrtoimax.
19919         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
19920         jm_AC_PREREQ_XSTRTOIMAX.
19921         Moved the strtol prerequisites to strtol.m4.
19922         Moved the strtoll prerequisites to strtoll.m4.
19923         Moved the strtoimax prerequisites to strtoimax.m4.
19924
19925         Module xstrtoumax.
19926         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
19927         jm_AC_PREREQ_XSTRTOUMAX.
19928         Moved the strtoul prerequisites to strtoul.m4.
19929         Moved the strtoull prerequisites to strtoull.m4.
19930         Moved the strtoumax prerequisites to strtoumax.m4.
19931
19932         Module chown.
19933         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
19934         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
19935
19936         Module dup2.
19937         * m4/dup2.m4: New file.
19938
19939         Module ftruncate.
19940         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
19941         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
19942
19943         Module getgroups.
19944         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
19945         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
19946
19947         Module gettimeofday.
19948         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
19949         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
19950         gl_PREREQ_GETTIMEOFDAY.
19951
19952         Module mkdir.
19953         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
19954         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
19955
19956         Module mkstemp.
19957         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
19958         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
19959         jm_AC_TYPE_UINTMAX_T.
19960         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
19961
19962         Module stat.
19963         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
19964         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
19965
19966         Module lstat.
19967         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
19968         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
19969
19970         Module timespec.
19971         * m4/timespec.m4 (gl_TIMESPEC): New macro.
19972         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
19973         * m4/st_mtim.m4: Indentation.
19974
19975         Module nanosleep.
19976         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
19977         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
19978         gl_PREREQ_NANOSLEEP.
19979
19980         Module regex.
19981         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
19982         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
19983         (gl_REGEX): New macro.
19984
19985         Module rename.
19986         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
19987         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
19988
19989         Module rmdir.
19990         * m4/rmdir.m4: New file.
19991
19992         Module utime.
19993         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
19994         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
19995         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
19996
19997         Module dirname.
19998         * m4/dirname.m4: New file.
19999
20000         Module getopt.
20001         * m4/getopt.m4: New file.
20002
20003         Module unistd-safer.
20004         * m4/unistd-safer.m4: New file.
20005
20006         Module fnmatch.
20007         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
20008         declaration.
20009         (gl_PREREQ_FNMATCH_EXTRA): New macro.
20010         (gl_FUNC_FNMATCH_POSIX): New macro.
20011         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
20012         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
20013         simply fnmatch.
20014
20015         Module exclude.
20016         * m4/exclude.m4: New file.
20017
20018         Module human.
20019         * m4/human.m4: New file.
20020
20021         Module acl.
20022         * m4/acl.m4: Nop.
20023
20024         Module backupfile.
20025         * m4/backupfile.m4: New file.
20026         * m4/d-ino.m4: Indentation.
20027
20028         Module fsusage.
20029         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
20030         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
20031         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
20032
20033         Module dirfd.
20034         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
20035         requirements.
20036
20037         Module euidaccess.
20038         * m4/euidaccess.m4: New file.
20039
20040         Module file-type.
20041         * m4/file-type.m4: New file.
20042
20043         Module fileblocks.
20044         * m4/fileblocks.m4: New file.
20045
20046         Module filemode.
20047         * m4/filemode.m4: New file.
20048
20049         Module isdir.
20050         * m4/isdir.m4: New file.
20051
20052         Module lchown.
20053         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
20054         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
20055
20056         Module makepath.
20057         * m4/makepath.m4: New file.
20058
20059         Module modechange.
20060         * m4/modechange.m4: New file.
20061
20062         Module mountlist.
20063         * m4/mountlist.m4: New file.
20064         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
20065         Indentation.
20066
20067         Module path-concat.
20068         * m4/path-concat.m4: New file.
20069
20070         Module pathmax.
20071         * m4/pathmax.m4: New file.
20072
20073         Module same.
20074         * m4/same.m4: New file.
20075
20076         Module save-cwd.
20077         * m4/save-cwd.m4: New file.
20078
20079         Module savedir.
20080         * m4/savedir.m4: New file.
20081
20082         Module xgetcwd.
20083         * m4/xgetcwd.m4: New file.
20084         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
20085
20086         Module xreadlink.
20087         * m4/xreadlink.m4: New file.
20088
20089         Module safe-read.
20090         * m4/safe-read.m4: New file.
20091
20092         Module safe-write.
20093         * m4/safe-write.m4: New file.
20094
20095         Module closeout.
20096         * m4/closeout.m4: New file.
20097
20098         Module stdio-safer.
20099         * m4/stdio-safer.m4: New file.
20100
20101         Module getpass.
20102         * m4/getpass.m4: New file.
20103
20104         Module getugroups.
20105         * m4/getugroups.m4: New file.
20106
20107         Module group-member.
20108         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
20109         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
20110
20111         Module idcache.
20112         * m4/idcache.m4: New file.
20113
20114         Module userspec.
20115         * m4/userspec.m4: New file.
20116
20117         Module gettime.
20118         * m4/clock_time.m4: New file.
20119         * m4/gettime.m4: New file.
20120
20121         Module settime.
20122         * m4/settime.m4: New file.
20123
20124         Module posixtm.
20125         * m4/posixtm.m4: New file.
20126
20127         Module gethostname.
20128         * m4/gethostname.m4: New file.
20129
20130         Module canon-host.
20131         * m4/canon-host.m4: New file.
20132
20133         Module gettext.
20134         * m4/codeset.m4: New file, from gettext-0.11.5.
20135         * m4/gettext.m4: New file, from gettext-0.11.5.
20136         * m4/glibc21.m4: New file, from gettext-0.11.5.
20137         * m4/iconv.m4: New file, from gettext-0.11.5.
20138         * m4/intdiv0.m4: New file, from gettext-0.11.5.
20139         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
20140         * m4/inttypes.m4: New file, from gettext-0.11.5.
20141         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
20142         * m4/isc-posix.m4: New file, from gettext-0.11.5.
20143         * m4/lcmessage.m4: New file, from gettext-0.11.5.
20144         * m4/lib-ld.m4: New file, from gettext-0.11.5.
20145         * m4/lib-link.m4: New file, from gettext-0.11.5.
20146         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
20147         * m4/progtest.m4: New file, from gettext-0.11.5.
20148         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
20149         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
20150         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
20151
20152         Module localcharset.
20153         * m4/localcharset.m4: New file.
20154
20155         Module hard-locale.
20156         * m4/hard-locale.m4: New file.
20157
20158         Module mbswidth.
20159         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
20160         onceonly macros.
20161         * m4/mbrtowc.m4: Add comment.
20162
20163         Module memcasecmp.
20164         * m4/memcasecmp.m4: New file.
20165
20166         Module memcoll.
20167         * m4/memcoll.m4: New file.
20168
20169         Module unicodeio.
20170         * m4/unicodeio.m4: New file.
20171
20172         Module rpmatch.
20173         * m4/rpmatch.m4: New file.
20174
20175         Module yesno.
20176         * m4/yesno.m4: New file.
20177
20178         Module exitfail.
20179         * m4/exitfail.m4: New file.
20180
20181         Module c-stack.
20182         * m4/c-stack.m4 (gl_C_STACK): New macro.
20183         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
20184
20185         Module error.
20186         * m4/error.m4 (gl_ERROR): New macro.
20187         (jm_PREREQ_ERROR): Use onceonly macros.
20188
20189         Module fatal.
20190         * m4/fatal.m4: New file.
20191
20192         Module getloadavg.
20193         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
20194         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
20195
20196         Module getpagesize.
20197         * m4/getpagesize.m4: New file.
20198
20199         Module getusershell.
20200         * m4/getusershell.m4: New file.
20201
20202         Module physmem.
20203         * m4/physmem.m4: New file.
20204
20205         Module posixver.
20206         * m4/posixver.m4: New file.
20207
20208         Module quotearg.
20209         * m4/quotearg.m4: New file.
20210
20211         Module quote.
20212         * m4/quote.m4: New file.
20213
20214         Module readutmp.
20215         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
20216
20217         Module sig2str.
20218         * m4/sig2str.m4: New file.
20219
20220         Other.
20221         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
20222         ulonglong.m4.
20223         * m4/intmax_t.m4: New file.
20224         * m4/d-type.m4: Indentation.
20225         * m4/jm-macros.m4: Update.
20226         * m4/prereq.m4 (jm_PREREQ): Update.
20227         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
20228         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
20229         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
20230         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
20231         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
20232         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
20233         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
20234         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
20235         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
20236         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
20237         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
20238         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
20239         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
20240         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
20241         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
20242         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
20243         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
20244         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
20245         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
20246
20247 2002-12-24  Bruno Haible  <bruno@clisp.org>
20248
20249         * MODULES.txt: Update according to m4/ changes.
20250
20251         Module gettext.
20252         * config.rpath: New file, from gettext-0.11.5.
20253
20254         * modules/*: New module descriptions.
20255         * gnulib-tool: New file.
20256         * MODULES.html.sh: New file.
20257
20258 2002-12-21  Karl Berry  <karl@gnu.org>
20259
20260         * doc/fdl.texi: update to version 1.2.
20261
20262 2002-12-19  Karl Berry  <karl@gnu.org>
20263
20264         * config/config.guess: update from prep.
20265
20266 2002-12-18  Bruno Haible  <bruno@clisp.org>
20267
20268         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
20269         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
20270
20271 2002-12-17  Bruno Haible  <bruno@clisp.org>
20272
20273         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
20274         stdlib.h, string.h.
20275
20276 2002-12-17  Bruno Haible  <bruno@clisp.org>
20277
20278         * lib/canon-host.c (strdup): Remove unused declaration.
20279
20280         * lib/fsusage.c: Include full_read.h.
20281         (get_fs_usage): Use full_read instead of safe_read.
20282
20283         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
20284
20285 2002-12-12  Karl Berry  <karl@gnu.org>
20286
20287         * config/config.guess: update from prep.
20288
20289 2002-12-11  Bruno Haible  <bruno@clisp.org>
20290
20291         * m4/setenv.m4: New file, from gettext-0.11.5.
20292
20293 2002-12-11  Bruno Haible  <bruno@clisp.org>
20294
20295         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
20296         not unsetenv().
20297         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
20298         modifications:
20299
20300         2002-12-11  Bruno Haible  <bruno@clisp.org>
20301
20302                 * setenv.c (alloca): Fall back to malloc.
20303                 (freea): New macro.
20304                 (setenv): Use freea() to free memory allocated with alloca().
20305
20306         2002-11-13  Bruno Haible  <bruno@clisp.org>
20307
20308                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
20309                 function declarations.
20310                 * unsetenv.c (unsetenv): Likewise.
20311
20312         2002-03-04  Bruno Haible  <bruno@clisp.org>
20313
20314                 Portability to AIX 4.3.3.
20315                 * unsetenv.c: New file, extracted from setenv.c.
20316                 * setenv.c: Move the unsetenv() function to unsetenv.c.
20317
20318         2001-12-20  Bruno Haible  <bruno@clisp.org>
20319
20320                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
20321                 use malloc instead. For SunOS 4.
20322
20323         2001-12-11  Bruno Haible  <bruno@clisp.org>
20324
20325                 * setenv.c: Declare alloca.
20326                 (compar_fn_t): New typedef.
20327                 (KNOWN_VALUE, STORE_VALUE): Use it.
20328
20329         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
20330         setenv.h.
20331
20332 2002-12-10  Paul Eggert  <eggert@twinsun.com>
20333
20334         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
20335         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
20336         Choose values that are less likely to collide with system fnmatch
20337         options.
20338         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
20339         defined (e.g., a pure POSIX system).
20340         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
20341         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
20342
20343 2002-12-06  Paul Eggert  <eggert@twinsun.com>
20344
20345         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
20346         a pain in practice to deal with generated m4 files.  This change
20347         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
20348
20349         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
20350         and jm-glibc-io.m4, as they are no longer a special case.
20351         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
20352         kludge and the auto-generation stuff.  Check only whether the
20353         functions are declared, not whether they exist, since older hosts
20354         that don't declare the functions can't use the optimization anyway.
20355
20356 2002-12-06  Jim Meyering  <jim@meyering.net>
20357
20358         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
20359
20360         Merge in changes from libc's misc/error.c, in preparation
20361         for the merge of gnulib's changes back into libc.
20362
20363         * lib/error.c (_): Define only if not already defined.
20364         Move definition to follow all #include directives.
20365         Include unlocked-io.h only if !_LIBC.
20366         [_LIBC]: Include <libio/libioP.h>.
20367         [USE_IN_LIBIO]: Include <libio/iolibio.h>
20368         (fflush): Tweak definition to use INTUSE.
20369         (putc): Define.
20370
20371 2002-12-05  Paul Eggert  <eggert@twinsun.com>
20372
20373         * lib/alloca.c [defined emacs]: Include "lisp.h".
20374         (xalloc_die) [defined emacs]: New macro.
20375         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
20376         [! defined emacs]: Include <xalloc.h>.
20377         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
20378         (pointer): Typedef to POINTER_TYPE *.
20379         (malloc): Remove decl; we now always use xmalloc.
20380         (alloca): Use old-style definition, since Emacs needs this.
20381         Check for arithmetic overflow when computing combined size.
20382
20383 2002-12-04  Paul Eggert  <eggert@twinsun.com>
20384
20385         Do not generate unlocked-io.h automatically, since it's easier to
20386         maintain it by hand.
20387
20388         * lib/unlocked-io.h: New file, from GNU diffutils,
20389         but with proper copyright notice and attribution.
20390         * lib/gen-uio: Remove.
20391         * lib/Makefile.am: Add copyright notice.
20392         (libfetish_a_SOURCES): Add unlocked-io.h.
20393         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
20394         (DISTCLEANFILES, io_functions): Remove macros.
20395         (EXTRA_DIST): Remove gen_uio.
20396         (unlocked-io.h): Remove rule.
20397
20398 2002-12-04  Jim Meyering  <jim@meyering.net>
20399
20400         Reflect the fact that stat.c and lstat.c are no longer generated.
20401         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
20402         (DISTCLEANFILES): Likewise.
20403         (EXTRA_DIST): Likewise.
20404         (all_local): Don't depend on stat.c or lstat.c.
20405         (stat.c, lstat.c): Remove rules.
20406         (EXTRA_DIST): Remove xstat.in.
20407
20408         * lib/xstat.in: Remove file.  Contents moved into stat.c.
20409         * lib/stat.c: New file.  Contents mostly from xstat.in.
20410         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
20411         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
20412
20413         * lib/safe-read.c: Rework so that it may serve to define safe_write,
20414         too.
20415         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
20416
20417 2002-12-03  Jim Meyering  <jim@meyering.net>
20418
20419         * lib/safe-read.c, safe-write.c: Change variable names and comments,
20420         but not semantics, to minimize the differences between these two files.
20421         (safe_read): Change comment to mention SAFE_READ_ERROR.
20422
20423         * lib/safe-read.c (IS_EINTR): Define.
20424         (safe_read): Use IS_EINTR in place of in-function cpp directives.
20425
20426 2002-12-02  Jim Meyering  <jim@meyering.net>
20427
20428         * lib/safe-read.c (EINTR): Define.
20429         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20430         (INT_MAX): Provide fallback.
20431         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
20432
20433         * lib/safe-read.h (SAFE_READ_ERROR): Define.
20434
20435 2002-12-02  Bruno Haible  <bruno@clisp.org>
20436
20437         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
20438         Define, taken from safe-read.c.
20439         (INT_MAX): Provide fallback.
20440         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
20441         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
20442
20443         * lib/safe-read.c (EINTR): Remove definition.
20444         (safe_read): Don't use EINTR if it is absent.
20445
20446 2002-12-01  Jim Meyering  <jim@meyering.net>
20447
20448         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
20449         zero.
20450         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
20451
20452 2002-11-27  Paul Eggert  <eggert@twinsun.com>
20453
20454         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
20455         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
20456         with `if (! (value < limit)) abort ();', for readability.
20457
20458 2002-11-26  Karl Berry  <karl@gnu.org>
20459
20460         * lib/strdup.c: copy from libc again, with jim's ok.
20461         * lib/.cppi-disable: re-add strdup.c
20462
20463 2002-11-25  Karl Berry  <karl@gnu.org>
20464
20465         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
20466         instead of "strtol.c".
20467
20468 2002-11-25  Karl Berry  <karl@gnu.org>
20469
20470         * config/install-sh: update from automake for variable quoting, $0 in
20471         error msgs, etc.
20472
20473         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
20474         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
20475         entry.
20476
20477 2002-11-25  Jim Meyering  <jim@meyering.net>
20478
20479         * lib/mktime.c: Sync from libc, now that it has the latest fix.
20480
20481 2002-11-24  Karl Berry  <karl@gnu.org>
20482
20483         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
20484         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
20485
20486 2002-11-24  Jim Meyering  <jim@meyering.net>
20487
20488         Update from coreutils:
20489
20490         * lib/mktime.c: Merge in changes from libc.
20491
20492         Avoid a link-time failure on some Linux systems.
20493         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
20494         (otherwise).
20495         (__mon_yday): Declare with the STATIC attribute.
20496         (__mktime_internal): Likewise.
20497         Based on a report from Greg Schafer.
20498
20499 2002-11-23  Jim Meyering  <jim@meyering.net>
20500
20501         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
20502         Use `unsigned', not `int', as type of index.
20503
20504         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
20505
20506         * lib/fsusage.c: Remove unneeded parentheses around operands of
20507         `defined'.
20508
20509 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20510
20511         * lib/quotearg.h: Allow multiple inclusion by surrounding with
20512         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
20513         so that we can be included first.
20514         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
20515         * lib/quotearg.c: Include quotearg.h immediately after config.h.
20516         No need to include stddef.h or sys/types.h any more.
20517         Surround local include files with "", not "<>".
20518         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
20519         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
20520         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
20521         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
20522         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
20523         (ISPRINT): Remove; no longer needed now that we assume C89.
20524
20525         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
20526         Preserve errno.
20527
20528         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
20529         quotearg_char): Use SIZE_MAX rather than
20530         (size_t) -1 when we are talking about "infinity".
20531
20532         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
20533
20534 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20535
20536         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
20537         hint that one should use `if (! x) abort ();' rather than `assert
20538         (x);', and anyway it's one less thing to worry about configuring.
20539         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
20540         hash_rehash, hash_insert): Use abort rather than assert.
20541
20542 2002-11-22  Bruno Haible  <bruno@clisp.org>
20543
20544         * lib/safe-read.h: Assume C89. Add comments.
20545         (safe_read): Change return type to size_t.
20546         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
20547         byte counts > SSIZE_MAX correctly.
20548         * lib/safe-write.h: New file.
20549         * lib/safe-write.c: New file.
20550         * lib/full-read.h: New file.
20551         * lib/full-read.c: New file.
20552         * lib/full-write.h: Assume C89. Add comments.
20553         * lib/full-write.c: Include safe-write.h.
20554         (full_write): Rewritten to use safe_write.
20555         Suggested by Jim Meyering and Paul Eggert.
20556
20557 2002-11-21  Jim Meyering  <jim@meyering.net>
20558
20559         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
20560
20561         Merge in changes from the coreutils.
20562
20563         2002-09-25  Paul Eggert  <eggert@twinsun.com>
20564         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
20565         <stdint.h>.
20566         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
20567         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
20568         int.  Work more efficiently if X is the same width as uintmax_t.
20569         Do not compare X to -1, to avoid bogus compiler warning.
20570         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
20571         Don't assume that f_frsize and f_bsize are the same type.
20572
20573         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
20574         warning on FreeBSD.
20575
20576         * lib/makepath.c (make_path): Restore umask *before* creating the final
20577         component.
20578         (make_path): Minor reformatting.
20579
20580         * lib/xmalloc.c: Adjust to work with new autoconf macros,
20581         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
20582         HAVE_MALLOC/HAVE_REALLOC.
20583
20584         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
20585         dummy ones.  At least on GNU/Linux systems, `auto' means something
20586         else.
20587         From Michael Stone.
20588
20589 2002-11-21  Bruno Haible  <bruno@clisp.org>
20590
20591         Remove case insensitive option matching.
20592         * lib/argmatch.h (argcasematch): Remove declaration.
20593         (ARGCASEMATCH): Remove macro.
20594         (__xargmatch_internal): Remove case_sensitive argument.
20595         (XARGMATCH): Update.
20596         (XARGCASEMATCH): Remove macro.
20597         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
20598         case_sensitive argument.
20599         (argcasematch): Remove function.
20600         (__xargmatch_internal): Remove case_sensitive argument.
20601         (main): Use XARGMATCH instead of XARGCASEMATCH.
20602
20603         * lib/xmalloc.c: Change compile-time error message. Add comment about
20604         required autoconf version.
20605
20606 2002-11-20  Paul Eggert  <eggert@twinsun.com>
20607
20608         Merge argmatch cleanups from Bison.  Assume C89.
20609
20610         * lib/argmatch.c: Include config.h here, not in argmatch.h.
20611         Include stdlib.h, for EXIT_FAILURE.
20612         Always include <string.h>, since we assume C89.
20613         (EXIT_FAILURE): Remove pre-C89 bug workaround.
20614         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
20615         Include <stddef.h> instead, since it's all we need for size_t.
20616         (PARAMS): Remove.  All uses removed.
20617         (ARRAY_CARDINALITY): Do not bother to #undef.
20618         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
20619         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20620         Remove unnecessary parentheses.
20621         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20622         Insert necessary parentheses.
20623         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
20624         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
20625
20626 2002-11-19  Bruno Haible  <bruno@clisp.org>
20627
20628         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
20629         * lib/mbswidth.h: Include <stddef.h>, for size_t.
20630
20631         * lib/mbswidth.h (PARAMS): Remove macro.
20632         (mbswidth, mbsnwidth): Use ANSI C function declarations.
20633         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
20634
20635         * lib/gcd.h (PARAMS): Remove macro.
20636         (gcd): Use ANSI C function declarations.
20637         * lib/gcd.c (gcd): Likewise.
20638
20639 2002-11-15  Bruno Haible  <bruno@clisp.org>
20640
20641         * lib/strcspn.c: Include <stddef.h>.
20642         (strcspn): Use ANSI C function declaration. Change return type to
20643         size_t. Use NULL.
20644         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
20645         (strpbrk): Use NULL.
20646         * lib/strpbrk.h (PARAMS): Remove macro.
20647         (strpbrk): Use ANSI C function declaration.
20648         * lib/strstr.c: Don't include <sys/types.h>.
20649         * lib/strstr.h (PARAMS): Remove macro.
20650         (strstr): Use ANSI C function declarations.
20651
20652 2002-11-14  Karl Berry  <karl@gnu.org>
20653
20654         * config/mkinstalldirs: `do' on separate line, instead of
20655         `for var; do'.
20656
20657 2002-11-06  Bruno Haible  <bruno@clisp.org>
20658
20659         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
20660         * lib/gcd.c (gcd): Likewise.
20661
20662 2002-11-05  Bruno Haible  <bruno@clisp.org>
20663
20664         * lib/gcd.h: New file, from gettext-0.11.5.
20665         * lib/gcd.c: New file, from gettext-0.11.5.
20666
20667 2002-11-05  Bruno Haible  <bruno@clisp.org>
20668
20669         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20670         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20671         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20672         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20673
20674         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
20675         <libintl.h>.
20676         * lib/makepath.c: Include gettext.h instead of <locale.h> and
20677         <libintl.h>.
20678
20679         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
20680         * lib/human.c: Include gettext.h instead of <libintl.h>.
20681         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
20682         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
20683         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
20684         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
20685         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
20686         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
20687         (textdomain): Remove definition.
20688         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
20689
20690         * lib/long-options.c: Remove include of <libintl.h> and definition of
20691         _.
20692         * lib/same.c: Remove include of <libintl.h> and definition of _.
20693
20694 2002-11-04  Owen Taylor  <otaylor@redhat.com>
20695
20696         * lib/config.charset: A few additions for Solaris.
20697
20698 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20699
20700         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
20701         * lib/localcharset.c (locale_charset): Declare as extern "C".
20702
20703 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20704
20705         * lib/config.charset: msdos in uk_UA uses CP1125.
20706
20707 2002-11-04  Bruno Haible  <bruno@clisp.org>
20708
20709         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
20710         * lib/strcase.h: New file, from GNU gettext-0.11.5.
20711         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
20712         * lib/strstr.h: New file, from GNU gettext-0.11.5.
20713         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
20714
20715 2002-11-04  Bruno Haible  <bruno@clisp.org>
20716
20717         * lib/localcharset.c (locale_charset): Don't return an empty string.
20718
20719 2002-11-04  Bruno Haible  <bruno@clisp.org>
20720
20721         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
20722         aliases.
20723
20724 2002-11-04  Bruno Haible  <bruno@clisp.org>
20725
20726         * lib/config.charset: Update for newest glibc. Add canonical names
20727         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
20728
20729 2002-11-04  Bruno Haible  <bruno@clisp.org>
20730
20731         * lib/config.charset: Add support for NetBSD.
20732
20733 2002-11-04  Bruno Haible  <bruno@clisp.org>
20734
20735         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
20736
20737 2002-11-01  Bruno Haible  <bruno@clisp.org>
20738
20739         * configure.in: Add AC_CONFIG_AUX_DIR call.
20740         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
20741         test/Makefile.
20742         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
20743
20744 2002-09-28  Karl Berry  <karl@gnu.org>
20745
20746         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
20747         installed automake until the next release, since changes have been
20748         made.
20749
20750 2002-09-25  Karl Berry  <karl@gnu.org>
20751
20752         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
20753         * lib/getopt*: copy from libc/posix.
20754         * lib/gettext.h: copy from gettext.
20755         * lib/.cppi-disable: add strdup.c, gettext.h.
20756
20757 2002-09-25  Karl Berry  <karl@gnu.org>
20758
20759         * config/srclist.txt: enable gettext.h check.
20760         * config/config.{guess,sub}: update from prep.
20761         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
20762                 from automake 1.6.3.
20763         See srclist*.
20764
20765 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
20766
20767         * regex.c (PATFETCH): Remove the translating fetch.
20768         (PATFETCH_RAW): Rename to PATFETCH.
20769         (set_image_of_range): New fun.
20770         (SET_RANGE_TABLE_WORK_AREA): Use it.
20771         (regex_compile): Don't translate the pattern chars so eagerly.
20772         Only do it when inserting an `exactn' bytecode or when handling
20773         a char-range.
20774         (mutually_exclusive_p): Avoid empty statement.
20775
20776 2002-07-06  Jim Meyering  <meyering@lucent.com>
20777
20778         * m4/README: Don't mention Makefile.am.in.
20779         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
20780
20781 2002-07-01  Jim Meyering  <meyering@lucent.com>
20782
20783         * lib/c-stack.c: Include sys/time.h.
20784         From Volker Borchert.
20785
20786 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20787
20788         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
20789
20790 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20791
20792         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
20793         New macro.  Use it uniformly instead of
20794         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
20795         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
20796         reported by Vin Shelton.
20797
20798 2002-06-22  Paul Eggert  <eggert@twinsun.com>
20799
20800         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
20801         Do not assume SA_SIGINFO behavior.
20802         Bug reported by Jim Meyering on NetBSD 1.5.2.
20803
20804 2002-06-22  Jim Meyering  <meyering@lucent.com>
20805
20806         * m4/c-stack.m4: New file, from diffutils-2.8.2.
20807         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
20808
20809         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
20810         now that configure.ac uses AC_GNU_SOURCE.
20811         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
20812         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
20813
20814         Update to latest tools.  Suggestions from Paul Eggert.
20815         * m4/stdbool.m4: New file, from diffutils-2.8.2.
20816         * m4/gnu-source.m4: Update from diffutils-2.8.2.
20817         * m4/fnmatch.m4: Likewise.
20818         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
20819         to AC_HEADER_STDBOOL
20820
20821 2002-06-22  Jim Meyering  <meyering@lucent.com>
20822
20823         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
20824         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
20825
20826 2002-06-22  Jim Meyering  <meyering@lucent.com>
20827
20828         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
20829
20830         * lib/exitfail.c, exitfail.h: Likewise.
20831         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
20832
20833         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
20834         of fnmatch.h.
20835         (EXTRA_DIST): Add fnmatch_loop.c.
20836         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
20837
20838         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
20839         * lib/fnmatch.c: Update from diffutils-2.8.2.
20840         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
20841         * lib/fnmatch.h: Remove file.
20842
20843 2002-06-21  Jim Meyering  <meyering@lucent.com>
20844
20845         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
20846         * m4/mbrtowc.m4: Likewise.
20847
20848         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
20849         * m4/mbswidth.m4: Reflect name change:
20850         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
20851         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
20852
20853         * m4/lib-link.m4: Update from gettext-0.11.2.
20854         * m4/gettext.m4: Likewise.
20855
20856         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
20857         From Alfred M. Szmidt.
20858
20859 2002-06-18  Paul Eggert  <eggert@twinsun.com>
20860
20861         * lib/file-type.h: Report an error if neither S_ISREG nor
20862         S_IFREG is defined, instead of using a test specific to glibc
20863         2.2.  This should be safe, since POSIX requires S_ISREG and
20864         Unix Version 7 had S_IFREG.  We don't need to check for
20865         <sys/types.h> since we don't use any symbols that it defines.
20866
20867 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
20868
20869         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
20870         $@-t, so that each temporary file name is unique and valid in the first
20871         8 characters, for operation under DOS.
20872
20873 2002-06-15  Paul Eggert  <eggert@twinsun.com>
20874
20875         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
20876
20877 2002-06-15  Jim Meyering  <meyering@lucent.com>
20878
20879         Work even with DJGPP 2.03, which lacks support for symlinks.
20880         From Richard Dawe.
20881         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
20882         is defined.
20883         * lib/lchown.c (S_ISLNK): Likewise.
20884
20885 2002-06-15  Jim Meyering  <meyering@lucent.com>
20886
20887         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
20888         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
20889         have been included before this file.
20890
20891 2002-06-14  Jim Meyering  <meyering@lucent.com>
20892
20893         * lib/file-type.h: Use the version from diffutils-2.8.2.
20894         * lib/file-type.c: Likewise.
20895
20896 2002-06-07  Jim Meyering  <meyering@lucent.com>
20897
20898         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
20899         They're needed at least for NetBSD 1.5.2.
20900         ($statxfs_includes): Include those same headers.
20901         ($statxfs_includes): Include sys/vfs.h if available.
20902         ($statxfs_includes): Likewise for sys/statvfs.h.
20903         Check for the following members in both structs statfs and statvfs:
20904         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
20905
20906 2002-06-01  Jim Meyering  <meyering@lucent.com>
20907
20908         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
20909         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
20910
20911 2002-05-28  Jim Meyering  <meyering@lucent.com>
20912
20913         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
20914         Reported by Volker Borchert.
20915
20916 2002-05-27  Jim Meyering  <meyering@lucent.com>
20917
20918         Fix a problem seen only on nonconforming systems whereby ls.c's
20919         use of localtime, and then of gettimeofday would cause trouble:
20920         the localtime call used to initialize rpl_gettimeofday's save
20921         mechanism would clobber ls's current local time information so
20922         that in any long listing the first file would always be listed
20923         with date 1970-01-01.  Analysis by Volker Borchert.
20924
20925         * lib/gettimeofday.c (localtime): Undefine.
20926         (rpl_localtime): New function.
20927
20928 2002-05-27  Jim Meyering  <meyering@lucent.com>
20929
20930         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
20931         localtime.
20932
20933         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
20934         use the replacement function; it wouldn't resolve at link time.
20935         Reported by Volker Borchert.
20936
20937 2002-05-22  Jim Meyering  <meyering@lucent.com>
20938
20939         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
20940         file-type.h.
20941         * lib/file-type.h: New file.
20942         * lib/file-type.c (file_type): New file/function.  Extracted from
20943         diffutils.
20944
20945 2002-04-30  Jim Meyering  <meyering@lucent.com>
20946
20947         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
20948
20949 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20950
20951         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
20952
20953 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20954
20955         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
20956         Do not check for alloca.h (no longer used) or stdbool.h (was never
20957         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
20958
20959 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20960
20961         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
20962
20963 2002-04-29  Jim Meyering  <meyering@lucent.com>
20964
20965         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
20966         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
20967         Use AC_FUNC_STRNLEN here instead.
20968
20969         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
20970         With autoconf-2.53a, it's part of AC_PROG_CC.
20971
20972 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20973
20974         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
20975         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
20976
20977 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20978
20979         * lib/sig2str.h, lib/sig2str.c: New files.
20980         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
20981
20982 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20983
20984         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
20985         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
20986         of 127, since 64 is the largest conceivable number for ancient
20987         nonstandard hosts.
20988         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
20989
20990 2002-04-28  Jim Meyering  <meyering@lucent.com>
20991
20992         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
20993
20994 2002-04-24  Jim Meyering  <meyering@lucent.com>
20995
20996         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
20997         (jm_PREREQ): Use it.
20998
20999         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
21000         mach/mach.h fcntl.h.
21001         Check for this function: setlocale.
21002
21003 2002-04-24  Jim Meyering  <meyering@lucent.com>
21004
21005         * lib/gettext.h: New file, from Gettext.
21006         * lib/Makefile.am (INCLUDES): Remove -I../intl.
21007         (libfetish_a_SOURCES): Add gettext.h.
21008
21009 2002-04-16  Jim Meyering  <meyering@lucent.com>
21010
21011         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
21012         ut_pid, ut_id, ut_exit.
21013
21014 2002-04-16  Jim Meyering  <meyering@lucent.com>
21015
21016         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
21017         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
21018         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
21019
21020 2002-04-12  Jim Meyering  <meyering@lucent.com>
21021
21022         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
21023         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
21024         existence of the getmntinfo function.  Needed for Darwin 5.3.
21025
21026         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
21027         This is necessary at least on Darwin 5.3.
21028
21029         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
21030         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
21031         strnlen.o in the library, and that makes some versions of ranlib
21032         object.
21033
21034 2002-04-12  Jim Meyering  <meyering@lucent.com>
21035
21036         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
21037
21038 2002-04-09  Jim Meyering  <meyering@lucent.com>
21039
21040         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
21041         to be more precise.  Rather than saying we're checking whether the
21042         function `works', say what we're testing.
21043         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
21044         Reported by Bruno Haible.
21045
21046 2002-03-10  Jim Meyering  <meyering@lucent.com>
21047
21048         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
21049         Suggestion from Santiago Vila.
21050
21051 2002-03-08  Jim Meyering  <meyering@lucent.com>
21052
21053         * lib/rename.c: Mention that this wrapper is needed also on
21054         mips-dec-ultrix4.4 systems.
21055
21056 2002-03-02  Jim Meyering  <meyering@lucent.com>
21057
21058         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
21059         not HAVE_CLOCK_SETTIME.
21060
21061 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21062
21063         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
21064         Check for clock_settime.
21065
21066 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21067
21068         * lib/nanosleep.h: Rename to....
21069         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
21070
21071         * lib/gettime.c: New file.
21072         * lib/settime.c: New file.
21073         * lib/stime.c: Remove.
21074
21075         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
21076         timespec.h.  Remove nanosleep.h.
21077
21078 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21079
21080         * m4/acl.m4: New file.
21081         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
21082         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
21083
21084 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21085
21086         * lib/acl.c, lib/acl.h: New files.
21087         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
21088
21089 2002-02-24  Jim Meyering  <meyering@lucent.com>
21090
21091         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
21092         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
21093         cause trouble.  Reported by Nelson Beebe.
21094
21095 2002-02-23  Paul Eggert  <eggert@twinsun.com>
21096
21097         * lib/path-concat.c (xpath_concat): Reorder code to pacify
21098         compilers that don't know that xalloc_die never returns.
21099
21100 2002-02-20  Jim Meyering  <meyering@lucent.com>
21101
21102         * lib/getdate.c: Regenerate using bison-1.33.
21103
21104 2002-02-17  Jim Meyering  <meyering@lucent.com>
21105
21106         * config/config.guess (main): Don't use `head -1'; it's no longer
21107         portable. Use `sed 1q' instead.
21108
21109 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
21110
21111         * m4/codeset.m4: Upgrade to gettext-0.11.
21112         * m4/gettext.m4: Upgrade to gettext-0.11.
21113         * m4/glibc21.m4: Upgrade to gettext-0.11.
21114         * m4/iconv.m4: Upgrade to gettext-0.11.
21115         * m4/isc-posix.m4: Upgrade to gettext-0.11.
21116         * m4/lcmessage.m4: Upgrade to gettext-0.11.
21117         * m4/lib-ld.m4: New file, from gettext-0.11.
21118         * m4/lib-link.m4: New file, from gettext-0.11.
21119         * m4/lib-prefix.m4: New file, from gettext-0.11.
21120         * m4/progtest.m4: Upgrade to gettext-0.11.
21121
21122 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21123
21124         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
21125         (jm_PREREQ): Use it.
21126
21127 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21128
21129         * lib/posixver.c, lib/posixver.h: New files.
21130         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21131
21132 2002-02-02  Paul Eggert  <eggert@twinsun.com>
21133             Bruno Haible  <bruno@clisp.org>
21134
21135         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
21136         (fwrite_success_callback): New declaration.
21137         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
21138         print_unicode_char. Call failure callback instead of error.
21139         (fwrite_success_callback): New function.
21140         (exit_failure_callback): New function.
21141         (fallback_failure_callback): New function.
21142         (print_unicode_char): Call unicode_to_mb.
21143
21144 2002-01-26  Jim Meyering  <meyering@lucent.com>
21145
21146         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
21147         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
21148
21149 2002-01-26  Jim Meyering  <meyering@lucent.com>
21150
21151         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
21152
21153 2002-01-22  Paul Eggert  <eggert@twinsun.com>
21154
21155         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
21156
21157 2002-01-22  Jim Meyering  <meyering@lucent.com>
21158
21159         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
21160         Otherwise, some versions of automake would omit the rule that makes
21161         Makefile from Makefile.in.
21162
21163 2002-01-21  Paul Eggert  <eggert@twinsun.com>
21164
21165         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
21166         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21167         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
21168         (memcoll): Set errno to zero if there is no error.
21169
21170         * lib/quotearg.c (quotearg_buffer_restyled):
21171         Fix bug with quoting buffers containing NUL when backslashing escapes.
21172         This bug was exposed by the other changes in this patch.
21173         (quotearg_n_options): New arg ARGSIZE.
21174         All callers changed.
21175         (quoting_options_from_style): New function.
21176         (quotearg_n_style): Use it.
21177         (quotearg_n_style_mem): New function.
21178
21179         * lib/quotearg.h (quotearg_n_style_mem): New function.
21180
21181 2002-01-19  Jim Meyering  <meyering@lucent.com>
21182
21183         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
21184         Remove useless quotes: DF_PROG="df".
21185         * m4/strnlen.m4: New file.
21186
21187 2002-01-16  Paul Eggert  <eggert@twinsun.com>
21188
21189         * lib/backupfile.c (ISDIGIT): Comment fix.
21190         * lib/getdate.y (ISDIGIT): Likewise.
21191         * lib/posixtm.c (ISDIGIT, year): Likewise.
21192         * lib/strverscmp.c (ISDIGIT): Likewise.
21193         * lib/userspec.c (ISDIGIT): Likewise.
21194
21195 2002-01-16  Jim Meyering  <meyering@lucent.com>
21196
21197         * lib/getdate.y: Add three semicolons, each just before a closing
21198         brace. Bison (as of version 1.31) no longer papers over that mistake.
21199
21200 2002-01-05  Jim Meyering  <meyering@lucent.com>
21201
21202         * lib/version-etc.c (version_etc_copyright): Update copyright year.
21203
21204 2001-12-19  Paul Eggert  <eggert@twinsun.com>
21205
21206         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
21207         not silently exit merely because the output buffer happens to
21208         have nothing pending.
21209
21210 2001-12-18  Paul Eggert  <eggert@twinsun.com>
21211
21212         See the big note in ../ChangeLog.
21213         * lib/human.c (suffixes): Prefer K to k for 1024.
21214         (generate_suffix_backwards): New function.
21215         (human_readable_inexact): Use it.
21216         * lib/xstrtol.c (__xstrtol): If there is no number but there
21217         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
21218         Accept 'K' as well as 'k'.
21219
21220 2001-12-15  Jim Meyering  <meyering@lucent.com>
21221
21222         * lib/regex.h (__restrict_arr): Update from libc.
21223
21224         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
21225         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
21226         (STREQ): Define.
21227
21228 2001-12-14  Jim Meyering  <meyering@lucent.com>
21229
21230         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
21231         Suggestion from Bruno Haible.
21232
21233 2001-12-10  Jim Meyering  <meyering@lucent.com>
21234
21235         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
21236         xrealloc, Instead, include "xalloc.h".
21237         (initbuffer): Don't cast xmalloc return value to char*.
21238         (readline): Reword comment.
21239         Don't cast xrealloc return value to char*
21240         Return NULL, not 0.
21241
21242 2001-12-09  Jim Meyering  <meyering@lucent.com>
21243
21244         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
21245         about `signed and unsigned type in conditional expression'.
21246         * lib/posixtm.c (posix_time_parse): Likewise.
21247
21248         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
21249
21250         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
21251         to avoid a pedantic warning.
21252
21253         * lib/getstr.c: Don't include assert.h.
21254         (getstr): Remove warning-evoking assertions.
21255         Return -1 if offset parameter is out of bounds.
21256         Change the type of a local from int to size_t.
21257
21258         * lib/strftime.c (my_strftime_localtime_r): Include this function
21259         definition in the `#if ! HAVE_TM_GMTOFF' block.
21260
21261         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
21262         Include xalloc.h instead.
21263
21264 2001-12-02  Jim Meyering  <meyering@lucent.com>
21265
21266         * lib/tempname.c: Don't declare getenv, thus reverting the change of
21267         2001-11-18.  It's no longer necessary, now that stdlib.h is always
21268         included.
21269
21270         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
21271         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
21272
21273 2001-11-30  Akim Demaille  <akim@epita.fr>
21274
21275         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
21276         before being defined.
21277
21278 2001-11-27  Paul Eggert  <eggert@twinsun.com>
21279
21280         * lib/quotearg.h (quotearg_n, quotearg_n_style):
21281         First arg is int, not unsigned.
21282         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
21283         (SIZE_MAX, UINT_MAX): New macros.
21284         (quotearg_n_options): Abort if N is negative.
21285         Avoid overflow check on hosts where size_t is 64 bits and int
21286         is 32 bits, as overflow is impossible there.
21287         Fix off-by-one typo that caused unnecessary reallocation.
21288
21289 2001-11-27  Jim Meyering  <meyering@lucent.com>
21290
21291         * lib/tempname.c: Merge with version from libc.
21292         * lib/regex.c: Likewise.
21293
21294         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
21295         systems for which STDC_HEADERS is 0, it was not included, resulting in
21296         a warning about an integer-to-pointer conversion problem with getenv.
21297         Reported by Volker Borchert.
21298
21299 2001-11-26  Jim Meyering  <meyering@lucent.com>
21300
21301         * lib/gtod.h: Remove file.
21302         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
21303         * lib/gettimeofday.c: Don't include gtod.h.
21304         (GTOD_init): Remove function.
21305         (rpl_gettimeofday): Do its job here instead, rather than aborting.
21306         Suggestion from Volker Borchert.
21307
21308 2001-11-23  Jim Meyering  <meyering@lucent.com>
21309
21310         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
21311         it.
21312         * lib/hash.c (struct hash_table): Define it here instead.
21313
21314 2001-11-22  Jim Meyering  <meyering@lucent.com>
21315
21316         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
21317
21318 2001-11-20  Jim Meyering  <meyering@lucent.com>
21319
21320         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
21321         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
21322
21323 2001-11-19  Jim Meyering  <meyering@lucent.com>
21324
21325         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
21326         directory.  Use "conftestXXXXXX" as the template.
21327         Suggestion from Paul Eggert.
21328
21329         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
21330         immediately, so the test doesn't mistakenly hit the max-open-files
21331         limit.
21332
21333 2001-11-18  Paul Eggert  <eggert@twinsun.com>
21334
21335         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
21336         (TEMPORARIES): New macro.
21337         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
21338         removes an artificial limitation (e.g. HP-UX 10.20, where
21339         TMP_MAX is 17576).
21340
21341 2001-11-18  Jim Meyering  <meyering@lucent.com>
21342
21343         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
21344
21345 2001-11-18  Jim Meyering  <meyering@lucent.com>
21346
21347         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
21348         on SunOS 4.
21349
21350         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
21351         files will be created before anything else.
21352
21353 2001-11-17  Paul Eggert  <eggert@twinsun.com>
21354
21355         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
21356         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
21357
21358 2001-11-17  Jim Meyering  <meyering@lucent.com>
21359
21360         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
21361         Prompted by a report from Bob Proulx.
21362
21363         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
21364         Instead, require UTILS_FUNC_MKSTEMP.
21365
21366 2001-11-17  Jim Meyering  <meyering@lucent.com>
21367
21368         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
21369         Now, that's done as part of AC_FUNC_STRTOD.
21370
21371 2001-11-17  Jim Meyering  <meyering@lucent.com>
21372
21373         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
21374         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
21375         rather than group writable.  Patch by Juan F. Codagnone.
21376
21377         * lib/readtokens.c: Remove explicit declarations of xmalloc and
21378         xrealloc, Instead, include "xalloc.h".
21379
21380         * lib/mountlist.c: Include unlocked-io.h after all system headers.
21381         Remove explicit declarations of xmalloc, xrealloc,
21382         and xstrdup.  Instead, include "xalloc.h".
21383
21384         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
21385         unlocked-io.h.
21386         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
21387         Likewise.
21388         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
21389
21390         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
21391         Reported by Padraig Brady.
21392
21393         * lib/mkstemp.c: #undef mkstemp.
21394         Include config.h.
21395         (rpl_mkstemp): Rename from mkstemp.
21396         Protoize.
21397
21398 2001-11-16  Jim Meyering  <meyering@lucent.com>
21399
21400         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
21401         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
21402         determine the amount of total physical memory, use pstat_getstatic.
21403         HPUX-11 doesn't define _SC_PHYS_PAGES.
21404         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
21405         If sysconf couldn't be used to determine the amount of available
21406         physical memory, use both pstat_getstatic and pstat_getdynamic.
21407         Based on a patch from Bob Proulx.
21408
21409 2001-11-10  Jim Meyering  <meyering@lucent.com>
21410
21411         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
21412         (jm_PREREQ): Use it.
21413
21414 2001-11-09  Jim Meyering  <meyering@lucent.com>
21415
21416         * m4/jm-macros.m4: Require autoconf-2.52f.
21417         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
21418         Use these AC_-prefixed names, not the AM_-prefixed ones.
21419
21420         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
21421
21422 2001-11-05  Jim Meyering  <meyering@lucent.com>
21423
21424         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
21425
21426 2001-11-04  Jim Meyering  <meyering@lucent.com>
21427
21428         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
21429         $DEFS.
21430
21431 2001-11-03  Jim Meyering  <meyering@lucent.com>
21432
21433         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
21434         of AC_DEFUN.
21435
21436         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
21437         know the name of the variable in the macro definition.
21438
21439 2001-11-03  Jim Meyering  <meyering@lucent.com>
21440
21441         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
21442         in argmatch_to_argument call.
21443
21444         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
21445         argument.
21446
21447         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
21448         e.g., a fault due to an attempt to free a NULL pointer.
21449
21450 2001-11-01  Jim Meyering  <meyering@lucent.com>
21451
21452         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
21453         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
21454
21455 2001-11-01  Jim Meyering  <meyering@lucent.com>
21456
21457         * lib/dirfd.c, lib/dirfd.h: New files.
21458         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
21459
21460         * lib/hash.c (hash_print) [TESTING]: Clean up.
21461
21462 2001-10-22  Paul Eggert  <eggert@twinsun.com>
21463
21464         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
21465         to avoid a warning if -Wall.
21466
21467 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
21468
21469         * README: New file
21470         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
21471         (per RMS's instructions, this is now the canonical source)
21472         * lgpl/, gpl/: New directories.
21473
21474 2001-10-21  Paul Eggert  <eggert@twinsun.com>
21475
21476         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
21477
21478 2001-10-21  Jim Meyering  <meyering@lucent.com>
21479
21480         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
21481         this code would end up calling gettext even in packages built
21482         with --disable-nls.
21483         * lib/getopt.c (_): Likewise.
21484         * lib/regex.c (_): Likewise.
21485
21486 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21487
21488         * m4/error.m4 (jm_PREREQ_ERROR):
21489         Do not invoke AC_CHECK_FUNCS with strerror_r, as
21490         AC_FUNC_STRERROR_R does that.
21491         Check for strerror declaration.
21492
21493         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
21494         are supposed to have them these days.
21495         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
21496         Merge changes from latest Autoconf CVS.
21497         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
21498         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
21499         POSIX decided to standardize on the int flavor of strerror_r.
21500
21501 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21502
21503         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
21504         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
21505         Use strerror_r that is only a macro, even if it is not a function.
21506         (strerror): Check for HAVE_DECL_STRERROR before declaring.
21507         (private_strerror): Use prototypes, not old-style function definition.
21508         (print_errno_message): New function.
21509         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
21510         char*-flavored one.
21511         (error_tail, error, error_at_line): Use it.
21512
21513 2001-10-11  Jim Meyering  <meyering@lucent.com>
21514
21515         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
21516         and quote_n (1, ... to avoid clobbering a buffer.
21517
21518 2001-10-05  Jim Meyering  <meyering@lucent.com>
21519
21520         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
21521         hash-pjw.h.
21522         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
21523         * lib/hash-pjw.h: New file.
21524
21525 2001-09-30  Jim Meyering  <meyering@lucent.com>
21526
21527         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
21528         `struct fsstat' has the `f_fstypename' member.
21529         Use that to define FS_TYPE, which is now used to make
21530         the getfsstat link test tighter.
21531
21532 2001-09-30  Jim Meyering  <meyering@lucent.com>
21533
21534         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
21535         Include <sys/ucred.h>, for Apple Darwin.
21536         Include sys/mount.h and sys/fs_types.h only if available.
21537         (FS_TYPE): Define.
21538         (read_filesystem_list): Use FS_TYPE.
21539
21540 2001-09-29  Paul Eggert  <eggert@twinsun.com>
21541
21542         * lib/exclude.c (excluded_filename): 0 -> false, since it's
21543         a boolean context.
21544
21545 2001-09-29  Jim Meyering  <meyering@lucent.com>
21546
21547         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21548         [one-argument getmntent function]): Include stdio.h before mntent.h.
21549         SunOS 4.1.x needs it for the declaration of `FILE'.
21550         Patch by Volker Borchert.
21551
21552         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21553         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
21554         sys/fs_types.h, and make the link-test for getfsstat guard #include
21555         directives with appropriate #if HAVE_*_H tests so that we can
21556         detect getfsstat on Apple Darwin1.3.7 systems.
21557         Reported by Nelson Beebe.
21558         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
21559
21560 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21561
21562         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21563         #defines strtoimax.  Also treat the other strto* functions
21564         like strtoimax.
21565
21566         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21567         Check for strtoul and strtoumax,
21568         as those declarations are made even in the signed case.
21569         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
21570         Likewise, for strtol and strtoimax.
21571
21572 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21573
21574         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21575         #defines strtoimax.  Also treat the other strto* functions
21576         like strtoimax.
21577
21578         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
21579         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
21580         (strtoimax, strtoumax): Do not declare if already defined as a macro.
21581
21582 2001-09-26  Jim Meyering  <meyering@lucent.com>
21583
21584         Most macros in unlocked-io.h had the wrong number of arguments.
21585         * lib/gen-uio: New script.
21586         (USE_UNLOCKED_IO): Define to 1 if not already defined.
21587         * lib/unlocked-io.hin: Remove file.
21588         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
21589         rather than trying to embed it here.
21590         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
21591         Reported by Padraig Brady.
21592
21593 2001-09-25  Volker Borchert  <bt@teknon.de>
21594
21595         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
21596         `result'.
21597
21598 2001-09-24  Jim Meyering  <meyering@lucent.com>
21599
21600         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
21601
21602 2001-09-23  Jim Meyering  <meyering@lucent.com>
21603
21604         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
21605         instead of the mere test for existence of mntent.h.  The latter
21606         would get a false-positive on AIX 3.4 systems.
21607         In the outer getmntent if-block, don't die if neither of the getmntent
21608         tests succeeds.  Instead, just fall through and continue with the
21609         remaining tests.
21610
21611 2001-09-23  Jim Meyering  <meyering@lucent.com>
21612
21613         * lib/mountlist.c: Remove useless parentheses in #if directives.
21614         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
21615         the deprecated MOUNTED symbol is no longer defined in mntent.h.
21616
21617 2001-09-22  Jim Meyering  <meyering@lucent.com>
21618
21619         * m4/gettext.m4: New file.  From gettext.
21620         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
21621         * m4/progtest.m4: Likewise
21622         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
21623         * m4/glibc21.m4: Likewise.
21624
21625         * m4/libintl.m4: Remove.  No longer used.
21626
21627 2001-09-22  Jim Meyering  <meyering@lucent.com>
21628
21629         * lib/localcharset.c: Update from latest gettext.
21630         * lib/config.charset: Likewise.
21631
21632 2001-09-20  Jim Meyering  <meyering@lucent.com>
21633
21634         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
21635         strtoimax.
21636         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
21637         strtoumax.
21638
21639 2001-09-20  Jim Meyering  <meyering@lucent.com>
21640
21641         * lib/xstrtol.c (strtoimax): Guard declaration with
21642         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
21643         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
21644         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
21645         (strtoumax): Likewise, for completeness (it wasn't necessary).
21646
21647 2001-09-17  Paul Eggert  <eggert@twinsun.com>
21648
21649         * lib/strtoimax.c (HAVE_LONG_LONG):
21650         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
21651         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
21652         to work around bug in IBM C compiler.
21653
21654 2001-09-17  Jim Meyering  <meyering@lucent.com>
21655
21656         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
21657         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
21658         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
21659         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
21660         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
21661         whenever the right hand side need not be expanded by the shell.
21662
21663 2001-09-16  Paul Eggert  <eggert@twinsun.com>
21664
21665         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
21666         library.  It's not correct, as some older glibcs are buggy.
21667         fnmatch wasn't fixed until glibc 2.2.
21668
21669         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
21670         special shell magic here.
21671
21672 2001-09-16  Jim Meyering  <meyering@lucent.com>
21673
21674         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
21675         * m4/jm-macros.m4: Require it.
21676
21677 2001-09-16  Jim Meyering  <meyering@lucent.com>
21678
21679         * lib/mkdir.c: New file.
21680
21681 2001-09-15  Jim Meyering  <meyering@lucent.com>
21682
21683         * m4/jm-macros.m4: Check for help2man.
21684
21685 2001-09-11  Jim Meyering  <meyering@lucent.com>
21686
21687         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
21688         The body, by Paul Eggert, was moved here from configure.in.
21689         * m4/jm-macros.m4: Require UTILS_HOST_OS.
21690
21691 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21692
21693         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
21694         (jm_PREREQ): Use it.
21695
21696 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21697
21698         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
21699         Use ssize_t, not int, to store result of readlink.
21700         Check for ssize_t overflow as well as size_t overflow,
21701         as POSIX says the result of readlink is implementation-defined
21702         when ssize_t overflows.
21703         Remove unnecessary cast to char*.
21704         Use free+malloc instead of realloc, as the storage doesn't need
21705         to be preserved and it's clearer and can be more efficient that way.
21706         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
21707         * lib/xreadlink.h (xreadlink): Update prototype.
21708
21709 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21710
21711         * lib/xgetcwd.c: Revert some of the previous change; intead,
21712         fix the HAVE_GETCWD_NULL code to behave more like the
21713         !HAVE_GETCWD_NULL code used to.
21714
21715         Include "xalloc.h".
21716         (xgetcwd): Do not return NULL when memory is exhausted; instead,
21717         invoke xalloc_die.
21718
21719 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21720
21721         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
21722         sys/param.h, as pathmax.h includes them.
21723
21724 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21725
21726         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
21727         (jm_PREREQ_XGETCWD): New macro.
21728
21729         * m4/getcwd.m4: New file.
21730
21731 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21732
21733         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
21734         like the HAVE_GETCWD_NULL code.
21735         Include pathmax.h if not HAVE_GETCWD.
21736         Do not include xalloc.h.
21737         (INITIAL_BUFFER_SIZE): New symbol.
21738         Do not use xmalloc / xrealloc, since the caller is responsible for
21739         handling errors.  Preserve errno around `free' during failure.
21740         Do not overrun buffer when using getwd.
21741
21742 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21743
21744         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
21745         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
21746         getcwd (NULL, 0).
21747
21748 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21749
21750         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
21751         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
21752         spotted by Jim Meyering.
21753
21754 2001-09-03  Jim Meyering  <meyering@lucent.com>
21755
21756         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
21757         failure.
21758
21759 2001-09-02  Jim Meyering  <meyering@lucent.com>
21760
21761         * lib/error.c: Update from GNU libc.
21762
21763 2001-09-01  Jim Meyering  <meyering@lucent.com>
21764
21765         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
21766         Used by df.
21767
21768 2001-09-01  Jim Meyering  <meyering@lucent.com>
21769
21770         * lib/xreadlink.c: New file.
21771         * lib/xreadlink.h: New file.
21772         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
21773         xreadlink.h.
21774
21775         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
21776         doesn't conflict with sparc Solaris 7's definition in
21777         /usr/include/sys/int_types.h.
21778
21779         * lib/exclude.c: Use `""', not `<>' to #include non-system header
21780         files.
21781         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
21782         and strncasecmp as r-values.  Unixware didn't have declarations.
21783
21784 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21785
21786         * lib/xstrtol.h: Add copyright notice.
21787         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
21788         LONGINT_INVALID_SUFFIX_CHAR.
21789
21790 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21791
21792         * lib/xstrtol.c (strtoimax): New decl.
21793
21794 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21795
21796         * lib/xgetcwd.c: Don't include pathmax.h.
21797         Include stdlib.h and unistd.h if available.
21798         Include xalloc.h.
21799         (xmalloc, xstrdup, free): Remove decls.
21800         (xgetcwd): Don't assume sizes fit in unsigned.
21801         Check for overflow when computing sizes.
21802         Simplify reallocation code.
21803
21804 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21805
21806         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
21807         a directory's st_size can have an arbitrary value, so the old
21808         usage could waste an arbitrary amount of memory.  All uses
21809         changed.
21810         * lib/savedir.h: Update prototype.
21811
21812 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21813
21814         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
21815
21816         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
21817         old strtoimax.c.
21818
21819         Also, make the following further changes to make this file's
21820         configuration more similar to that of strtol.c:
21821         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
21822         (strtoumax, uintmax_t, strtoull, strtol): Remove.
21823         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
21824         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
21825         changed to signed values.
21826
21827         And make the following changes as well:
21828         Fix copyright notice, as 1999 was missing.
21829         (verify): New macro.
21830         (strtoimax): Check sizes at compile-time, not run-time.
21831         Prefer strtol to strtoll if both work.
21832         (main): Remove; it was not that useful and was a pain to maintain.
21833
21834         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
21835
21836 2001-08-31  Jim Meyering  <meyering@lucent.com>
21837
21838         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
21839         Use an initial, malloc'd, buffer of length 128 rather than
21840         a statically allocated one of length 1024.
21841
21842 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21843
21844         Simplify code, partly by assuming autoconf 2.52 semantics.
21845
21846         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
21847
21848         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
21849         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
21850         All uses removed.
21851         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
21852         Move AC_REQUIRE to next-to-top level, to avoid confusion.
21853         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
21854         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
21855         jm_AC_HEADER_INTTYPES_H.
21856         * m4/jm-macros.m4 (jm_MACROS): Likewise.
21857
21858         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
21859
21860         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21861         Quote first arg of AC_DEFUN.
21862         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
21863         since they are needed to parse the include file even if we need
21864         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
21865         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
21866         but with opposite signedness.
21867
21868 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21869
21870         Merge 'exclude' changes from tar 1.13.22.
21871         This fixes one or two unlikely storage allocation overflow bugs,
21872         but doesn't change user-visible behavior otherwise.
21873
21874 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21875
21876         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
21877         (jm_PREREQ_EXCLUDE): New macro.
21878
21879 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21880
21881         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
21882         tm to be declared.
21883
21884 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21885
21886         * lib/hash.c: Remove '2001' from copyright notice.
21887
21888 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21889
21890         * lib/full-write.h: New file.
21891         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
21892         * lib/full-write.c: Correct credits, as cccp.c no longer
21893         exists and anyway it was so heavily changed from the old cccp
21894         code as to be unrecognizable.  Include full-write.h.
21895         (full_write) Return size_t, with short writes meaning failure.
21896         All callers changed.  This fixes a bug with large buffers
21897         on 64-bit hosts.
21898         * lib/utime.c: Include full-write.h.
21899
21900 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21901
21902         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
21903         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
21904         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
21905         Include if available.
21906         (<xalloc.h>): Include
21907         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
21908         (verify): New macro.  Use it to verify that EXCLUDE macros do not
21909         collide with FNM macros.
21910         (struct patopts): New struct.
21911         (struct exclude): Use it, as exclude patterns now come with options.
21912         (new_exclude): Support above changes.
21913         (new_exclude, add_exclude_file):
21914         Initial size must now be a power of two to simplify overflow checking.
21915         (free_exclude, fnmatch_no_wildcards): New function.
21916         (excluded_filename): No longer requires options arg, as the options
21917         are determined by add_exclude.  Now returns bool, not int.
21918         (excluded_filename, add_exclude):
21919         Add support for the fancy new exclusion options.
21920         (add_exclude, add_exclude_file): Now takes int options arg.
21921         Check for arithmetic overflow when computing sizes.
21922         (add_exclude_file): xrealloc might modify errno, so don't
21923         realloc until after errno might be used.
21924
21925         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
21926         New macros.
21927         (free_exclude): New decl.
21928         (add_exclude, add_exclude_file): Now takes int options arg.
21929         (excluded_filename): No longer requires options arg, as the options
21930         are determined by add_exclude.  Now returns bool, not int.
21931
21932 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21933
21934         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
21935
21936 2001-08-27  Jim Meyering  <meyering@lucent.com>
21937
21938         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
21939
21940         * lib/version-etc.c (N_): Remove definition.
21941         Revert most of last change.
21942         Instead, simply don't mark the `Copyright...' string for translation.
21943         Based on advice from Paul Eggert.
21944
21945         * lib/strtoxmax.c: Tweak comment.
21946
21947 2001-08-26  Jim Meyering  <meyering@lucent.com>
21948
21949         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
21950
21951         * m4/xstrtoimax.m4: New file.
21952         * m4/xstrtoumax.m4: Add comments explaining why we
21953         AC_REPLACE_FUNCS(strtol).
21954
21955 2001-08-26  Jim Meyering  <meyering@lucent.com>
21956
21957         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
21958         of copyright with `%s' so translators don't get an untranslated
21959         message in 2002.
21960         (COPYRIGHT_YEAR): Define.
21961         (version_etc): Use fprintf rather than fputs.
21962         Suggestion from Ulrich Drepper.
21963
21964         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
21965
21966         * lib/strtoll.c: New file, from GNU libc.
21967         * lib/xstrtoimax.c: New file.
21968
21969         * lib/xstrtol.h: Add xstrtoimax.
21970         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
21971         * lib/strtoimax.c: New file.  Likewise, but first define
21972         STRTOUXMAX_SIGNED.
21973
21974         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
21975         ...
21976         * lib/strtoxmax.c: ... then renamed to this.
21977
21978 2001-08-18  Paul Eggert  <eggert@twinsun.com>
21979
21980         * m4/inttypes.m4: Add AC_PREREQ(2.13).
21981         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
21982         (jm_AC_TYPE_INTMAX_T): New macro.
21983         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
21984
21985         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
21986
21987         * m4/longlong.m4: Renamed from ulonglong.m4.
21988         * m4/inttypes.m4: Renamed from inttypes_h.m4.
21989         * m4/uintmax_t.m4: Removed.
21990
21991 2001-08-13  Paul Eggert  <eggert@twinsun.com>
21992
21993         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
21994         Port to Solaris 8, where 'sed' requires a space after the 'r'
21995         command, and where sh dislikes "$/".  Clean up the spacing a bit.
21996         Redirect output to $tmp just once.
21997
21998 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
21999
22000         * lib/addext.c (<errno.h>): Include.
22001         (errno): Declare if not defined.
22002         (addext): Work correctly when pathconf returns -1 and leaves
22003         errno alone because there is no limit.  Also, work even if
22004         pathconf returns a value greater than SIZE_MAX.
22005
22006 2001-08-12  Jim Meyering  <meyering@lucent.com>
22007
22008         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
22009         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
22010         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
22011         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
22012         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
22013         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
22014         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
22015         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
22016         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
22017         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
22018         utime.m4, utimes.m4, xstrtoumax.m4:
22019         Quote the first argument in each use of AC_DEFUN.
22020
22021 2001-08-12  Jim Meyering  <meyering@lucent.com>
22022
22023         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
22024         Simply `return getcwd (NULL, 0);'.
22025         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
22026         Use 1300 as initial value for length, not PATH_MAX.
22027
22028         * lib/pathmax.h: Clean up cpp syntax.
22029
22030 2001-08-12  Jim Meyering  <meyering@lucent.com>
22031
22032         * lib/gettimeofday.c: New file.
22033         * lib/gtod.h: New file.
22034         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
22035
22036 2001-08-05  Jim Meyering  <meyering@lucent.com>
22037
22038         * m4/jm-macros.m4: Require autoconf-2.52.
22039
22040 2001-08-04  Jim Meyering  <meyering@lucent.com>
22041
22042         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
22043         stmt, to get in sync with glibc.
22044
22045 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22046
22047         The following changes are from gettext 0.10.39 as maintained by
22048         Bruno Haible.
22049
22050         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
22051         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
22052         with inverted sense.  All uses changed.
22053
22054         * lib/mbswidth.c: Don't include <limits.h>.
22055         Include <stdlib.h> and <string.h> unconditionally.
22056         (iswcntrl, mbsinit, ISCNTRL): New macros.
22057         (mbsnwidth): Use K&R style function declarations.
22058         Don't bother checking for MB_LEN_MAX == 1, since the compiler
22059         can optimize it when MB_CUR_MAX == 1.
22060         The width of control characters is zero, not 1.
22061
22062 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22063
22064         The following changes are from gettext 0.10.39 as maintained by
22065         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
22066
22067         * m4/codeset.m4: Upgrade to serial AM1.
22068         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
22069         all uses changed.  Quote first arg of AC_DEFUN.
22070         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
22071
22072         * m4/iconv.m4: Upgrade to serial AM2.
22073         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
22074         Add --with-libconv-prefix.
22075         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
22076         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
22077         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
22078         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
22079         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
22080
22081         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
22082         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
22083         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
22084         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
22085         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
22086         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
22087         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
22088         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
22089         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
22090
22091         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
22092         string.h any more.
22093
22094         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
22095         not the default value.
22096
22097         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
22098         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
22099         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
22100         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
22101         Also check for iswcntrl, used for wcwidth fallback.
22102         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
22103         to Autoconf 2.13.
22104
22105 2001-08-03  Jim Meyering  <meyering@lucent.com>
22106
22107         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
22108         as it was in the original.  Reported by Paul Eggert.
22109
22110 2001-07-16  Jim Meyering  <meyering@lucent.com>
22111
22112         * m4/gettimeofday.m4: New file.
22113         Prompted by a report from Bernhard Baehr.
22114
22115 2001-07-15  Jim Meyering  <meyering@lucent.com>
22116
22117         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
22118         stuff. Now it's in ../Makefile.cfg.
22119
22120 2001-07-15  Jim Meyering  <meyering@lucent.com>
22121
22122         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
22123         (BUILT_SOURCES): Add unlocked-io.h.
22124         (io_functions): Define.
22125         (unlocked-io.h): New rule.
22126         (DISTCLEANFILES): Add unlocked-io.h.
22127         (all-local): Depend on unlocked-io.h, to ensure it is created.
22128
22129         * lib/unlocked-io.hin: New file
22130
22131         * lib/regex.c: Update from glibc.
22132
22133 2001-07-05  Jim Meyering  <meyering@lucent.com>
22134
22135         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
22136         recommendation.
22137         (libfetish_a_SOURCES): Put all .h files here instead.
22138         Remove a thus-exposed (better checks in automake) duplicate and
22139         two unnecessary .h files.
22140
22141 2001-07-04  Jim Meyering  <meyering@lucent.com>
22142
22143         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
22144         that generates jm-glibc-io.m4 so that it doesn't trigger any make
22145         distcheck failure.
22146
22147 2001-07-02  Jim Meyering  <meyering@lucent.com>
22148
22149         The following changes were prompted by suggestions from Bruno Haible.
22150
22151         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
22152         is now generated.
22153         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
22154         definition of EXTRA_DIST.
22155         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
22156         ensure that the generated file is created/updated whenever the list
22157         of $(unlocked_functions) is changed.
22158         (jm-glibc-io.m4): New rule.
22159         (unlocked-io.h): New rule -- currently unused.
22160
22161 2001-06-24  Jim Meyering  <meyering@lucent.com>
22162
22163         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
22164         unmatched right bracket, rather than kludging it with an extra,
22165         falsely-matching quote in a comment.  Patch by Akim Demaille.
22166
22167 2001-06-11  Jim Meyering  <meyering@lucent.com>
22168
22169         * lib/regex.c: Update from GNU libc.
22170
22171 2001-05-27  Jim Meyering  <meyering@lucent.com>
22172
22173         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
22174         Check for ut_type in struct utmp.
22175
22176 2001-05-27  Jim Meyering  <meyering@lucent.com>
22177
22178         * lib/readutmp.h (UT_TYPE): Define.
22179
22180 2001-05-24  Jim Meyering  <meyering@lucent.com>
22181
22182         * lib/argmatch.c: Include "quote.h".
22183         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
22184         quote function.  Reported by Göran Uddeborg.
22185
22186 2001-05-22  Jim Meyering  <meyering@lucent.com>
22187
22188         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
22189         now that we use the package-supplied version unconditionally.
22190         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
22191
22192 2001-05-21  Jim Meyering  <meyering@lucent.com>
22193
22194         * m4/regex.m4: Change a couple backticks to single quotes to avoid
22195         shell syntax errors.
22196
22197 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22198
22199         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
22200
22201 2001-05-20  Paul Eggert  <eggert@twinsun.com>
22202
22203         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
22204         Don't bother to check library strftime, since
22205         we'll be using our own my_strftime function anyway.
22206         Define my_strftime instead of strftime.
22207
22208 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
22209
22210         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
22211         which is not yet declared.
22212
22213 2001-05-15  Jim Meyering  <meyering@lucent.com>
22214
22215         * m4/regex.m4: Use proper quoting so brackets appear in the test
22216         program.
22217         Reported by, and with help from, Bruno Haible.
22218
22219 2001-05-13  Jim Meyering  <meyering@lucent.com>
22220
22221         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
22222         undefined.
22223
22224 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22225
22226         dirname code cleanup.  base_name now behaves more compatibly
22227         with POSIX basename when given file names that have trailing
22228         slashes, and similarly for dir_name.  Add new primitives
22229         base_len and dir_len.  Put the directory-name-related decls
22230         into dirname.h.
22231
22232         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
22233         * lib/backupfile.c (base_name): Likewise.
22234         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
22235         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
22236         * lib/makepath.c (strip_trailing_slashes): Likewise.
22237         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
22238         ISSLASH): Likewise.
22239         * lib/rename.c (strip_trailing_slashes): Likewise.
22240         * lib/same.c (base_name): Likewise.
22241         * lib/stripslash.c (ISSLASH): Likewise.
22242
22243         * lib/addext.c: Include <dirname.h> after size_t is defined.
22244         * lib/backupfile.c: Likewise.
22245
22246         * lib/addext.c (addext): Use base_len to trim redundant
22247         trailing slashes instead of doing it ourselves.
22248         But do not trim the last slash if it is not redundant.
22249
22250         * lib/backupfile.c (find_backup_file_name,
22251         max_backup_version): Use base_len instead of rolling it ourselves.
22252         Handle the case of "" and (on DOS) "C:" correctly.
22253
22254         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
22255         needed. Include <string.h>, <dirname.h>.
22256         (base_name): Allow file names ending in slashes, other than names
22257         that are all slashes.  In this case, return the basename followed
22258         by the slashes.  This is more general, and can be used in places
22259         where the original base_name purposely had an assertion failure.
22260         (base_len): New function.
22261
22262         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
22263         Do not include <assert.h>; no longer needed.
22264         Include xalloc.h.
22265         (memrchr): Remove decl.
22266         (dir_name_r): Remove.
22267         (dir_len): Renamed from dirlen.  All callers changed.
22268         Rewrite in terms of base_name, for simplicity and consistency.
22269         (dir_name): Never return NULL.  All callers changed.
22270         Do not include <stdlib.h> in test program; no longer needed.
22271         return 0; is fine for test program.
22272
22273         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
22274         New macros.
22275         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
22276
22277         * lib/path-concat.c (path_concat): Use base_len to compute
22278         base length, not strlen; this means we cannot rely on memcpy
22279         to null-terminate.
22280
22281         * lib/same.c (STREQ): Remove.
22282         (same_name): Handle the case where the basename ends in trailing '/'.
22283
22284         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
22285         a slash was stripped.  Do not strip the last slash after a
22286         file system prefix.
22287
22288 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22289
22290         * lib/Makefile.am (libfetish_a_SOURCES):
22291         Add strftime.c, since we now compile it on all hosts.
22292
22293         * lib/strftime.c (my_strftime):
22294         Define to nstrftime if emacs, but only if my_strftime is not defined.
22295         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
22296         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
22297         Add one more extra argument: a nanoseconds value.
22298         All uses changed.
22299         (ns): New macro.
22300         (my_strftime function): Add %N format.
22301         (emacs_strftimeu): Renamed from emacs_strftime,
22302         with extra ut argument.
22303
22304 2001-05-09  Paul Eggert  <eggert@twinsun.com>
22305
22306         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
22307
22308 2001-04-21  Jim Meyering  <meyering@lucent.com>
22309
22310         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
22311         doesn't interfere.
22312
22313 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22314
22315         * m4/ftruncate.m4: Check for chsize.
22316         Link with ftruncate.o unconditionally if ftruncate is missing.
22317         This was required when cross-compiling to i586-mingw32msvc.
22318
22319 2001-04-08  Jim Meyering  <meyering@lucent.com>
22320
22321         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
22322         recomputed; that's necessary when the offset spans a DST transition.
22323         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
22324
22325 2001-04-02  Jim Meyering  <meyering@lucent.com>
22326
22327         * lib/regex.h, regex.c: Update from GNU libc.
22328
22329 2001-03-24  Jim Meyering  <meyering@lucent.com>
22330
22331         * m4/jm-macros.m4: Require autoconf-2.49d.
22332
22333 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
22334
22335         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
22336
22337 2001-03-19  Paul Eggert  <eggert@twinsun.com>
22338
22339         * lib/version-etc.c (version_etc_copyright): Update to 2001.
22340
22341 2001-03-17  Jim Meyering  <meyering@lucent.com>
22342
22343         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
22344         now that the version in autoconf is equivalent.
22345         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
22346
22347         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
22348         Suggestion from Akim Demaille.
22349
22350         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
22351         (jm_PREREQ_TEMPNAME): New function.
22352
22353 2001-03-16  Paul Eggert  <eggert@twinsun.com>
22354
22355         * lib/tempname.c (uint64_t): Define to uintmax_t if
22356         not defined, and if UINT64_MAX is not defined.
22357         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
22358         Reported by John David Anglin.
22359
22360 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
22361
22362         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
22363         resolve alias if codeset is empty.
22364         * lib/config.charset (BeOS): Use wildcard syntax.
22365
22366 2001-03-13  Jim Meyering  <meyering@lucent.com>
22367
22368         * lib/path-concat.c (path_concat)
22369         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
22370         concatenating e.g., `C:' and `foo'.
22371         From Bruno Haible.
22372
22373 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22374
22375         * lib/localcharset.c (locale_charset): Don't use
22376         setlocale(LC_CTYPE,NULL). Don't return NULL.
22377         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
22378
22379 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22380
22381         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
22382         support for DOS/DJGPP.
22383
22384 2001-03-01  Paul Eggert  <eggert@twinsun.com>
22385
22386         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
22387         lacks mkstemp.  Compile our own tempname.c if we compile our own
22388         mkstemp.c, as mkstemp relies on tempname.
22389
22390 2001-03-01  Jim Meyering  <meyering@lucent.com>
22391
22392         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
22393         AH_VERBATIM really does output its argument verbatim.
22394
22395 2001-02-28  Paul Eggert  <eggert@twinsun.com>
22396
22397         * lib/Makefile.am (libfetish_a_SOURCES):
22398         Add dup-safer.c, fopen-safer.c.
22399         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
22400
22401         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
22402         * lib/unistd-safer.h: New files.
22403
22404 2001-02-25  Paul Eggert  <eggert@twinsun.com>
22405
22406         The mkstemp replacement is taken from glibc 2.2.2, with some
22407         portability fixes for use outside glibc, as follows:
22408
22409         * lib/tempname.c (struct_stat64): New macro.
22410         (direxists, __gen_tempname): Use it.
22411         This avoids a portability problem with Solaris 8.
22412
22413         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
22414         (<stddef.h>, <stdint.h>, <string.h>):
22415         Include only if STDC_HEADERS || _LIBC.
22416         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
22417         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
22418         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
22419         (__set_errno): Define this macro if <errno.h> doesn't.
22420         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
22421         Define these macros if <stdio.h> doesn't.
22422         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
22423         Define these macros if <sys/stat.h>
22424         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
22425         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
22426         __xstat64): Define if not _LIBC.
22427         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
22428         (__gen_tempname): Invoke gettimeofday only if
22429         HAVE_GETTIMEOFDAY || _LIBC;
22430         otherwise, fall back on plain "time".
22431         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
22432
22433         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
22434
22435         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
22436
22437 2001-02-18  Paul Eggert  <eggert@twinsun.com>
22438
22439         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
22440
22441 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22442
22443         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
22444         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
22445         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
22446         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22447
22448 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22449
22450         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
22451         Remove workaround macros for hosts that have mbrtowc but not
22452         mbstate_t, as we now insist on proper declarations for both
22453         before using mbrtowc.
22454
22455 2001-02-17  Jim Meyering  <meyering@lucent.com>
22456
22457         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
22458         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
22459         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
22460         UnixWare 7.1.1.
22461
22462         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
22463         rather than AC_CACHE_VAL.
22464
22465 2001-02-17  Jim Meyering  <meyering@lucent.com>
22466
22467         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
22468         around included file name.
22469
22470         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
22471
22472         * lib/strftime.c: Update from GNU libc (the only changes were to
22473         comments).
22474
22475 2001-02-17  Jim Meyering  <meyering@lucent.com>
22476
22477         * lib/regex.c: Update from libc.
22478
22479 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
22480
22481         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
22482         clash.
22483
22484 2001-02-16  Paul Eggert  <eggert@twinsun.com>
22485
22486         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
22487         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
22488         Reported by Mark Hounschell via Paul Eggert.
22489
22490 2001-02-07  Jim Meyering  <meyering@lucent.com>
22491
22492         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
22493
22494 2001-02-05  Jim Meyering  <meyering@lucent.com>
22495
22496         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
22497         it includes the patch required for `large file' support with at least
22498         HP-UX's 10.20 /bin/cc.
22499
22500 2001-02-03  Jim Meyering  <meyering@lucent.com>
22501
22502         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
22503         AS_IF, now that it works once again (mysteriously).
22504         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22505
22506 2001-01-30  Jim Meyering  <meyering@lucent.com>
22507
22508         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
22509         * m4/chown.m4: Rename conftestchown to conftest.chown.
22510         * m4/rename.m4: s/conftestdir/conftest.d1/ and
22511         s/conftestdir2/conftest.d2/.
22512         * m4/utimes.m4: s/conftestdata/conftest.data/
22513         Inspired by Pavel Roskin's change in autoconf.
22514
22515 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
22516
22517         * lib/config.charset: Update for FreeBSD 4.2.
22518
22519 2001-01-27  Jim Meyering  <meyering@lucent.com>
22520
22521         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
22522         a use of AS_IF.
22523         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22524
22525 2001-01-26  Jim Meyering  <meyering@lucent.com>
22526
22527         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
22528         quotearg.c includes it.
22529
22530 2001-01-26  Jim Meyering  <meyering@lucent.com>
22531
22532         * lib/quotearg.c: Include stddef.h.
22533         * lib/quote.c: Include stddef.h.
22534         Reported by Axel Kittenberger.
22535
22536         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
22537         line in double quotes so that it evokes a better diagnostic.
22538         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
22539         Reported by Axel Kittenberger.
22540
22541 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
22542
22543         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
22544         as if it was a `charset'.
22545
22546 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22547
22548         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
22549         has const.
22550
22551 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22552
22553         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
22554         to avoid a warning.  Add back 'const' to inptr.
22555
22556 2001-01-20  Jim Meyering  <meyering@lucent.com>
22557
22558         Be sure that headers are checked before used in code compiled
22559         for the type checks.
22560         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
22561         In place of that, invoke jm_CHECK_ALL_TYPES.
22562         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
22563         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
22564         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
22565         The check for ssize_t was mistakenly run before the test for unistd.h.
22566
22567         The configure-time check for stdbool.h was missing.
22568         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
22569         (jm_PREREQ_HASH): New function.
22570
22571 2001-01-17  Jim Meyering  <meyering@lucent.com>
22572
22573         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
22574         for autoconf-2.49c.
22575         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
22576
22577 2001-01-16  Jim Meyering  <meyering@lucent.com>
22578
22579         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
22580         From Bruno Haible.
22581
22582 2001-01-14  Jim Meyering  <meyering@lucent.com>
22583
22584         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
22585         foo and bar.  Create conftestdir/ in the script, not in the C code.
22586         Remove directories in the script, not in the C code.
22587         Remove conftestdir{,2} before trying to create the directory.
22588         Make the entire configure script fail if the mkdir fails.
22589
22590 2001-01-14  Jim Meyering  <meyering@lucent.com>
22591
22592         * lib/rename.c: New file.  From Volker Borchert.
22593         Include stdlib.h, string.h or strings.h, and xalloc.h.
22594         Use strip_trailing_slashes rather than open-coding it.
22595
22596 2001-01-03  Paul Eggert  <eggert@twinsun.com>
22597
22598         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
22599
22600 2001-01-03  Jim Meyering  <meyering@lucent.com>
22601
22602         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
22603         of local `inptr' to avoid warning with some system declarations of
22604         iconv.
22605
22606 2001-01-02  Volker Borchert  <bt@teknon.de>
22607
22608         * m4/rename.m4: New file.
22609         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
22610
22611 2001-01-01  Jim Meyering  <meyering@lucent.com>
22612
22613         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
22614         even on systems with utmpx.h.  It's necessary for the declaration of
22615         utmp's ut_user member.  Reported by Andreas Jaeger.
22616
22617         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
22618         available. They are required for the declarations of getgrgid and
22619         getpwuid resp.
22620         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
22621         Reported by Andreas Jaeger.
22622
22623 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
22624
22625         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
22626         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
22627         so `make install' also works in VPATH builds.
22628
22629 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
22630
22631         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
22632         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
22633         can be used in subdirectories.
22634
22635 2000-12-29  Paul Eggert  <eggert@twinsun.com>
22636
22637         * lib/modechange.c: Do not assume that mode_t uses the
22638         traditional octal encoding.  E.g. "chmod 1 FOO" should set
22639         the other-execute bit of FOO even if S_IXOTH != 1.
22640
22641         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
22642         WOTH, XOTH, ALLM): New macros.
22643         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
22644          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
22645         Use them.
22646         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
22647         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
22648         (mode_compile):
22649         No need to use uintmax_t; unsigned long is long enough.
22650         Don't bother to get suffix since we don't use it.
22651
22652 2000-12-26  Jim Meyering  <meyering@lucent.com>
22653
22654         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
22655         better with autoheader.
22656
22657 2000-12-24  Jim Meyering  <meyering@lucent.com>
22658
22659         * lib/hash.c (is_prime): Return explicit boolean values.
22660         (hash_get_first): Return NULL to appease Irix5.6's 89.
22661         Reported by Nelson Beebe.
22662
22663 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
22664
22665         * lib/localcharset.c (locale_charset): Add support for Win32.
22666
22667 2000-12-18  Paul Eggert  <eggert@twinsun.com>
22668
22669         * lib/physmem.h, lib/physmem.c: New files.
22670
22671         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
22672         (noinst_HEADERS): Add physmem.h.
22673
22674         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
22675         't' for compatibility with Solaris 8 sort.
22676
22677 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
22678
22679         * lib/config.charset: Add support for BeOS.
22680
22681 2000-12-17  Jim Meyering  <meyering@lucent.com>
22682
22683         * m4/dos.m4 (jm_AC_DOS): New file and macro.
22684         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
22685
22686 2000-12-16  Jim Meyering  <meyering@lucent.com>
22687
22688         This bug had a serious impact on chown: `chown N:M FILE' (for integer
22689         N and M) would have treated it like `chown N:N FILE'.
22690
22691         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
22692
22693 2000-12-16  Jim Meyering  <meyering@lucent.com>
22694
22695         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
22696         SHELLS_FILE to a file name that's useful on djgpp systems.
22697         Include stdlib.h.
22698         (ADDITIONAL_DEFAULT_SHELLS): Define.
22699         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
22700         Based mostly on a patch from Prashant TR.
22701
22702 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
22703
22704         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
22705         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
22706         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
22707
22708 2000-12-08  Andreas Schwab  <schwab@suse.de>
22709
22710         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
22711         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
22712
22713 2000-12-07  Jim Meyering  <meyering@lucent.com>
22714
22715         * lib/stripslash.c (ISSLASH): Define.
22716         (strip_trailing_slashes): Use ISSLASH rather than comparing against
22717         `/'.
22718         From Prashant TR.
22719
22720         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
22721         (dir_name_r): Declare this function as static.
22722         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
22723         manifest itself on a name containing a mix of slashes and
22724         backslashes.
22725         Make this function work with names starting with a DOS-style
22726         drive letter and colon prefix.
22727         (dir_name): Append `.' if necessary.
22728         Based mostly on patches from Prashant TR and Eli Zaretskii.
22729
22730         * lib/dirname.h (dir_name_r): Remove prototype.
22731
22732 2000-12-06  Paul Eggert  <eggert@twinsun.com>
22733
22734         * m4/off_t-format.m4: Remove this file.
22735         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
22736
22737 2000-12-06  Jim Meyering  <meyering@lucent.com>
22738
22739         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
22740         replacement strtoull, we may well need the replacement strtoul, too.
22741         Check for declarations of strtoul and strtoull.
22742         Check for strtol.  Mainly as a cue to cause automake to include
22743         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
22744         Check for limits.h -- strtol.c needs it.
22745
22746 2000-12-05  Jim Meyering  <meyering@lucent.com>
22747
22748         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
22749
22750 2000-12-04  Jim Meyering  <meyering@lucent.com>
22751
22752         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
22753         Also include memory.h, stdlib.h, unistd.h if appropriate.
22754         Reported by Andreas Jaeger (conflicting declaration of malloc).
22755
22756 2000-12-02  Jim Meyering  <meyering@lucent.com>
22757
22758         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
22759         * m4/jm-macros.m4 (jm_MACROS): require it.
22760
22761 2000-12-02  Jim Meyering  <meyering@lucent.com>
22762
22763         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
22764
22765 2000-12-01  Paul Eggert  <eggert@twinsun.com>
22766
22767         * lib/memrchr.c: Include <config.h> before any system include file.
22768
22769 2000-11-30  Jim Meyering  <meyering@lucent.com>
22770
22771         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
22772
22773 2000-11-30  Jim Meyering  <meyering@lucent.com>
22774
22775         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
22776
22777 2000-11-29  Paul Eggert  <eggert@twinsun.com>
22778
22779         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
22780
22781 2000-11-26  Jim Meyering  <meyering@lucent.com>
22782
22783         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
22784
22785 2000-11-22  Paul Eggert  <eggert@twinsun.com>
22786
22787         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
22788         size of (size_t) -1; it's not portable.
22789
22790 2000-11-17  Jim Meyering  <meyering@lucent.com>
22791
22792         * lib/strstr.c: Update from GNU libc.
22793
22794 2000-11-17  Akim Demaille  <akim@epita.fr>
22795
22796         * lib/obstack.h: Formatting changes.
22797         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
22798         prevent type checking.
22799         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
22800         cast the value to (void *): assigning a `foo *' to a `void *'
22801         variable is valid.
22802         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
22803
22804 2000-11-16  Jim Meyering  <meyering@lucent.com>
22805
22806         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
22807
22808 2000-11-11  Jim Meyering  <meyering@lucent.com>
22809
22810         * lib/error.c: Add a couple #includes, merging from GNU libc version.
22811
22812 2000-11-10  Jim Meyering  <meyering@lucent.com>
22813
22814         * lib/obstack.h: Update from GNU libc.
22815         * lib/obstack.c: Likewise.
22816
22817 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
22818
22819         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
22820
22821 2000-11-06  Paul Eggert  <eggert@twinsun.com>
22822
22823         * lib/getusershell.c (setusershell): Use rewind rather than
22824         fseek/fseeko, to avoid configuration hassles with fseeko.
22825         Don't bother opening SHELLS_FILE if shellstream is NULL;
22826         it's not necessary.
22827
22828 2000-11-05  Jim Meyering  <meyering@lucent.com>
22829
22830         * lib/makepath.h (make_dir): Declare.
22831         * lib/makepath.c (make_dir): Remove `static' attribute.
22832         Tweak a comment.
22833
22834 2000-11-04  Jim Meyering  <meyering@lucent.com>
22835
22836         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
22837
22838 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
22839
22840         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
22841         last one in a bucket, advance to the next bucket.
22842
22843 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
22844
22845         * lib/fnmatch.c: Do not comment out all the code if we are using
22846         the GNU C library, because in some cases we are replacing buggy
22847         code in the GNU C library itself.
22848
22849 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
22850
22851         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
22852         (regex_compile): Catch bogus \(\1\).
22853
22854 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22855
22856         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
22857         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
22858         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
22859
22860 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22861
22862         * lib/error.h, getline.h, modechange.h:
22863         Remove "2000" from Copyright line, as the file hasn't been
22864         changed this year other than in the copyright notice.
22865
22866         * lib/xalloc.h: Add "2000" to Copyright line, as this file
22867         was changed this year.
22868
22869 2000-10-29  Jim Meyering  <meyering@lucent.com>
22870
22871         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
22872         renaming.
22873         * m4/ls-mntd-fs.m4: Likewise
22874
22875 2000-10-29  Jim Meyering  <meyering@lucent.com>
22876
22877         * lib/xstat.in: Fix grammar in comment.
22878
22879 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
22880
22881         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
22882         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
22883         doesn't define __restrict_arr.
22884
22885 2000-10-28  Jim Meyering  <meyering@lucent.com>
22886
22887         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
22888         (jm_PREREQ_MEMCHR): New function.
22889
22890 2000-10-28  Jim Meyering  <meyering@lucent.com>
22891
22892         * lib/memchr.c: Update from libc.
22893         Adjust for portability:
22894         [HAVE_STDLIB_H]: Include stdlib.h.
22895         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
22896         Undef __memchr, too.
22897         [!weak_alias]: Define __memchr to memchr.
22898
22899         * lib/regex.c: Update from libc.
22900         * lib/regex.h: Likewise.
22901         * lib/getopt1.c: Likewise.
22902         * lib/memcmp.c: Likewise.
22903
22904         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
22905         Avoid using fseek, when possible -- it's broken by design.
22906         Patch by Ulrich Drepper.
22907
22908 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
22909
22910         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
22911         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
22912         Giving in to popular pressure to shut up the compiler with casts.
22913
22914 2000-10-26  Jim Meyering  <meyering@lucent.com>
22915
22916         * lib/strftime.c: Update from libc.
22917
22918 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
22919
22920         * regex.c: More `unsigned char' -> `re_char' changes.
22921         Also change several `int' into `re_wchar_t'.
22922         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
22923         (PUSH_FAILURE_POINTER): Don't cast any more.
22924         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
22925         We want GCC to complain, since this piece of code makes
22926         re_match non-reentrant, which *should* be fixed.
22927         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
22928         (EXTEND_BUFFER): Use RETALLOC.
22929         (SET_LIST_BIT): Don't cast.
22930         (re_wchar_t): New type.
22931         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
22932         that those two functions will always properly return.
22933         (IMMEDIATE_QUIT_CHECK): Cast to void.
22934         (analyse_first): Use recursion rather than an explicit stack.
22935         (re_compile_fastmap): Can't fail anymore.
22936         (re_search_2): Don't check re_compile_fastmap for failure.
22937         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
22938         Now also sets the new value (passed in a new argument).
22939         (re_match_2_internal): Use it.
22940         Also, use a new var `reg' of type size_t when looping through regs
22941         rather than reuse the inappropriate `mcnt'.
22942
22943 2000-10-25  Jim Meyering  <meyering@lucent.com>
22944
22945         * lib/obstack.c: Update from libc.
22946
22947 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
22948
22949         * regex.c (regex_compile): Change the way of handling a range from
22950         a char less than 256 to a char not less than 256.
22951
22952 2000-10-24  Andrew Innes  <andrewi@gnu.org>
22953
22954         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
22955         NT-Emacs only.
22956         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
22957         so that re_search functions only quit when callers expect them to.
22958
22959 2000-10-23  Jim Meyering  <meyering@lucent.com>
22960
22961         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
22962         wrong.  That set_locale call must not have any side effects.
22963         From Paul Eggert.
22964
22965 2000-10-22  Jim Meyering  <meyering@lucent.com>
22966
22967         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
22968         [CYCLIC]: Remove now-unused definition.
22969
22970         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
22971         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
22972         Suggestion from Ulrich Drepper.
22973
22974 2000-10-21  Jim Meyering  <meyering@lucent.com>
22975
22976         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
22977         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
22978         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
22979
22980 2000-10-21  Jim Meyering  <meyering@lucent.com>
22981
22982         * lib/dirname.c (memrchr): Declare if necessary.
22983         (dir_name): Remove the restriction that there be no
22984         trailing slashes.  Now, this code skips past them, effectively
22985         ignoring them.
22986         [TEST_DIRNAME] (main): New unit tests.
22987
22988         * lib/memrchr.c: New file from GNU libc.
22989         Undef __memrchr, too.
22990         [!weak_alias]: Define __memrchr to memrchr.
22991         Guard weak_alias use with `#ifdef weak_alias'.
22992
22993 2000-10-21  Jim Meyering  <meyering@lucent.com>
22994
22995         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
22996         (dir_name): Use dir_name_r.
22997         * lib/dirname.h (dir_name_r): Declare it.
22998
22999 2000-10-17  Jim Meyering  <meyering@lucent.com>
23000
23001         * lib/quote.h (PARAMS): Define and use.
23002         Reported by Akim Demaille.
23003
23004         * lib/getopt.c: Update from libc.
23005
23006 2000-10-16  Jim Meyering  <meyering@lucent.com>
23007
23008         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
23009         setlocale.
23010         From Jan Fedak.
23011
23012 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
23013
23014         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
23015
23016 2000-09-25  Jim Meyering  <meyering@lucent.com>
23017
23018         * lib/md5.h (rol): Define (from GnuPG).
23019
23020         * lib/sha.c: Give credit (GnuPG) where due.
23021         (M): Use rol rather than open-coding it.
23022         Add a FIXME comment.
23023
23024 2000-09-21  Jim Meyering  <meyering@lucent.com>
23025
23026         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
23027         Reported by Michael Stone.
23028
23029 2000-09-20  Jim Meyering  <meyering@lucent.com>
23030
23031         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
23032         (noinst_HEADERS): Add sha.h.
23033         Based on code from Scott G. Miller and from GnuPG.
23034
23035 2000-09-18  Jim Meyering  <meyering@lucent.com>
23036
23037         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
23038         LIBS. Otherwise, everyone ends up linking with -lelf for some
23039         configurations.
23040         Reported by Mike Stone.
23041
23042 2000-09-15  Jim Meyering  <meyering@lucent.com>
23043
23044         * lib/regex.c: Update from libc.
23045
23046 2000-09-10  Jim Meyering  <meyering@lucent.com>
23047
23048         * lib/getopt.c (_getopt_internal): Update from glibc.
23049
23050 2000-09-09  Jim Meyering  <meyering@lucent.com>
23051
23052         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
23053         think it should be used as a general replacement for isascii.
23054         * lib/fnmatch.c: Likewise.
23055         * lib/mbswidth.c: Likewise
23056         * lib/regex.c: Likewise.
23057
23058         Don't use atoi.
23059         * lib/userspec.c: Include sys/param.h and limits.h.
23060         Include xstrtol.h.
23061         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23062         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
23063         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
23064         UID, GID.  Check range.
23065
23066 2000-09-06  Jim Meyering  <meyering@lucent.com>
23067
23068         * lib/getopt.c (_getopt_internal): Update from glibc.
23069
23070 2000-08-30  Jim Meyering  <meyering@lucent.com>
23071
23072         * lib/strftime.c: Merge in changes from GNU libc.
23073
23074 2000-08-26  Jim Meyering  <meyering@lucent.com>
23075
23076         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
23077         * m4/fpending.m4: New file.
23078
23079 2000-08-26  Jim Meyering  <meyering@lucent.com>
23080
23081         * lib/closeout.c: Include "__fpending.h".
23082         (close_stdout_status): Return right away if there's nothing to flush.
23083
23084         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
23085         * lib/__fpending.c: New file.
23086         * lib/__fpending.h: New file.
23087
23088 2000-08-20  Jim Meyering  <meyering@lucent.com>
23089
23090         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
23091         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
23092         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
23093
23094 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
23095
23096         Improve fileutils installation on systems where running
23097         programs (like install) can't be unlinked.
23098         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
23099         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
23100
23101 2000-08-07  Paul Eggert  <eggert@twinsun.com>
23102
23103         Standardize on "memory exhausted" instead of "Memory exhausted"
23104         or "virtual memory exhausted".
23105         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
23106         "virtual memory exhausted".
23107         * lib/same.c (same_name): Invoke xalloc_die instead of printing
23108         our own message.
23109         * lib/userspec.c (parse_user_spec): Likewise.
23110         * lib/bumpalloc.h: comment fix
23111         * lib/same.c, userspec.c: Include xalloc.h.
23112
23113         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
23114         not char *const and pointing to a constant array.
23115         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
23116         (xrealloc): Comment fix.
23117
23118         * lib/userspec.c (parse_user_spec):
23119         Don't translate a message until just before returning,
23120         to avoid unnecessary translation.
23121
23122 2000-08-07  Jim Meyering  <meyering@lucent.com>
23123
23124         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
23125         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
23126         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
23127         getgroups.c, gethostname.c, getopt.h, group-member.c,
23128         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
23129         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
23130         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
23131         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
23132         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
23133         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
23134         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
23135         yesno.c: Back out Copyright date changes for each file with no change
23136         this year.  This eases coordination with other programs using the same
23137         source code modules.  From Paul Eggert.
23138
23139 2000-08-06  Paul Eggert  <eggert@twinsun.com>
23140
23141         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
23142         not char, for compatibility with glibc 2.1.3 strftime.c.
23143
23144 2000-08-03  Greg McGary  <greg@mcgary.org>
23145
23146         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
23147         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
23148         (EXTEND_BUFFER): Use them.
23149
23150 2000-08-01  Jim Meyering  <meyering@lucent.com>
23151
23152         * lib/dirname.c (ISSLASH): Define.
23153         (BACKSLASH_IS_PATH_SEPARATOR): Define.
23154         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
23155         both `\' and `/' may be use as path separators.
23156         Based on a patch from Prashant TR.
23157
23158 2000-07-31  Paul Eggert  <eggert@twinsun.com>
23159
23160         * lib/quotearg.c (quotearg_n_options): Don't make the initial
23161         slot vector a constant, since it might get modified.
23162
23163 2000-07-31  Jim Meyering  <meyering@lucent.com>
23164
23165         * lib/xmalloc.c: Use `virtual memory exhausted', not
23166         `Memory exhausted'.
23167         * lib/obstack.c (print_and_abort): Likewise.
23168
23169 2000-07-30  Paul Eggert  <eggert@twinsun.com>
23170
23171         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
23172         buffer, so that the caller can always quote one small
23173         component of a "memory exhausted" message in slot 0.
23174         From a suggestion by Jim Meyering.
23175
23176 2000-07-30  Jim Meyering  <meyering@lucent.com>
23177
23178         * lib/makepath.c (make_path): Quote the other instance, too.
23179
23180         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
23181         (STATIC_BUF_SIZE): Define.
23182         (quotearg_n_options): Use only statically allocated storage when
23183         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
23184         than STATIC_BUF_SIZE.
23185
23186 2000-07-29  Jim Meyering  <meyering@lucent.com>
23187
23188         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
23189         * lib/dirname.c (dir_name): Likewise.
23190
23191         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
23192         `/'.
23193
23194         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
23195         (dir_name): Assert that there are no trailing slashes.
23196
23197 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
23198
23199         * lib/mbswidth.h (mbswidth): Add a flags argument.
23200         (mbswidth): New declaration.
23201         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
23202         * lib/mbswidth.c (mbswidth): Add a flags argument.
23203         (mbsnwidth): New function.
23204
23205 2000-07-24  Jim Meyering  <meyering@lucent.com>
23206
23207         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
23208
23209 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23210
23211         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
23212
23213 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23214
23215         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
23216         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
23217         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
23218         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
23219         invoke multibyte primitives.
23220
23221 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23222
23223         * lib/quotearg.c:
23224         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
23225         so that mbstate_t is always defined.
23226
23227         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
23228         be 1 in at least one GCC installation, and this configuration
23229         error is likely to be common.  Ignoring MB_LEN_MAX hurts
23230         performance on hosts that have mbrtowc but have only unibyte
23231         locales, but I assume these hosts are rare.
23232
23233 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23234
23235         * lib/mbswidth.c (_XOPEN_SOURCE):
23236         Don't define; this causes problems on Solaris 7.
23237         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
23238
23239 2000-07-23  Jim Meyering  <meyering@lucent.com>
23240
23241         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
23242         too: getgrgid, getpwuid, getuid.
23243
23244 2000-07-23  Jim Meyering  <meyering@lucent.com>
23245
23246         * lib/basename.c (base_name): Add an assertion.
23247
23248 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
23249
23250         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
23251         shadow its mbsinit function.
23252
23253 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23254
23255         * lib/mbswidth.h: New file.
23256         * lib/mbswidth.c: New file.
23257         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
23258         (noinst_HEADERS): Add mbswidth.h.
23259
23260 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23261
23262         * lib/config.charset: Add support for FreeBSD. Improve support for
23263         HP-UX and IRIX 6.
23264
23265 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
23266
23267         * m4/mbswidth.m4: New file.
23268         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
23269
23270 2000-07-15  Jim Meyering  <meyering@lucent.com>
23271
23272         * lib/makepath.c: Include quote.h.
23273         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
23274         corresponding argument in a `quote (...)' call.
23275         Give better diagnostics.
23276
23277         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
23278         (noinst_HEADERS): Add quote.h.
23279
23280         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
23281         from tar's src/misc.c.
23282         * lib/quote.h: New file.  Prototypes for same.
23283
23284 2000-07-14  Paul Eggert  <eggert@twinsun.com>
23285
23286         From a suggestion by Bruno Haible.
23287         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
23288         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
23289         to decide whether to define the BeOS workaround macro;
23290         this adjusts to the change to AC_MBSTATE_T.
23291
23292 2000-07-14  Jim Meyering  <meyering@lucent.com>
23293
23294         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
23295         jm_AC_TYPE_UINTMAX_T.
23296
23297 2000-07-13  Paul Eggert  <eggert@twinsun.com>
23298
23299         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
23300
23301         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
23302         quotearg_buffer_restyled): Add support for
23303         clocale_quoting_style.  Undo previous change to
23304         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
23305         and "{RIGHT QUOTATION MARK}" msgids.
23306
23307 2000-07-10  Paul Eggert  <eggert@twinsun.com>
23308
23309         From a suggestion by Bruno Haible.
23310         * m4/mbstate_t.m4 (AC_MBSTATE_T):
23311         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
23312         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
23313         and mbstate_t, to a single-part test that simply defines mbstate_t.
23314         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
23315         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
23316
23317 2000-07-10  Jim Meyering  <meyering@lucent.com>
23318
23319         * m4/strerror_r.m4: Mirror the correction made in autoconf.
23320
23321         * m4/gnu-source.m4: Output to confdefs.h directly.
23322         Suggestion from Akim Demaille.
23323
23324 2000-07-09  Paul Eggert  <eggert@twinsun.com>
23325
23326         The old behavior of quoting `like this' doesn't look good with
23327         newer, ISO-style fonts.  See:
23328         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
23329
23330         Instead, quote "like this" by default.  Let the translator
23331         tailor the locale-specific quoting behavior by providing
23332         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
23333
23334         * lib/quotearg.c (N_): New macro.
23335         (gettext_default): New function.
23336         (quotearg_buffer_restyled): Use
23337         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
23338         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
23339
23340 2000-07-09  Jim Meyering  <meyering@lucent.com>
23341
23342         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
23343         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
23344
23345         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
23346         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
23347
23348 2000-07-09  Jim Meyering  <meyering@lucent.com>
23349
23350         * lib/Most files: Update copyright dates to include 2000.
23351
23352 2000-07-08  Jim Meyering  <meyering@lucent.com>
23353
23354         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
23355         if not defined.
23356         (xgethostname): Remove now-unnecessary #ifdef.
23357         Move declaration of `err' into loop where it's used.
23358
23359 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23360         and Bruno Haible  <haible@clisp.cons.org>
23361
23362         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
23363         only if the test for an object-type mbstate_t fails.  This
23364         prevents us from mistakenly reporting that mbstate_t is a
23365         system object type after we "#define mbstate_t int" to work
23366         around its lack.
23367
23368 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23369         and Bruno Haible  <haible@clisp.cons.org>
23370
23371         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
23372
23373 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23374
23375         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
23376         to strerror_r.
23377         Include <ctype.h> for use of isalpha.
23378
23379 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23380
23381         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
23382         by allocating a larger buffer. Test the gethostname return value for
23383         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
23384         returns an error and ENAMETOOLONG isn't defined.
23385
23386 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23387
23388         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
23389         dimension.
23390
23391 2000-07-04  Jim Meyering  <meyering@lucent.com>
23392
23393         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
23394         of the deprecated AC_CHECKING.
23395
23396 2000-07-04  Jim Meyering  <meyering@lucent.com>
23397
23398         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
23399         Reported by Bruno Haible.
23400
23401 2000-07-04  Jim Meyering  <meyering@lucent.com>
23402
23403         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
23404         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
23405         lacks mbrtowc.
23406
23407 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23408
23409         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
23410         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
23411
23412 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23413         and Bruno Haible  <haible@clisp.cons.org>
23414
23415         * lib/quotearg.c (mbrtowc):
23416         Assign to *pwc, and return 1 only if result is nonzero.
23417         (iswprint): Use ISPRINT when substituting our own mbrtowc.
23418
23419 2000-07-03  Jim Meyering  <meyering@lucent.com>
23420
23421         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
23422
23423 2000-07-03  Jim Meyering  <meyering@lucent.com>
23424
23425         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
23426         This is necessary to get a definition of e.g., UTMP_FILE on
23427         HP-UX 10.20.
23428         From Bob Proulx.
23429
23430 2000-07-02  Jim Meyering  <meyering@lucent.com>
23431
23432         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
23433
23434         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
23435         AC_LIBOBJ(function_name).
23436         * m4/chown.m4: Likewise.
23437         * m4/fnmatch.m4: Likewise.
23438         * m4/ftruncate.m4: Likewise.
23439         * m4/getgroups.m4: Likewise.
23440         * m4/getline.m4: Likewise.
23441         * m4/group-member.m4: Likewise.
23442         * m4/jm-macros.m4: Likewise.
23443         * m4/lstat.m4: Likewise.
23444         * m4/malloc.m4: Likewise.
23445         * m4/memcmp.m4: Likewise.
23446         * m4/nanosleep.m4: Likewise.
23447         * m4/putenv.m4: Likewise.
23448         * m4/realloc.m4: Likewise.
23449         * m4/regex.m4: Likewise.
23450         * m4/stat.m4: Likewise.
23451         * m4/strftime.m4: Likewise.
23452
23453 2000-07-02  Jim Meyering  <meyering@lucent.com>
23454
23455         * lib/quotearg.c (mbstate_t): Don't define here.
23456
23457 2000-07-02  Jim Meyering  <meyering@lucent.com>
23458
23459         * lib/nanosleep.c (SIGCONT): Define if not already defined.
23460
23461 2000-07-01  Jim Meyering  <meyering@lucent.com>
23462
23463         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
23464
23465 2000-07-01  Jim Meyering  <meyering@lucent.com>
23466
23467         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
23468         problem.
23469
23470 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23471
23472         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
23473         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
23474
23475 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23476
23477         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
23478         per change in ../m4/ls-mntd-fs.m4.
23479         (read_filesystem_list): Ignore symbolic links.
23480
23481 2000-06-29  Jim Meyering  <meyering@lucent.com>
23482
23483         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
23484         for declaration of strcmp.
23485
23486         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
23487
23488         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
23489         Avoid warning by casting result to `char *' to remove `const'.
23490
23491 2000-06-28  Jim Meyering  <meyering@lucent.com>
23492
23493         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
23494         included by quotearg.c, for which we perform this test.  From
23495         Bruno Haible.
23496
23497 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23498
23499         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
23500         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
23501         <utmpx.h> exists, put readutmp.o into LIBOBJS.
23502
23503 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23504
23505         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
23506
23507 2000-06-26  Paul Eggert  <eggert@twinsun.com>
23508
23509         savedir now sets errno on failure and invokes xmalloc to get memory.
23510         Fix a couple of other minor bugs while we're at it.
23511
23512         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
23513         (NAMLEN): Remove macro.
23514         (malloc, realloc): Remove decls.
23515         (stpcpy): Likewise.
23516         ("xalloc.h"): Include.
23517         (NAME_SIZE_DEFAULT): New macro.
23518         (savedir): Use xmalloc / xrealloc to allocate memory.
23519         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
23520         Skip "" directory entries.
23521         Use strlen to calculate directory entry length, since the old method
23522         is rarely used these days and isn't worth supporting.
23523         Don't use a pointer after freeing it.
23524         Check for integer overflow when calculating allocation size.
23525         Use memcpy to copy entries, instead of stpcpy.
23526         Set errno properly when returning NULL.
23527         Check for readdir error.
23528
23529 2000-06-26  Jim Meyering  <meyering@lucent.com>
23530
23531         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
23532
23533 2000-06-25  Jim Meyering  <meyering@lucent.com>
23534
23535         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
23536         Linux header bug when _XOPEN_SOURCE is defined to 500.
23537
23538 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23539
23540         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
23541         deficiency.
23542
23543 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23544
23545         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
23546         Include xalloc.h.
23547         Don't include <stdlib.h>.  Don't declare malloc, realloc.
23548
23549 2000-06-24  Jim Meyering  <meyering@lucent.com>
23550
23551         * m4/strerror_r.m4: Revive this file -- to try out an experimental
23552         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
23553         for which strerror does return char*, but which lacks a conveniently
23554         accessible declaration of the function.  If the compile-test says
23555         strerror_r doesn't work, then resort to a `run'-test that works on
23556         BeOS and segfaults on DEC Unix.
23557
23558 2000-06-24  Jim Meyering  <meyering@lucent.com>
23559
23560         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
23561
23562 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23563
23564         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
23565         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
23566
23567 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23568
23569         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
23570         (mbrtowc, mbstate_t): Define substitutes if
23571         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
23572         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
23573         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
23574
23575 2000-06-23  Jim Meyering  <meyering@lucent.com>
23576
23577         * m4/afs.m4: Add missing AC_MSG_RESULT.
23578         Reported by Bruno Haible.
23579
23580         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
23581         Suggestion from Bruno Haible.
23582
23583 2000-06-23  Jim Meyering  <meyering@lucent.com>
23584
23585         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
23586
23587 2000-06-21  Jim Meyering  <meyering@lucent.com>
23588
23589         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
23590
23591 2000-06-21  Jim Meyering  <meyering@lucent.com>
23592
23593         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
23594         (noinst_HEADERS): Add getstr.h.
23595
23596         * lib/getline.c (getstr): Move into a separate file.
23597         * lib/getstr.c (getstr): New file, extracted from getline.c, with
23598         the following changes: new parameter, delim2; both delim[12]
23599         parameters have type `int', not `char'.  The latter would lose
23600         with 8-bit delimiters.
23601         * lib/getstr.h: New file.
23602
23603 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23604
23605         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
23606         than 1024, return a memory chunk of least possible size, instead
23607         of size PATH_MAX + 2. In the loop, increment the size proportionally.
23608         Use free/xmalloc instead of xrealloc to avoid copying for very long
23609         paths.
23610
23611 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23612
23613         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
23614         the empty string.
23615
23616 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23617
23618         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
23619         address, not strdup.  Include <stdlib.h> and don't declare free().
23620
23621 2000-06-19  Jim Meyering  <meyering@lucent.com>
23622
23623         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
23624
23625 2000-06-18  Jim Meyering  <meyering@lucent.com>
23626
23627         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
23628
23629         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
23630         `checking whether...' message to be consistent with that of the
23631         lstat test.
23632
23633 2000-06-18  Jim Meyering  <meyering@lucent.com>
23634
23635         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
23636         Besides, these days every porting target provides a mkdir function.
23637
23638         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
23639         needed. (this snippet comes from src/system.h).
23640
23641 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
23642
23643         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
23644
23645 2000-06-15  Paul Eggert  <eggert@twinsun.com>
23646
23647         * lib/human.c (adjust_value): New function.
23648         (human_readable_inexact): Apply rounding style even when
23649         printing approximate values.
23650
23651 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23652
23653         * lib/human.c (human_readable_inexact): Allow an input block
23654         size that is not a multiple of the output block size, and vice versa.
23655         Reported by Piergiorgio Sartor.
23656
23657 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23658
23659         * lib/getdate.y (get_date): Apply relative times after time
23660         zone indicator, not before.  Reported by Todd A. Jacobs.
23661
23662 2000-06-13  Jim Meyering  <meyering@lucent.com>
23663
23664         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
23665
23666         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
23667
23668 2000-06-12  Paul Eggert  <eggert@twinsun.com>
23669
23670         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
23671
23672 2000-06-12  Jim Meyering  <meyering@lucent.com>
23673
23674         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
23675         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
23676         optional argument.
23677         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
23678         the optional argument, `lib'.
23679
23680 2000-06-08  Jim Meyering  <meyering@lucent.com>
23681
23682         * m4/largefile.m4: Remove file (now that it's part of autoconf).
23683
23684 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23685
23686         Rewrite largefile configuration so that we don't need to run
23687         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
23688         AC_CANONICAL_HOST in configure.in -- jmm]
23689
23690         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
23691         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
23692         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
23693         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
23694         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
23695         All uses changed.
23696         Instead of inspecting the output of getconf, try to compile the
23697         test program without and with the macro definition.
23698         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
23699         for getconf.  Instead, check for the needed flags by compiling
23700         test programs.
23701
23702 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23703
23704         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
23705
23706 2000-06-04  Jim Meyering  <meyering@lucent.com>
23707
23708         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
23709         SunOS 4.1.4 for which gid_t is an unsigned type.
23710
23711 2000-06-03  Jim Meyering  <meyering@lucent.com>
23712
23713         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
23714         now that autoconf requires that.
23715
23716         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
23717         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
23718         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
23719
23720 2000-06-03  Jim Meyering  <meyering@lucent.com>
23721
23722         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
23723
23724 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23725
23726         * m4/glibc21.m4: New file.
23727         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
23728
23729 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23730
23731         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
23732         newer, don't install charset.alias.
23733         * lib/config.charset: Change the Linux/glibc rules so they become empty
23734         on glibc-2.1 or newer.
23735
23736 2000-06-02  Jim Meyering  <meyering@lucent.com>
23737
23738         * lib/mountlist.c: Back out last change.  Instead, do this...
23739         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
23740         me_dummy member using the same `ignore'-testing code.
23741         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
23742         fs_type strings.
23743         From Mark D. Roth.
23744
23745 2000-05-29  Jim Meyering  <meyering@lucent.com>
23746
23747         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
23748         mounts with the `ignore' attribute.  Based on a patch from
23749         Mark D. Roth.
23750
23751 2000-05-28  Jim Meyering  <meyering@lucent.com>
23752
23753         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
23754         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23755         * m4/stat.m4: Likewise.
23756         * m4/lstat.m4: Likewise.
23757         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
23758
23759         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
23760         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
23761
23762 2000-05-26  Jim Meyering  <meyering@lucent.com>
23763
23764         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
23765
23766 2000-05-24  Jim Meyering  <meyering@lucent.com>
23767
23768         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
23769         autoconf requires that.
23770         * m4/lib-check.m4: Likewise.
23771         * m4/jm-macros.m4: Likewise.
23772         * m4/strftime.m4: Likewise.
23773
23774         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
23775         AC_CHECK_DECLS, now that autoconf requires that.
23776
23777 2000-05-22  Jim Meyering  <meyering@lucent.com>
23778
23779         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23780         * m4/lstat.m4: Likewise.
23781
23782 2000-05-22  Jim Meyering  <meyering@lucent.com>
23783
23784         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
23785
23786 2000-05-20  Jim Meyering  <meyering@lucent.com>
23787
23788         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
23789         (jm_PREREQ): Use it.
23790
23791 2000-05-18  Jim Meyering  <meyering@lucent.com>
23792
23793         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
23794         back, too, since it may have been modified by allocate_entry.
23795         (hash_delete): Rewrite to use neither the assignment operator
23796         nor the comma operator in an if-expression.
23797
23798 2000-05-15  Paul Eggert  <eggert@twinsun.com>
23799
23800         * lib/closeout.c:
23801         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
23802         Remove; no longer needed.
23803         "quotearg.h": Add include.
23804         (file_name): Do not bother to explicitly initialize to NULL; it's less
23805         efficient on some hosts.
23806         (close_stdout_status): Remove test as to whether stdout was already
23807         closed; it breaks for the case "echo x | sort >&-".
23808         Quote file name colons.
23809         Do not assume that _("write error") lacks format strings.
23810
23811 2000-05-15  Jim Meyering  <meyering@lucent.com>
23812
23813         * lib/version-etc.c (version_etc_copyright): Update the copyright
23814         string used in all --version output.
23815
23816 2000-05-14  Jim Meyering  <meyering@lucent.com>
23817
23818         * lib/closeout.c (close_stdout_set_file_name): New function.
23819         (close_stdout_status): Use new file-scoped global.
23820         Return right away if fstat says the stdout file descriptor is invalid.
23821         * lib/closeout.h (close_stdout_set_file_name): Declare.
23822
23823 2000-05-10  Jim Meyering  <meyering@lucent.com>
23824
23825         * lib/closeout.c [default_exit_status]: New file-scoped variable.
23826         (close_stdout_set_status): New function.
23827         * lib/closeout.h (close_stdout_set_status): Declare.
23828
23829 2000-05-09  Jim Meyering  <meyering@lucent.com>
23830
23831         * m4/gettext.m4: Rename this...
23832         * m4/libintl.m4: ...to this.
23833
23834 2000-05-08  Jim Meyering  <meyering@lucent.com>
23835
23836         * lib/long-options.c: Don't include closeout.h.
23837         (parse_long_options): Don't call close_stdout for --version.
23838
23839 2000-05-06  Paul Eggert  <eggert@twinsun.com>
23840
23841         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
23842         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
23843         2.1.3 bug.  This avoids a clash when files like regex.c define
23844         _GNU_SOURCE.
23845
23846 2000-05-06  Jim Meyering  <meyering@lucent.com>
23847
23848         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
23849         (AC_REPLACE_FUNCS): Add strnlen.
23850
23851         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
23852         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
23853
23854         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
23855         AC_SEARCH_LIBS call for nanosleep.
23856         (LIB_NANOSLEEP): Set and AC_SUBST.
23857
23858 2000-05-06  Jim Meyering  <meyering@lucent.com>
23859
23860         * lib/strnlen.c: Undefine __strnlen and strnlen.
23861         [!weak_alias]: Define __strnlen to strnlen.
23862
23863         * lib/atexit.c: New file, from libiberty.
23864
23865 2000-05-06  Jim Meyering  <meyering@lucent.com>
23866
23867         * lib/closeout.c (close_stdout_status): Also check for errors on the
23868         stderr stream.
23869
23870 2000-05-05  Jim Meyering  <meyering@lucent.com>
23871
23872         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
23873         AC_SEARCH_LIBS call for clock_gettime.
23874         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
23875
23876         * m4/search-libs.m4: Update from autoconf.
23877
23878         su doesn't work on Solaris 2.6.
23879         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
23880         <shadow.h>.  Reported by Dragos Harabor.
23881
23882 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
23883
23884         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
23885         memcpy instead of xmalloc, xrealloc, path_concat.
23886         (locale_charset): Treat empty environment variables as absent.
23887         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
23888
23889 2000-05-04  Jim Meyering  <meyering@lucent.com>
23890
23891         * lib/getopt.c: Update from glibc.
23892         * lib/obstack.c: Likewise.
23893         * lib/obstack.h: Likewise.
23894         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
23895         file
23896
23897         * lib/regex.h: Likewise.
23898         * lib/strndup.c: Likewise.
23899         * lib/strnlen.c: New file, from glibc.
23900
23901 2000-05-03  Jim Meyering  <meyering@lucent.com>
23902
23903         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
23904
23905 2000-05-02  Paul Eggert  <eggert@twinsun.com>
23906
23907         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
23908         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
23909         compile-time test, rather than inspecting host and OS, to
23910         decide whether to define _LARGEFILE_SOURCE.
23911
23912 2000-05-01  Jim Meyering  <meyering@lucent.com>
23913
23914         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
23915
23916         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
23917         Based on a patch from Bruno Haible.
23918
23919 2000-05-01  Jim Meyering  <meyering@lucent.com>
23920
23921         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
23922
23923 2000-04-29  Jim Meyering  <meyering@lucent.com>
23924
23925         * lib/path-concat.c: Declare strdup only if it's not defined.
23926         * lib/canon-host.c: Likewise.
23927
23928 2000-04-28  Jim Meyering  <meyering@lucent.com>
23929
23930         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
23931         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
23932         is included first, then limits.h is included by locale.h by libintl.h.
23933         From John David Anglin.
23934
23935 2000-04-25  Jim Meyering  <meyering@lucent.com>
23936
23937         * lib/makepath.c (S_IRWXUGO): Define.
23938         (make_path): Always perform explicit chmod if MODE specifies any
23939         of the `special' permission bits.  Prompted by a bug report against
23940         install from Mate Wierdl and Joost van Baal.
23941
23942 2000-04-18  Jim Meyering  <meyering@lucent.com>
23943
23944         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
23945         (jm_PREREQ): Use it.
23946
23947 2000-04-18  Jim Meyering  <meyering@lucent.com>
23948
23949         * lib/README: New file.
23950
23951         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
23952         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
23953
23954 2000-04-17  Jim Meyering  <meyering@lucent.com>
23955
23956         Get it right :-)
23957         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
23958         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
23959         Suggestion from Akim Demaille.
23960
23961 2000-04-17  Jim Meyering  <meyering@lucent.com>
23962
23963         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
23964         the definition of it to rpl_strftime also defined-away the system's
23965         declaration.
23966
23967 2000-04-15  Jim Meyering  <meyering@lucent.com>
23968
23969         Use `C' to denote so-called `contiguous' files, the same way
23970         that tar does.
23971         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
23972         (ftypelet): Use S_ISCTG.
23973         From Michael Deutschmann.
23974
23975 2000-04-14  Jim Meyering  <meyering@lucent.com>
23976
23977         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
23978         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
23979         clobbered.
23980
23981 2000-04-14  Jim Meyering  <meyering@lucent.com>
23982
23983         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
23984
23985 2000-04-13  Jim Meyering  <meyering@lucent.com>
23986
23987         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
23988         AH_VERBATIM to insert required #ifndef into config.h.in.
23989         Suggestion from Akim Demaille.
23990
23991 2000-04-12  Jim Meyering  <meyering@lucent.com>
23992
23993         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
23994         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
23995         Christian Krackowizer.
23996
23997         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
23998         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
23999         (AC_SYS_LARGEFILE): Require.
24000         (AM_C_PROTOTYPES): Require.
24001
24002 2000-04-08  Jim Meyering  <meyering@lucent.com>
24003
24004         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
24005         names don't conflict.  Reported by Eli Zaretskii.
24006
24007 2000-04-07  Jim Meyering  <meyering@lucent.com>
24008
24009         * lib/putenv.c: Move inclusion of errno.h so it follows that of
24010         sys/types.h, to work around system header problems on AIX 3.2.5.
24011         From Bruno Haible.
24012
24013 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
24014
24015         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
24016         bug.  Deal with the different error behavior of Irix iconv.
24017
24018 2000-04-05  Paul Eggert  <eggert@twinsun.com>
24019
24020         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
24021         IRIX if the installer said otherwise.
24022
24023 2000-04-05  Jim Meyering  <meyering@lucent.com>
24024
24025         Portability tweaks required for ultrix4.3.
24026         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
24027         (jm_CHECK_DECLS): Add getutent to the list of functions.
24028         (_jm_DECL_HEADERS): Add utmpx.h.
24029         From John David Anglin.
24030
24031         * m4/strftime.m4: Back out the 2000-04-02 change.
24032         Instead of that change, simply undefine putenv in the test program.
24033
24034 2000-04-05  Jim Meyering  <meyering@lucent.com>
24035
24036         Portability tweaks required for ultrix4.3.
24037         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
24038         getutent.
24039         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
24040         * lib/canon-host.c: Declare strdup.
24041         * lib/path-concat.c: Likewise.
24042         From John David Anglin.
24043
24044 2000-04-04  Jim Meyering  <meyering@lucent.com>
24045
24046         Be more DOS 8.3-friendly.
24047         * lib/ref-add.sin: Renamed from ref-add.sed.in.
24048         * lib/ref-del.sin: Renamed from ref-del.sed.in.
24049         * lib/Makefile.am: Reflect renaming.
24050         Reported by Eli Zaretskii.
24051
24052         Use a temporary file name that won't clash with `charset.alias'
24053         in the DOS 8.3 name space.
24054         * lib/Makefile.am (charset_tmp): Define.
24055         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
24056         (uninstall-local): Likewise.
24057         Reported by Eli Zaretskii.
24058
24059 2000-04-03  Jim Meyering  <meyering@lucent.com>
24060
24061         * m4/gettext.m4: Fix typo in comment.
24062
24063         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
24064         textutils/configure.in).  Suggestion from Paul Eggert.
24065         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
24066
24067 2000-04-02  Paul Eggert  <eggert@twinsun.com>
24068
24069         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
24070         variable in the shell rather than using putenv, which isn't
24071         portable.  This avoids the configure-time inter-test dependency
24072         on the potentially-renamed putenv function.
24073
24074 2000-03-30  Paul Eggert  <eggert@twinsun.com>
24075
24076         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
24077         before checking struct stat.st_blksize, so that
24078         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
24079
24080 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24081
24082         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
24083         since strftime.c uses HAVE_STRFTIME to decide whether to use
24084         the underlying strftime.
24085
24086 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24087
24088         * lib/time/strftime.c (my_strftime): Make sure we call the system
24089         strftime, not ourselves, when invoking the underlying strftime.
24090
24091 2000-03-24  Jim Meyering  <meyering@lucent.com>
24092
24093         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
24094         (charset_alias): Define.
24095         (install-exec-local): Factor out common code.
24096         (uninstall-local): Split lines longer than 80.
24097         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
24098         (SUFFIXES): Define.
24099         (.sed.in.sed): New rule.  Don't redirect directly to $@.
24100         (CLEANFILES): Add ref-add.sed and ref-del.sed.
24101
24102 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
24103
24104         * lib/config.charset: Output a line containing "Packages using this
24105         file".
24106         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
24107         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
24108         ref-del.sed): New rules.
24109
24110 2000-03-17  Jim Meyering  <meyering@lucent.com>
24111
24112         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
24113         Otherwise, include <strings.h>
24114
24115 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
24116
24117         * lib/unicodeio.c (utf8_wctomb): New function.
24118         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
24119         format instead of in UCS-4 with platform dependent endianness.
24120
24121 2000-03-10  Jim Meyering  <meyering@lucent.com>
24122
24123         * m4/lib-check.m4: Look for getspnam in -lgen, too.
24124         From Marco Franzen.
24125
24126 2000-03-07  Paul Eggert  <eggert@twinsun.com>
24127
24128         * lib/savedir.c (savedir): Work even if directory size is
24129         negative; this can happen with some screwy NFS configurations.
24130
24131 2000-03-06  Jim Meyering  <meyering@lucent.com>
24132
24133         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
24134         if it's NULL (because we ran out of memory).  From Bruno Haible.
24135
24136 2000-03-05  Jim Meyering  <meyering@lucent.com>
24137
24138         * lib/localcharset.c ("path-concat.h"): Include.
24139         (get_charset_aliases): Use path_concat instead of ANSI string
24140         concatenation.
24141
24142         * lib/unicodeio.h (PARAMS): Define.
24143         Use it to guard prototype.
24144
24145 2000-03-04  Jim Meyering  <meyering@lucent.com>
24146
24147         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
24148         for lib/localcharset.c.
24149
24150 2000-03-04  Jim Meyering  <meyering@lucent.com>
24151
24152         * lib/Makefile.am (install-exec-local): Create $(libdir) before
24153         installing into it.
24154         (uninstall-local): Uncomment this rule so `make distcheck' works
24155         once again.
24156
24157         * lib/unicodeio.c (<errno.h>): Include it.
24158         (errno): Declare if not defined.
24159
24160         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
24161
24162         * lib/config.charset: New version, incorporating remarks from a linux
24163         i18n mailing list.  From Bruno Haible.
24164
24165 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
24166
24167         * m4/codeset.m4: New file.
24168         * m4/iconv.m4: New file.
24169         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
24170
24171 2000-03-03  Jim Meyering  <meyering@lucent.com>
24172
24173         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
24174
24175 2000-03-02  Jim Meyering  <meyering@lucent.com>
24176
24177         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
24178         the messages come out on separate lines.
24179
24180         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
24181         rather than jm_CHECK_DECLARATIONS.
24182         * m4/decl.m4: Remove now-unused file.
24183
24184         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
24185         geteuid.
24186
24187 2000-03-02  Jim Meyering  <meyering@lucent.com>
24188
24189         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
24190
24191 2000-03-01  Jim Meyering  <meyering@lucent.com>
24192
24193         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
24194         * lib/unicodeio.c: Likewise.
24195
24196 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
24197
24198         * lib/config.charset: New file.
24199         * lib/localcharset.c: New file.
24200         * lib/unicodeio.h, lib/unicodeio.c: New files.
24201         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
24202         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
24203         (noinst_HEADERS): Add unicodeio.h.
24204         (all-local, install-exec-local, charset.alias): New targets.
24205
24206 2000-02-28  Paul Eggert  <eggert@twinsun.com>
24207
24208         * lib/quotearg.c (ALERT_CHAR): New macro.
24209         (quotearg_buffer_restyled): Use it.
24210
24211 2000-02-27  Jim Meyering  <meyering@lucent.com>
24212
24213         * m4/check-decl.m4: Add getenv to the list.
24214
24215 2000-02-27  Jim Meyering  <meyering@lucent.com>
24216
24217         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
24218         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
24219
24220         * lib/backupfile.c: Guard inclusion of stdlib.h with
24221         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
24222         Declare malloc if needed.
24223
24224         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
24225         `#ifndef HAVE_DECL..'
24226         now that autoconf always defines the HAVE_DECL_ symbols.
24227         * lib/human.c: Likewise.
24228         * lib/same.c: Likewise.
24229         * lib/strtoumax.c: Likewise.
24230
24231         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
24232         declaration check was not run.
24233         * lib/hash.c: Likewise.
24234         * lib/human.c: Likewise.
24235         * lib/same.c: Likewise.
24236         * lib/strtoumax.c: Likewise.
24237
24238         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
24239         `.', then first look up the entire `.'-containing string as a login
24240         name.
24241
24242 2000-02-23  Jim Meyering  <meyering@lucent.com>
24243
24244         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
24245         in place of my hack.
24246
24247 2000-02-18  Paul Eggert  <eggert@twinsun.com>
24248
24249         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
24250         (textint): New typedef.
24251         (parser_control): Member year changed from int to textint.
24252         All uses changed.
24253         (YYSTYPE): Removed; replaced by %union with int and textint members.
24254         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
24255         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
24256         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
24257         (tSNUMBER, tUNUMBER): Now of type <textintval>.
24258         (date, number, to_year): Use width of number in digits, not its value,
24259         to determine whether it's a 2-digit year, or a 2-digit time.
24260         (yylex): Store number of digits of numeric tokens.
24261         Reported by John Kendall.
24262
24263         (parser_control): Changed from struct parser_control to typedef (for
24264         consistency).  All uses changed.
24265
24266         (tID): Removed; not used.
24267         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
24268
24269 2000-02-14  Paul Eggert  <eggert@twinsun.com>
24270
24271         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
24272         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
24273
24274 2000-02-12  Jim Meyering  <meyering@lucent.com>
24275
24276         * lib/userspec.c (ISDIGIT): Define it.
24277         (isdigit): Remove definition.
24278         (is_number): Use ISDIGIT, not isdigit.
24279         <libintl.h>: Include.
24280         (_ and N_): Define.
24281         (parse_user_spec): Mark translatable strings.
24282
24283 2000-02-10  Jim Meyering  <meyering@lucent.com>
24284
24285         With these changes, nanosleep.[ch] are finally enough like the other
24286         lib/* replacement files to compile on a few more losing systems.
24287
24288         * lib/nanosleep.h: Don't include config.h.
24289         Remove prototype from declaration of nanosleep.
24290         (PARAMS): Remove now-unneeded definition.
24291         * lib/nanosleep.c: #undef nanosleep.
24292         (rpl_nanosleep): Rename from nanosleep.
24293
24294 2000-02-10  Jim Meyering  <meyering@lucent.com>
24295
24296         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
24297         gnu_nanosleep to rpl_nanosleep.
24298
24299 2000-02-09  Jim Meyering  <meyering@lucent.com>
24300
24301         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
24302         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
24303
24304 2000-02-08  Akim Demaille  <akim@epita.fr>
24305
24306         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
24307         `[' and `]' and remove uses of `changequote'.
24308         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
24309         (AC_SYS_LARGEFILE): Likewise.
24310         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
24311         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
24312         of changequote.
24313         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
24314         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
24315         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
24316         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
24317
24318 2000-02-05  Jim Meyering  <meyering@lucent.com>
24319
24320         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
24321         Remove explicit use of AC_HEADER_TIME.  It is required by
24322         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
24323         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
24324         in autoconf whereby the expansion of the latter ended up preceding
24325         the expansion of its prerequisite, AC_HEADER_TIME.
24326         Reported by Volker Borchert.
24327
24328 2000-02-03  Jim Meyering  <meyering@lucent.com>
24329
24330         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
24331
24332 2000-02-03  Jim Meyering  <meyering@lucent.com>
24333
24334         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
24335         rather than with `#if HAVE_UTMPNAME'.
24336
24337 2000-02-02  Jim Meyering  <meyering@lucent.com>
24338
24339         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
24340         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
24341         Reported by Eli Zaretskii.
24342
24343 2000-02-01  Jim Meyering  <meyering@lucent.com>
24344
24345         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
24346
24347 2000-01-31  Jim Meyering  <meyering@lucent.com>
24348
24349         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
24350         functions.  Add the time.h and sys/time.h headers along with the
24351         AC_REQUIRE'ment of AC_HEADER_TIME.
24352
24353 2000-01-31  Jim Meyering  <meyering@lucent.com>
24354
24355         * lib/nanosleep.h (nanosleep): Guard declaration with
24356         `#if ! HAVE_DECL_NANOSLEEP'.
24357         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
24358         the declaration in that vendor's sys/timers.h.
24359         Reported by Christian Krackowizer.
24360
24361         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
24362         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
24363         (ISPRINT): Likewise.
24364         Reported by Tom Tromey.
24365
24366 2000-01-30  Jim Meyering  <meyering@lucent.com>
24367
24368         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
24369
24370         * m4/prereq.m4 (utmp_includes): Define.
24371         Check for ut_user and ut_name members in both struct utmpx
24372         and struct utmp.
24373
24374 2000-01-30  Jim Meyering  <meyering@lucent.com>
24375
24376         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
24377         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
24378         header files where only utmpx.ut_user is declared.
24379
24380         * lib/readutmp.h (UT_USER): Define.
24381
24382 2000-01-29  Jim Meyering  <meyering@lucent.com>
24383
24384         * m4/lib-check.m4: New file containing library-related checks from
24385         fileutils and sh-utils (textutils had none).
24386
24387 2000-01-28  Jim Meyering  <meyering@lucent.com>
24388
24389         * m4/perl.m4: Change format of warning message to look more like that
24390         from the missing script.  Suggestion from François Pinard.
24391
24392 2000-01-25  Jim Meyering  <meyering@lucent.com>
24393
24394         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
24395         well as time.h in the compile check.
24396         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
24397         Fix typo in cross-compiling case: s/yes/no/.
24398
24399 2000-01-23  Jim Meyering  <meyering@lucent.com>
24400
24401         * m4/jm-macros.m4: Move df-related tests here from
24402         fileutils/configure.in
24403
24404         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
24405         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
24406
24407         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
24408         s/space/ac_fsusage_space/.
24409         (jm_FILE_SYSTEM_USAGE): Take two parameters.
24410
24411         * m4/ftruncate.m4: New file (derived from part of
24412         fileutils/configure.in).
24413         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
24414         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
24415
24416         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
24417         AC_SUBST these here, rather than just in sh-util/configure.in, so
24418         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
24419         all the same.
24420         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
24421         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
24422         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
24423         (AC_SUBST(POW_LIBM)): Likewise.
24424         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
24425
24426 2000-01-23  Jim Meyering  <meyering@lucent.com>
24427
24428         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
24429         obstack.c.
24430
24431 2000-01-22  Jim Meyering  <meyering@lucent.com>
24432
24433         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
24434
24435         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
24436
24437         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
24438         configure.in
24439         (AC_CHECK_HEADERS): Likewise for sh-utils.
24440         (AC_CHECK_HEADERS): Likewise for textutils.
24441         Merge the three lists of headers.
24442
24443         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
24444         from fileutils' configure.in.
24445
24446         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
24447         code. Moved tests into their own function (_jm_DECL_HEADERS) in
24448         check-decl.m4.
24449
24450         * m4/check-decl.m4: Use #if rather than #ifdef.
24451         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
24452         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
24453         (_jm_DECL_HEADERS): Define new function.
24454         (jm_CHECK_DECLARATIONS): Require it.
24455
24456 2000-01-22  Jim Meyering  <meyering@lucent.com>
24457
24458         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
24459         [! HAVE_DECL_STRTOULL]: Declare strtoull.
24460         Required for some AIX systems.  Reported by Christian Krackowizer.
24461         [TESTING] (main): New function.
24462
24463         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
24464         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
24465         letters.
24466
24467         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
24468         iswprint.
24469
24470         * lib/strverscmp.c (ISDIGIT): Define.
24471         (strverscmp): Use ISDIGIT, not isdigit.
24472
24473 2000-01-19  Jim Meyering  <meyering@lucent.com>
24474
24475         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
24476         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
24477         defines `struct timespec' in <sys/time.h>
24478
24479         * m4/c-bs-a.m4: Remove uses of changequote altogether.
24480         Thanks to Akim for explaining.
24481
24482 2000-01-17  Paul Eggert  <eggert@twinsun.com>
24483
24484         * lib/nanosleep.c (nanosleep):
24485         Don't use SA_INTERRUPT to decide whether to call sigaction, as
24486         POSIX.1 doesn't require SA_INTERRUPT and some systems
24487         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
24488         it's been part of POSIX.1 since day 1 (in 1988).
24489
24490 2000-01-17  Jim Meyering  <meyering@lucent.com>
24491
24492         * lib/interlock: Remove unused file.  Reported by François Pinard.
24493
24494 2000-01-16  Paul Eggert  <eggert@twinsun.com>
24495
24496         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
24497         alert, backslash, formfeed, and vertical tab unnecessarily in
24498         shell quoting style.
24499
24500 2000-01-16  Jim Meyering  <meyering@lucent.com>
24501
24502         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
24503         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
24504         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
24505         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
24506
24507 2000-01-16  Jim Meyering  <meyering@lucent.com>
24508
24509         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
24510         because the latter didn't work.
24511
24512 2000-01-15  Jim Meyering  <meyering@lucent.com>
24513
24514         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
24515         (AC_REPLACE_FUNCS): Add memcpy and memset.
24516         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
24517         Add strpbrk.
24518         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
24519
24520 2000-01-12  Jim Meyering  <meyering@lucent.com>
24521
24522         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
24523         (jm_PREREQ): Use it.
24524         (jm_PREREQ_READUTMP): New macro.
24525         (jm_PREREQ): Use it.
24526
24527 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24528
24529         Quote multibyte characters correctly.
24530         * m4/c-bs-a.m4: New file.
24531         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
24532         (jm_PREREQ): Use it.
24533
24534 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24535
24536         * m4/uintmax_t.m4: Port to autoconf 2.13.
24537
24538 2000-01-08  Jim Meyering  <meyering@ascend.com>
24539
24540         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
24541         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
24542
24543 2000-01-04  Jim Meyering  <meyering@ascend.com>
24544
24545         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
24546         jm_STRUCT_DIRENT_D_TYPE.
24547         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
24548         jm_STRUCT_DIRENT_D_INO.
24549         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
24550         jm_STRUCT_UTIMBUF.
24551         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
24552         renamings.
24553         * m4/utime.m4: Likewise.
24554
24555         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
24556         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
24557
24558 2000-01-03  Paul Eggert  <eggert@twinsun.com>
24559
24560         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
24561         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
24562
24563 2000-01-02  Jim Meyering  <meyering@ascend.com>
24564
24565         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
24566         remember if this is necessary.
24567
24568 1999-12-26  Jim Meyering  <meyering@ascend.com>
24569
24570         * m4/jm-macros.m4: Use it here.
24571         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
24572
24573 1999-12-23  Jim Meyering  <meyering@ascend.com>
24574
24575         * m4/jm-macros.m4: Check for clock_gettime (moved from
24576         fileutils/configure.in)
24577         Check for gettimeofday.
24578
24579 1999-12-20  Jim Meyering  <meyering@ascend.com>
24580
24581         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
24582         autoconf-2.14a-1999-12-20.
24583
24584 1999-12-19  Jim Meyering  <meyering@ascend.com>
24585
24586         * m4/lstat-slash.m4: New file.
24587         * m4/jm-macros.m4: Use the new macro:
24588         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24589
24590 1999-12-07  Jim Meyering  <meyering@ascend.com>
24591
24592         * m4/perl.m4: Require that File::Compare be available, too.
24593         Too many systems seem to lack it.
24594
24595         * m4/strftime.m4: Add checks for most of the cpp macros tested in
24596         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
24597
24598 1999-11-18  Paul Eggert  <eggert@twinsun.com>
24599
24600         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
24601         problem with the QNX 4.25 shell, which doesn't propagate exit
24602         status of failed commands inside shell assignments.
24603
24604 1999-11-17  Jim Meyering  <meyering@ascend.com>
24605
24606         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
24607
24608 1999-11-07  Jim Meyering  <meyering@ascend.com>
24609
24610         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
24611
24612 1999-11-06  Jim Meyering  <meyering@ascend.com>
24613
24614         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
24615         * m4/jm-macros.m4 (jm_MACROS): Use it here.
24616
24617 1999-11-05  Jim Meyering  <meyering@ascend.com>
24618
24619         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
24620         configure.in of textutils, fileutils, and sh-utils into this one
24621         (shared between those packages) file.
24622         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
24623         AC_STRUCT_ST_BLKSIZE.
24624
24625 1999-11-03  Jim Meyering  <meyering@ascend.com>
24626
24627         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
24628         of AC_CHECK_TYPE checks includes unistd.h.
24629         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
24630         Suggestion from Akim Demaille.
24631
24632 1999-10-30  Jim Meyering  <meyering@ascend.com>
24633
24634         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
24635         m4-quoted string.
24636         * m4/ls-mntd-fs.m4: Likewise.
24637         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
24638         * m4/jm-winsz1.m4: Likewise.
24639
24640         * m4/const.m4: Remove file, since the fix made it into the experimental
24641         version of autoconf.
24642         * m4/mktime.m4: Likewise.
24643
24644         * m4/check-type.m4: Remove file, now that the latest version of
24645         AC_CHECK_TYPE takes a third arg to specify additional #includes.
24646
24647         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
24648         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
24649         AC_CHECK_TYPE.
24650
24651 1999-10-04  Jim Meyering  <meyering@ascend.com>
24652
24653         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
24654
24655 1999-09-22  Paul Eggert  <eggert@twinsun.com>
24656
24657         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
24658         2.95.1 bug with HP-UX 10.20.
24659
24660 1999-09-17  Jim Meyering  <meyering@ascend.com>
24661
24662         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
24663         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
24664         due to missing strdup (against sh-utils-2.0).
24665
24666 1999-08-29  Jim Meyering  <meyering@ascend.com>
24667
24668         * m4/jm-macros.m4: Require jm_BISON.
24669         * m4/bison.m4: New file.
24670
24671 1999-08-17  Paul Eggert  <eggert@twinsun.com>
24672
24673         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
24674         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
24675
24676 1999-08-05  Jim Meyering  <meyering@ascend.com>
24677
24678         * m4/getline.m4: Rename test file from conftestdata to conftest.data
24679         to avoid conflicts with `conftest' on 8+3 filesystems.
24680         Suggestion from Eli Zaretskii.
24681
24682 1999-08-04  Jim Meyering  <meyering@ascend.com>
24683
24684         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
24685         fileutils and sh-utils (textutils's getline test was inadequate).
24686         (AM_FUNC_GETLINE): Run this test.
24687         (AC_CHECK_FUNCS): Check for getdelim.
24688         Reported by Bob Proulx.
24689
24690 1999-08-02  Jim Meyering  <meyering@ascend.com>
24691
24692         * m4/jm-macros.m4: Add a comment.
24693
24694 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24695
24696         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
24697         <inttypes.h> defines strtoumax as a macro (and not as a
24698         function).
24699
24700 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24701
24702         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
24703         that we can shift, multiply and divide unsigned long long
24704         values; Ultrix cc can't do it.
24705
24706 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24707
24708         * m4/mktime.m4: New file, which is a preview of what should appear
24709         in the next public autoconf release.
24710
24711 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24712
24713         * m4/lfs.m4: Remove this file.
24714         * m4/largefile.m4: New file.  It contains the old contents of
24715         lfs.m4, except that all names with prefix AC_LFS have been
24716         changed to use the prefix AC_SYS_LARGEFILE instead, to be
24717         compatible with future autoconf versions.  Also, some minor m4
24718         quoting problems have been fixed.
24719
24720 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24721
24722         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
24723         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
24724         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
24725         and simplify the shell code.
24726
24727 1999-08-01  Jim Meyering  <meyering@ascend.com>
24728
24729         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
24730         m4.
24731
24732 1999-07-20  Jim Meyering  <meyering@ascend.com>
24733
24734         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
24735
24736 1999-07-15  Jim Meyering  <meyering@ascend.com>
24737
24738         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
24739
24740 1999-05-22  Jim Meyering  <meyering@ascend.com>
24741
24742         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
24743
24744 1999-05-20  Jim Meyering  <meyering@ascend.com>
24745
24746         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
24747         Add a colon after each `then' in case $4 is empty.
24748
24749 1999-05-16  Jim Meyering  <meyering@ascend.com>
24750
24751         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
24752
24753 1999-05-10  Jim Meyering  <meyering@ascend.com>
24754
24755         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
24756
24757         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
24758         AC_FUNC_MKTIME.
24759
24760 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
24761
24762         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
24763
24764 1999-05-04  Paul Eggert  <eggert@twinsun.com>
24765
24766         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
24767         not CPPFLAGS, so that linking works correctly in IRIX.
24768
24769 1999-04-30  Paul Eggert  <eggert@twinsun.com>
24770
24771         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
24772
24773 1999-04-20  Paul Eggert  <eggert@twinsun.com>
24774
24775         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
24776         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
24777         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
24778         jm_AC_TYPE_UNSIGNED_LONG_LONG.
24779         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
24780
24781         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
24782
24783 1999-04-20  Jim Meyering  <meyering@ascend.com>
24784
24785         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
24786         AC_REPLACE xstroull if necessary.  From Paul Eggert.
24787         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
24788
24789 1999-04-18  Jim Meyering  <meyering@ascend.com>
24790
24791         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
24792         * m4/jm-macros.m4: Use it.
24793
24794 1999-04-06  Jim Meyering  <meyering@ascend.com>
24795
24796         * m4/strftime.m4: Remove test for %f.
24797
24798 1999-03-29  Jim Meyering  <meyering@ascend.com>
24799
24800         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
24801         superset of the AC_TYPE_* checks in the textutils, fileutils,
24802         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
24803         AC_TYPE_PID_T.
24804
24805 1999-03-28  Jim Meyering  <meyering@ascend.com>
24806
24807         * m4/jm-macros.m4: Define GNU_PACKAGE here.
24808         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
24809         replaced e.g., in the *.sh files of the sh-utils.
24810
24811 1999-03-20  Jim Meyering  <meyering@ascend.com>
24812
24813         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
24814         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
24815         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
24816
24817 1999-03-19  Jim Meyering  <meyering@ascend.com>
24818
24819         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
24820
24821 1999-03-12  Jim Meyering  <meyering@ascend.com>
24822
24823         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
24824
24825 1999-03-07  Jim Meyering  <meyering@ascend.com>
24826
24827         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
24828         declared.
24829
24830 1999-02-17  Jim Meyering  <meyering@ascend.com>
24831
24832         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
24833         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
24834
24835 1999-02-07  Jim Meyering  <meyering@ascend.com>
24836
24837         * m4/group-member.m4: New file -- extracted from sh-utils'
24838         configure.in.
24839
24840         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
24841         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
24842
24843 1999-02-06  Jim Meyering  <meyering@ascend.com>
24844
24845         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
24846         * m4/fnmatch.m4: Likewise.
24847         * m4/getgroups.m4: Likewise.
24848         * m4/lstat.m4: Likewise.
24849         * m4/malloc.m4: Likewise.
24850         * m4/putenv.m4: Likewise.
24851         * m4/realloc.m4: Likewise.
24852         * m4/regex.m4: Likewise.
24853         * m4/stat.m4: Likewise.
24854         * m4/strftime.m4: Likewise.
24855         Suggestion from Alain Magloire.
24856
24857         * m4/chown.m4: Use `.$ac_objext', not `.o'.
24858         * m4/fnmatch.m4: Likewise.
24859         * m4/getgroups.m4: Likewise.
24860         * m4/getline.m4: Likewise.
24861         * m4/lstat.m4: Likewise.
24862         * m4/malloc.m4: Likewise.
24863         * m4/memcmp.m4: Likewise.
24864         * m4/putenv.m4: Likewise.
24865         * m4/realloc.m4: Likewise.
24866         * m4/regex.m4: Likewise.
24867         * m4/stat.m4: Likewise.
24868         * m4/strftime.m4: Likewise.
24869         Suggestion from Alain Magloire.
24870
24871         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
24872         an argument.
24873
24874         * m4/regex.m4: Add a run-time Test for proper operation of
24875         re_compile_pattern.
24876
24877 1999-01-31  Jim Meyering  <meyering@ascend.com>
24878
24879         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
24880
24881 1999-01-30  Jim Meyering  <meyering@ascend.com>
24882
24883         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
24884
24885         * m4/jm-mktime.m4: Make this a wrapper around the official
24886         AM_FUNC_MKTIME rather than my private copy, now that the official one
24887         is up to date.
24888         * m4/mktime.m4: Remove file.
24889
24890         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
24891         * m4/uptime.m4: Likewise.
24892         * m4/uintmax_t.m4: Likewise.
24893
24894 1999-01-28  Jim Meyering  <meyering@ascend.com>
24895
24896         * m4/jm-macros.m4: Use jm_AFS.
24897         * m4/afs.m4: New file (from fileutils' configure.in).
24898
24899         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
24900         * m4/chown.m4: Likewise.
24901         * m4/d-ino.m4: Likewise.
24902         * m4/d-type.m4: Likewise.
24903         * m4/fnmatch.m4: Likewise.
24904         * m4/getgroups.m4: Likewise.
24905         * m4/gettext.m4: Likewise.
24906         * m4/jm-mktime.m4: Likewise.
24907         * m4/jm-winsz2.m4: Likewise.
24908         * m4/lcmessage.m4: Likewise.
24909         * m4/ls-mntd-fs.m4: Likewise.
24910         * m4/malloc.m4: Likewise.
24911         * m4/memcmp.m4: Likewise.
24912         * m4/putenv.m4: Likewise.
24913         * m4/realloc.m4: Likewise.
24914         * m4/st_mtim.m4: Likewise.
24915         * m4/strftime.m4: Likewise.
24916
24917 1999-01-16  Jim Meyering  <meyering@ascend.com>
24918
24919         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
24920         (ARGMATCH_DIE_DECL): Define.
24921
24922 1999-01-12  Jim Meyering  <meyering@ascend.com>
24923
24924         * m4/Makefile.am.in: Rewrite to avoid using fmt.
24925         Reported by Lars Hecking.
24926
24927 1999-01-10  Jim Meyering  <meyering@ascend.com>
24928
24929         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
24930         gross kludge.
24931         * m4/inttypes_h.m4: Likewise.
24932         * m4/lstat.m4: Likewise.
24933         * m4/malloc.m4: Likewise.
24934         * m4/readdir.m4: Likewise.
24935         * m4/realloc.m4: Likewise.
24936         * m4/st_dm_mode.m4: Likewise.
24937         * m4/stat.m4: Likewise.
24938         * m4/utimbuf.m4: Likewise.
24939         * m4/utimes.m4: Likewise.
24940
24941         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
24942         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
24943         comments in config.h.in are meaningful.
24944
24945         * m4/jm-macros.m4: Require autoconf-2.13 here.
24946
24947         * m4/regex.m4: By default, don't use the included regex.c on systems
24948         with glibc 2.  Suggestion from Uli Drepper.
24949
24950 1999-01-02  Jim Meyering  <meyering@ascend.com>
24951
24952         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
24953
24954 1998-12-18  Jim Meyering  <meyering@ascend.com>
24955
24956         * m4/Makefile.am.in (Makefile.am): Simplify rule.
24957         Based on a suggestion from Lars Hecking.
24958
24959 1998-11-16  Paul Eggert  <eggert@twinsun.com>
24960
24961         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
24962
24963 1998-11-16  Jim Meyering  <meyering@ascend.com>
24964
24965         * m4/lfs.m4: Double-quote the `uname...` expression.
24966
24967 1998-11-14  Jim Meyering  <meyering@ascend.com>
24968
24969         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
24970         * m4/stat.m4: Likewise.
24971
24972 1998-11-03  Jim Meyering  <meyering@ascend.com>
24973
24974         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
24975         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
24976
24977 1998-10-18  Jim Meyering  <meyering@ascend.com>
24978
24979         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
24980
24981 1998-10-17  Jim Meyering  <meyering@ascend.com>
24982
24983         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
24984         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
24985         calls for those previously hard-coded headers.  Instead, take a new
24986         parameter.
24987         (jm_CHECK_DECLARATIONS): Reflect interface change.
24988         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
24989         (jm_CHECK_DECL_LOCALTIME_R): New macro.
24990
24991         * m4/mktime.m4: Test for spring-forward gap before long-running test.
24992
24993 1998-10-14  Jim Meyering  <meyering@ascend.com>
24994
24995         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
24996         instead of "TZ=America/Vancouver".  From Paul Eggert.
24997
24998 1998-10-11  Jim Meyering  <meyering@ascend.com>
24999
25000         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
25001         This adds a test for a recently added compatibility fix for mktime.c.
25002         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
25003
25004 1998-09-27  Jim Meyering  <meyering@ascend.com>
25005
25006         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
25007
25008         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
25009         ../configure.in, including a change from Gordon Matzigkeit to allow
25010         cross-compiling for the Hurd.
25011
25012         * m4/glibc.m4: New file/macro to test for the GNU C Library
25013         versions 1 and 2.  From Gordon Matzigkeit.
25014         Indent.
25015
25016 1998-09-21  Jim Meyering  <meyering@ascend.com>
25017
25018         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
25019
25020 1998-08-18  Paul Eggert  <eggert@twinsun.com>
25021
25022         Port nanosecond-resolution times to UnixWare 2.1.2 and
25023         pedantic Solaris 2.6.
25024
25025         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
25026         AC_STRUCT_ST_MTIM.
25027         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
25028         Generate name of ns member, instead of just 1 or undef.
25029         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
25030
25031 1998-08-15  Jim Meyering  <meyering@ascend.com>
25032
25033         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
25034         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
25035         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
25036         instead of jm_TYPE_SSIZE_T.
25037
25038 1998-08-12  Jim Meyering  <meyering@ascend.com>
25039
25040         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
25041
25042 1998-08-02  Jim Meyering  <meyering@ascend.com>
25043
25044         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
25045         in acconfig.h manually.
25046
25047 1998-07-31  Paul Eggert  <eggert@twinsun.com>
25048
25049         * m4/st_mtim.m4: New file.
25050
25051 1998-07-28  Jim Meyering  <meyering@ascend.com>
25052
25053         * m4/utimes.m4: Undef stat.
25054
25055 1998-07-25  Jim Meyering  <meyering@ascend.com>
25056
25057         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
25058         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
25059
25060 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
25061
25062         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
25063         uid and gid actually remain unchanged.
25064
25065 1998-07-07  Jim Meyering  <meyering@ascend.com>
25066
25067         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
25068
25069 1998-07-04  Jim Meyering  <meyering@ascend.com>
25070
25071         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
25072         to prove that this macro can be used in packages without regex.c.
25073
25074 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
25075
25076         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
25077         is to be used.
25078
25079 1998-07-03  Jim Meyering  <meyering@ascend.com>
25080
25081         * m4/gettext.m4: Add -lintl if it's found to be necessary.
25082
25083         * m4/gettext.m4: New file -- from gettext-0.10.35.
25084         * m4/lcmessage.m4: Likewise.
25085         * m4/progtest.m4: Likewise.
25086
25087         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
25088         * m4/jm-macros.m4: Require the new macro.
25089
25090 1998-06-29  Jim Meyering  <meyering@ascend.com>
25091
25092         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
25093         for the definition of NGROUPS (used in a system header included
25094         by sys/mount.h).
25095
25096 1998-06-28  Jim Meyering  <meyering@ascend.com>
25097
25098         * m4/ls-mntd-fs.m4: New file.
25099         * m4/fstypename.m4: New file.
25100
25101         * m4/jm-macros.m4: Require the new macro.
25102         * m4/jm-glibc-io.m4: New file.
25103
25104 1998-05-19  Jim Meyering  <meyering@ascend.com>
25105
25106         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
25107         * m4/lchown.m4: New file.
25108
25109         * m4/Makefile.am.in: New file.
25110         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
25111
25112 1998-05-14  Jim Meyering  <meyering@ascend.com>
25113
25114         * m4/Makefile.am (EXTRA_DIST): Add them.
25115         * m4/jm-macros.m4: New file.
25116         * m4/utimbuf.m4: New file.
25117
25118 1998-05-12  Jim Meyering  <meyering@ascend.com>
25119
25120         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
25121
25122 1998-05-11  Jim Meyering  <meyering@ascend.com>
25123
25124         * m4/isc-posix.m4: New file.
25125
25126 1998-05-10  Jim Meyering  <meyering@ascend.com>
25127
25128         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
25129
25130 1998-05-09  Jim Meyering  <meyering@ascend.com>
25131
25132         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
25133         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
25134         with automake.
25135
25136         * m4/ssize_t.m4: New file.
25137         * m4/mktime.m4: Remove file -- the new automake has this now.
25138
25139 1998-04-26  Jim Meyering  <meyering@ascend.com>
25140
25141         * m4/assert.m4: New file.
25142         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
25143
25144 1998-04-05  Jim Meyering  <meyering@ascend.com>
25145
25146         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
25147         (jm_PREREQ): Use it here.
25148
25149 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
25150
25151         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
25152         in acconfig.h.
25153
25154 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
25155
25156         * m4/prereq.m4: New file.
25157         * m4/error.m4: New file.
25158         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
25159
25160 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
25161
25162         * m4/getline.m4: Don't set am_cv_func_working_getline before the
25163         cache-check for the same variable -- that defeated the purpose of
25164         the test; the test program was never run.  This was a problem only
25165         on systems with losing getline functions -- HP-UX 10.20 is one.
25166         Reported by Bjorn Helgaas.
25167
25168 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
25169
25170         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
25171
25172 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
25173
25174         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
25175
25176         * m4/const.m4: New file.  Use an initializer in this declaration
25177         typedef int charset[2]; const charset x;
25178         Reported by Bob Glickstein.
25179
25180 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
25181
25182         * m4/chown.m4: Fix reversed types on -1 args to chown.
25183         From Kaveh Ghazi.
25184
25185 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
25186
25187         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
25188         Add lseek and memchr.
25189
25190         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
25191         T.E.Dickey <dickey@clark.net> said that some older preprocessors
25192         have a 20-character limit on names.
25193
25194 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
25195
25196         * m4/inttypes_h.m4: New file.
25197         * m4/uintmax_t.m4: New file.
25198         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
25199
25200 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
25201   Free Software Foundation, Inc.
25202 Copying and distribution of this file, with or without modification,
25203 are permitted provided the copyright notice and this notice are preserved.