Exclude all files inside the CVS directory.
[pspp] / ChangeLog
1 2007-01-11  Bruno Haible  <bruno@clisp.org>
2
3         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
4         directory.
5
6 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7
8         Use @...@ consistently in lib/wctype_.h.
9         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
10         on it being set to 1 or 0.
11         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
12         go back to AC_SUBSTing it.
13         * modules/wctype (Makefile.am): Undo previous change.
14
15 2007-01-10  Eric Blake  <ebb9@byu.net>
16
17         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
18         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
19         * modules/wctype (Makefile.am): Likewise.
20         Reported by Chris McGuire.
21
22 2007-01-10  Jim Meyering  <jim@meyering.net>
23
24         fts.c: a small readability/maintainability improvement
25         * lib/fts.c (fts_read): Make this code slightly more readable and
26         maintainable by hoisting the "sp->fts_cur = p" assignments to
27         immediately follow the statements that set P.  Derived from
28         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
29
30 2007-01-10  Eric Blake  <ebb9@byu.net>
31
32         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
33         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
34         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
35         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
36         Reported by Chris McGuire.
37
38 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39
40         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
41         in sed script.
42
43 2007-01-09  Bruno Haible  <bruno@clisp.org>
44
45         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
46         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
47         variables.
48         (func_module): Use them.
49
50 2007-01-09  Bruno Haible  <bruno@clisp.org>
51
52         * modules/unistr/base: New file.
53         * lib/unistr.h: New file.
54
55         * modules/unistr/u8-to-u16: New file.
56         * lib/unistr/u8-to-u16.c: New file.
57
58         * modules/unistr/u8-to-u32: New file.
59         * lib/unistr/u8-to-u32.c: New file.
60
61         * modules/unistr/u16-to-u8: New file.
62         * lib/unistr/u16-to-u8.c: New file.
63
64         * modules/unistr/u16-to-u32: New file.
65         * lib/unistr/u16-to-u32.c: New file.
66
67         * modules/unistr/u32-to-u8: New file.
68         * lib/unistr/u32-to-u8.c: New file.
69
70         * modules/unistr/u32-to-u16: New file.
71         * lib/unistr/u32-to-u16.c: New file.
72
73         * modules/unistr/u8-check: New file.
74         * modules/unistr/u16-check: New file.
75         * modules/unistr/u32-check: New file.
76         * lib/unistr/u8-check.c: New file.
77         * lib/unistr/u16-check.c: New file.
78         * lib/unistr/u32-check.c: New file.
79
80         * modules/unistr/u8-chr: New file.
81         * modules/unistr/u16-chr: New file.
82         * modules/unistr/u32-chr: New file.
83         * lib/unistr/u8-chr.c: New file.
84         * lib/unistr/u16-chr.c: New file.
85         * lib/unistr/u32-chr.c: New file.
86
87         * modules/unistr/u8-cmp: New file.
88         * modules/unistr/u16-cmp: New file.
89         * modules/unistr/u32-cmp: New file.
90         * lib/unistr/u8-cmp.c: New file.
91         * lib/unistr/u16-cmp.c: New file.
92         * lib/unistr/u32-cmp.c: New file.
93
94         * modules/unistr/u8-cpy: New file.
95         * modules/unistr/u16-cpy: New file.
96         * modules/unistr/u32-cpy: New file.
97         * lib/unistr/u8-cpy.c: New file.
98         * lib/unistr/u16-cpy.c: New file.
99         * lib/unistr/u32-cpy.c: New file.
100         * lib/unistr/u-cpy.h: New file.
101
102         * modules/unistr/u8-cpy-alloc: New file.
103         * modules/unistr/u16-cpy-alloc: New file.
104         * modules/unistr/u32-cpy-alloc: New file.
105         * lib/unistr/u8-cpy-alloc.c: New file.
106         * lib/unistr/u16-cpy-alloc.c: New file.
107         * lib/unistr/u32-cpy-alloc.c: New file.
108         * lib/unistr/u-cpy-alloc.h: New file.
109
110         * modules/unistr/u8-endswith: New file.
111         * modules/unistr/u16-endswith: New file.
112         * modules/unistr/u32-endswith: New file.
113         * lib/unistr/u8-endswith.c: New file.
114         * lib/unistr/u16-endswith.c: New file.
115         * lib/unistr/u32-endswith.c: New file.
116         * lib/unistr/u-endswith.h: New file.
117
118         * modules/unistr/u8-mblen: New file.
119         * modules/unistr/u16-mblen: New file.
120         * modules/unistr/u32-mblen: New file.
121         * lib/unistr/u8-mblen.c: New file.
122         * lib/unistr/u16-mblen.c: New file.
123         * lib/unistr/u32-mblen.c: New file.
124
125         * modules/unistr/u8-mbtouc: New file.
126         * modules/unistr/u16-mbtouc: New file.
127         * modules/unistr/u32-mbtouc: New file.
128         * lib/unistr/u8-mbtouc.c: New file.
129         * lib/unistr/u16-mbtouc.c: New file.
130         * lib/unistr/u32-mbtouc.c: New file.
131
132         * modules/unistr/u8-mbtouc-safe: New file.
133         * modules/unistr/u16-mbtouc-safe: New file.
134         * modules/unistr/u32-mbtouc-safe: New file.
135         * lib/unistr/u8-mbtouc-safe.c: New file.
136         * lib/unistr/u16-mbtouc-safe.c: New file.
137         * lib/unistr/u32-mbtouc-safe.c: New file.
138
139         * modules/unistr/u8-move: New file.
140         * modules/unistr/u16-move: New file.
141         * modules/unistr/u32-move: New file.
142         * lib/unistr/u8-move.c: New file.
143         * lib/unistr/u16-move.c: New file.
144         * lib/unistr/u32-move.c: New file.
145         * lib/unistr/u-move.h: New file.
146
147         * modules/unistr/u8-next: New file.
148         * modules/unistr/u16-next: New file.
149         * modules/unistr/u32-next: New file.
150         * lib/unistr/u8-next.c: New file.
151         * lib/unistr/u16-next.c: New file.
152         * lib/unistr/u32-next.c: New file.
153
154         * modules/unistr/u8-prev: New file.
155         * modules/unistr/u16-prev: New file.
156         * modules/unistr/u32-prev: New file.
157         * lib/unistr/u8-prev.c: New file.
158         * lib/unistr/u16-prev.c: New file.
159         * lib/unistr/u32-prev.c: New file.
160
161         * modules/unistr/u8-set: New file.
162         * modules/unistr/u16-set: New file.
163         * modules/unistr/u32-set: New file.
164         * lib/unistr/u8-set.c: New file.
165         * lib/unistr/u16-set.c: New file.
166         * lib/unistr/u32-set.c: New file.
167         * lib/unistr/u-set.h: New file.
168
169         * modules/unistr/u8-startswith: New file.
170         * modules/unistr/u16-startswith: New file.
171         * modules/unistr/u32-startswith: New file.
172         * lib/unistr/u8-startswith.c: New file.
173         * lib/unistr/u16-startswith.c: New file.
174         * lib/unistr/u32-startswith.c: New file.
175         * lib/unistr/u-startswith.h: New file.
176
177         * modules/unistr/u8-stpcpy: New file.
178         * modules/unistr/u16-stpcpy: New file.
179         * modules/unistr/u32-stpcpy: New file.
180         * lib/unistr/u8-stpcpy.c: New file.
181         * lib/unistr/u16-stpcpy.c: New file.
182         * lib/unistr/u32-stpcpy.c: New file.
183         * lib/unistr/u-stpcpy.h: New file.
184
185         * modules/unistr/u8-stpncpy: New file.
186         * modules/unistr/u16-stpncpy: New file.
187         * modules/unistr/u32-stpncpy: New file.
188         * lib/unistr/u8-stpncpy.c: New file.
189         * lib/unistr/u16-stpncpy.c: New file.
190         * lib/unistr/u32-stpncpy.c: New file.
191         * lib/unistr/u-stpncpy.h: New file.
192
193         * modules/unistr/u8-strcat: New file.
194         * modules/unistr/u16-strcat: New file.
195         * modules/unistr/u32-strcat: New file.
196         * lib/unistr/u8-strcat.c: New file.
197         * lib/unistr/u16-strcat.c: New file.
198         * lib/unistr/u32-strcat.c: New file.
199         * lib/unistr/u-strcat.h: New file.
200
201         * modules/unistr/u8-strchr: New file.
202         * modules/unistr/u16-strchr: New file.
203         * modules/unistr/u32-strchr: New file.
204         * lib/unistr/u8-strchr.c: New file.
205         * lib/unistr/u16-strchr.c: New file.
206         * lib/unistr/u32-strchr.c: New file.
207
208         * modules/unistr/u8-strcmp: New file.
209         * modules/unistr/u16-strcmp: New file.
210         * modules/unistr/u32-strcmp: New file.
211         * lib/unistr/u8-strcmp.c: New file.
212         * lib/unistr/u16-strcmp.c: New file.
213         * lib/unistr/u32-strcmp.c: New file.
214
215         * modules/unistr/u8-strcpy: New file.
216         * modules/unistr/u16-strcpy: New file.
217         * modules/unistr/u32-strcpy: New file.
218         * lib/unistr/u8-strcpy.c: New file.
219         * lib/unistr/u16-strcpy.c: New file.
220         * lib/unistr/u32-strcpy.c: New file.
221         * lib/unistr/u-strcpy.h: New file.
222
223         * modules/unistr/u8-strcspn: New file.
224         * modules/unistr/u16-strcspn: New file.
225         * modules/unistr/u32-strcspn: New file.
226         * lib/unistr/u8-strcspn.c: New file.
227         * lib/unistr/u16-strcspn.c: New file.
228         * lib/unistr/u32-strcspn.c: New file.
229         * lib/unistr/u-strcspn.h: New file.
230
231         * modules/unistr/u8-strdup: New file.
232         * modules/unistr/u16-strdup: New file.
233         * modules/unistr/u32-strdup: New file.
234         * lib/unistr/u8-strdup.c: New file.
235         * lib/unistr/u16-strdup.c: New file.
236         * lib/unistr/u32-strdup.c: New file.
237         * lib/unistr/u-strdup.h: New file.
238
239         * modules/unistr/u8-strlen: New file.
240         * modules/unistr/u16-strlen: New file.
241         * modules/unistr/u32-strlen: New file.
242         * lib/unistr/u8-strlen.c: New file.
243         * lib/unistr/u16-strlen.c: New file.
244         * lib/unistr/u32-strlen.c: New file.
245         * lib/unistr/u-strlen.h: New file.
246
247         * modules/unistr/u8-strmblen: New file.
248         * modules/unistr/u16-strmblen: New file.
249         * modules/unistr/u32-strmblen: New file.
250         * lib/unistr/u8-strmblen.c: New file.
251         * lib/unistr/u16-strmblen.c: New file.
252         * lib/unistr/u32-strmblen.c: New file.
253
254         * modules/unistr/u8-strmbtouc: New file.
255         * modules/unistr/u16-strmbtouc: New file.
256         * modules/unistr/u32-strmbtouc: New file.
257         * lib/unistr/u8-strmbtouc.c: New file.
258         * lib/unistr/u16-strmbtouc.c: New file.
259         * lib/unistr/u32-strmbtouc.c: New file.
260
261         * modules/unistr/u8-strncat: New file.
262         * modules/unistr/u16-strncat: New file.
263         * modules/unistr/u32-strncat: New file.
264         * lib/unistr/u8-strncat.c: New file.
265         * lib/unistr/u16-strncat.c: New file.
266         * lib/unistr/u32-strncat.c: New file.
267         * lib/unistr/u-strncat.h: New file.
268
269         * modules/unistr/u8-strncmp: New file.
270         * modules/unistr/u16-strncmp: New file.
271         * modules/unistr/u32-strncmp: New file.
272         * lib/unistr/u8-strncmp.c: New file.
273         * lib/unistr/u16-strncmp.c: New file.
274         * lib/unistr/u32-strncmp.c: New file.
275
276         * modules/unistr/u8-strncpy: New file.
277         * modules/unistr/u16-strncpy: New file.
278         * modules/unistr/u32-strncpy: New file.
279         * lib/unistr/u8-strncpy.c: New file.
280         * lib/unistr/u16-strncpy.c: New file.
281         * lib/unistr/u32-strncpy.c: New file.
282         * lib/unistr/u-strncpy.h: New file.
283
284         * modules/unistr/u8-strnlen: New file.
285         * modules/unistr/u16-strnlen: New file.
286         * modules/unistr/u32-strnlen: New file.
287         * lib/unistr/u8-strnlen.c: New file.
288         * lib/unistr/u16-strnlen.c: New file.
289         * lib/unistr/u32-strnlen.c: New file.
290         * lib/unistr/u-strnlen.h: New file.
291
292         * modules/unistr/u8-strpbrk: New file.
293         * modules/unistr/u16-strpbrk: New file.
294         * modules/unistr/u32-strpbrk: New file.
295         * lib/unistr/u8-strpbrk.c: New file.
296         * lib/unistr/u16-strpbrk.c: New file.
297         * lib/unistr/u32-strpbrk.c: New file.
298         * lib/unistr/u-strpbrk.h: New file.
299
300         * modules/unistr/u8-strrchr: New file.
301         * modules/unistr/u16-strrchr: New file.
302         * modules/unistr/u32-strrchr: New file.
303         * lib/unistr/u8-strrchr.c: New file.
304         * lib/unistr/u16-strrchr.c: New file.
305         * lib/unistr/u32-strrchr.c: New file.
306
307         * modules/unistr/u8-strspn: New file.
308         * modules/unistr/u16-strspn: New file.
309         * modules/unistr/u32-strspn: New file.
310         * lib/unistr/u8-strspn.c: New file.
311         * lib/unistr/u16-strspn.c: New file.
312         * lib/unistr/u32-strspn.c: New file.
313         * lib/unistr/u-strspn.h: New file.
314
315         * modules/unistr/u8-strstr: New file.
316         * modules/unistr/u16-strstr: New file.
317         * modules/unistr/u32-strstr: New file.
318         * lib/unistr/u8-strstr.c: New file.
319         * lib/unistr/u16-strstr.c: New file.
320         * lib/unistr/u32-strstr.c: New file.
321         * lib/unistr/u-strstr.h: New file.
322
323         * modules/unistr/u8-strtok: New file.
324         * modules/unistr/u16-strtok: New file.
325         * modules/unistr/u32-strtok: New file.
326         * lib/unistr/u8-strtok.c: New file.
327         * lib/unistr/u16-strtok.c: New file.
328         * lib/unistr/u32-strtok.c: New file.
329         * lib/unistr/u-strtok.h: New file.
330
331         * modules/unistr/u8-uctomb: New file.
332         * modules/unistr/u16-uctomb: New file.
333         * modules/unistr/u32-uctomb: New file.
334         * lib/unistr/u8-uctomb.c: New file.
335         * lib/unistr/u16-uctomb.c: New file.
336         * lib/unistr/u32-uctomb.c: New file.
337
338         * MODULES.html.sh (Unicode string functions): Add the new modules.
339
340 2007-01-08  Bruno Haible  <bruno@clisp.org>
341
342         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
343         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
344         subdirectories.
345
346 2007-01-08  Karl Berry  <karl@gnu.org>
347
348         * doc/error.texi: mention that main() fns must set program_name
349         when progname is used.
350
351 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
352
353         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
354         WCTYPE_H is empty, for the benefit of builds from non-distclean
355         directories.  Problem reported by Eric Blake in
356         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
357
358 2007-01-08  Bruno Haible  <bruno@clisp.org>
359
360         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
361         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
362         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
363         PROVIDE_CANONICALIZE_FILENAME_MODE.
364         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
365
366 2007-01-08  Bruno Haible  <bruno@clisp.org>
367
368         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
369         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
370         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
371         * lib/fts.c: Likewise.
372         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
373
374 2006-12-25  Bruno Haible  <bruno@clisp.org>
375
376         * modules/utf8-ucs4-safe: New file.
377         * lib/utf8-ucs4-safe.h: New file.
378         * lib/unistr/utf8-ucs4-safe.c: New file.
379
380         * modules/utf16-ucs4-safe: New file.
381         * lib/utf16-ucs4-safe.h: New file.
382         * lib/unistr/utf16-ucs4-safe.c: New file.
383
384         * MODULES.html.sh (Unicode string functions): Add the new modules.
385
386 2007-01-08  Bruno Haible  <bruno@clisp.org>
387
388         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
389         (Depends-on): Add unitypes.
390         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
391         (u8_mbtouc_aux): Move out to separate file.
392         (u8_mbtouc): Use ucs4_t, uint8_t types.
393         * lib/unistr/utf8-ucs4.c: New file.
394
395         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
396         (Depends-on): Add unitypes.
397         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
398         (u16_mbtouc_aux): Move out to separate file.
399         (u16_mbtouc): Use ucs4_t, uint16_t types.
400         * lib/unistr/utf16-ucs4.c: New file.
401
402         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
403         (Depends-on): Add unitypes.
404         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
405         (u8_uctomb_aux): Move out to separate file.
406         (u8_uctomb): Use ucs4_t, uint8_t types.
407         * lib/unistr/ucs4-utf8.c: New file.
408
409         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
410         (Depends-on): Add unitypes.
411         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
412         (u16_uctomb_aux): Move out to separate file.
413         (u16_uctomb): Use ucs4_t, uint16_t types.
414         * lib/unistr/ucs4-utf16.c: New file.
415
416 2006-12-25  Bruno Haible  <bruno@clisp.org>
417
418         * modules/unitypes: New file.
419         * lib/unitypes.h: New file.
420         * MODULES.html.sh (func_all_modules): New section "Unicode string
421         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
422         this section. Add unitypes.
423
424 2007-01-08  Bruno Haible  <bruno@clisp.org>
425
426         Avoid variable names that conflict with those from libtool.
427         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
428         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
429         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
430         library_names_spec to acl_library_names_spec, hardcode_* to
431         acl_hardcode_*.
432         Reported by Ralf Wildenhues.
433
434 2007-01-08  Bruno Haible  <bruno@clisp.org>
435
436         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
437         definition.
438         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
439         definition.
440         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
441         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
442         definition.
443         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
444         definition.
445         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
446         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
447         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
448         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
449         definition.
450         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
451         definition.
452         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
453         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
454         GC_USE_<algorithm>.
455         * lib/gc-libgcrypt.c: Likewise.
456         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
457         * modules/gc-arctwo (configure.ac): Likewise.
458         * modules/gc-des (configure.ac): Likewise.
459         * modules/gc-hmac-md5 (configure.ac): Likewise.
460         * modules/gc-hmac-sha1 (configure.ac): Likewise.
461         * modules/gc-md2 (configure.ac): Likewise.
462         * modules/gc-md4 (configure.ac): Likewise.
463         * modules/gc-md5 (configure.ac): Likewise.
464         * modules/gc-random (configure.ac): Likewise.
465         * modules/gc-rijndael (configure.ac): Likewise.
466         * modules/gc-sha1 (configure.ac): Likewise.
467
468 2007-01-08  Bruno Haible  <bruno@clisp.org>
469
470         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
471         macro definition.
472         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
473         definition.
474         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
475         definition.
476         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
477         * modules/fcntl-safer (configure.ac): Likewise.
478         * modules/fopen-safer (configure.ac): Likewise.
479         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
480         GNULIB_FWRITEERROR macro definition.
481
482 2007-01-08  Bruno Haible  <bruno@clisp.org>
483
484         * m4/gnulib-common.m4: New file.
485         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
486         (func_get_filelist): Add m4/gnulib-common.m4.
487
488 2007-01-08  Bruno Haible  <bruno@clisp.org>
489
490         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
491         command.
492
493 2007-01-08  Jim Meyering  <jim@meyering.net>
494
495         Use a more robust test for a "can't happen" condition.
496         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
497         narrowed the st_size value.  Presuming the "can't happen" condition
498         is true, that narrowing could conceivably convert an invalid st_size
499         value into a valid one.  Instead, use a change based on Matthew
500         Woehlke's original patch.
501
502         Slight readability improvement: use an assert-like macro
503         in place of literal "abort ()" uses.
504         * lib/fts.c (fts_assert): Define.
505         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
506         Use this macro instead of a bare 'abort'.
507
508 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
509
510         Don't worry about using IRIX 5.3's wctype.h broken definitions;
511         simply work around them.
512         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
513         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
514         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
515         Don't bother to define as macros, since the standard doesn't require it.
516         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
517         longer worry about IRIX 5.3.
518         (HAVE_WCTYPE_CTMP_BUG): Remove.
519
520 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
521
522         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
523         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
524         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
525         Problems reported by Georg Schwarz for IRIX 5.3.
526
527         * gnulib-tool (autoconf_minversion): Take the maximum version number
528         found, not the minimum.  Problem reported by James Youngman.
529
530 2007-01-03  Karl Berry  <karl@gnu.org>
531
532         * doc/error.texi: new file, explaining interaction with progname.
533         * doc/gnulib.texi: include it.  Update copyright.
534
535 2007-01-03  Simon Josefsson  <simon@josefsson.org>
536
537         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
538         AC_CANONICAL_HOST, to improve autobuild outputs.
539
540 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
541             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
542
543         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
544         sockets, server sockets, and other file descriptors.  Count errors
545         to compute the return value.  Reorder the code a bit to be easier
546         to follow.  Don't set event bits that were not requested (except
547         POLLERR and POLLHUP).
548
549 2007-01-01  Bruno Haible  <bruno@clisp.org>
550
551         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
552
553 2007-01-03  Jim Meyering  <jim@meyering.net>
554
555         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
556
557 2007-01-02  Bruno Haible  <bruno@clisp.org>
558
559         * modules/settime (Include): Require timespec.h.
560         * modules/nanosleep (Include): Likewise.
561
562 2007-01-01  Bruno Haible  <bruno@clisp.org>
563
564         * gnulib-tool (func_emit_copyright_notice): Bump year.
565         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
566
567 2007-01-01  Bruno Haible  <bruno@clisp.org>
568
569         Improve support for OpenBSD.
570         * build-aux/config.rpath (libname_spec): Export.
571         (library_names_spec): New variable. Export.
572         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
573         library_names_spec from the config.rpath output. Locate shared library
574         through the name pattern in library_names_spec.
575
576 2007-01-01  Eric Blake  <ebb9@byu.net>
577
578         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
579
580 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
581
582         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
583         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
584         assume the C locale, and avoid an "eval" that could cause trouble.
585         Problem with SORT reported by Bob Proulx.
586
587         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
588         Define.  Trivial patch from Henning Nielsen Lund, originally
589         sent to bug-grep@gnu.org today.
590
591 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
592
593         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
594         struct stat.  Problem reported by Henning Nielsen Lund.
595         * lib/acl.c: Include acl.h first, to check interface.  Don't
596         bother to include sys/types.h and sys/stat.h again.
597
598 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
599
600         Import the following change from libc; problem reported by
601         Sven Verdoolaege.
602
603         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
604
605         [BZ #1373]
606         * lib/argp.h: Remove __NTH for __argp_usage inline function.
607
608 2006-12-28  Jim Meyering  <jim@meyering.net>
609
610         * build-aux/announce-gen: Do not assume that the package
611         builds any of tar.gz, tar.bz2, and .xdelta files.
612         Suggestion from Simon Josefsson.
613
614 2006-12-28  Simon Josefsson  <simon@josefsson.org>
615
616         * modules/announce-gen: New file.
617
618 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
619
620         * lib/mbchar.h: Just include <wctype.h>; the wctype module
621         handles its gotchas now.
622         * lib/mbswidth.c: Likewise.
623         * lib/wcwidth.h: Likewise.
624         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
625         and iswcntrl; the wctype module does this stuff now.
626         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
627         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
628         * modules/mbchar (Depends-on): Add wctype.
629         * modules/mbswidth (Depends-on): Likewise.
630         * modules/wcwidth (Depends-on): Likewise.
631
632 2006-12-27  Eric Blake  <ebb9@byu.net>
633
634         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
635         module uses more than what <wctype.h> is required to provide.
636
637 2006-12-26  Eric Blake  <ebb9@byu.net>
638
639         * gnulib-tool (sed_extract_prog): Avoid space-tab.
640
641 2006-12-26  Eric Blake  <ebb9@byu.net>
642
643         * modules/absolute-header: New module.
644         * modules/fcntl (Depends-on): Depend on it.
645         * modules/inttypes (Depends-on): Likewise.
646         * modules/stdint (Depends-on): Likewise.
647         * modules/sys_stat (Depends-on): Likewise.
648         * modules/wctype (Depends-on): Likewise.
649         * MODULES.html.sh (Support for building libraries and
650         executables): Document it.
651
652 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
653
654         * gnulib-tool (SED): Remove, undoing previous change.
655         The problem was that it broke coreutils on Solaris, because
656         "sed --posix" leaked into a makefile.
657         (sed): New alias, if 'alias' and GNU sed.
658
659 2006-12-24  Jim Meyering  <jim@meyering.net>
660
661         Work around an fchownat bug in glibc-2.4:
662         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
663         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
664         in spite of the -P option.
665         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
666         New macros.
667         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
668         * modules/openat (Files): Add lib/fchownat.c.
669         * lib/openat.c (fchownat): Don't define here.  Move to...
670         * lib/fchownat.c: ...this new file.
671
672 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
673
674         Fix bug reported by Bruno Haible in
675         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
676         where quotearg.c didn't compile on Mac OS X 10.2 because it
677         lacks <wchar.h> and wint_t.
678         * lib/wctype_.h (__wctype_wint_t): New type.
679         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
680         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
681         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
682         Arg is now of type __wctype_wint_t, not wint_t.
683         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
684         substitute HAVE_WINT_T.
685         * modules/wctype (Files): Add m4/wint_t.m4.
686         (wctype.h): Substitute HAVE_WINT_T.
687
688 2006-12-23  Bruno Haible  <bruno@clisp.org>
689
690         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
691
692 2006-12-23  Bruno Haible  <bruno@clisp.org>
693
694         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
695         S_ISLNK.
696         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
697         mingw.
698
699 2006-12-22  Bruno Haible  <bruno@clisp.org>
700
701         * lib/copy-file.c: Include acl.h.
702         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
703         Close the file descriptors only after being done with copy_acl.
704         * modules/copy-file (Depends-on): Add acl.
705
706 2006-12-22  Bruno Haible  <bruno@clisp.org>
707
708         * gnulib-tool (SED): New variable.
709         Use $SED instead of sed everywhere.
710
711 2006-12-22  Bruno Haible  <bruno@clisp.org>
712
713         * modules/no-c++: New file.
714         * m4/no-c++.m4: New file.
715         * MODULES.html.sh (Support for building libraries and executables):
716         Add no-c++.
717
718 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
719
720         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
721         Include <limits.h>, and use its INT_MAX to rewrite the
722         j loop so that it does not overflow 'int'.  Problem reported by
723         Ralf Wildenhues in
724         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
725         Play it safe by shifting left by 1 rather than multiplying by 2,
726         as GCC is less likely to optimize this away when the value
727         is signed (when it assumes overflow leads to undefined behavior).
728         Also, don't assume time_t uses two's complement.
729
730 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
731
732         * MODULES.html.sh: New module wctype.
733         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
734         * lib/fnmatch.c: Don't bother to include <wchar.h> before
735         <wctype.h>, since the new wctype module should fix this.
736         * lib/quotearg.c: Include <wctype.h> unconditionally, since
737         the wctype module should arrange for it.
738         * lib/regex_internal.h: Likewise.
739         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
740         since the wctype module should handle this now.
741         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
742         * modules/fnmatch (Depends-on): Add wctype.
743         * modules/quotearg (Depends-on): Likewise.
744         * modules/regex (Depends-on): Likewise.
745
746 2006-12-19  Bruno Haible  <bruno@clisp.org>
747
748         * lib/strdup.h [C++]: Wrap definitions in extern "C".
749         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
750
751 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
752
753         * modules/savewd (Depends-on): Fix dependency on fcntl.
754
755 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
756
757         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
758         conforms to C99, rather than relying on the user's environment
759         setting of STDINT_H.
760
761 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
762         and Eric Blake  <ebb9@byu.net>
763
764         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
765         This is more consistent with the other defines here.
766         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
767         Port to z/OS.  Problem reported by Paul Gilmartin.
768         Change local vars to use gl_ prefix rather than ac_.
769         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
770         with other defines.
771         * modules/double-slash-root: New module.
772         * modules/dirname (Files): Remove m4/double-slash-root.m4.
773         (Depends-on): Add double-slash-root.
774         * MODULES.html.sh (File system functions): Mention new module.
775
776 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
777
778         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
779         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
780         This is for the benefit of gzip, which doesn't do i18n.
781
782 2006-12-12  Jim Meyering  <jim@meyering.net>
783
784         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
785         Reported by Andreas Schwab <schwab@suse.de>.
786
787 2006-12-12  Bruno Haible  <bruno@clisp.org>
788
789         Merge these changes.
790         2006-09-05  Bruno Haible  <bruno@clisp.org>
791         * lib/iconvme.c (iconv_string): No need to save and restore errno when
792         iconv_alloc succeeded.
793         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
794         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
795         test for " && dest " at the end - dest is always != NULL there. Call
796         iconv with 4xNULL arguments initially, to reset the state. Call iconv
797         with 2xNULL arguments, also to flush the state storage. Handle the
798         IRIX iconv behaviour. Realloc the final result, to throw away unused
799         memory.
800
801 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
802
803         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
804         and fchmodat unconditionally, since glibc 2.4 has them.
805         Problem reported by Arkadiusz Miskiewicz.
806
807 2006-12-10  Bruno Haible  <bruno@clisp.org>
808
809         * gnulib-tool (func_import): Show the include files only for those
810         modules that are copied and specified.
811         Reported by Karl Berry.
812
813 2006-12-08  Jim Meyering  <jim@meyering.net>
814
815         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
816         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
817
818         * build-aux/announce-gen: Add two new options, both optional:
819         --bootstrap-tools=TOOL_LIST
820               a comma-separated list of tools, e.g.,
821               autoconf,automake,bison,gnulib
822         --gnulib-snapshot-date=DATE
823               if gnulib is in the bootstrap tool list,
824               then report this as the snapshot date.
825               If not specified, use the current date/time.
826               If you specify a date here, be sure it's UTC.
827
828 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
829
830         * tests/test-argp-2.sh: Fix test to match actual output.
831         (func_compare): Fix sed script to be portable.
832
833 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
834
835         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
836         workaround for this case.  It is not autoconfigured now; offhand
837         it's hard to see how to autoconfigure it.
838
839 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
840
841         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
842         a directory that is about to be chowned.  Such a directory's
843         initial file permissions should permit the owner only and this
844         should not be changed until after the chown, since the group and
845         other bits would be incorrect if they granted permission before
846         the chown.
847
848         Fix porting problem for iswctype reported by Georg Schwarz in:
849         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
850         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
851         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
852         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
853         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
854
855 2006-12-03  Jim Meyering  <jim@meyering.net>
856
857         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
858         p->fts_statp may not yet be defined.
859         (fts_read): Instead, set it in the caller, once p->fts_statp is
860         sure to be defined, and corresponds to a top-level directory.
861         This bug made du -x fail.  Here's the coreutils test case:
862         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
863         Reported by Mike Frysinger.
864
865 2006-12-01  Jim Meyering  <jim@meyering.net>
866
867         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
868         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
869         Reported by Simon Josefsson.
870
871 2006-11-30  Jim Meyering  <jim@meyering.net>
872
873         * m4/warning.m4: Use the all-permissive copyright notice
874         recommended by RMS (rather than LGPL).
875         * m4/vararrays.m4: Likewise.
876         * m4/flexmember.m4: Likewise.
877
878 2006-11-29  Bruno Haible  <bruno@clisp.org>
879
880         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
881         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
882         using +=.
883         Reported by Simon Josefsson <simon@josefsson.org>.
884
885 2006-11-28  James Youngman <jay@gnu.org>
886
887         * README: Advise users that they might find the bug-gnulib@gnu.org
888         and autotools-announce@gnu.org mailing lists useful.
889
890 2006-11-28  Bruno Haible  <bruno@clisp.org>
891
892         * m4/ptrdiff_max.m4: Remove file.
893
894 2006-11-21  Bruno Haible  <bruno@clisp.org>
895
896         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
897         _AC_COMPUTE_INT.
898         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
899         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
900         _AC_COMPUTE_INT.
901         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
902         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
903         _AC_COMPUTE_INT.
904         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
905
906 2006-11-28  Jim Meyering  <jim@meyering.net>
907
908         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
909         warning from "gcc -Wshadow" about shadowing the builtin.
910
911 2006-11-27  Bruno Haible  <bruno@clisp.org>
912
913         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
914         _AC_COMPUTE_INT.
915         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
916
917 2006-11-27  Bruno Haible  <bruno@clisp.org>
918             Paul Eggert  <eggert@cs.ucla.edu>
919
920         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
921
922 2006-11-26  Bruno Haible  <bruno@clisp.org>
923
924         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
925         noinst_LTLIBRARIES.
926
927 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
928             Bruno Haible  <bruno@clisp.org>
929
930         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
931         if compiling with "gcc -ansi".
932
933 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
934
935         Fix some incompatibilities with gcc -ansi -pedantic.
936         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
937         if compiling pedantically with GCC, unless it's C99 or later.
938         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
939         it mishandles gcc -ansi -pedantic as well.
940         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
941         if gcc -pedantic.
942         * lib/regexec.c (check_node_accept_bytes): Don't use auto
943         initializers for struct if -pedantic, unless it's C99 or later.
944
945 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
946
947         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
948         Don't close an fd more than once. Identical atimes indicate
949         success, not failure.
950
951 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
952
953         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
954
955 2006-11-23  Jim Meyering  <jim@meyering.net>
956
957         * build-aux/announce-gen: New file.  From coreutils.
958
959 2006-11-22  Jim Meyering  <jim@meyering.net>
960
961         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
962         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
963         (fts_read): Use a temporary to narrow the overused st_size member
964         before using it in a switch statement.  Reported by Matthew Woehlke.
965
966         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
967         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
968
969 2006-11-20  Bruno Haible  <bruno@clisp.org>
970
971         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
972         changequote instead of pairs of brackets.
973         Reported by Andreas Schwab <schwab@suse.de>.
974
975 2006-11-21  Jim Meyering  <jim@meyering.net>
976
977         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
978         so as to remain compatible with older compilers.
979         Patch from Michael Deutschmann.
980
981 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
982
983         * MODULES.html.sh (File system functions): Add openat.
984
985         * lib/openat.h (rpl_fstatat): New macro, if
986         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
987         (fstatat): Define to rpl_fstatat under the same conditions,
988         unless COMPILING_FSTATAT.
989         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
990         seems to have the bug.
991         * lib/fstatat.c: New file.
992         * modules/openat (Files): Add it.
993
994 2006-11-20  Bruno Haible  <bruno@clisp.org>
995
996         * Makefile: New file.
997
998 2006-11-20  Jim Meyering  <jim@meyering.net>
999
1000         The beginnings of syntax-related checks for gnulib.
1001         * lib/Makefile: New file.
1002         * lib/t-idcache: New script.  Ensure that the two halves of
1003         idcache.c stay in sync.
1004
1005         * lib/idcache.c: Adjust comments in user- and group- portions to
1006         be more accurate, and to be consistent with one another.
1007
1008 2006-11-20  Jim Meyering  <jim@meyering.net>
1009
1010         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
1011         continue using the flexible array member (thus, this module performs
1012         half as many malloc calls), with the addition that...
1013         (getgroup, getuser): Consistently record a non-match via an empty
1014         "name" string, and map an empty string match to a NULL return value.
1015         * modules/idcache (Depends-on): Re-add flexmember.
1016
1017         * lib/idcache.c (getuser): Remove all uses of the register keyword.
1018         (getuidbyname, getgroup, getgidbyname): Likewise.
1019
1020         Use cleaner syntax: NULL rather than 0.
1021         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
1022
1023 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1024
1025         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
1026         It mishandled the case where the group was missing.
1027         Problem reported by Greg Schafer.
1028         * modules/idcache: Likewise.
1029
1030 2006-11-18  Jim Meyering  <jim@meyering.net>
1031
1032         * check-module (%exempt_header): Add exception for some
1033         conditionally-included headers.
1034
1035         * modules/i-ring (Depends-on): Add verify.
1036         (License): Change to LGPL.
1037
1038 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
1039
1040         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
1041         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
1042         and inttostr.h.  Use snprintf rather than uinttostr, so that
1043         LGPLed code doesn't depend on GPLed.
1044
1045 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
1046
1047         * modules/inline (License): Change from GPL to LGPL.
1048
1049 2006-11-17  Jim Meyering  <jim@meyering.net>
1050
1051         * modules/d-type (License): Switch to LGPL.
1052
1053 2006-11-15  Bruno Haible  <bruno@clisp.org>
1054
1055         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
1056
1057 2006-11-15  Eric Blake  <ebb9@byu.net>
1058
1059         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
1060         the module dependency.
1061
1062 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1063             Bruno Haible  <bruno@clisp.org>
1064
1065         * gnulib-tool (func_create_testdir): Add license consistency check.
1066
1067 2006-11-15  Eric Blake  <ebb9@byu.net>
1068
1069         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
1070         random "(cached)" in configure output.
1071
1072 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1073
1074         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
1075         test for conforming inttypes.h is both announced and cached.
1076
1077         * MODULES.html.sh (seen_modules, seen_files): New variables.
1078         (func_module): Rewrite to use a few less gnulib-tool and sed
1079         invocations.  Avoid a couple of quadratic algorithms for ...
1080         (missed_modules, missed_files): ... these, with ...
1081         (func_append, func_tmpdir): ... these new functions, from
1082         gnulib-tool.  Analogously, install traps for cleanup.
1083
1084         * tests/test-gc.c (main): Remove unused variables.
1085         * tests/test-read-file.c: Include stdlib.h, for 'free'.
1086
1087 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
1088
1089         * modules/inttostr (License): Change to LGPL.
1090
1091 2006-11-14  Eric Blake  <ebb9@byu.net>
1092
1093         * modules/tempname (License): Change to LGPL.
1094
1095 2006-11-14  Eric Blake  <ebb9@byu.net>
1096
1097         * doc/functions.texi (Function Portability): *printf functions on
1098         Cygwin now understand all POSIX size specifiers.
1099
1100 2006-11-14  Bruno Haible  <bruno@clisp.org>
1101
1102         * modules/c-ctype (License): Change to LGPL.
1103
1104 2006-11-12  Bruno Haible  <bruno@clisp.org>
1105
1106         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
1107         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
1108         for GNOME libraries, for which the include files are installed in
1109         subdirectories of $prefix/include.
1110
1111 2006-11-12  Bruno Haible  <bruno@clisp.org>
1112
1113         * m4/lib-link.m4: Require at least autoconf-2.54.
1114         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
1115         name to underscores for the --with option.
1116
1117 2006-11-13  Bruno Haible  <bruno@clisp.org>
1118
1119         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
1120         the tests directory.
1121         Reported by Ralf Wildenhues.
1122
1123 2006-11-13  Bruno Haible  <bruno@clisp.org>
1124
1125         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
1126         (func_emit_initmacro_end): Undo the override here.
1127         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
1128         Works around the famous automake error in coreutils.
1129
1130 2006-11-13  Eric Blake  <ebb9@byu.net>
1131
1132         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
1133         element, not its node.
1134
1135 2006-11-12  Bruno Haible  <bruno@clisp.org>
1136
1137         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
1138         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
1139
1140 2006-11-12  Bruno Haible  <bruno@clisp.org>
1141
1142         * gnulib-tool: New option --local-symlink.
1143         (func_usage): Document it.
1144         (lsymbolic): New variable.
1145         (func_import, func_create_testdir): If --symlink was not specified,
1146         test whether --local-symlink was specified and the file comes from
1147         the local_gnulib_dir.
1148
1149 2006-11-12  Bruno Haible  <bruno@clisp.org>
1150
1151         * gnulib-tool (func_ln): New function.
1152         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
1153
1154 2006-11-12  Bruno Haible  <bruno@clisp.org>
1155
1156         Finish support for source files in subdirectories.
1157         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
1158         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
1159         AUTOMAKE_OPTIONS.
1160         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
1161
1162 2006-11-12  Bruno Haible  <bruno@clisp.org>
1163
1164         * gnulib-tool (func_get_automake_snippet): Synthesize also an
1165         EXTRA_lib_SOURCES augmentation.
1166         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
1167
1168 2006-11-12  Jim Meyering  <jim@meyering.net>
1169
1170         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
1171         file descriptors.  This also averts a failure on systems with
1172         native openat support when a traversed directory lacks "x" access.
1173         * lib/fts_.h: Include "i-ring.h"
1174         (struct FTS) [fts_fd_ring]: New member.
1175         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
1176         (FCHDIR): Add parentheses.
1177         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
1178         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
1179         When descending, rather than simply closing the previous
1180         fts_cwd_fd value, push that file descriptor onto the ring.
1181         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
1182         (fts_open): Initialize the new fd_ring member.
1183         (fts_close): Clear the ring.
1184         (fts_safe_changedir): When possible, use our new fd_ring to skip
1185         the diropen and fstat and dev/ino comparison that would normally
1186         accompany a virtual `chdir ("..")'.
1187
1188         * modules/fts (Depends-on): Add i-ring.
1189         * modules/i-ring: New module.
1190         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
1191         * m4/i-ring.m4: New file.
1192
1193 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1194
1195         * gnulib-tool (func_create_testdir): Fix replacement of
1196         `build-aux' in configure.ac.  Run autotools in gltests
1197         subdirectory.
1198         (func_create_testdir, func_create_megatestdir, test): There is
1199         no need for '--force' in most autotool invocations in a new
1200         tree.  Actually fail the whole test if any of the tools, or the
1201         configure or make stages fail.
1202
1203         Sync from Automake.
1204         * build-aux/gnupload: Revert last change.  Add pointer to upload
1205         instructions of the GNU Maintenance Instructions.
1206         Suggestion by Karl Berry.
1207
1208 2006-11-10  Jim Meyering  <jim@meyering.net>
1209
1210         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
1211
1212 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1213
1214         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
1215         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
1216         (bind_textdomain_codeset) [! ENABLE_NLS]:
1217         Evaluate all the arguments.  That way, callers get compatible behavior
1218         if the arguments have side effects.  Also, it avoids some GCC
1219         diagnostics in some cases; Joel E. Denny reported problems when Bison
1220         was configured with --enable-gcc-warnigs.
1221
1222 2006-11-10  Jim Meyering  <jim@meyering.net>
1223
1224         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
1225         relevant options in CFLAGS (like -O, -fno-inline) are taken into
1226         account.
1227
1228 2006-11-10  Jim Meyering  <jim@meyering.net>
1229
1230         * modules/inline: New file/module.
1231         * modules/xalloc (Files): Remove m4/inline.m4.
1232         (Depends-on): Add inline, instead.
1233         * modules/oset: Likewise.
1234         * modules/list: Likewise.
1235
1236 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1237
1238         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
1239         Problem reported by Matthew Woehlke.
1240
1241 2006-11-09  Bruno Haible  <bruno@clisp.org>
1242
1243         * lib/tempname.c (gen_tempname): Remove variant that invokes
1244         __gen_tempname.
1245         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
1246         __gen_tempname.
1247
1248 2006-11-08  Bruno Haible  <bruno@clisp.org>
1249
1250         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
1251         to 'yes' instead of 'cross-compiling'.
1252
1253 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
1254
1255         * lib/quotearg.h (quotearg_free): New decl.
1256         * lib/quotearg.c (quotearg_free): New function.
1257         (slot0, nslots, slotvec0, slotvec):
1258         Now file-scope so that quotearg_free can get at them.
1259
1260 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1261
1262         Sync from Automake.
1263         * build-aux/gnupload: Add missing 'gnu' to example URL.
1264         Report by Karl Berry.
1265
1266 2006-11-08  Bruno Haible  <bruno@clisp.org>
1267
1268         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
1269         Suggested by Paul Eggert.
1270
1271 2006-11-08  Jim Meyering  <jim@meyering.net>
1272
1273         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
1274         It's already included if !_LIBC.
1275         (fts_safe_changedir): Add a comment.
1276
1277 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1278
1279         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
1280         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
1281         Matthew Woehlke.
1282
1283         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
1284         definitions up, to avoid colliding with change below.
1285         (static_inline) [HAVE_INLINE]: New macro.
1286         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
1287         Provide extern decls when !HAVE_INLINE.  Do not define unless
1288         static_inline is defined, either by us or by xmalloc.c.  Use
1289         static_inline rather than static inline.
1290         (XCALLOC): Optimize sizeof(T) = 1 case.
1291         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
1292
1293 2006-11-07  Bruno Haible  <bruno@clisp.org>
1294
1295         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
1296         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
1297         AC_C_INLINE.
1298         * modules/xalloc (Files): Add m4/inline.m4.
1299
1300 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1301
1302         * README: Fix typo.
1303         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
1304         (Miscellanous Notes): ...from this.
1305
1306 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1307
1308         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
1309         Mention that offsetof should be used instead of sizeof.
1310         From Bruno Haible.
1311
1312 2006-11-07  Bruno Haible  <bruno@clisp.org>
1313
1314         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
1315
1316 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1317
1318         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1319         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
1320         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1321         (gl_tree_add_before, gl_tree_add_after):
1322         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
1323         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
1324         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1325         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
1326         (gl_linked_add_after, gl_linked_add_at): Likewise.
1327         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
1328         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1329         (gl_tree_add_before, gl_tree_add_after): Likewise.
1330         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
1331         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
1332         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
1333
1334 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1335
1336         * lib/gl_oset.h: Use C comment style, not C++ comment style.
1337
1338 2006-11-06  Bruno Haible  <bruno@clisp.org>
1339
1340         * m4/inline.m4: New file.
1341         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
1342         * modules/list (Files): Add m4/inline.m4.
1343         * modules/oset (Files): Likewise.
1344
1345 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1346
1347         * lib/idcache.c: Include <stddef.h>, for offsetof.
1348         (struct userid.name): Change from char * to a flexible array member.
1349         All uses changed.
1350         * modules/idcache (Depends-on): Add flexmember.
1351
1352         * MODULES.html.sh (Core language properties): New module flexmember.
1353         * modules/flexmember, m4/flexmember.m4: New files.
1354
1355         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
1356         inline functions that are identical with the old xnmalloc_inline,
1357         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
1358         that we can avoid some unnecessary integer multiplications and
1359         divisions in the common case where the element size is known at
1360         compile time.
1361         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
1362         needed.
1363         (xnboundedmalloc): Remove.
1364         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
1365         arguments, for consistency with rest of this header.
1366         (xcharalloc): Rewrite using XNMALLOC.
1367         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
1368         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
1369         versions have been moved to lib/xalloc.h and renamed to be the
1370         non-*_inline versions.
1371         (xmalloc, xrealloc): Implement without reference to the xnmalloc
1372         and xnrealloc functions, since those functions are now inline and
1373         now call us.
1374         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
1375         renaming described above.
1376         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
1377         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
1378         captures the dependency in AC_C_INLINE.
1379
1380         New module canonicalize-lgpl, proposed by Charles Wilson in
1381         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
1382         with a few small changes afterwards.
1383         * MODULES.html.sh (File system functions): New module
1384         canonicalize-lgpl.
1385         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
1386         and canonicalize_file_name.
1387         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
1388         * modules/canonicalize-lgpl: New files.
1389
1390 2006-11-05  Bruno Haible  <bruno@clisp.org>
1391
1392         * gnulib-tool (func_import, func_create_testdir): Create directories
1393         also for files in subdirectories of lib/.
1394
1395 2006-11-05  Bruno Haible  <bruno@clisp.org>
1396
1397         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
1398         ANSI C compliant.
1399
1400 2006-11-03  Bruno Haible  <bruno@clisp.org>
1401
1402         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1403         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
1404         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
1405         (xnboundedmalloc): New inline function.
1406         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
1407         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
1408         xmalloc.
1409         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
1410         xmalloc.
1411         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
1412         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
1413         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
1414         xmalloc.
1415         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1416         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
1417         xmalloc.
1418         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
1419         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1420         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
1421         xmalloc.
1422         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1423         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
1424         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1425         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
1426         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
1427         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
1428         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
1429
1430 2006-11-03  Bruno Haible  <bruno@clisp.org>
1431
1432         * lib/c-ctype.h [C++]: Define functions without name mangling.
1433         * lib/fwriteerror.h [C++]: Likewise.
1434         * lib/gcd.h [C++]: Likewise.
1435         * lib/linebreak.h [C++]: Likewise.
1436
1437 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
1438
1439         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
1440         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
1441         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
1442         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1443         Check for functions and headers just once.
1444         Check for declaration of canonicalize_file_name.
1445         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
1446
1447 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1448
1449         * gnulib-tool (func_import): Fix typo in actioncmd.
1450
1451 2006-11-02  Bruno Haible  <bruno@clisp.org>
1452
1453         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
1454         newline sequence in the Makefile.am snippet as a space, like "make"
1455         does.
1456         Reported by Roger Persson <perrog@gmail.com>.
1457
1458 2006-11-01  Bruno Haible  <bruno@clisp.org>
1459
1460         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
1461         already declared in <string.h>.
1462         * lib/strcase.h (strncasecmp): Don't declare it if yes.
1463
1464 2006-11-01  Bruno Haible  <bruno@clisp.org>
1465
1466         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
1467         * lib/strcase.h: Include <string.h>.
1468         (strcasecmp): Define to rpl_strcasecmp here.
1469
1470 2006-11-01  Bruno Haible  <bruno@clisp.org>
1471
1472         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
1473
1474 2006-11-01  Eric Blake  <ebb9@byu.net>
1475
1476         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
1477
1478         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
1479
1480 2006-10-29  Bruno Haible  <bruno@clisp.org>
1481
1482         Make it compile in C++ mode.
1483         * lib/full-write.c (full_rw): Add a cast.
1484
1485 2006-11-01  Bruno Haible  <bruno@clisp.org>
1486
1487         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
1488         be POSIX compliant.
1489         Reported by Roger Persson <perrog@gmail.com>.
1490
1491 2006-11-01  Eric Blake  <ebb9@byu.net>
1492
1493         * lib/getopt_.h: Fix comments.
1494
1495 2006-10-31  Eric Blake  <ebb9@byu.net>
1496
1497         * modules/tmpdir (Depends-on): Add sys_stat.
1498         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
1499         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
1500         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
1501         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
1502         tempname.
1503
1504 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
1505
1506         Avoid some C++ diagnostics reported by Bruno Haible.
1507         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
1508         xmalloc.
1509         (quotearg_alloc): Use xcharalloc rather than xmalloc.
1510         (struct slotvec): Move to top level.
1511         (quotearg_n_options): Rewrite to avoid xmalloc.
1512         * lib/xalloc.h (xcharalloc): New function.
1513         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
1514         [defined __cplusplus]: Add function template that provides result
1515         type propagation.  This part of the change is from Bruno Haible.
1516
1517 2006-10-29  Bruno Haible  <bruno@clisp.org>
1518
1519         Make it compile in C++ mode.
1520         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
1521         * lib/strnlen1.c (strnlen1): Cast memchr result.
1522         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
1523         * lib/clean-temp.c (string_equals, string_hash): Add casts.
1524         (create_temp_dir): Rename local variable 'template'.
1525         (compile_csharp_using_sscli): Add cast.
1526         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
1527         * lib/findprog.c (find_in_path): Likewise.
1528         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
1529         * lib/wait-process.c (register_slave_subprocess): Likewise.
1530
1531 2006-10-22  Bruno Haible  <bruno@clisp.org>
1532
1533         * modules/tsearch: New file.
1534         * lib/tsearch.h: New file.
1535         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
1536         * m4/tsearch.m4: New file.
1537         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
1538
1539 2006-10-29  Eric Blake  <ebb9@byu.net>
1540
1541         * lib/arcfour.c: Assume config.h.
1542         * lib/arctwo.c: Likewise.
1543         * lib/base64.c: Likewise.
1544         * lib/check-version.c: Likewise.
1545         * lib/crc.c: Likewise.
1546         * lib/des.c: Likewise.
1547         * lib/gc-gnulib.c: Likewise.
1548         * lib/gc-libgcrypt.c: Likewise.
1549         * lib/gc-pbkdf2-sha1.c: Likewise.
1550         * lib/getaddrinfo.c: Likewise.
1551         * lib/getdelim.c: Likewise.
1552         * lib/getline.c: Likewise.
1553         * lib/hmac-md5.c: Likewise.
1554         * lib/hmac-sha1.c: Likewise.
1555         * lib/iconvme.c: Likewise.
1556         * lib/md2.c: Likewise.
1557         * lib/md4.c: Likewise.
1558         * lib/memxor.c: Likewise.
1559         * lib/read-file.c: Likewise.
1560         * lib/readline.c: Likewise.
1561         * lib/rijndael-alg-fst.c: Likewise.
1562         * lib/rijndael-api-fst.c: Likewise.
1563         * lib/xgetdomainname.c: Likewise.
1564
1565 2006-10-28  Eric Blake  <ebb9@byu.net>
1566
1567         * lib/xstrndup.c: Assume config.h.
1568
1569 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
1570
1571         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
1572         stat-macros.h is now for our own macros, whereas stat_h is for
1573         macros in the <sys/stat.h> name space.
1574         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
1575         (STAT_MACROS_H): Remove.
1576         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
1577         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
1578         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
1579         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
1580         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
1581         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
1582         Move these macros to ...
1583         * lib/stat_.h: here.  Don't include stat-macros.h.
1584         * lib/canonicalize.c: Don't include stat-macros.h.
1585         * lib/chown.c: Likewise.
1586         * lib/euidaccess.c: Likewise.
1587         * lib/file-type.c: Likewise.
1588         * lib/filemode.c: Likewise.
1589         * lib/glob.c: Likewise.
1590         * lib/isapipe.c: Likewise.
1591         * lib/lchown.c: Likewise.
1592         * lib/lstat.c: Likewise.
1593         * lib/mkdir-p.c: Likewise.
1594         * lib/rmdir.c: Likewise.
1595         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
1596         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
1597         unless mkdir isn't declared, to speed up 'configure'.
1598         Always create sys/stat.h, since it's unlikely any real sys/stat.h
1599         would define all the S_* symbols.
1600         * modules/canonicalize (Depends-on):
1601         Depend on sys_stat, not stat-macros.
1602         * modules/chown: Likewise.
1603         * modules/euidaccess: Likewise.
1604         * modules/filemode: Likewise.
1605         * modules/file-type: Likewise.
1606         * modules/glob: Likewise.
1607         * modules/isapipe: Likewise.
1608         * modules/lchown: Likewise.
1609         * modules/lstat: Likewise.
1610         * modules/mkancesdirs: Likewise.
1611         * modules/rmdir: Likewise.
1612         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
1613         * modules/modechange: Likewise.
1614         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
1615         (configure.ac): Remove gl_STAT_MACROS.
1616         * modules/sys_stat (Depends-on): Remove stat-macros.
1617
1618 2006-10-27  Bruno Haible  <bruno@clisp.org>
1619
1620         * m4/signed.m4: Remove file.
1621         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
1622         invocation.
1623         * modules/vasnprintf (Files): Remove m4/signed.m4.
1624
1625 2006-10-27  Bruno Haible  <bruno@clisp.org>
1626
1627         Update to GNU gettext 0.16.
1628         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
1629         m4/inttypes-h.m4, m4/signed.m4.
1630         * m4/gettext.m4: Update to GNU gettext 0.16.
1631         * m4/intl.m4: New file, from GNU gettext.
1632         * m4/intldir.m4: New file, from GNU gettext.
1633         * config/srclist.txt: Update
1634
1635 2006-10-27  Eric Blake  <ebb9@byu.net>
1636
1637         * MODULES.html.sh: Document tempname.
1638         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
1639         dependencies.
1640         (Files): Move lib/tempname.c...
1641         * modules/tempname: ...to this new module.
1642         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
1643         (gl_PREREQ_TEMPNAME): Move...
1644         * m4/tempname.m4: ...to this new file.
1645         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
1646         * modules/sys_stat (Depends-on): Add stat-macros.
1647         * lib/stat_.h (includes): Pick up stat macros.
1648         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
1649         if stat macros are broken.
1650         * lib/tempname.c (includes): No need to include "stat-macros.h".
1651         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
1652         (direxists, __path_search) [!_LIBC]: Don't compile these in
1653         gnulib; the tmpdir module covers that.
1654         * lib/tempname.h: New file.
1655
1656 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
1657
1658         * COPYING: Explain how gnulib-tool converts licence headers.
1659         Almost all wording by Eric Blake.
1660
1661 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
1662
1663         * lib/mbchar.h (is_basic_table): Make read-only.
1664         * lib/mbchar.c (is_basic_table): Likewise.
1665         Reported by John Darrington.
1666
1667 2006-10-25  Bruno Haible  <bruno@clisp.org>
1668
1669         * lib/progname.h (set_program_name): Undefine before defining.
1670
1671 2006-10-25  Bruno Haible  <bruno@clisp.org>
1672
1673         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
1674         false for non-gcc C++ compilers.
1675         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
1676
1677 2006-10-24  Bruno Haible  <bruno@clisp.org>
1678
1679         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
1680         iconv implementations like Irix iconv.
1681
1682 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1683
1684         * modules/vararrays: New file.
1685         * m4/vararrays.m4: New file, taken from diffutils.
1686         * MODULES.html.sh: New module vararrays.
1687
1688 2006-10-24  Karl Berry  <karl@gnu.org>
1689
1690         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
1691         Don't call GNU Unix.
1692
1693 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1694
1695         * users.txt: Add Libtool.
1696
1697         Sync from Libtool:
1698
1699         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1700
1701         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
1702         to gnulib's policy of including config.h unconditionally.
1703
1704 2006-10-24  Bruno Haible  <bruno@clisp.org>
1705
1706         * modules/wcwidth (Files): Add m4/wint_t.m4.
1707         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
1708         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
1709
1710 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1711
1712         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
1713         to pacify GCC with some -W flags enabled.  Problem reported by
1714         Bruno Haible.
1715
1716 2006-10-24  Jim Meyering  <jim@meyering.net>
1717
1718         * MODULES.html.sh: Remove uinttostr.  It's not a module.
1719         Reported by Karl Berry.
1720
1721 2006-10-23  Bruno Haible  <bruno@clisp.org>
1722
1723         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
1724
1725 2006-10-24  Bruno Haible  <bruno@clisp.org>
1726
1727         * lib/gl_list.h: Use C comment style, not C++ comment style.
1728
1729 2006-10-23  Eric Blake  <ebb9@byu.net>
1730
1731         * lib/getaddrinfo.c (includes): Add missing include.
1732
1733 2006-10-23  Bruno Haible  <bruno@clisp.org>
1734             Paul Eggert  <eggert@cs.ucla.edu>
1735
1736         Ability to rename obstack_free.
1737         * lib/obstack.h (__obstack_free): New macro. Declare instead of
1738         obstack_free.
1739         (obstack_free): Invoke the __obstack_free macro.
1740         * lib/obstack.c (obstack_free): Use __obstack_free macro.
1741
1742 2006-10-23  Bruno Haible  <bruno@clisp.org>
1743             Paul Eggert  <eggert@cs.ucla.edu>
1744
1745         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
1746         __argc, __argv from the declaration. (They are defined as macros on
1747         mingw.)
1748
1749 2006-10-22  Bruno Haible  <bruno@clisp.org>
1750
1751         * doc/gnulib-intro.texi: New file.
1752         * doc/gnulib.texi: Include it.
1753
1754 2006-10-21  Bruno Haible  <bruno@clisp.org>
1755
1756         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
1757         "Introduction", "Miscellanous Notes", "Particular Modules".
1758
1759 2006-10-21  Bruno Haible  <bruno@clisp.org>
1760
1761         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1762         Change mostlyclean-local rule to avoid sh syntax error from bash
1763         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
1764
1765 2006-10-23  Jim Meyering  <jim@meyering.net>
1766
1767         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
1768         in place of snprintf.
1769
1770         * modules/inttostr (Files): Add lib/uinttostr.c.
1771         * lib/uinttostr.c (inttostr): New file/function.
1772         * lib/inttostr.h (uinttostr): Declare.
1773         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
1774         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
1775         Add uinttostr.
1776         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
1777
1778 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1779
1780         * lib/canonicalize.c (ELOOP): Define if not already defined.
1781         Problem reported by Bruno Haible in
1782         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
1783
1784 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1785
1786         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
1787         Problem reported by Perry Smith and Ville Laurikari.
1788
1789         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
1790         uses.
1791
1792 2006-10-19  Bruno Haible  <bruno@clisp.org>
1793
1794         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
1795         for mingw.
1796
1797 2006-10-19  Bruno Haible  <bruno@clisp.org>
1798
1799         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
1800         Needed for mingw.
1801
1802 2006-10-19  Bruno Haible  <bruno@clisp.org>
1803
1804         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
1805
1806 2006-10-19  Bruno Haible  <bruno@clisp.org>
1807
1808         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
1809         it.
1810
1811 2006-10-19  Bruno Haible  <bruno@clisp.org>
1812
1813         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
1814         invocation.
1815
1816 2006-10-19  Bruno Haible  <bruno@clisp.org>
1817
1818         * gnulib-tool (func_create_testdir): Don't include ftruncate and
1819         mountlist by default.
1820
1821 2006-10-16  Bruno Haible  <bruno@clisp.org>
1822
1823         * lib/c-strstr.c: Include c-strstr.h.
1824
1825 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1826
1827         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
1828         in a slash.
1829
1830 2006-10-18  Bruno Haible  <bruno@clisp.org>
1831
1832         * lib/lock.h [C++]: Wrap definitions in extern "C".
1833
1834 2006-10-18  Bruno Haible  <bruno@clisp.org>
1835
1836         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
1837         gl_LIBOBJS list.
1838
1839 2006-10-18  Bruno Haible  <bruno@clisp.org>
1840
1841         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
1842
1843 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
1844
1845         * lib/xstrtol.h: Include gettext.h.
1846         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
1847         Problem reported by Eric Blake.
1848         * modules/xstrtol (Depends-on): Add gettext-h.
1849
1850 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
1851
1852         * lib/strftime.c (advance): New macro.
1853         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
1854         incomplete type, so you can't add 0 to it.  Problem and patch
1855         reported by Eelco Dolstra for dietlibc.
1856
1857 2006-10-18  Jim Meyering  <jim@meyering.net>
1858
1859         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
1860         type for a local, and rename it: s/up/user_proc/.
1861
1862 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
1863
1864         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
1865         READ_UTMP_USER_PROCESS.
1866         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
1867
1868 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
1869
1870         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
1871         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
1872
1873 2006-10-17  Eric Blake  <ebb9@byu.net>
1874
1875         * lib/sigprocmask.c (sigprocmask): Fix typo.
1876
1877         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
1878
1879         * modules/clean-temp (Makefile.am): Don't add to make output...
1880         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
1881         config.h.
1882
1883 2006-10-17  Bruno Haible  <bruno@clisp.org>
1884
1885         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
1886         differently if DEFAULT_TEXT_DOMAIN is set.
1887
1888 2006-10-16  Bruno Haible  <bruno@clisp.org>
1889
1890         * lib/clean-temp.c: Include fwriteerror.h.
1891
1892 2006-10-16  Bruno Haible  <bruno@clisp.org>
1893
1894         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
1895
1896 2006-10-16  Bruno Haible  <bruno@clisp.org>
1897
1898         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
1899         * lib/sigprocmask.h: Include <sys/types.h>.
1900         (sigset_t): Use the system's definition if present.
1901
1902 2006-10-17  Eric Blake  <ebb9@byu.net>
1903
1904         * lib/xvasprintf.c (includes): Assume config.h.
1905         * lib/xasprintf.c (includes): Likewise.
1906
1907 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
1908
1909         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
1910         at least as wide as intmax_t.
1911
1912 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
1913
1914         (Imported from Automake.)
1915         * build-aux/gnupload: Update to version 1.1 of directive file.
1916
1917 2006-10-16  Eric Blake  <ebb9@byu.net>
1918
1919         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
1920         match Automake 1.10a.
1921
1922 2006-10-14  Bruno Haible  <bruno@clisp.org>
1923
1924         * modules/sigprocmask: New file.
1925         * lib/sigprocmask.h: New file.
1926         * lib/sigprocmask.c: New file.
1927         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
1928         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
1929         request sigprocmask.o.
1930         (gl_PREREQ_SIGPROCMASK): New macro.
1931         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
1932         (Depends-on): Add sigprocmask.
1933         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
1934         gt_SIGNALBLOCKING. Test for 'raise' only once.
1935         * lib/fatal-signal.c: Include sigprocmask.h.
1936         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
1937         unblock_fatal_signals): Define always.
1938         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
1939         sigprocmask.
1940
1941 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
1942
1943         Sync from Automake.
1944         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
1945         which incorrectly sets the mode of an existing destination
1946         directory.  In some cases the unpatched install-sh could do the
1947         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
1948         system.  We hope this is rare in practice, but it's clearly worth
1949         fixing.  Problem reported by Alex Unleashed in
1950         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
1951         Also, don't bother to check for -m bugs unless we're using -m;
1952         suggested by Stepan Kasal.
1953
1954 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1955
1956         Sync from Automake.
1957         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
1958         `-c' flag, so they appear at the same position as in %FASTDEP%
1959         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
1960         which ignores unknown options only after the first non-option.
1961         Bug report against M4 by Nelson H. F. Beebe.
1962
1963 2006-10-13  Jim Meyering  <jim@meyering.net>
1964
1965         Fix a bug in yesterday's change.
1966         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
1967         p->fts_statp->st_dev would be used uninitialized.
1968         Ensures that we always call fts_stat on the very first entry.
1969         Miklos Szeredi reported that find -xdev stopped working.
1970
1971 2006-10-12  Bruno Haible  <bruno@clisp.org>
1972
1973         * gnulib-tool (func_get_automake_snippet): Append an automatically
1974         computed EXTRA_DIST augmentation.
1975         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
1976         * modules/alloca-opt (Makefile.am): Likewise.
1977         * modules/allocsa (Makefile.am): Likewise.
1978         * modules/arcfour (Makefile.am): Likewise.
1979         * modules/arctwo (Makefile.am): Likewise.
1980         * modules/argmatch (Makefile.am): Likewise.
1981         * modules/argz (Makefile.am): Likewise.
1982         * modules/atexit (Makefile.am): Likewise.
1983         * modules/backupfile (Makefile.am): Likewise.
1984         * modules/byteswap (Makefile.am): Likewise.
1985         * modules/c-strtod (Makefile.am): Likewise.
1986         * modules/c-strtold (Makefile.am): Likewise.
1987         * modules/calloc (Makefile.am): Likewise.
1988         * modules/canon-host (Makefile.am): Likewise.
1989         * modules/canonicalize (Makefile.am): Likewise.
1990         * modules/chdir-long (Makefile.am): Likewise.
1991         * modules/chdir-safer (Makefile.am): Likewise.
1992         * modules/check-version (Makefile.am): Likewise.
1993         * modules/chown (Makefile.am): Likewise.
1994         * modules/cloexec (Makefile.am): Likewise.
1995         * modules/close-stream (Makefile.am): Likewise.
1996         * modules/closeout (Makefile.am): Likewise.
1997         * modules/crc (Makefile.am): Likewise.
1998         * modules/csharpexec (Makefile.am): Likewise.
1999         * modules/cycle-check (Makefile.am): Likewise.
2000         * modules/des (Makefile.am): Likewise.
2001         * modules/dev-ino (Makefile.am): Likewise.
2002         * modules/dirfd (Makefile.am): Likewise.
2003         * modules/dirname (Makefile.am): Likewise.
2004         * modules/dup2 (Makefile.am): Likewise.
2005         * modules/eealloc (Makefile.am): Likewise.
2006         * modules/error (Makefile.am): Likewise.
2007         * modules/euidaccess (Makefile.am): Likewise.
2008         * modules/exclude (Makefile.am): Likewise.
2009         * modules/exitfail (Makefile.am): Likewise.
2010         * modules/fcntl-safer (Makefile.am): Likewise.
2011         * modules/fcntl (Makefile.am): Likewise.
2012         * modules/file-type (Makefile.am): Likewise.
2013         * modules/fileblocks (Makefile.am): Likewise.
2014         * modules/filemode (Makefile.am): Likewise.
2015         * modules/filenamecat (Makefile.am): Likewise.
2016         * modules/fnmatch (Makefile.am): Likewise.
2017         * modules/fopen-safer (Makefile.am): Likewise.
2018         * modules/fpending (Makefile.am): Likewise.
2019         * modules/fprintftime (Makefile.am): Likewise.
2020         * modules/free (Makefile.am): Likewise.
2021         * modules/fsusage (Makefile.am): Likewise.
2022         * modules/ftruncate (Makefile.am): Likewise.
2023         * modules/fts (Makefile.am): Likewise.
2024         * modules/gc-arcfour (Makefile.am): Likewise.
2025         * modules/gc-des (Makefile.am): Likewise.
2026         * modules/gc-hmac-md5 (Makefile.am): Likewise.
2027         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
2028         * modules/gc-md4 (Makefile.am): Likewise.
2029         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2030         * modules/gc-sha1 (Makefile.am): Likewise.
2031         * modules/gc (Makefile.am): Likewise.
2032         * modules/getaddrinfo (Makefile.am): Likewise.
2033         * modules/getcwd (Makefile.am): Likewise.
2034         * modules/getdelim (Makefile.am): Likewise.
2035         * modules/getdomainname (Makefile.am): Likewise.
2036         * modules/getgroups (Makefile.am): Likewise.
2037         * modules/gethostname (Makefile.am): Likewise.
2038         * modules/gethrxtime (Makefile.am): Likewise.
2039         * modules/getline (Makefile.am): Likewise.
2040         * modules/getloadavg (Makefile.am): Likewise.
2041         * modules/getlogin_r (Makefile.am): Likewise.
2042         * modules/getndelim2 (Makefile.am): Likewise.
2043         * modules/getopt (Makefile.am): Likewise.
2044         * modules/getpagesize (Makefile.am): Likewise.
2045         * modules/getpass-gnu (Makefile.am): Likewise.
2046         * modules/getpass (Makefile.am): Likewise.
2047         * modules/getsubopt (Makefile.am): Likewise.
2048         * modules/gettime (Makefile.am): Likewise.
2049         * modules/gettimeofday (Makefile.am): Likewise.
2050         * modules/getugroups (Makefile.am): Likewise.
2051         * modules/getusershell (Makefile.am): Likewise.
2052         * modules/glob (Makefile.am): Likewise.
2053         * modules/group-member (Makefile.am): Likewise.
2054         * modules/hard-locale (Makefile.am): Likewise.
2055         * modules/hash (Makefile.am): Likewise.
2056         * modules/hmac-md5 (Makefile.am): Likewise.
2057         * modules/hmac-sha1 (Makefile.am): Likewise.
2058         * modules/human (Makefile.am): Likewise.
2059         * modules/idcache (Makefile.am): Likewise.
2060         * modules/imaxabs (Makefile.am): Likewise.
2061         * modules/imaxdiv (Makefile.am): Likewise.
2062         * modules/inet_ntop (Makefile.am): Likewise.
2063         * modules/inet_pton (Makefile.am): Likewise.
2064         * modules/intprops (Makefile.am): Likewise.
2065         * modules/inttostr (Makefile.am): Likewise.
2066         * modules/inttypes (Makefile.am): Likewise.
2067         * modules/isapipe (Makefile.am): Likewise.
2068         * modules/javaversion (Makefile.am): Likewise.
2069         * modules/lchmod (Makefile.am): Likewise.
2070         * modules/lchown (Makefile.am): Likewise.
2071         * modules/localcharset (Makefile.am): Likewise.
2072         * modules/long-options (Makefile.am): Likewise.
2073         * modules/lstat (Makefile.am): Likewise.
2074         * modules/malloc (Makefile.am): Likewise.
2075         * modules/mathl (Makefile.am): Likewise.
2076         * modules/mbchar (Makefile.am): Likewise.
2077         * modules/md2 (Makefile.am): Likewise.
2078         * modules/md4 (Makefile.am): Likewise.
2079         * modules/md5 (Makefile.am): Likewise.
2080         * modules/memcasecmp (Makefile.am): Likewise.
2081         * modules/memchr (Makefile.am): Likewise.
2082         * modules/memcmp (Makefile.am): Likewise.
2083         * modules/memcoll (Makefile.am): Likewise.
2084         * modules/memcpy (Makefile.am): Likewise.
2085         * modules/memmem (Makefile.am): Likewise.
2086         * modules/memmove (Makefile.am): Likewise.
2087         * modules/mempcpy (Makefile.am): Likewise.
2088         * modules/memrchr (Makefile.am): Likewise.
2089         * modules/memset (Makefile.am): Likewise.
2090         * modules/memxor (Makefile.am): Likewise.
2091         * modules/mkancesdirs (Makefile.am): Likewise.
2092         * modules/mkdir-p (Makefile.am): Likewise.
2093         * modules/mkdir (Makefile.am): Likewise.
2094         * modules/mkdtemp (Makefile.am): Likewise.
2095         * modules/mkstemp (Makefile.am): Likewise.
2096         * modules/mktime (Makefile.am): Likewise.
2097         * modules/modechange (Makefile.am): Likewise.
2098         * modules/mountlist (Makefile.am): Likewise.
2099         * modules/nanosleep (Makefile.am): Likewise.
2100         * modules/obstack (Makefile.am): Likewise.
2101         * modules/openat (Makefile.am): Likewise.
2102         * modules/pagealign_alloc (Makefile.am): Likewise.
2103         * modules/pathmax (Makefile.am): Likewise.
2104         * modules/physmem (Makefile.am): Likewise.
2105         * modules/poll (Makefile.am): Likewise.
2106         * modules/posixtm (Makefile.am): Likewise.
2107         * modules/posixver (Makefile.am): Likewise.
2108         * modules/putenv (Makefile.am): Likewise.
2109         * modules/quote (Makefile.am): Likewise.
2110         * modules/quotearg (Makefile.am): Likewise.
2111         * modules/raise (Makefile.am): Likewise.
2112         * modules/read-file (Makefile.am): Likewise.
2113         * modules/readline (Makefile.am): Likewise.
2114         * modules/readlink (Makefile.am): Likewise.
2115         * modules/readtokens (Makefile.am): Likewise.
2116         * modules/readutmp (Makefile.am): Likewise.
2117         * modules/realloc (Makefile.am): Likewise.
2118         * modules/regex (Makefile.am): Likewise.
2119         * modules/rename-dest-slash (Makefile.am): Likewise.
2120         * modules/rename (Makefile.am): Likewise.
2121         * modules/rijndael (Makefile.am): Likewise.
2122         * modules/rmdir (Makefile.am): Likewise.
2123         * modules/rpmatch (Makefile.am): Likewise.
2124         * modules/safe-read (Makefile.am): Likewise.
2125         * modules/safe-write (Makefile.am): Likewise.
2126         * modules/same-inode (Makefile.am): Likewise.
2127         * modules/same (Makefile.am): Likewise.
2128         * modules/save-cwd (Makefile.am): Likewise.
2129         * modules/savedir (Makefile.am): Likewise.
2130         * modules/setenv (Makefile.am): Likewise.
2131         * modules/settime (Makefile.am): Likewise.
2132         * modules/sha1 (Makefile.am): Likewise.
2133         * modules/sig2str (Makefile.am): Likewise.
2134         * modules/snprintf (Makefile.am): Likewise.
2135         * modules/stat-macros (Makefile.am): Likewise.
2136         * modules/stat-time (Makefile.am): Likewise.
2137         * modules/stdbool (Makefile.am): Likewise.
2138         * modules/stdint (Makefile.am): Likewise.
2139         * modules/stdlib-safer (Makefile.am): Likewise.
2140         * modules/stpcpy (Makefile.am): Likewise.
2141         * modules/stpncpy (Makefile.am): Likewise.
2142         * modules/strcase (Makefile.am): Likewise.
2143         * modules/strcasestr (Makefile.am): Likewise.
2144         * modules/strchrnul (Makefile.am): Likewise.
2145         * modules/strcspn (Makefile.am): Likewise.
2146         * modules/strdup (Makefile.am): Likewise.
2147         * modules/strerror (Makefile.am): Likewise.
2148         * modules/strftime (Makefile.am): Likewise.
2149         * modules/strndup (Makefile.am): Likewise.
2150         * modules/strnlen (Makefile.am): Likewise.
2151         * modules/strpbrk (Makefile.am): Likewise.
2152         * modules/strsep (Makefile.am): Likewise.
2153         * modules/strstr (Makefile.am): Likewise.
2154         * modules/strtod (Makefile.am): Likewise.
2155         * modules/strtoimax (Makefile.am): Likewise.
2156         * modules/strtok_r (Makefile.am): Likewise.
2157         * modules/strtol (Makefile.am): Likewise.
2158         * modules/strtoll (Makefile.am): Likewise.
2159         * modules/strtoul (Makefile.am): Likewise.
2160         * modules/strtoull (Makefile.am): Likewise.
2161         * modules/strtoumax (Makefile.am): Likewise.
2162         * modules/strverscmp (Makefile.am): Likewise.
2163         * modules/sys_socket (Makefile.am): Likewise.
2164         * modules/sys_stat (Makefile.am): Likewise.
2165         * modules/sysexits (Makefile.am): Likewise.
2166         * modules/time_r (Makefile.am): Likewise.
2167         * modules/timegm (Makefile.am): Likewise.
2168         * modules/timespec (Makefile.am): Likewise.
2169         * modules/tmpfile-safer (Makefile.am): Likewise.
2170         * modules/trim (Makefile.am): Likewise.
2171         * modules/unistd-safer (Makefile.am): Likewise.
2172         * modules/unlinkdir (Makefile.am): Likewise.
2173         * modules/unlocked-io (Makefile.am): Likewise.
2174         * modules/userspec (Makefile.am): Likewise.
2175         * modules/utime (Makefile.am): Likewise.
2176         * modules/utimecmp (Makefile.am): Likewise.
2177         * modules/utimens (Makefile.am): Likewise.
2178         * modules/vasnprintf (Makefile.am): Likewise.
2179         * modules/vasprintf (Makefile.am): Likewise.
2180         * modules/vsnprintf (Makefile.am): Likewise.
2181         * modules/xalloc (Makefile.am): Likewise.
2182         * modules/xgetcwd (Makefile.am): Likewise.
2183         * modules/xnanosleep (Makefile.am): Likewise.
2184         * modules/xreadlink (Makefile.am): Likewise.
2185         * modules/xstrtod (Makefile.am): Likewise.
2186         * modules/xstrtol (Makefile.am): Likewise.
2187         * modules/xstrtold (Makefile.am): Likewise.
2188         * modules/yesno (Makefile.am): Likewise.
2189         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
2190
2191 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2192
2193         * modules/error (Makefile.am): Distribute files through
2194         EXTRA_DIST, not lib_SOURCES.
2195
2196 2006-10-12  Eric Blake  <ebb9@byu.net>
2197
2198         * modules/error (Makefile.am): Distribute files in /lib.
2199         * modules/obstack (Makefile.am): Likewise.
2200
2201 2006-10-12  Bruno Haible  <bruno@clisp.org>
2202
2203         * modules/acl (Makefile.am): Distribute all files in lib/ through
2204         EXTRA_DIST.
2205         * modules/arcfour (Makefile.am): Likewise.
2206         * modules/arctwo (Makefile.am): Likewise.
2207         * modules/argmatch (Makefile.am): Likewise.
2208         * modules/argz (Makefile.am): Likewise.
2209         * modules/atexit (Makefile.am): Likewise.
2210         * modules/backupfile (Makefile.am): Likewise.
2211         * modules/c-strtod (Makefile.am): Likewise.
2212         * modules/c-strtold (Makefile.am): Likewise.
2213         * modules/calloc (Makefile.am): Likewise.
2214         * modules/canon-host (Makefile.am): Likewise.
2215         * modules/canonicalize (Makefile.am): Likewise.
2216         * modules/chdir-long (Makefile.am): Likewise.
2217         * modules/chdir-safer (Makefile.am): Likewise.
2218         * modules/check-version (Makefile.am): Likewise.
2219         * modules/chown (Makefile.am): Likewise.
2220         * modules/cloexec (Makefile.am): Likewise.
2221         * modules/close-stream (Makefile.am): Likewise.
2222         * modules/closeout (Makefile.am): Likewise.
2223         * modules/crc (Makefile.am): Likewise.
2224         * modules/cycle-check (Makefile.am): Likewise.
2225         * modules/des (Makefile.am): Likewise.
2226         * modules/dirfd (Makefile.am): Likewise.
2227         * modules/dirname (Makefile.am): Likewise.
2228         * modules/dup2 (Makefile.am): Likewise.
2229         * modules/euidaccess (Makefile.am): Likewise.
2230         * modules/exclude (Makefile.am): Likewise.
2231         * modules/exitfail (Makefile.am): Likewise.
2232         * modules/fcntl-safer (Makefile.am): Likewise.
2233         * modules/file-type (Makefile.am): Likewise.
2234         * modules/fileblocks (Makefile.am): Likewise.
2235         * modules/filemode (Makefile.am): Likewise.
2236         * modules/filenamecat (Makefile.am): Likewise.
2237         * modules/fnmatch (Makefile.am): Likewise.
2238         * modules/fopen-safer (Makefile.am): Likewise.
2239         * modules/fpending (Makefile.am): Likewise.
2240         * modules/fprintftime (Makefile.am): Likewise.
2241         * modules/free (Makefile.am): Likewise.
2242         * modules/fsusage (Makefile.am): Likewise.
2243         * modules/ftruncate (Makefile.am): Likewise.
2244         * modules/fts (Makefile.am): Likewise.
2245         * modules/gc (Makefile.am): Likewise.
2246         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2247         * modules/getaddrinfo (Makefile.am): Likewise.
2248         * modules/getcwd (Makefile.am): Likewise.
2249         * modules/getdelim (Makefile.am): Likewise.
2250         * modules/getdomainname (Makefile.am): Likewise.
2251         * modules/getgroups (Makefile.am): Likewise.
2252         * modules/gethostname (Makefile.am): Likewise.
2253         * modules/gethrxtime (Makefile.am): Likewise.
2254         * modules/getline (Makefile.am): Likewise.
2255         * modules/getloadavg (Makefile.am): Likewise.
2256         * modules/getlogin_r (Makefile.am): Likewise.
2257         * modules/getopt (Makefile.am): Likewise.
2258         * modules/getpass (Makefile.am): Likewise.
2259         * modules/getpass-gnu (Makefile.am): Likewise.
2260         * modules/getsubopt (Makefile.am): Likewise.
2261         * modules/gettime (Makefile.am): Likewise.
2262         * modules/gettimeofday (Makefile.am): Likewise.
2263         * modules/getugroups (Makefile.am): Likewise.
2264         * modules/getusershell (Makefile.am): Likewise.
2265         * modules/glob (Makefile.am): Likewise.
2266         * modules/group-member (Makefile.am): Likewise.
2267         * modules/hard-locale (Makefile.am): Likewise.
2268         * modules/hash (Makefile.am): Likewise.
2269         * modules/hmac-md5 (Makefile.am): Likewise.
2270         * modules/hmac-sha1 (Makefile.am): Likewise.
2271         * modules/human (Makefile.am): Likewise.
2272         * modules/idcache (Makefile.am): Likewise.
2273         * modules/imaxabs (Makefile.am): Likewise.
2274         * modules/imaxdiv (Makefile.am): Likewise.
2275         * modules/inet_ntop (Makefile.am): Likewise.
2276         * modules/inet_pton (Makefile.am): Likewise.
2277         * modules/inttostr (Makefile.am): Likewise.
2278         * modules/isapipe (Makefile.am): Likewise.
2279         * modules/lchown (Makefile.am): Likewise.
2280         * modules/long-options (Makefile.am): Likewise.
2281         * modules/lstat (Makefile.am): Likewise.
2282         * modules/malloc (Makefile.am): Likewise.
2283         * modules/mathl (Makefile.am): Likewise.
2284         * modules/mbchar (Makefile.am): Likewise.
2285         * modules/md2 (Makefile.am): Likewise.
2286         * modules/md4 (Makefile.am): Likewise.
2287         * modules/md5 (Makefile.am): Likewise.
2288         * modules/memcasecmp (Makefile.am): Likewise.
2289         * modules/memchr (Makefile.am): Likewise.
2290         * modules/memcmp (Makefile.am): Likewise.
2291         * modules/memcoll (Makefile.am): Likewise.
2292         * modules/memcpy (Makefile.am): Likewise.
2293         * modules/memmem (Makefile.am): Likewise.
2294         * modules/memmove (Makefile.am): Likewise.
2295         * modules/mempcpy (Makefile.am): Likewise.
2296         * modules/memrchr (Makefile.am): Likewise.
2297         * modules/memset (Makefile.am): Likewise.
2298         * modules/memxor (Makefile.am): Likewise.
2299         * modules/mkancesdirs (Makefile.am): Likewise.
2300         * modules/mkdir (Makefile.am): Likewise.
2301         * modules/mkdir-p (Makefile.am): Likewise.
2302         * modules/mkdtemp (Makefile.am): Likewise.
2303         * modules/mkstemp (Makefile.am): Likewise.
2304         * modules/mktime (Makefile.am): Likewise.
2305         * modules/modechange (Makefile.am): Likewise.
2306         * modules/mountlist (Makefile.am): Likewise.
2307         * modules/nanosleep (Makefile.am): Likewise.
2308         * modules/openat (Makefile.am): Likewise.
2309         * modules/pagealign_alloc (Makefile.am): Likewise.
2310         * modules/physmem (Makefile.am): Likewise.
2311         * modules/poll (Makefile.am): Likewise.
2312         * modules/posixtm (Makefile.am): Likewise.
2313         * modules/posixver (Makefile.am): Likewise.
2314         * modules/putenv (Makefile.am): Likewise.
2315         * modules/quote (Makefile.am): Likewise.
2316         * modules/quotearg (Makefile.am): Likewise.
2317         * modules/raise (Makefile.am): Likewise.
2318         * modules/read-file (Makefile.am): Likewise.
2319         * modules/readline (Makefile.am): Likewise.
2320         * modules/readlink (Makefile.am): Likewise.
2321         * modules/readtokens (Makefile.am): Likewise.
2322         * modules/readutmp (Makefile.am): Likewise.
2323         * modules/realloc (Makefile.am): Likewise.
2324         * modules/regex (Makefile.am): Likewise.
2325         * modules/rename (Makefile.am): Likewise.
2326         * modules/rename-dest-slash (Makefile.am): Likewise.
2327         * modules/rijndael (Makefile.am): Likewise.
2328         * modules/rmdir (Makefile.am): Likewise.
2329         * modules/rpmatch (Makefile.am): Likewise.
2330         * modules/safe-read (Makefile.am): Likewise.
2331         * modules/safe-write (Makefile.am): Likewise.
2332         * modules/same (Makefile.am): Likewise.
2333         * modules/save-cwd (Makefile.am): Likewise.
2334         * modules/savedir (Makefile.am): Likewise.
2335         * modules/setenv (Makefile.am): Likewise.
2336         * modules/settime (Makefile.am): Likewise.
2337         * modules/sha1 (Makefile.am): Likewise.
2338         * modules/sig2str (Makefile.am): Likewise.
2339         * modules/snprintf (Makefile.am): Likewise.
2340         * modules/stdlib-safer (Makefile.am): Likewise.
2341         * modules/stpcpy (Makefile.am): Likewise.
2342         * modules/stpncpy (Makefile.am): Likewise.
2343         * modules/strcase (Makefile.am): Likewise.
2344         * modules/strcasestr (Makefile.am): Likewise.
2345         * modules/strchrnul (Makefile.am): Likewise.
2346         * modules/strcspn (Makefile.am): Likewise.
2347         * modules/strdup (Makefile.am): Likewise.
2348         * modules/strerror (Makefile.am): Likewise.
2349         * modules/strftime (Makefile.am): Likewise.
2350         * modules/strndup (Makefile.am): Likewise.
2351         * modules/strnlen (Makefile.am): Likewise.
2352         * modules/strpbrk (Makefile.am): Likewise.
2353         * modules/strsep (Makefile.am): Likewise.
2354         * modules/strstr (Makefile.am): Likewise.
2355         * modules/strtod (Makefile.am): Likewise.
2356         * modules/strtoimax (Makefile.am): Likewise.
2357         * modules/strtok_r (Makefile.am): Likewise.
2358         * modules/strtol (Makefile.am): Likewise.
2359         * modules/strtoll (Makefile.am): Likewise.
2360         * modules/strtoul (Makefile.am): Likewise.
2361         * modules/strtoull (Makefile.am): Likewise.
2362         * modules/strtoumax (Makefile.am): Likewise.
2363         * modules/strverscmp (Makefile.am): Likewise.
2364         * modules/time_r (Makefile.am): Likewise.
2365         * modules/timegm (Makefile.am): Likewise.
2366         * modules/tmpfile-safer (Makefile.am): Likewise.
2367         * modules/unistd-safer (Makefile.am): Likewise.
2368         * modules/unlinkdir (Makefile.am): Likewise.
2369         * modules/userspec (Makefile.am): Likewise.
2370         * modules/utime (Makefile.am): Likewise.
2371         * modules/utimecmp (Makefile.am): Likewise.
2372         * modules/utimens (Makefile.am): Likewise.
2373         * modules/vasnprintf (Makefile.am): Likewise.
2374         * modules/vasprintf (Makefile.am): Likewise.
2375         * modules/vsnprintf (Makefile.am): Likewise.
2376         * modules/xalloc (Makefile.am): Likewise.
2377         * modules/xgetcwd (Makefile.am): Likewise.
2378         * modules/xnanosleep (Makefile.am): Likewise.
2379         * modules/xreadlink (Makefile.am): Likewise.
2380         * modules/xstrtod (Makefile.am): Likewise.
2381         * modules/xstrtol (Makefile.am): Likewise.
2382         * modules/xstrtold (Makefile.am): Likewise.
2383         * modules/yesno (Makefile.am): Likewise.
2384
2385 2006-10-12  Jim Meyering  <jim@meyering.net>
2386
2387         * m4/getloadavg.m4: Revert the change below.
2388
2389         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
2390         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
2391         fail with a symlink, which is what coreutils' ./bootstrap now
2392         creates by default.
2393
2394 2006-10-12  Bruno Haible  <bruno@clisp.org>
2395
2396         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
2397         mingw.
2398         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
2399         MSVC and mingw explicitly.
2400
2401 2006-10-11  Simon Josefsson  <jas@extundo.com>
2402             Bruno Haible  <bruno@clisp.org>
2403
2404         Add support for multiple gnulib-tool invocations in the scope of a
2405         single configure.ac file.
2406         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
2407         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
2408         with the same contents as the _LIBADD variable.
2409         (func_emit_initmacro_start, func_emit_initmacro_end,
2410         func_emit_initmacro_done): New functions.
2411         (func_import, func_create_testdir): Invoke them. Allow the identifiers
2412         gl_LIBOBJS and gl_LTLIBOBJS.
2413
2414 2006-10-11  Bruno Haible  <bruno@clisp.org>
2415
2416         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
2417         (func_create_testdir): Don't create po/Makefile.am, don't invoke
2418         autoreconf. Instead, invoke autopoint explicitly but move back the
2419         *.m4 files from gnulib.
2420
2421 2006-10-11  Bruno Haible  <bruno@clisp.org>
2422
2423         * gnulib-tool (func_usage): Make module names after --create-testdir
2424         optional.
2425         (func_create_testdir): If no module was specified, use nearly all
2426         modules.
2427
2428 2006-10-12  Jim Meyering  <jim@meyering.net>
2429
2430         Big performance improvement for fts-based tools that use FTS_NOSTAT.
2431         Avoid spurious inode-mismatch problems on non-POSIX file systems.
2432         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
2433         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
2434         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
2435         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
2436         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
2437         (fts_set_stat_required): New function.
2438         (fts_open): Defer the calls to fts_stat, if possible or requested.
2439         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
2440         into fts_stat itself.
2441         (fts_read): Perform any required (deferred) fts_stat call.
2442         (fts_build): Likewise, for the directory we're about to open and read.
2443         In the readdir loop, carefully decide whether each entry will require
2444         an eventual call to fts_stat, using dirent.d_type info if available.
2445         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
2446         a command line argument into this function.  Update all callers.
2447         Map a return value of FTS_DOT to FTS_D for a command line argument.
2448         * modules/fts (Depends-on): Add d-type.  Alphabetize.
2449         Thanks to Miklos Szeredi for his tenacity and for the initial
2450         bug report about "find" failing on a FUSE-based file system.
2451
2452         * lib/fts.c (fts_open): Use consistent indentation.
2453
2454 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2455
2456         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
2457         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
2458         reported by Jim Meyering.  All uses of cache variables renamed
2459         to match Autoconf's.
2460         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
2461         the other one.
2462
2463         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
2464         Fix misspelling in diagnostic.
2465
2466 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2467
2468         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
2469         defined.  Problem reported by Matthew Woehlke.
2470
2471         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
2472         Add support for Tandem NonStop R series.
2473         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
2474         Use new macro.
2475
2476         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
2477         (has_trailing_slash): Omit size arg; all callers changed.
2478         Omit 'inline', since it doesn't help performance and we'd
2479         need to configure it.
2480         Don't count //, ///, etc. as having a trailing slash.
2481         As a side effect, this removes a C99ism reported by Matthew Woehlke.
2482         (rpl_rename_dest_slash): On failure, use rename's errno rather
2483         than (in some cases) an incorrect or junk errno.
2484         Simplify code by removing need to compute length; this does
2485         cause it to make two passes instead of one over the file name,
2486         but it's worth it.
2487
2488         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
2489         change, since Autoconf's version may no longer be appropriate now
2490         that we are using CVS Autoconf's version.  Add support for Tandem.
2491
2492 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2493             Bruno Haible  <bruno@clisp.org>
2494
2495         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
2496         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
2497         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
2498         gl_AC_TYPE_LONG_LONG.
2499
2500         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
2501         instead of HAVE_LONG_LONG.
2502         * lib/printf-args.c (printf_fetchargs): Likewise.
2503         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
2504         * lib/vasnprintf.c (VASNPRINTF): Likewise.
2505         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
2506         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
2507         gl_AC_TYPE_LONG_LONG.
2508
2509 2006-10-11  Bruno Haible  <bruno@clisp.org>
2510
2511         * m4/longlong.m4: Add comments.
2512         * m4/ulonglong.m4: Likewise.
2513
2514 2006-10-10  Bruno Haible  <bruno@clisp.org>
2515
2516         Make it possible to #define stpcpy, strdup to aliases.
2517         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
2518         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
2519
2520 2006-10-10  Bruno Haible  <bruno@clisp.org>
2521
2522         Make it possible to #define gcd to an alias.
2523         * lib/gcd.c: Include config.h.
2524
2525 2006-10-10  Bruno Haible  <bruno@clisp.org>
2526
2527         Make it possible to #define c_isascii to an alias.
2528         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
2529         defined. Undefine the macros before defining them, to avoid gcc
2530         warnings.
2531         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
2532         define NO_C_CTYPE_MACROS early.
2533
2534 2006-10-10  Bruno Haible  <bruno@clisp.org>
2535
2536         Make it possible to #define set_program_name to an alias.
2537         * lib/progname.c: Don't undefine set_program_name; instead, undefine
2538         ENABLE_RELOCATABLE early.
2539
2540 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
2541
2542         Port to Tandem NSK OSS, which has 64-bit signed int but at most
2543         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
2544         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
2545         More generally, don't assume that 64-bit signed int is available
2546         if unsigned int is, and vice versa.
2547         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
2548         unsigned symbols, not on their signed counterparts.
2549         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
2550         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
2551         (UINT64_C, UINTMAX_C):
2552         Likewise.
2553         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
2554         unsigned counterparts.
2555         (Have_long_long, Unsigned): New macros.
2556         (Int): Renamed from INT.
2557         (strtoimax): Use the new macros.
2558         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
2559         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
2560         * modules/inttypes (inttypes.h): Substitute
2561         HAVE_UNSIGNED_LONG_LONG_INT.
2562         * modules/stdint (stdint.h): Likewise.
2563         (Files): Add m4/ulonglong.m4.
2564
2565 2006-10-10  Bruno Haible  <bruno@clisp.org>
2566
2567         Fix a gcc -Wshadow warning.
2568         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
2569         to 'bucket'.
2570         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
2571         gl_linked_indexof_from_to): Likewise.
2572         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
2573         Likewise.
2574         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
2575         Likewise.
2576         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
2577         Reported by Eric Blake.
2578
2579 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2580
2581         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
2582         for NetBSD.  Problem reported by Bruno Haible.
2583
2584 2006-10-09  Jim Meyering  <jim@meyering.net>
2585
2586         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
2587         Patch from Bruno Haible.
2588
2589 2006-10-09  Jim Meyering  <jim@meyering.net>
2590
2591         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
2592         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
2593         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
2594
2595 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
2596
2597         Don't include <config.h> twice; this doesn't work in some cases,
2598         e.g., when config.h has "#define intmax_t long long int" and
2599         we include <config.h>, <inttypes.h>, <config.h> in that order.
2600         Problem reported by Matthew Woehlke in:
2601         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
2602         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
2603         * lib/fts-cycle.c: Don't include config.h.
2604         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
2605         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
2606         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
2607         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
2608         inttypes.h.
2609         * lib/xstrtoumax.c: Likewise.
2610         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
2611         __strtol and the like, so that this module is more like its siblings.
2612         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
2613         Remove; no longer needed now that we assume gnulib inttypes.h.
2614
2615 2006-10-08  Bruno Haible  <bruno@clisp.org>
2616
2617         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
2618         option.
2619
2620 2006-10-07  Jim Meyering  <jim@meyering.net>
2621
2622         * modules/inttypes (inttypes.h): Revert what seems to have been
2623         an inadvertent part of today's change: use "|", not "/" in the
2624         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
2625
2626 2006-10-07  Bruno Haible  <bruno@clisp.org>
2627
2628         * modules/sublist: New file.
2629
2630 2006-10-07  Bruno Haible  <bruno@clisp.org>
2631
2632         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
2633         * modules/argz (argz.h): Likewise.
2634         * modules/arpa_inet (arpa/inet.h): Likewise.
2635         * modules/byteswap (byteswap.h): Likewise.
2636         * modules/configmake (configmake.h): Likewise.
2637         * modules/fcntl (fcntl.h): Likewise.
2638         * modules/fnmatch (fnmatch.h): Likewise.
2639         * modules/getopt (getopt.h): Likewise.
2640         * modules/glob (glob.h): Likewise.
2641         * modules/inttypes (inttypes.h): Likewise.
2642         * modules/netinet_in (netinet/in.h): Likewise.
2643         * modules/poll (poll.h): Likewise.
2644         * modules/stdbool (stdbool.h): Likewise.
2645         * modules/stdint (stdint.h): Likewise.
2646         * modules/sys_select (sys/select.h): Likewise.
2647         * modules/sys_socket (sys/socket.h): Likewise.
2648         * modules/sys_stat (sys/stat.h): Likewise.
2649         * modules/sysexits (sysexits.h): Likewise.
2650         * modules/unistd (unistd.h): Likewise.
2651         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2652         Add a "DO NOT EDIT" comment to the generated file.
2653         (func_import): Likewise for gnulib-comp.m4.
2654
2655 2006-10-07  Bruno Haible  <bruno@clisp.org>
2656
2657         * lib/gl_sublist.h: New file.
2658         * lib/gl_sublist.c: New file.
2659
2660 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
2661
2662         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
2663         name (relative to the original working directory) and the file
2664         name component (relative to the temporary working directory).  All
2665         callers changed.
2666         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
2667         * lib/mkdir-p.c (make_dir_parents): Likewise.
2668         * lib/mkdir-p.h (make_dir_parents): Likewise.
2669
2670 2006-10-06  Eric Blake  <ebb9@byu.net>
2671
2672         Define several macros for use by the clean-temp module.
2673         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
2674         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
2675         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
2676
2677         * lib/clean-temp.h (close_stream_temp): New declaration.
2678         * lib/clean-temp.c (includes): Pull in headers according to what
2679         other modules are in use.
2680         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
2681
2682 2006-10-06  Bruno Haible  <bruno@clisp.org>
2683
2684         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
2685         instead of fopen, fwriteerror.
2686
2687 2006-10-06  Bruno Haible  <bruno@clisp.org>
2688
2689         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
2690         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
2691         int.
2692         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
2693         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
2694         Return an error indicator.
2695         Suggested by Eric Blake.
2696
2697 2006-10-06  Bruno Haible  <bruno@clisp.org>
2698
2699         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
2700         Reported by Eric Blake.
2701
2702 2006-10-06  Bruno Haible  <bruno@clisp.org>
2703
2704         * modules/closeout (Description): Mention stderr too.
2705
2706 2006-10-06  Bruno Haible  <bruno@clisp.org>
2707         and Paul Eggert  <eggert@cs.ucla.edu>
2708
2709         * lib/closeout.c (close_stdout): Also close stderr.
2710         * lib/closeout.h: Update comment.
2711
2712 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
2713
2714         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
2715         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
2716         * lib/dirchownmod.c: Include lchown.h.
2717         * lib/lchown.c: Don't include files that lchown.h now includes.
2718         Don't declare chown, since lchown.h now does that.
2719         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
2720         (lchown): Define to rpl_chown if lchown is declared but
2721         does not exist.  Declare using a prototype if lchown is not
2722         declared.  Add a copyright notice.
2723         * lib/mkstemp.h: Include <unistd.h>.
2724         * lib/openat.c: Include lchown.h.
2725
2726         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
2727         we now test for that separately.
2728         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
2729         rather than O_NOFOLLOW, when testing whether it's possible to
2730         avoid a race condition reliably.
2731         * lib/savewd.c (savewd_chdir): Likewise.
2732
2733         Remove macros that are no longer needed now that stdint.h is
2734         reliable.
2735         * lib/fsusage.c (UINTMAX_MAX): Remove.
2736         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
2737         * lib/utimecmp.c (SIZE_MAX): Remove.
2738
2739         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
2740
2741         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
2742         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
2743         O_NOATIME works.
2744
2745 2006-10-05  Bruno Haible  <bruno@clisp.org>
2746
2747         * lib/gl_list.h (gl_sortedlist_search_from_to,
2748         gl_sortedlist_indexof_from_to): New declarations.
2749         (gl_list_implementation): New fields sortedlist_search_from_to,
2750         sortedlist_indexof_from_to.
2751         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
2752         inline functions.
2753         * lib/gl_list.c (gl_sortedlist_search_from_to,
2754         gl_sortedlist_indexof_from_to): New functions.
2755         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
2756         function.
2757         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
2758         (gl_array_sortedlist_search_from_to): New function.
2759         (gl_array_list_implementation): Update.
2760         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
2761         function.
2762         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
2763         (gl_carray_sortedlist_search_from_to): New function.
2764         (gl_carray_list_implementation): Update.
2765         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
2766         gl_linked_sortedlist_indexof_from_to): New functions.
2767         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2768         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2769         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
2770         gl_tree_sortedlist_indexof_from_to): New functions.
2771         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2772         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2773         Update.
2774         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2775         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
2776         Update.
2777
2778 2006-10-05  Bruno Haible  <bruno@clisp.org>
2779
2780         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
2781         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
2782         (struct gl_list_implementation): Add fields search_from_to,
2783         indexof_from_to. Remove fields search, indexof.
2784         (gl_list_search): Use the search_from_to method.
2785         (gl_list_search_from, gl_list_search_from_to): New functions.
2786         (gl_list_indexof): Use the indexof_from_to method.
2787         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2788         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
2789         (gl_list_search_from, gl_list_search_from_to): New functions.
2790         (gl_list_indexof): Use the indexof_from_to method.
2791         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2792         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
2793         gl_array_indexof. Add start_index, end_index arguments.
2794         (gl_array_search_from_to): Renamed from gl_array_search. Add
2795         start_index, end_index arguments.
2796         (gl_array_remove, gl_array_list_implementation): Update.
2797         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
2798         gl_carray_indexof. Add start_index, end_index arguments.
2799         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
2800         start_index, end_index arguments.
2801         (gl_carray_remove, gl_carray_list_implementation): Update.
2802         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
2803         gl_linked_search. Add start_index, end_index arguments.
2804         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
2805         start_index, end_index arguments.
2806         (gl_linked_remove): Update.
2807         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2808         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2809         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
2810         field to 'size_t'.
2811         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
2812         gl_tree_search. Add start_index, end_index arguments.
2813         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2814         start_index, end_index arguments.
2815         (gl_tree_remove): Update.
2816         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2817         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2818         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
2819         function.
2820         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
2821         gl_tree_search. Add start_index, end_index arguments.
2822         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2823         start_index, end_index arguments.
2824         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2825         Update.
2826         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
2827
2828 2006-10-05  Bruno Haible  <bruno@clisp.org>
2829
2830         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
2831
2832         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
2833         fwriteerror_temp): New declarations.
2834         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
2835         (descriptors): New variable.
2836         (cleanup): First, close the descriptors.
2837         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
2838         fclose_temp, fwriteerror_temp): New functions.
2839
2840 2006-10-04  Jim Meyering  <jim@meyering.net>
2841
2842         * lib/fts.c (fts_open): Tiny comment change.
2843
2844 2006-10-04  Bruno Haible  <bruno@clisp.org>
2845
2846         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
2847         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
2848         gl_LOCK_BODY.
2849         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
2850         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
2851         gl_LOCK_EARLY_BODY.
2852         (gl_LOCK): Require gl_LOCK_BODY.
2853
2854 2006-10-04  Bruno Haible  <bruno@clisp.org>
2855
2856         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
2857         (gl_oset_search_atleast): New declaration.
2858         (struct gl_oset_implementation): Add field 'search_atleast'.
2859         (gl_oset_search_atleast): New inline function.
2860         * lib/gl_oset.c (gl_oset_search_atleast): New function.
2861         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
2862         (gl_array_oset_implementation): Update.
2863         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
2864         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
2865         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
2866
2867 2006-10-04  Bruno Haible  <bruno@clisp.org>
2868
2869         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
2870
2871 2006-10-03  Bruno Haible  <bruno@clisp.org>
2872
2873         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
2874         from gl_avltreehash_list_implementation.
2875
2876 2006-10-03  Bruno Haible  <bruno@clisp.org>
2877
2878         * lib/gl_oset.c (gl_oset_add): Fix return type.
2879
2880 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
2881
2882         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
2883
2884 2006-10-02  Eric Blake  <ebb9@byu.net>
2885
2886         * modules/strnlen (Depends-on): Add extensions.
2887
2888 2006-10-02  Eric Blake  <ebb9@byu.net>
2889
2890         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
2891         definition in 2.60+.
2892
2893 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
2894
2895         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
2896         checks.
2897
2898 2006-10-02  Bruno Haible  <bruno@clisp.org>
2899
2900         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
2901         to the AUTOMAKE_OPTIONS.
2902         Reported by Jim Meyering.
2903
2904 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
2905
2906         Work around bug in Solaris 10 /proc file system:
2907         /proc/self/fd/NNN/.. isn't the parent directory of
2908         the directory whose file descriptor is NNN.  This needs to
2909         be worked around at run time, not compile time, since a
2910         program might be built on Solaris 8, where things work, and
2911         run on Solaris 10.
2912         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
2913         to use the following interface instead:
2914         (OPENAT_BUFFER_SIZE): New macro.
2915         (openat_proc_name): New function.
2916         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
2917         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
2918         Likewise.
2919         * lib/openat-proc.c: New file.
2920         * modules/openat (Files): Add lib/openat-proc.c.
2921         (Depends-on): Add same-inode, stdbool.
2922         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
2923
2924 2006-09-29  Bruno Haible  <bruno@clisp.org>
2925
2926         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
2927         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
2928         argument. Set stdout_closed before testing for ferror, not after.
2929         (fwriteerror, fwriteerror_no_ebadf): New functions.
2930
2931 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2932
2933         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
2934
2935 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
2936
2937         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
2938         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
2939
2940 2006-09-28  Jim Meyering  <jim@meyering.net>
2941
2942         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
2943         Include <unistd.h>.
2944
2945 2006-09-28  Bruno Haible  <bruno@clisp.org>
2946
2947         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
2948         * modules/linkedhash-list (Depends-on): Likewise.
2949         * modules/rbtreehash-list (Depends-on): Likewise.
2950
2951 2006-09-28  Bruno Haible  <bruno@clisp.org>
2952
2953         * lib/strndup.h: Simplify the redefinition of strndup.
2954         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
2955         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
2956
2957 2006-09-28  Bruno Haible  <bruno@clisp.org>
2958
2959         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
2960         * lib/gl_linkedhash_list.c: Likewise.
2961         * lib/gl_rbtreehash_list.c: Likewise.
2962
2963 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
2964
2965         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
2966         getaddrinfo.
2967
2968         * lib/__fpending.h: Don't include <stdio_ext.h> unless
2969         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
2970         it causes <stdio_ext.h> to cause a compile-time error.
2971         Problem reported by Nelson H. F. Beebe.
2972         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
2973         of HAVE_DECL___PENDING.
2974
2975         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
2976         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
2977         declaration.
2978
2979 2006-09-27  Jim Meyering  <jim@meyering.net>
2980
2981         This file could end up with a definition for a function
2982         named __strndup, rather than rpl_strndup on a system with
2983         incomplete weak_alias support.
2984         * lib/strndup.c (strndup): Rename from __strndup.
2985         Remove #defines that used to map __strndup to strndup.
2986         Don't use K&R prototypes.
2987         Remove LIBC-related code, since this file is not sync'd with glibc.
2988         * lib/strndup.h: Revamp, accordingly.
2989         * m4/strndup.m4: Modernize.
2990
2991 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
2992
2993         * modules/savewd (Depends-on): Add 'raise'.
2994         * lib/savewd.c: Include <signal.h>, for 'raise'.
2995
2996 2006-09-26  Jim Meyering  <jim@meyering.net>
2997
2998         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
2999         when we detect Darwin 8.7.0's acl_get_file bug.
3000         Rearrange to perform the new (below) run-test while $LIBS
3001         contains any acl-related library.  Set USE_ACL at the end.
3002         (gl_ACL_GET_FILE): New function.
3003
3004 2006-09-26  Eric Blake  <ebb9@byu.net>
3005
3006         * lib/verror.c: Include <config.h> unconditionally.
3007
3008 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
3009
3010         * modules/clock-time (Maintainer): Add self.
3011         * modules/getlogin_r (Depends-on): Add extensions.
3012
3013 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3014
3015         * modules/clock-time: New module.
3016         * modules/nanosleep (Depends-on): Add clock-time.
3017         * modules/gethrxtime (Depends-on): Likewise.
3018         * modules/gettime (Depends-on): Likewise.
3019         * modules/settime (Depends-on): Likewise.
3020
3021         * modules/fts-lgpl: Depend on openat.
3022         * modules/mkancesdirs: Depend on savewd.
3023         * modules/mkdir-p: Likewise.
3024
3025 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3026
3027         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
3028
3029         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
3030         `gl_have_arbitrary_file_name_length_limit' to
3031         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
3032         actually works between configure runs.
3033
3034 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3035             Bruno Haible  <bruno@clisp.org>
3036
3037         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
3038
3039 2006-09-25  Jim Meyering  <jim@meyering.net>
3040
3041         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
3042         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
3043
3044 2006-09-25  Eric Blake  <ebb9@byu.net>
3045
3046         * gnulib-tool (func_import, func_create_testdir): Fix typos in
3047         exec's in 2006-09-18 patch when shuffling fds.
3048
3049 2006-09-25  Bruno Haible  <bruno@clisp.org>
3050
3051         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
3052         Reported by Jim Meyering.
3053
3054 2006-09-24  Jim Meyering  <jim@meyering.net>
3055
3056         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
3057         compare a pointer against a literal "0".  That caused failures with
3058         at least HP-UX's hpcc.
3059
3060 2006-09-22  Simon Josefsson  <jas@extundo.com>
3061
3062         * modules/gc-sha1:
3063         * modules/gc-md4:
3064         * modules/gc-hmac-sha1:
3065         * modules/gc-hmac-md5:
3066         * modules/gc-des:
3067         * modules/gc-arcfour: Distribute more files.
3068
3069 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3070
3071         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
3072         (gl_linked_iterator_from_to): Initialize struct completely.
3073         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
3074         (gl_tree_iterator_from_to): Likewise
3075         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
3076         * lib/gl_array_list.c [lint] (gl_array_iterator)
3077         (gl_array_iterator_from_to): Likewise.
3078         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
3079         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
3080         (gl_carray_iterator_from_to): Likewise.
3081
3082         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
3083         * lib/md4.c (md4_process_block): Remove unused variable.
3084         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
3085         parentheses for clarity.
3086
3087 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3088
3089         * modules/bison-i18n (Depends-on): Add gettext.
3090
3091 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3092
3093         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
3094         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
3095         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
3096         also add missing comma that caused broken test.
3097         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
3098         stdlib.h, for `abort'.
3099         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
3100         variables.
3101         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
3102         include unistd.h if present, for `rmdir'.
3103         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
3104         variables.
3105         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
3106         in the process include standard headers for prototypes.
3107         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
3108         gets declared on GNU/Linux.
3109         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
3110         unistd.h, for `rmdir'.
3111         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
3112
3113         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
3114         always true.
3115         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
3116
3117         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
3118
3119 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3120
3121         * gnulib-tool (func_version): Create output all at once.  This
3122         may help avoid triggering unnecessary SIGPIPEs, and at any
3123         rate it doesn't hurt.
3124
3125 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3126             Bruno Haible  <bruno@clisp.org>
3127
3128         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
3129         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
3130         * m4/signed.m4 (bh_C_SIGNED): Likewise.
3131
3132         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
3133         (gl_FUNC_VASPRINTF): Invoke it.
3134
3135 2006-09-22  Bruno Haible  <bruno@clisp.org>
3136
3137         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
3138         getloadavg.c as first argument.
3139
3140 2006-09-22  Bruno Haible  <bruno@clisp.org>
3141
3142         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
3143         at the beginning of the gl_INIT macro.
3144         * modules/getloadavg (configure.ac): Pass $gl_source_base to
3145         gl_GETLOADAVG.
3146
3147 2006-09-22  Bruno Haible  <bruno@clisp.org>
3148
3149         * gnulib-tool (func_create_megatestdir): Don't include the config-h
3150         module.
3151         Suggested by Ralf Wildenhues.
3152
3153 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
3154
3155         Import this patch from libc:
3156
3157         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
3158
3159         * lib/regex_internal.c (re_string_reconstruct): Handle
3160         offset < pstr->valid_raw_len && pstr->offsets_needed case.
3161         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
3162         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
3163         re_string_context_at.
3164
3165         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
3166         now requires it.
3167         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
3168         gl_REGEX now does it for us.
3169         (gl_REGEX): Add test taken from
3170         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
3171
3172         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
3173         Check that large offsets work.  Modernize Autoconf usages.
3174         Prefer "yes" to mean a good thing rather than a bad.
3175         Don't put "#define mkstemp" in config.h, as this might interfere
3176         with standard system headers that "#define mkstemp mkstemp64".
3177
3178         * modules/mkstemp (Depends-on): Add extensions, so that
3179         mkstemp is visible on some platforms.
3180         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
3181         (Include): Change to "mkstemp.h" from <stdlib.h>.
3182         (Files): Add mkstemp.h.
3183
3184         * lib/mkstemp.h: New file, since some standard headers
3185         #define mkstemp.
3186         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
3187         Include "mkstemp.h".
3188         Make the _LIBC code resemble glibc original more,
3189         e.g., use K&R style.
3190         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
3191         (mkstemp): Remove, since mkstemp.h does this for us.
3192         * lib/stdlib--.h: Include mkstemp.h.
3193
3194         Import this patch from libc:
3195
3196         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3197
3198         * lib/tempname.c (__gen_tempname): Change attempts_min
3199         into a macro.  Use preprocessor to decide how to initialize
3200         attempts [Coverity CID 67].
3201
3202 2006-09-20  Bruno Haible  <bruno@clisp.org>
3203
3204         * lib/mkdtemp.c: Import from libc.
3205         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3206                 * sysdeps/posix/tempname.c (__gen_tempname): Change
3207                 attempts_min into a macro.  Use preprocessor to decide how to
3208                 initialize attempts [Coverity CID 67].
3209         2001-11-27  Paul Eggert  <eggert@twinsun.com>
3210                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
3211                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
3212
3213 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3214
3215         * gnulib-tool (func_exit): New function, to allow to pass the
3216         exit status portably through the trap.  Use everywhere.
3217         (--help, --version): Signal a write error.
3218         (trap): catch SIGPIPE, for write errors.
3219         Exit at the end of the trap, with the correct exit status.
3220
3221 2006-09-19  Karl Berry  <karl@gnu.org>
3222
3223         * doc/gnulib.texi: note about the license texinfo files.
3224
3225 2006-09-19  Eric Blake  <ebb9@byu.net>
3226
3227         * gnulib-tool: Avoid space-tab.
3228
3229 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3230
3231         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
3232         that prevented coreutils 6.1 from building.  Problem reported
3233         by Petter Reinholdtsen.
3234
3235 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3236
3237         * gnulib-tool (avoidlist): Fix typo that broke options like
3238         --avoid=lock that are used by coreutils bootstrap.
3239
3240 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
3241
3242         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
3243         more systematically.
3244
3245 2006-09-18  Jim Meyering  <jim@meyering.net>
3246
3247         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
3248
3249 2006-09-18  Bruno Haible  <bruno@clisp.org>
3250
3251         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
3252
3253 2006-09-18  Bruno Haible  <bruno@clisp.org>
3254
3255         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
3256         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
3257         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
3258         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
3259         * m4/gettext.m4: Require autoconf >= 2.52.
3260         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
3261         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
3262         of gl_cv_header_inttypes_h.
3263
3264 2006-09-18  Bruno Haible  <bruno@clisp.org>
3265
3266         * lib/javaversion.c: Include configmake.h.
3267
3268 2006-09-18  Bruno Haible  <bruno@clisp.org>
3269
3270         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
3271         avoid that the while loops be executed in a subshell.
3272
3273 2006-09-18  Bruno Haible  <bruno@clisp.org>
3274
3275         * MODULES.html.sh (func_module): Break long lines.
3276         Suggested by Bruce Korb <bkorb@gnu.org>.
3277
3278 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3279
3280         Speed up by a factor of 1.12.
3281         * gnulib-tool (nl): New variable.
3282         (func_import): Rewrite include directive extraction to only read each
3283         directive once.
3284
3285 2006-09-17  Bruno Haible  <bruno@clisp.org>
3286
3287         * modules/javaversion (Makefile.am): Remove DEFS setting.
3288         (Depends-on): Add configmake, for PKGDATADIR definition.
3289
3290 2006-09-17  Bruno Haible  <bruno@clisp.org>
3291
3292         * gnulib-tool (func_create_testdir): Rewrite all files at once.
3293
3294 2006-09-17  Bruno Haible  <bruno@clisp.org>
3295
3296         * gnulib-tool (func_append): New function, stolen from libtool.m4.
3297         (func_modules_transitive_closure, func_modules_add_dummy,
3298         func_modules_to_filelist, func_import, func_create_testdir,
3299         func_create_megatestdir, ...): Use it wherever possible.
3300         Suggested by Ralf Wildenhues.
3301
3302 2006-09-16  Karl Berry  <karl@gnu.org>
3303
3304         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
3305         to avoid sectioning errors.
3306         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
3307         [ifinfo]: blank line after @center-ed titles.
3308         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
3309         Spell FSF address consistently with others.
3310         (These changes approved by rms.)
3311
3312 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3313
3314         Speed up by a factor of 1.61.
3315         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
3316         already checked module names again.
3317
3318 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3319
3320         Speed up by a factor of 1.13.
3321         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
3322         for new_files, and the input to func_add_or_update.
3323
3324 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3325
3326         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
3327         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
3328
3329 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3330
3331         * modules/mkancesdirs (Depends-on): Add fcntl.
3332         * modules/savewd: New file.
3333         * MODULES.html.sh (File system functions): Add savewd.
3334
3335         * modules/configmake (Makefile.am): Add support for the
3336         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
3337
3338 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3339
3340         * m4/savewd.m4: New file.
3341
3342 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3343
3344         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
3345         (dirchownmod): New arg FD.  All callers changed.
3346         Use FD rather than opening the directory ourself, as opening is
3347         now the caller's responsibility.
3348         * lib/dirchownmod.h: Likewise.
3349         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
3350         hosts that require <sys/types.h> before <sys/stat.h>.  Include
3351         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
3352         (test_dir): Remove.
3353         (mkancesdirs): Return length of prefix of FILE that has already
3354         been made, or -2 if there is a child doing the work.  Redo
3355         algorithm so that it is O(N) rather than O(N**2).  Optimize away
3356         ".", and treat ".." specially since it might stray back into
3357         already-created areas.  Use a subprocess if necessary.  New arg
3358         WD; all users changed.  MAKE_DIR function should now return 1
3359         if it creates a directory that is not readable.  Return -2 if
3360         a child process is spun off.
3361         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
3362         Adjust signature to match code.
3363         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
3364         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
3365         all users changed.
3366         * lib/savewd.c, lib/savewd.h: New files.
3367
3368 2006-09-15  Jim Meyering  <jim@meyering.net>
3369
3370         * modules/rename-dest-slash: New module.
3371         * MODULES.html.sh (posix_compat): Add it here.
3372
3373         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
3374
3375 2006-09-15  Jim Meyering  <jim@meyering.net>
3376
3377         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
3378         file.
3379
3380         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
3381
3382 2006-09-15  Jim Meyering  <jim@meyering.net>
3383
3384         * lib/rename-dest-slash.c (has_trailing_slash): Use
3385         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
3386         (rpl_rename_dest_slash): Perform the cheaper trailing slash
3387         test before testing whether SRC is a directory.
3388         Suggestions from Bruno Haible.
3389
3390         Avoid a warning about an unused variable.
3391         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
3392         into the #ifdef block where it's used.
3393
3394         * lib/rename-dest-slash.c: New file.
3395
3396 2006-09-14  Bruno Haible  <bruno@clisp.org>
3397
3398         * lib/allocsa.c: Include <config.h> unconditionally.
3399         * lib/asnprintf.c: Likewise.
3400         * lib/asprintf.c: Likewise.
3401         * lib/c-strcasecmp.c: Likewise.
3402         * lib/c-strcasestr.c: Likewise.
3403         * lib/c-strncasecmp.c: Likewise.
3404         * lib/c-strstr.c: Likewise.
3405         * lib/classpath.c: Likewise.
3406         * lib/clean-temp.c: Likewise.
3407         * lib/concatpath.c: Likewise.
3408         * lib/copy-file.c: Likewise.
3409         * lib/csharpcomp.c: Likewise.
3410         * lib/csharpexec.c: Likewise.
3411         * lib/execute.c: Likewise.
3412         * lib/fatal-signal.c: Likewise.
3413         * lib/findprog.c: Likewise.
3414         * lib/fwriteerror.c: Likewise.
3415         * lib/gl_array_list.c: Likewise.
3416         * lib/gl_array_oset.c: Likewise.
3417         * lib/gl_avltree_list.c: Likewise.
3418         * lib/gl_avltree_oset.c: Likewise.
3419         * lib/gl_avltreehash_list.c: Likewise.
3420         * lib/gl_carray_list.c: Likewise.
3421         * lib/gl_linked_list.c: Likewise.
3422         * lib/gl_linkedhash_list.c: Likewise.
3423         * lib/gl_list.c: Likewise.
3424         * lib/gl_oset.c: Likewise.
3425         * lib/gl_rbtree_list.c: Likewise.
3426         * lib/gl_rbtree_oset.c: Likewise.
3427         * lib/gl_rbtreehash_list.c: Likewise.
3428         * lib/imaxabs.c: Likewise.
3429         * lib/imaxdiv.c: Likewise.
3430         * lib/javacomp.c: Likewise.
3431         * lib/javaexec.c: Likewise.
3432         * lib/javaversion.c: Likewise.
3433         * lib/linebreak.c: Likewise.
3434         * lib/localcharset.c: Likewise.
3435         * lib/lock.c: Likewise.
3436         * lib/mbchar.c: Likewise.
3437         * lib/mbswidth.c: Likewise.
3438         * lib/mkdtemp.c: Likewise.
3439         * lib/pipe.c: Likewise.
3440         * lib/printf-args.c: Likewise.
3441         * lib/printf-parse.c: Likewise.
3442         * lib/progname.c: Likewise.
3443         * lib/progreloc.c: Likewise.
3444         * lib/readlink.c: Likewise.
3445         * lib/sh-quote.c: Likewise.
3446         * lib/stpcpy.c: Likewise.
3447         * lib/stpncpy.c: Likewise.
3448         * lib/strcasecmp.c: Likewise.
3449         * lib/strcasestr.c: Likewise.
3450         * lib/strcspn.c: Likewise.
3451         * lib/striconv.c: Likewise.
3452         * lib/strncasecmp.c: Likewise.
3453         * lib/strnlen1.c: Likewise.
3454         * lib/strstr.c: Likewise.
3455         * lib/strtok_r.c: Likewise.
3456         * lib/tls.c: Likewise.
3457         * lib/tmpdir.c: Likewise.
3458         * lib/unicodeio.c: Likewise.
3459         * lib/unsetenv.c: Likewise.
3460         * lib/vasnprintf.c: Likewise.
3461         * lib/vasprintf.c: Likewise.
3462         * lib/wait-process.c: Likewise.
3463         * lib/xallocsa.c: Likewise.
3464         * lib/xsetenv.c: Likewise.
3465         * lib/xstriconv.c: Likewise.
3466
3467 2006-09-13  Simon Josefsson  <jas@extundo.com>
3468
3469         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
3470         that internally, suggested by Ralf Wildenhues
3471         <Ralf.Wildenhues@gmx.de>.
3472
3473 2006-09-13  Simon Josefsson  <jas@extundo.com>
3474
3475         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
3476         @LIBOBJS@.
3477         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3478
3479 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
3480
3481         * lib/_fpending.c: Include <config.h> unconditionally, since we no
3482         longer worry about uses that don't define HAVE_CONFIG_H.
3483         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
3484         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
3485         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
3486         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
3487         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
3488         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
3489         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
3490         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
3491         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
3492         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
3493         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
3494         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
3495         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
3496         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
3497         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
3498         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
3499         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
3500         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
3501         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
3502         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
3503         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
3504         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
3505         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
3506         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
3507         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
3508         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
3509         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
3510         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
3511         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
3512         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
3513         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
3514         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
3515         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
3516         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
3517         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
3518         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
3519         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
3520         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
3521         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
3522         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
3523         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
3524         Likewise.
3525
3526 2006-09-13  Eric Blake  <ebb9@byu.net>
3527
3528         * lib/getopt.c: Fix typo in last commit.
3529
3530 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
3531
3532         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
3533         dgettext.
3534
3535 2006-09-12  Jim Meyering  <jim@meyering.net>
3536
3537         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
3538         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
3539         Reported by Nelson H. F. Beebe.
3540
3541 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
3542
3543         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
3544         program_invocation_name and program_invocation_short_name are
3545         initialized.
3546         * lib/argp-namefrob.h: Move declarations of program_invocation_name
3547         and program_invocation_short_name to argp.h, so they are visible
3548         to user programs.
3549         * lib/argp.h: Likewise
3550
3551 2006-09-10  Bruno Haible  <bruno@clisp.org>
3552
3553         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
3554         m4/inttypes_h.m4, m4/uintmax_t.m4.
3555
3556 2006-09-10  Bruno Haible  <bruno@clisp.org>
3557
3558         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
3559         gl_AC_TYPE_UINTMAX_T.
3560
3561 2006-09-10  Bruno Haible  <bruno@clisp.org>
3562
3563         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
3564
3565 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
3566
3567         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
3568         convention.  Text proposed by Bruno Haible.
3569         (struct argp_option): Document the use of N_() wrappers.
3570
3571         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
3572         '\v', and translate the two parts separately, instead of feeding
3573         the whole string to gettext.  This allows to exclude
3574         '\v' from the strings visible to the translator by writing doc
3575         strings as N_("..") "\v" N_("..").
3576
3577 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
3578
3579         * config/srclist.txt: Undo latest change; the bug was fixed.
3580
3581 2006-09-09  Bruno Haible  <bruno@clisp.org>
3582
3583         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
3584         assignments if building a library without libtool.
3585         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
3586         in func_emit_lib_Makefile_am.
3587         (func_import): When building a static library libfoo.a, arrange to
3588         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
3589         (func_create_testdir): Likewise.
3590         * modules/gc (configure.ac, Makefile.am): If building statically,
3591         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
3592         * modules/iconvme (configure.ac, Makefile.am): Likewise.
3593         * modules/striconv (configure.ac, Makefile.am): Likewise.
3594         Based on a suggestion by Ralf Wildenhues.
3595
3596 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3597
3598         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
3599         Check for unistd.h too, since Autoconf doesn't assume POSIX.
3600         Also:
3601
3602         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3603         Add year_2050_test to catch glibc bug 2821
3604         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3605
3606         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
3607         Prefer #ifdef to #if.
3608
3609         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
3610         Return from 'main' instead of calling 'exit'.
3611
3612 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3613
3614         * lib/mktime.c (guess_time_tm): Fix bug where mktime
3615         returned the maximum time_t value rather than (time_t) -1.
3616         Problem originally reported by William Bardwell
3617         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3618
3619         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3620         Moved to here ...
3621         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3622         ... from here.
3623
3624 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3625
3626         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
3627         2821 is fixed.
3628
3629 2006-09-08  Jim Meyering  <jim@meyering.net>
3630
3631         Don't make generated files read-only.  That would bother too many
3632         people.  However, do retain the ability to work when targets are
3633         read-only: remove the destination and temporary files before writing
3634         them (when generated via sed or echo), or by using the -f option for
3635         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
3636         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3637         * modules/byteswap, modules/configmake, modules/fcntl:
3638         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3639         * modules/localcharset, modules/netinet_in, modules/poll:
3640         * modules/stdbool, modules/stdint, modules/sys_select:
3641         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3642
3643 2006-09-08  Jim Meyering  <jim@meyering.net>
3644
3645         Avoid new build failure on FreeBSD 6.0.
3646         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
3647         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
3648         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
3649
3650 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3651
3652         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
3653
3654 2006-09-07  Jim Meyering  <jim@meyering.net>
3655
3656         Fix global typo in last change: use chmod u-w, not chmod u-x.
3657         Spotted by Paul Eggert and Bruce Korb.
3658         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3659         * modules/byteswap, modules/configmake, modules/fcntl:
3660         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3661         * modules/localcharset, modules/netinet_in, modules/poll:
3662         * modules/stdbool, modules/stdint, modules/sys_select:
3663         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3664
3665 2006-09-06  Jim Meyering  <jim@meyering.net>
3666
3667         Make generated files be read-only.
3668         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
3669         Ensure that each generated file is now read-only.
3670         * modules/argz: Likewise.
3671         * modules/arpa_inet: Likewise.
3672         * modules/byteswap: Likewise.
3673         * modules/configmake: Likewise.
3674         * modules/fcntl: Likewise.
3675         * modules/fnmatch: Likewise.
3676         * modules/getopt: Likewise.
3677         * modules/glob: Likewise.
3678         * modules/inttypes: Likewise.
3679         * modules/netinet_in: Likewise.
3680         * modules/poll: Likewise.
3681         * modules/stdbool: Likewise.
3682         * modules/stdint: Likewise.
3683         * modules/sys_select: Likewise.
3684         * modules/sys_socket: Likewise.
3685         * modules/sys_stat: Likewise.
3686         * modules/sysexits: Likewise.
3687         * modules/localcharset: Same as above, but continue using temporary
3688         file named "t-$@" (why different?) rather than the "$@-t" used
3689         everywhere else.
3690
3691         * modules/sysexits (Makefile.am): Replace literal occurrences
3692         of "sysexit.h" more readable, and more consistent, "$@".
3693
3694 2006-09-06  Bruno Haible  <bruno@clisp.org>
3695
3696         * modules/striconv: New file.
3697         * modules/xstriconv: New file.
3698         * MODULES.html.sh (Internationalization functions): Add striconv,
3699         xstriconv.
3700
3701 2006-09-06  Bruno Haible  <bruno@clisp.org>
3702
3703         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
3704         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
3705         not using libtool correctly.
3706
3707 2006-09-06  Bruno Haible  <bruno@clisp.org>
3708
3709         * lib/striconv.h: New file.
3710         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
3711         iconvstring.c.
3712         * lib/xstriconv.h: New file.
3713         * lib/xstriconv.c: New file.
3714
3715 2006-09-06  Bruno Haible  <bruno@clisp.org>
3716
3717         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
3718         lib_..._LDFLAGS.
3719
3720 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3721
3722         * lib/argz_.h: Sync from Libtool.
3723
3724         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
3725                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3726
3727         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
3728
3729 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3730
3731         * modules/trim: New file.
3732
3733 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3734
3735         * lib/trim.h: New file.
3736         * lib/trim.c: New file.
3737
3738 2006-09-05  Bruno Haible  <bruno@clisp.org>
3739
3740         * MODULES.html.sh (String handling): Add trim.
3741
3742 2006-09-04  Karl Berry  <karl@gnu.org>
3743
3744         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
3745         until next release.
3746
3747 2006-09-03  Bruno Haible  <bruno@clisp.org>
3748
3749         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
3750         correctly.
3751
3752 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3753
3754         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
3755         not gl_GETLOADAVG.  Omit unneeded semicolons.
3756         Problems reported by Ralf Wildenhues in
3757         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3758         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
3759         at the end, which is the usual gnulib style.
3760
3761         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
3762         of doing all the work ourselves.
3763         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
3764         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
3765
3766 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3767
3768         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
3769         Problem reported by Ralf Wildenhues in
3770         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3771
3772         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
3773         HAVE_STRUCT_STATFS_F_FSTYPENAME.
3774
3775 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3776
3777         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
3778         yesterday's patch by changing test -n to test -z.
3779
3780 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3781
3782         * modules/getloadavg (Files): Add m4/getloadavg.m4.
3783         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
3784         the former is now obsolescent.
3785
3786         * modules/chdir-long (Depends-on): Add fcntl.
3787
3788 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3789
3790         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
3791         obsolescent, and programs should use gnulib instead.
3792         * m4/getloadavg.m4: New file, with contents taken from Autoconf
3793         but with prefixes changed.
3794
3795 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3796
3797         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
3798         or stdbool.h, because they might not exist while configuring.
3799
3800         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
3801         Don't include unistd.h or limits.h; not needed, since chdir-long.h
3802         does that for us.
3803         (O_DIRECTORY): Remove.
3804
3805 2006-08-31  Eric Blake  <ebb9@byu.net>
3806
3807         * gnulib-tool: Don't let emacs change spaces to TAB.
3808
3809 2006-08-31  Bruno Haible  <bruno@clisp.org>
3810
3811         * gnulib-tool: When calling func_import more than once, do it in a
3812         subshell.
3813         Reported by Eric Blake <ebb9@byu.net>.
3814
3815 2006-08-31  Bruno Haible  <bruno@clisp.org>
3816
3817         * gnulib-tool (nl): Remove variable.
3818         (sed_transform_lib_file): Use more robust test for config-h module.
3819         (func_import): Fix typo in 2006-08-25 patch.
3820
3821 2006-08-31  Bruno Haible  <bruno@clisp.org>
3822
3823         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
3824         specified, augment Makefile.am variables instead of assigning them.
3825
3826 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3827
3828         Work around a bug in both the Linux and SunOS 64-bit kernels:
3829         nanosleep mishandles sleeps for longer than 2**31 seconds.
3830         Problem reported by Frank v Waveren in
3831         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3832         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
3833         Check for nanosleep bug.
3834         (LIB_NANOSLEEP): Append clock_gettime library if needed.
3835
3836 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3837
3838         Work around a bug in both the Linux and SunOS 64-bit kernels:
3839         nanosleep mishandles sleeps for longer than 2**31 seconds.
3840         Problem reported by Frank v Waveren in
3841         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3842         * lib/nanosleep.c (BILLION): New constant.
3843         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
3844         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
3845         implementation.
3846
3847 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3848
3849         * modules/nanosleep (Depends-on): Add gettime.
3850
3851 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3852         and Simon Josefsson  <jas@extundo.com>
3853         and Oskar Liljeblad  <oskar@osk.mine.nu>
3854
3855         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
3856         * gnulib-tool (func_import): New license type 'unmodifiable license
3857         text'.
3858         * modules/fdl: Use it.  Longer description.
3859         * module/gpl, module/lgpl: New files.
3860
3861 2006-08-30  Jim Meyering  <jim@meyering.net>
3862
3863         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
3864         shadowing the parameter.
3865
3866 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3867
3868         Sync from Libtool:
3869
3870         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3871
3872         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
3873         sharing with gnulib.  Report by Eric Blake.
3874
3875 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3876
3877         * modules/isapipe: New file.
3878         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
3879
3880 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3881
3882         * modules/configmake (Makefile.am): Add a comment, and omit
3883         the CONFIGMAKE_ prefix from generated macro names.  Suggested
3884         by Bruno Haible.
3885
3886 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3887
3888         * m4/isapipe.m4: New file.
3889
3890 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3891
3892         * lib/isapipe.c, lib/isapipe.h: New files.
3893
3894 2006-08-29  Jim Meyering  <jim@meyering.net>
3895
3896         * modules/configmake (Makefile.am): Make configmake.h depend on
3897         Makefile.  Otherwise, a stale configmake.h could hang around.
3898
3899 2006-08-29  Eric Blake  <ebb9@byu.net>
3900
3901         * lib/error.c (error_at_line, print_errno_message): Match libc, after
3902         resolution of upstream bug 3044.
3903
3904 2006-08-29  Bruno Haible  <bruno@clisp.org>
3905
3906         * modules/localcharset (Depends-on): Add configmake.
3907         (Makefile.am): Remove setting of LIBDIR through DEFS.
3908
3909 2006-08-29  Bruno Haible  <bruno@clisp.org>
3910
3911         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
3912         defined.
3913
3914 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3915
3916         * modules/fcntl: New file.
3917         * modules/chdir-safer (Depends-on): Add fcntl.
3918         * modules/fts: Likewise.
3919         * modules/mkdir-p: Likewise.
3920
3921         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
3922         This undoes the most recent change, since we're now addressing the
3923         problem in a different way.
3924
3925         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
3926         into output, since the output might be called Makefile.am even
3927         if $makefile_name is something different.
3928         (func_import): Use $makefile_am rather than
3929         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
3930         empty.
3931
3932         * modules/inttypes (Files): Add m4/inttypes-h.m4.
3933
3934 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3935
3936         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
3937         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
3938         recent change to stdint.m4, since we're now addressing the problem in a
3939         different way.
3940
3941 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3942
3943         * m4/fcntl_h.m4: New file.
3944
3945 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3946
3947         * lib/fcntl_.h: New file.
3948         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
3949         the fcntl module.
3950         * lib/dirchownmod.c: Likewise.
3951         * lib/fts.c: Likewise.
3952
3953         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
3954         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
3955         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
3956         just before including <inttypes.h>, to avoid circular inclusion.
3957
3958 2006-08-28  Jim Meyering  <jim@meyering.net>
3959
3960         * doc/visibility.texi: Actually read and correct the grammar of the
3961         sentence affected by yesterday's change.
3962
3963 2006-08-28  Eric Blake  <ebb9@byu.net>
3964
3965         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
3966         needs wrapper.
3967
3968 2006-08-28  Eric Blake  <ebb9@byu.net>
3969
3970         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
3971
3972 2006-08-28  Eric Blake  <ebb9@byu.net>
3973
3974         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
3975
3976 2006-08-28  Bruno Haible  <bruno@clisp.org>
3977
3978         * modules/c-strstr: New file, from GNU gettext.
3979         * MODULES.html.sh (String handling): Add c-strstr.
3980
3981 2006-08-28  Bruno Haible  <bruno@clisp.org>
3982
3983         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
3984         macros.
3985         Reported by Eric Blake.
3986
3987 2006-08-28  Bruno Haible  <bruno@clisp.org>
3988
3989         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
3990         (VASNPRINTF): Return a string of length > INT_MAX without failing.
3991         * lib/vasprintf.c: Include errno.h, limits.h.
3992         (EOVERFLOW): New fallback definition.
3993         (vasprintf): Test here whether the string length is > INT_MAX.
3994         * lib/vsnprintf.c: Include errno.h, limits.h.
3995         (EOVERFLOW): New fallback definition.
3996         (vsnprintf): Fix bug when generated string was too long for the buffer.
3997         Test here whether the string length is > INT_MAX.
3998
3999 2006-08-28  Bruno Haible  <bruno@clisp.org>
4000
4001         * lib/inttypes_.h (SCNX*): Remove definitions.
4002         Reported by Eric Blake.
4003
4004 2006-08-28  Bruno Haible  <bruno@clisp.org>
4005
4006         * lib/c-strstr.h: New file, from GNU gettext.
4007         * lib/c-strstr.c: New file, from GNU gettext.
4008
4009 2006-08-28  Bruno Haible  <bruno@clisp.org>
4010
4011         * gnulib-tool: Reorder some statements.
4012
4013 2006-08-28  Bruno Haible  <bruno@clisp.org>
4014
4015         * gnulib-tool: New option --makefile-name.
4016         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
4017         $makefile_name.
4018         (func_import): Write $makefile_name to the cache file, and read it from
4019         there unless explicitly specified. Use $makefile_name as file name
4020         instead of Makefile.am. Adjust the recommendations accordingly.
4021
4022 2006-08-28  Bruno Haible  <bruno@clisp.org>
4023
4024         * gnulib-tool (func_verify_module): Check against misapplying patch.
4025
4026 2006-08-28  Bruno Haible  <bruno@clisp.org>
4027
4028         * gnulib-tool (func_relativize, func_relconcat): New functions.
4029         Give an error if --local-dir is given with --update.
4030         Remove trailing slashes from $local_gnulib_dir.
4031         (func_import): Store the relativized $local_gnulib_dir in
4032         gnulib-cache.m4, and read it from there if not specified explicitly.
4033
4034 2006-08-28  Bruno Haible  <bruno@clisp.org>
4035
4036         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
4037         is the current directory. Respect also $local_gnulib_dir.
4038
4039 2006-08-28  Bruno Haible  <bruno@clisp.org>
4040             Simon Josefsson  <jas@extundo.com>
4041
4042         BeOS portability.
4043         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
4044
4045 2006-08-27  Jim Meyering  <jim@meyering.net>
4046
4047         * doc/visibility.texi: Remove duplicate word: "pointer".
4048
4049 2006-08-26  Bruno Haible  <bruno@clisp.org>
4050
4051         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
4052         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
4053         (Makefile.am): Create inttypes.h from inttypes_.h.
4054         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
4055
4056         * modules/imaxabs: New file.
4057
4058         * modules/imaxdiv: New file.
4059
4060 2006-08-26  Bruno Haible  <bruno@clisp.org>
4061
4062         * m4/inttypes.m4: New file.
4063         * m4/_inttypes_h.m4: Remove file.
4064         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
4065         PRI_MACROS_BROKEN.
4066         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
4067
4068         * m4/imaxabs.m4: New file.
4069
4070         * m4/imaxdiv.m4: New file.
4071
4072 2006-08-26  Bruno Haible  <bruno@clisp.org>
4073
4074         * lib/inttypes_.h: New file.
4075         * lib/inttypes.h: Remove file.
4076         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
4077
4078         * lib/imaxabs.c: New file.
4079
4080         * lib/imaxdiv.c: New file.
4081
4082 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4083
4084         New config-h module, so that "make" output needn't be cluttered
4085         by -DHAVE_CONFIG_H.
4086         * MODULES.html.sh (Support for building libraries and executables):
4087         Add config-h.
4088         * modules/config-h: New file.
4089         * gnulib-tool (nl, sed_transform_lib_file): New vars.
4090         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
4091         the config-h module is used.
4092
4093         New configmake module, so that "make" output needn't be cluttered
4094         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
4095         * MODULES.html.sh (Support for building libraries and executables):
4096         Add configmake.
4097         * modules/configmake: New file.
4098
4099 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4100
4101         * m4/config-h.m4: New file.
4102
4103 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4104
4105         * config/srclist.txt: Add elisp-comp.
4106
4107 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4108
4109         * MODULES.html.sh (Support for building libraries and executables):
4110         Add elisp-comp.
4111         * build-aux/elisp-comp: New file.
4112         * modules/elisp-comp: New file.
4113
4114 2006-08-24  Bruno Haible  <bruno@clisp.org>
4115
4116         * gnulib-tool (func_create_testdir): Use non-default values of
4117         sourcebase and m4base.
4118
4119 2006-08-24  Bruno Haible  <bruno@clisp.org>
4120
4121         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
4122         HTML structure.
4123
4124 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
4125
4126         * modules/openat (Depends-on): Add lchown.
4127
4128 2006-08-23  Bruno Haible  <bruno@clisp.org>
4129
4130         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
4131         of gl_LOCK_EARLY instead of gl_LOCK.
4132
4133 2006-08-23  Bruno Haible  <bruno@clisp.org>
4134
4135         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
4136         on OSF/1 to no.
4137         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
4138
4139 2006-08-23  Bruno Haible  <bruno@clisp.org>
4140
4141         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
4142         as unusable.
4143
4144         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
4145         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
4146         (gl_LOCK): New macro.
4147
4148 2006-08-22  Simon Josefsson  <jas@extundo.com>
4149
4150         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
4151         to md5 module.
4152
4153 2006-08-22  Simon Josefsson  <jas@extundo.com>
4154
4155         * MODULES.html.sh: Add "Support for maintaining and release
4156         projects".
4157
4158         * build-aux/gnupload: New file, from coreutils.
4159
4160 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4161
4162         Avoid the need for AC_LIBSOURCES in m4 macros.
4163         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
4164         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
4165         * modules/check-version (EXTRA_DIST): Add check-version.h.
4166         * modules/crc (EXTRA_DIST): Add crc.h.
4167         * modules/des (EXTRA_DIST): Add des.h.
4168         * modules/gc (EXTRA_DIST): Add gc.h.
4169         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
4170         * modules/getline (EXTRA_DIST): Add getline.h.
4171         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
4172         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
4173         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
4174         * modules/md2 (EXTRA_DIST): Add md2.h.
4175         * modules/md4 (EXTRA_DIST): Add md4.h.
4176         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
4177         * modules/read-file (EXTRA_DIST): Add read-file.h.
4178         * modules/readline (EXTRA_DIST): Add readline.h.
4179         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
4180         rijndael-api-fst.h.
4181
4182 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4183
4184         * m4/rijndael.m4 (gl_ARCFOUR):
4185         * m4/arctwo.m4 (gl_ARCTWO):
4186         * m4/check-version.m4 (gl_CHECK_VERSION):
4187         * m4/crc.m4 (gl_CRC):
4188         * m4/des.m4 (gl_DES):
4189         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
4190         * m4/gc.m4 (gl_GC):
4191         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
4192         * m4/getline.m4 (gl_FUNC_GETLINE):
4193         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
4194         * m4/hmac-md5.m4 (gl_HMAC_MD5):
4195         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
4196         * m4/md2.m4 (gl_MD2):
4197         * m4/md4.m4 (gl_MD4):
4198         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
4199         * m4/read-file.m4 (gl_FUNC_READ_FILE):
4200         * m4/readline.m4 (gl_FUNC_READLINE):
4201         * m4/rijndael.m4 (gl_RIJNDAEL):
4202         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4203         to get the necessary .h files and whatnot.
4204
4205 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4206
4207         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
4208         gnulib rather than the other way around.
4209         * config/srclistvars.sh (COREUTILS): Remove.
4210
4211 2006-08-22  Jim Meyering  <jim@meyering.net>
4212
4213         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
4214
4215         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
4216
4217 2006-08-22  Eric Blake  <ebb9@byu.net>
4218
4219         * modules/regexprops-generic: New file.
4220         * MODULES.html.sh (Support for building documentation): List it.
4221
4222 2006-08-22  Eric Blake  <ebb9@byu.net>
4223
4224         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
4225         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
4226         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
4227         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
4228
4229 2006-08-22  Bruno Haible  <bruno@clisp.org>
4230
4231         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
4232         and lib_LTLIBRARIES like the other lib_* variables.
4233
4234 2006-08-22  Bruno Haible  <bruno@clisp.org>
4235
4236         * build-aux/x-to-1.in: New file, from GNU gettext.
4237
4238 2006-08-22  Bruno Haible  <bruno@clisp.org>
4239
4240         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
4241         <utmpx.h> exists.
4242
4243 2006-08-22  Bruno Haible  <bruno@clisp.org>
4244
4245         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
4246         <utmpx.h> exists.
4247
4248 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4249
4250         BeOS portability.
4251         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
4252         exist.
4253         Problem reported by Bruno Haible.
4254
4255 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4256
4257         Avoid the need for AC_LIBSOURCES in m4 macros.
4258         * modules/acl (EXTRA_DIST): Add acl.h.
4259         * modules/argmatch (Files): Add m4/argmatch.m4.
4260         (configure.ac): Add gl_ARGMATCH.
4261         (EXTRA_DIST): Renamed from lib_SOURCES, for
4262         consistency with the other modules.  Remove argmatch.c.
4263         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
4264         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
4265         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
4266         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
4267         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
4268         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
4269         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
4270         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
4271         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
4272         * modules/closeout (EXTRA_DIST): Add closeout.h.
4273         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
4274         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
4275         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
4276         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
4277         dirname.h; remove basename.c and stripslash.c.
4278         * modules/exclude (EXTRA_DIST): Add exclude.h.
4279         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
4280         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
4281         * modules/file-type (EXTRA_DIST): Add file-type.h.
4282         * modules/filemode (EXTRA_DIST): Add filemode.h.
4283         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
4284         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4285         * modules/fpending (EXTRA_DIST): Add __fpending.h.
4286         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
4287         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
4288         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
4289         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
4290         * modules/getdate (EXTRA_DIST): Add getdate.c.
4291         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
4292         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
4293         * modules/getpass (EXTRA_DIST): Add getpass.h.
4294         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
4295         * modules/group-member (EXTRA_DIST): Add group-member.h.
4296         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
4297         * modules/hash (EXTRA_DIST): Add hash.h.
4298         * modules/human (EXTRA_DIST): Add human.h.
4299         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
4300         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
4301         * modules/lchown (EXTRA_DIST): Add lchown.h.
4302         * modules/long-options (EXTRA_DIST): Add long-options.h.
4303         * modules/lstat (EXTRA_DIST): Add lstat.h.
4304         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
4305         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
4306         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
4307         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
4308         * modules/memxor (EXTRA_DIST): Add memxor.h.
4309         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
4310         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
4311         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
4312         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
4313         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
4314         * modules/physmem (EXTRA_DIST): Add physmem.h.
4315         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
4316         * modules/posixver (EXTRA_DIST): Add posixver.h.
4317         * modules/quote (EXTRA_DIST): Add quote.h.
4318         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
4319         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
4320         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
4321         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
4322         regex_internal.h regexec.c.
4323         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
4324         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
4325         * modules/same (EXTRA_DIST): Add same.h.
4326         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
4327         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
4328         * modules/savedir (EXTRA_DIST): Add savedir.h.
4329         * modules/sha1 (EXTRA_DIST): Add sha1.h.
4330         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
4331         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
4332         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
4333         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
4334         * modules/strdup (EXTRA_DIST): Add strdup.h.
4335         * modules/strftime (EXTRA_DIST): Add strftime.h.
4336         * modules/strndup (EXTRA_DIST): Add strndup.h.
4337         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
4338         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
4339         * modules/time_r (EXTRA_DIST): Add time_r.h.
4340         * modules/timespec (EXTRA_DIST): Add timespec.h.
4341         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4342         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
4343         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
4344         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
4345         * modules/userspec (EXTRA_DIST): Add userspec.h.
4346         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
4347         * modules/utimens (EXTRA_DIST): Add utimens.h.
4348         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
4349         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
4350         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
4351         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
4352         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
4353         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
4354         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
4355         * modules/yesno (EXTRA_DIST): Add yesno.h.
4356
4357 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4358
4359         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
4360
4361         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
4362         * m4/dev-ino.m4, same-inode.m4: Remove.
4363
4364         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
4365         * m4/acl.m4 (AC_FUNC_ACL):
4366         * m4/backupfile.m4 (gl_BACKUPFILE):
4367         * m4/c-strtod.m4 (gl_C99_STRTOLD):
4368         * m4/canon-host.m4 (gl_CANON_HOST):
4369         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4370         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
4371         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
4372         * m4/cloexec.m4 (gl_CLOEXEC):
4373         * m4/close-stream.m4 (gl_CLOSE_STREAM):
4374         * m4/closeout.m4 (gl_CLOSEOUT):
4375         * m4/dirfd.m4 (gl_FUNC_DIRFD):
4376         * m4/dirname.m4 (gl_DIRNAME):
4377         * m4/exclude.m4 (gl_EXCLUDE):
4378         * m4/exitfail.m4 (gl_EXITFAIL):
4379         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
4380         * m4/file-type.m4 (gl_FILE_TYPE):
4381         * m4/filemode.m4 (gl_FILEMODE):
4382         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
4383         * m4/fpending.m4 (gl_FUNC_FPENDING):
4384         * m4/fprintftime.m4 (gl_FPRINTFTIME):
4385         * m4/fts.m4 (gl_FUNC_FTS):
4386         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
4387         * m4/getdate.m4 (gl_GETDATE):
4388         * m4/gethrxtime.m4 (gl_GETHRXTIME):
4389         * m4/getpagesize.m4 (gl_GETPAGESIZE):
4390         * m4/getpass.m4 (gl_FUNC_GETPASS):
4391         * m4/gettime.m4 (gl_GETTIME):
4392         * m4/getugroups.m4 (gl_GETUGROUPS):
4393         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
4394         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
4395         * m4/hard-locale.m4 (gl_HARD_LOCALE):
4396         * m4/hash.m4 (gl_HASH):
4397         * m4/idcache.m4 (gl_IDCACHE):
4398         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
4399         * m4/lchown.m4 (gl_FUNC_LCHOWN):
4400         * m4/long-options.m4 (gl_LONG_OPTIONS):
4401         * m4/lstat.m4 (gl_FUNC_LSTAT):
4402         * m4/md5.m4 (gl_MD5):
4403         * m4/memcasecmp.m4 (gl_MEMCASECMP):
4404         * m4/memcoll.m4 (gl_MEMCOLL):
4405         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
4406         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
4407         * m4/memxor.m4 (gl_MEMXOR):
4408         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
4409         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
4410         * m4/modechange.m4 (gl_MODECHANGE):
4411         * m4/mountlist.m4 (gl_MOUNTLIST):
4412         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4413         * m4/openat.m4 (gl_FUNC_OPENAT):
4414         * m4/pathmax.m4 (gl_PATHMAX):
4415         * m4/physmem.m4 (gl_PHYSMEM):
4416         * m4/posixtm.m4 (gl_POSIXTM):
4417         * m4/posixver.m4 (gl_POSIXVER):
4418         * m4/quote.m4 (gl_QUOTE):
4419         * m4/quotearg.m4 (gl_QUOTEARG):
4420         * m4/readtokens.m4 (gl_READTOKENS):
4421         * m4/readutmp.m4 (gl_READUTMP):
4422         * m4/regex.m4 (gl_REGEX):
4423         * m4/safe-read.m4 (gl_SAFE_READ):
4424         * m4/safe-write.m4 (gl_SAFE_WRITE):
4425         * m4/same.m4 (gl_SAME):
4426         * m4/save-cwd.m4 (gl_SAVE_CWD):
4427         * m4/savedir.m4 (gl_SAVEDIR):
4428         * m4/settime.m4 (gl_SETTIME):
4429         * m4/sha1.m4 (gl_SHA1):
4430         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
4431         * m4/stat-macros.m4 (gl_STAT_MACROS):
4432         * m4/stat-time.m4 (gl_STAT_TIME):
4433         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
4434         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
4435         * m4/strdup.m4 (gl_FUNC_STRDUP):
4436         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
4437         * m4/strndup.m4 (gl_FUNC_STRNDUP):
4438         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
4439         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
4440         * m4/time_r.m4 (gl_TIME_R):
4441         * m4/timespec.m4 (gl_TIMESPEC):
4442         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
4443         * m4/unlinkdir.m4 (gl_UNLINKDIR):
4444         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
4445         * m4/userspec.m4 (gl_USERSPEC):
4446         * m4/utimecmp.m4 (gl_UTIMECMP):
4447         * m4/utimens.m4 (gl_UTIMENS):
4448         * m4/xalloc.m4 (gl_XALLOC):
4449         * m4/xgetcwd.m4 (gl_XGETCWD):
4450         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
4451         * m4/xreadlink.m4 (gl_XREADLINK):
4452         * m4/xstrtod.m4 (gl_XSTRTOD):
4453         * m4/yesno.m4 (gl_YESNO):
4454         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4455         to get the necessary .h files and whatnot.
4456
4457 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
4458             Bruno Haible  <bruno@clisp.org>
4459
4460         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
4461         /bin/sh understanding of '!' conditional negation.
4462
4463 2006-08-21  Jim Meyering  <jim@meyering.net>
4464
4465         * modules/openat (Depends-on): Really alphabetize.
4466
4467         * modules/acl (Depends-on): Add error and quote.
4468
4469         * check-module (find_included_lib_files): Add at-func.c to the
4470         ok-to-include-more-than-once white list.
4471
4472         * modules/openat (Depends-on): Add lstat.  Alphabetize.
4473
4474 2006-08-21  Bruno Haible  <bruno@clisp.org>
4475
4476         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4477         Emit a pkgdata_DATA variable only if some snippets add contents to it.
4478         Reported by Martin Lambers <marlam@marlam.de>.
4479
4480 2006-08-21  Bruno Haible  <bruno@clisp.org>
4481
4482         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
4483         specify an installation location, don't emit a noinst_LIBRARIES or
4484         noinst_LTLIBRARIES assignment.
4485
4486 2006-08-21  Bruno Haible  <bruno@clisp.org>
4487
4488         BeOS portability.
4489         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
4490         BeOS has mbrtowc() but no <wctype.h>.
4491
4492 2006-08-21  Bruno Haible  <bruno@clisp.org>
4493
4494         BeOS portability.
4495         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
4496         exist.
4497
4498 2006-08-21  Bruno Haible  <bruno@clisp.org>
4499
4500         BeOS portability.
4501         * lib/mbchar.h: Include <wctype.h> only if it exists.
4502
4503 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4504
4505         Remove files that are no longer needed by their respective modules.
4506         * m4/obstack.m4: Remove.
4507         * m4/strerror_r.m4: Remove.
4508         * m4/uint32_t.m4: Remove.
4509         * m4/uintptr_t.m4: Remove.
4510         * m4/ullong_max.m4: Remove.
4511         * m4/xstrtoimax.m4: Remove.
4512         * m4/xstrtoumax.m4: Remove.
4513
4514         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
4515         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
4516         dependencies now capture this.
4517
4518         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
4519         Do not use AC_LIBSOURCES, since gnulib modules now do this.
4520         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
4521         * m4/human.m4 (gl_HUMAN): Likewise.
4522         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
4523         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
4524
4525         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
4526
4527         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
4528         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
4529         stdint.
4530         * m4/human.m4 (gl_HUMAN): Likewise.
4531         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
4532         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
4533         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4534         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4535         * m4/xstrtol (gl_XSTRTOL): Likewise.
4536
4537         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
4538         AC_TYPE_LONG_LONG_INT.
4539         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4540         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
4541         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
4542         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4543
4544         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
4545         on stdbool.
4546
4547         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
4548         (gl_PREREQ_XSTRTOUL): Remove.
4549
4550         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
4551
4552         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
4553         mode.
4554
4555 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4556
4557         Add and change modules to make it easier for coreutils to use
4558         gnulib-tool.
4559         * modules/backupfile (Files): Remove m4/d-ino.m4.
4560         (Depends-on): Add d-ino.
4561         * modules/cycle-check (Depends-on): Add stdint.
4562         (lib_SOURCES): Add cycle-check.h.
4563         * modules/d-ino: New module.
4564         * modules/d-type: New module.
4565         * modules/error (Files): Remove m4/strerror_r.m4.
4566         * modules/filemode (Files): Add m4/st_dm_mode.m4.
4567         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4568         m4/inttypes_h.m4, m4/uintmax_t.m4.
4569         (Depends-on): Add stdint.
4570         (lib_SOURCES): Add fsusage.h.
4571         * modules/getcwd (Files): Remove d-ino.m4.
4572         (Depends-on): Add d-ino.
4573         * modules/getndelim2 (Depends-on): Add stdint.
4574         * modules/glob (Files): Remove m4/d-type.m4.
4575         (Depends-on): Add d-type.
4576         * modules/host-os: New module.
4577         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
4578         m4/inttypes_h.m4, m4/uintmax_t.m4.
4579         * Depends-on: Add stdint.
4580         (lib_SOURCES): Add human.h.
4581         * modules/inttostr (Files): Remove m4/intmax_t.m4,
4582         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
4583         m4/uintmax_t.m4, m4/ulonglong.m4.
4584         (Depends-on): Add stdint.
4585         (EXTRA_DIST): Add inttostr.h.
4586         * modules/lchmod: New module.
4587         * modules/link-follow: New module.
4588         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
4589         (Depends-on): Add lchmod.
4590         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
4591         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
4592         (Depends-on): Add stdint.
4593         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
4594         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
4595         (Depends-on): Add stdint.
4596         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
4597         * modules/perl: New module.
4598         * modules/regex (Depends-on): Add stdint.
4599         * modules/rmdir-errno: New module.
4600         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4601         m4/intmax_t.m4.
4602         (Depends-on): Add stdint.
4603         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4604         m4/uintmax_t.m4.
4605         (Depends-on): Add stdint.
4606         * modules/unlink-busy: New module.
4607         * modules/utimecmp (Depends-on): Add stdint.
4608         * modules/uptime: New module.
4609         * modules/winsz-ioctl: New module.
4610         * modules/winsz-termios: New module.
4611         * modules/xnanosleep (Depends-on): Add nanosleep.
4612         * modules/ullong_max: Remove.
4613         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
4614         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
4615         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
4616         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
4617         (Depends-on): Add inttypes.
4618         (lib_SOURCES): Add xstrtol.h.
4619         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
4620         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
4621         * MODULES.html.sh: Move 'assert' into the assert section.
4622         Move 'dummy' into the linking section.
4623         Remove ullong_max.
4624         Add section for compatibility checks for POSIX:2001 functions,
4625         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
4626         winsz-ioctl, and winsz-termios into it.
4627         Add lchmod.
4628         Add top-level Misc section and put host-os, perl, and uptime
4629         into it.
4630
4631 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4632
4633         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
4634         now assume the stdint module.  Do not include inttypes.h.
4635         * lib/fsusage.h: Likewise.
4636         * lib/getndelim2.c: Likewise.
4637         * lib/human.h: Likewise.
4638         * lib/inttostr.h: Likewise.
4639         * lib/obstack.c: Likewise.
4640         * lib/regex_internal.h: Likewise.
4641         * lib/tempname.c: Likewise.
4642         * lib/utimecmp.c: Likewise.
4643         * lib/xstrtol.h: Likewise.
4644
4645         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
4646
4647         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
4648         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
4649         * lib/xtime.h: Likewise.
4650
4651 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4652
4653         * modules/openat (Files): Add lib/fchmodat.c.
4654         Fixes problem reported by Jay Youngman.
4655
4656 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4657
4658         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
4659         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
4660
4661 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
4662             Bruno Haible  <bruno@clisp.org>
4663
4664         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
4665         and is a script that invokes bison. Tighten the code. Add comments.
4666
4667 2006-08-18  Jim Meyering  <jim@meyering.net>
4668
4669         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
4670         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
4671         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
4672         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
4673
4674 2006-08-18  Bruno Haible  <bruno@clisp.org>
4675
4676         * modules/bison-i18n: New file.
4677         * MODULES.html.sh (Internationalization functions): Add it.
4678
4679 2006-08-18  Bruno Haible  <bruno@clisp.org>
4680
4681         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
4682         sys/statvfs.h. When getmntinfo was found, check its declaration and
4683         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
4684
4685 2006-08-18  Bruno Haible  <bruno@clisp.org>
4686
4687         * m4/bison-i18n.m4: New file, from bison.
4688
4689 2006-08-18  Bruno Haible  <bruno@clisp.org>
4690
4691         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
4692         (ME_DUMMY): Treat "kernfs" as a dummy.
4693         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
4694
4695 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4696
4697         Update from coreutils.
4698
4699         2006-08-15  Jim Meyering  <jim@meyering.net>
4700
4701         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
4702
4703         2006-01-17  Jim Meyering  <jim@meyering.net>
4704
4705         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
4706
4707         2006-01-11  Jim Meyering  <jim@meyering.net>
4708
4709         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
4710         Check for the lchmod function.
4711
4712 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4713
4714         Update from coreutils.
4715
4716         * lib/__fpending.h: Add copyright notice.
4717         * lib/fprintftime.h: Likewise.
4718         * lib/savedir.c: Use (C) in copyright notice.
4719         * lib/savedir.h: Likewise.
4720
4721         2006-08-15  Jim Meyering  <jim@meyering.net>
4722
4723         * lib/at-func.c: New file, with the logic of all emulated at-functions.
4724         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
4725         in support of the EXPECTED_ERRNO macro.
4726         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
4727         definitions.  Instead, define the appropriate symbols and include
4728         "at-func.c".
4729         * lib/mkdirat.c (mkdirat): Likewise.
4730         * lib/fchmodat.c (fchmodat): Likewise.
4731         (ENOSYS): Remove definition.
4732         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
4733         it.  Don't include "unistd--.h" -- it wasn't ever used.
4734
4735         2006-01-17  Jim Meyering  <jim@meyering.net>
4736
4737         Rewrite fts.c not to change the current working directory,
4738         by using openat, fstatat, fdopendir, etc..
4739
4740         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
4741         (HAVE_OPENAT_SUPPORT): Define.
4742         [_LIBC] (fchdir): Don't undef or define; no longer used.
4743         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
4744         Now, this `function' always succeeds, and consumes its file descriptor
4745         parameter -- so callers must not close such FDs.  Update callers.
4746         (diropen_fd, opendirat, cwd_advance_fd): New functions.
4747         (diropen): Add parameter, SP.  Adjust all callers.
4748         Implement using diropen_fd, rather than open.
4749         (fts_open): Initialize new member, fts_cwd_fd.
4750         Remove fts_rft-setting code.
4751         (fts_close): Close fts_cwd_fd, if necessary.
4752         (__opendir2): Define in terms of opendir or opendirat,
4753         depending on whether the FST_NOCHDIR flag is set.
4754         (fts_build): Since fts_safe_changedir consumes its FD, and since
4755         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
4756         and close the dup'd file descriptor upon failure.
4757         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
4758         (fts_safe_changedir): Tweak semantics to reflect that this function
4759         now calls cwd_advance_fd and hence consumes its FD argument.
4760         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
4761         [struct FTS] (fts_rft): Remove now-unused member.
4762         [struct FTS] (fts_cycle.state): Improve comment.
4763
4764         * lib/openat.c (openat_needs_fchdir): New function.
4765         * lib/openat.h (openat_needs_fchdir): Declare it.
4766
4767 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
4768
4769         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
4770         Problem and fix reported by Pádraig Brady in
4771         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
4772
4773 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4774
4775         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
4776
4777 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4778
4779         * lib/memcoll.c (memcoll): Optimize for the common case where the
4780         arguments are bytewise equal.
4781
4782 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4783
4784         * doc/regexprops-generic.texi: Add a copyright notice.
4785
4786 2006-08-15  Bruno Haible  <bruno@clisp.org>
4787
4788         * modules/tmpdir (License): Change to LGPL.
4789
4790 2006-08-15  Bruno Haible  <bruno@clisp.org>
4791
4792         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
4793         module.
4794
4795 2006-08-14  Simon Josefsson  <jas@extundo.com>
4796
4797         * config/srclist.txt: Add gnupload.
4798
4799 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4800
4801         Change copyright notice from LGPL 2 to GPL 2, since that's the
4802         standard form used in the gnulib repository.
4803         * tests/test-lock.c: Likewise.
4804         * tests/test-stdint.c: Likewise.
4805         * tests/test-tls.c: Likewise.
4806
4807         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
4808         prelude-manager.  User shorter URLs for GNU projects, without '?'.
4809         Add copyright notice.
4810
4811         * check-module: Add copyright notice.  Output a copyright
4812         notice if "--version" is specified.
4813         * modules/COPYING: New file.
4814         * tests/test-getaddrinfo.c: Add copyright notice.
4815         * tests/test-verify.c: Likewise.
4816
4817 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4818
4819         Change copyright notice from LGPL 2 to GPL 2, since that's the
4820         standard form used in the gnulib repository.
4821         * lib/lock.c: LGPL -> GPL.
4822         * lib/lock.h: Likewise.
4823         * lib/strnlen1.c: Likewise.
4824         * lib/strnlen1.h: Likewise.
4825         * lib/tls.c: Likewise.
4826         * lib/tls.h: Likewise.
4827         * lib/tmpdir.c: Likewise.
4828
4829         * lib/TODO: Remove; this belongs only in coreutils.
4830
4831 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4832
4833         Add copyright notices to long-enough files that lack them, since
4834         otherwise the files aren't clearly free.  Use the same notice that
4835         getdate.texi already uses.
4836         * doc/alloca-opt.texi: Add copyright notice.
4837         * doc/alloca.texi: Likewise.
4838         * doc/ctime.texi: Likewise.
4839         * doc/functions.texi: Likewise.
4840         * doc/gcd.texi: Likewise.
4841         * doc/gnulib-tool.texi: Likewise.
4842         * doc/inet_ntoa.texi: Likewise.
4843         * doc/visibility.texi: Likewise.
4844
4845         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
4846         * doc/quote.texi: Add copyright notice.
4847
4848         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
4849         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
4850         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
4851         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
4852         is now obsolete, and give a pointer to the Sun list.
4853         Add copyright notice.
4854
4855 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4856
4857         * config/srclistvars.sh: Add copyright notice.
4858
4859 2006-08-14  Eric Blake  <ebb9@byu.net>
4860
4861         Import the following change from libc:
4862
4863         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
4864
4865         Upstream bug 2997.
4866         * lib/misc/error.c: Add space between program name and message if file
4867         name is missing.
4868
4869 2006-08-12  Karl Berry  <karl@gnu.org>
4870
4871         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
4872         remove, these originate in gnulib now.
4873
4874 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4875
4876         * doc/Makefile (standards.info standards.html standards.dvi):
4877         Also depend on make-stds.texi.
4878
4879 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
4880
4881         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
4882         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
4883
4884         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
4885         in wchar_t.  Problem reported by Eric Blake.
4886
4887         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
4888         LEN is smaller than SIZE.  Suggested by Bruno Haible.
4889         Also, help the compiler to keep LEN in a register.
4890
4891 2006-08-11  Eric Blake  <ebb9@byu.net>
4892
4893         * users.txt: Sort.  Add tar.
4894
4895 2006-08-11  Bruno Haible  <bruno@clisp.org>
4896
4897         * users.txt: New file.
4898
4899 2006-08-11  Bruno Haible  <bruno@clisp.org>
4900
4901         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
4902         before <wchar.h>. Needed for OSF/1 and BSD/OS.
4903
4904 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
4905
4906         * modules/snprintf (Depends-on): Remove minmax.
4907         (Maintainer): Add self and Bruno.
4908
4909 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
4910
4911         * lib/.cppi-disable: Add snprintf.h, socket_.h.
4912         * lib/snprintf.c: Include <errno.h> and <limits.h>.
4913         (EOVERFLOW): Define if the system does not.
4914         Do not include "minmax.h"; it wasn't used.
4915         (snprintf): Don't assume size_t promotes to an unsigned type.
4916         Fix bug when generated string was too long for the buffer: the
4917         buffer's contents are supposed to be the initial prefix of the
4918         output.  Don't assume vasnprintf returns EOVERFLOW if the size
4919         exceeds INT_MAX; do the check ourselves.
4920
4921         Import the following changes from libc:
4922
4923         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
4924
4925         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
4926         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
4927         set wc to the byte which couldn't be converted.
4928         (re_string_reconstruct): Don't clear valid_raw_len before calling
4929         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
4930         tip_context using re_string_context_at.
4931
4932         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
4933
4934         * lib/posix/regex.h: g++ still cannot handled [restrict].
4935
4936         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
4937
4938         * lib/posix/regex.h: Remove special handling for VMS.
4939
4940 2006-08-10  Jim Meyering  <jim@meyering.net>
4941
4942         * modules/same-inode: New module.
4943         * modules/dev-ino: New module.
4944         * modules/cycle-check: Depend on these modules, rather than simply
4945         including their .h files.
4946         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
4947         required via m4/cycle-check.m4.
4948         * modules/same: Depend on new same-inode module, rather than
4949         including same-inode.h.
4950         * modules/chdir-safer: New file.
4951
4952         * modules/chown (Depends-on): Add stat-macros.
4953
4954 2006-08-10  Jim Meyering  <jim@meyering.net>
4955
4956         * m4/cycle-check.m4: New file.
4957         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
4958         * m4/dev-ino.m4, m4/same-inode.m4: New files.
4959
4960 2006-08-10  Eric Blake  <ebb9@byu.net>
4961
4962         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
4963         in from original proposal.
4964
4965 2006-08-10  Eric Blake  <ebb9@byu.net>
4966         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
4967
4968         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
4969         namespace.
4970
4971 2006-08-10  Bruno Haible  <bruno@clisp.org>
4972
4973         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
4974         as well.
4975
4976 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
4977
4978         Sync from coreutils.
4979
4980         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
4981
4982         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
4983         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
4984
4985 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
4986
4987         * modules/restrict: Remove; no longer needed now that we assume
4988         Autoconf 2.59 or later.
4989         * MODULES.html.sh: Remove 'restrict'.
4990         * modules/argp (Depends-on): Remove 'restrict'.
4991         * modules/base64 (Depends-on): Likewise.
4992         * modules/gc (Depends-on): Likewise.
4993         * modules/getaddrinfo (Depends-on): Likewise.
4994         * modules/glob (Depends-on): Likewise.
4995         * modules/inet_ntop (Depends-on): Likewise.
4996         * modules/inet_pton (Depends-on): Likewise.
4997         * modules/memxor (Depends-on): Likewise.
4998         * modules/regex (Depends-on): Likewise.
4999         * modules/strtok_r (Depends-on): Likewise.
5000         * modules/time_r (Depends-on): Likewise.
5001
5002 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5003
5004         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
5005         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
5006         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5007         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
5008         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
5009         * m4/memxor.m4 (gl_MEMXOR): Likewise.
5010         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
5011         gl_C_RESTRICT replaced by AC_C_RESTRICT.
5012
5013         Merge from coreutils.
5014         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
5015         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
5016         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
5017         * m4/time_r.m4 (gl_TIME_R): Likewise.
5018
5019 2006-08-09  Karl Berry  <karl@gnu.org>
5020
5021         * config/srclist.txt: no more gettext-tools, per Bruno.
5022
5023 2006-08-08  Eric Blake  <ebb9@byu.net>
5024
5025         * modules/verror: New module.
5026         * MODULES.html.sh: Document it.
5027
5028 2006-08-08  Eric Blake  <ebb9@byu.net>
5029
5030         * lib/verror.h, lib/verror.c: New files.
5031
5032 2006-08-08  Eric Blake  <ebb9@byu.net>
5033
5034         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
5035         verror_at_line output complies with GNU Coding Standards even when
5036         file is NULL.
5037
5038 2006-08-07  Bruno Haible  <bruno@clisp.org>
5039
5040         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
5041         versions of AIX.
5042         Reported by Ralf Wildenhues.
5043
5044 2006-08-07  Bruno Haible  <bruno@clisp.org>
5045
5046         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
5047         in an AC_DEFUN. Needed so that the autoconf snippets can use
5048         AC_REQUIRE.
5049
5050 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5051
5052         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5053         Initialize pkgdata_DATA.
5054         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
5055         overriding it.
5056
5057 2006-08-06  Eric Blake  <ebb9@byu.net>
5058
5059         * lib/error.h: Fold in some upstream changes from glibc.
5060         * lib/error.c: Likewise.
5061
5062 2006-08-04  Bruno Haible  <bruno@clisp.org>
5063
5064         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5065         Make the mostlyclean-local rule depend on mostlyclean-generic.
5066         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
5067
5068 2006-07-31  Bruno Haible  <bruno@clisp.org>
5069
5070         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
5071         <stdlib.h>, <string.h>.
5072
5073 2006-07-30  Bruno Haible  <bruno@clisp.org>
5074
5075         * modules/readlink (License): Change to LGPL.
5076
5077 2006-07-30  Bruno Haible  <bruno@clisp.org>
5078
5079         * modules/javaversion (Makefile.am): Distribute javaversion.java and
5080         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
5081         set PKGDATADIR to point to it.
5082
5083 2006-07-30  Bruno Haible  <bruno@clisp.org>
5084
5085         * modules/csharpexec (configure.ac): Comment out macro invocation.
5086         * modules/javaexec (configure.ac): Likewise.
5087         * modules/javacomp-script (configure.ac): Likewise.
5088
5089         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
5090
5091 2006-07-30  Bruno Haible  <bruno@clisp.org>
5092
5093         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
5094         linked-list.
5095
5096 2006-07-30  Bruno Haible  <bruno@clisp.org>
5097
5098         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
5099
5100 2006-07-30  Bruno Haible  <bruno@clisp.org>
5101
5102         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5103         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
5104         get removed.
5105
5106 2006-07-29  Bruno Haible  <bruno@clisp.org>
5107
5108         Make it possible for gnulib-tool to work with locally modified or
5109         augmented gnulib repositories.
5110         * gnulib-tool (func_usage): Document --local-dir option.
5111         (local_gnulib_dir): New variable.
5112         Handle --local-dir option.
5113         (func_lookup_file): New function.
5114         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
5115         (func_get_description, func_get_filelist, func_get_description,
5116         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
5117         func_get_automake_snippet, func_get_include_directive,
5118         func_get_license, func_get_maintainer): Use func_lookup_file.
5119         (func_import, func_create_testdir): Use func_lookup_file.
5120
5121 2006-07-29  Bruno Haible  <bruno@clisp.org>
5122
5123         * modules/setenv (Depends-on): Add unistd.
5124
5125 2006-07-29  Bruno Haible  <bruno@clisp.org>
5126
5127         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
5128
5129 2006-07-29  Bruno Haible  <bruno@clisp.org>
5130
5131         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
5132
5133 2006-07-29  Bruno Haible  <bruno@clisp.org>
5134
5135         * gnulib-tool (import, update): If there is no Makefile.am, look at
5136         aclocal.m4, instead of bailing out.
5137
5138 2006-07-29  Bruno Haible  <bruno@clisp.org>
5139
5140         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
5141         Categorize the options by when they are useful.
5142
5143 2006-07-29  Bruno Haible  <bruno@clisp.org>
5144
5145         * gnulib-tool (func_usage): Document option --no-libtool.
5146         Handle option --no-libtool.
5147         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
5148         for changed semantics of $libtool variable.
5149         (func_import): Likewise. If libtool is not used, show this through
5150         an option --no-libtool.
5151         (func_create_testdir): Update.
5152
5153 2006-07-29  Bruno Haible  <bruno@clisp.org>
5154
5155         * gnulib-tool (func_import): Extend error message about missing
5156         --doc-base.
5157
5158 2006-07-29  Bruno Haible  <bruno@clisp.org>
5159
5160         * gnulib-tool (func_import): Don't create the $docbase directory if
5161         there is no file to store there.
5162
5163 2006-07-29  Bruno Haible  <bruno@clisp.org>
5164
5165         * gnulib-tool (autoconf_minversion): If a --dir option is given and
5166         relevant, look for configure.ac there, not in the current directory.
5167         Also use a simple search for AC_PREREQ, not "autoconf --trace".
5168
5169 2006-07-29  Bruno Haible  <bruno@clisp.org>
5170
5171         * gnulib-tool (SORT): New variable.
5172         (func_usage): Undocument --assume-autoconf option.
5173         Remove --assume-autoconf option handling.
5174         (autoconf_minversion): Determine from the contents of configure.ac.
5175         (func_import): Remove autoconf_minversion handling.
5176         Suggested by Eric Blake.
5177
5178 2006-07-29  Bruno Haible  <bruno@clisp.org>
5179
5180         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
5181
5182 2006-07-29  Bruno Haible  <bruno@clisp.org>
5183
5184         * config/srclist.txt (*setenv.[ch]): Remove rules.
5185
5186 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5187
5188         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
5189
5190 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5191
5192         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
5193         arpa/inet.h.
5194
5195 2006-07-28  Simon Josefsson  <jas@extundo.com>
5196
5197         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
5198         * modules/inet_pton (Depends-on): Likewise.
5199
5200 2006-07-28  Simon Josefsson  <jas@extundo.com>
5201
5202         * m4/netinet_in_h.m4: New file.
5203
5204 2006-07-28  Simon Josefsson  <jas@extundo.com>
5205
5206         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
5207         #include's.
5208
5209 2006-07-28  Simon Josefsson  <jas@extundo.com>
5210
5211         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
5212         #include's.
5213
5214 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
5215
5216         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
5217         setgid on directories only if they set these bits.
5218         * lib/modechange.h: Remove obsolete comment about masks.
5219
5220 2006-07-28  Eric Blake  <ebb9@byu.net>
5221
5222         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
5223         macro expansion.
5224
5225 2006-07-28  Bruno Haible  <bruno@clisp.org>
5226
5227         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
5228
5229 2006-07-28  Bruno Haible  <bruno@clisp.org>
5230
5231         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
5232
5233 2006-07-28  Bruno Haible  <bruno@clisp.org>
5234
5235         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
5236         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
5237         Define fallbacks.
5238         Avoids link error on FreeBSD 4.x.
5239         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
5240
5241         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
5242         encoding.
5243         * lib/mbswidth.c (iswcntrl): Likewise.
5244
5245 2006-07-27  Bruno Haible  <bruno@clisp.org>
5246
5247         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
5248         test.
5249
5250 2006-07-27  Bruno Haible  <bruno@clisp.org>
5251
5252         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
5253         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
5254         defined.
5255
5256 2006-07-26  Eric Blake  <ebb9@byu.net>
5257
5258         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
5259
5260 2006-07-26  Eric Blake  <ebb9@byu.net>
5261
5262         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
5263         like mingw that lack mkstemp.
5264         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
5265         avoid compilation warning on mingw.
5266
5267 2006-07-26  Bruno Haible  <bruno@clisp.org>
5268
5269         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
5270         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
5271         INT_FAST*_MIN, INTPTR_MIN.
5272
5273 2006-07-25  Bruno Haible  <bruno@clisp.org>
5274
5275         * modules/version-etc (Depends-on): Add stdarg.
5276
5277 2006-07-25  Bruno Haible  <bruno@clisp.org>
5278
5279         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
5280         complex commands.
5281
5282 2006-07-25  Bruno Haible  <bruno@clisp.org>
5283
5284         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
5285         defined in <stdarg.h> or config.h.
5286
5287 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5288
5289         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
5290         (gl_STDIO_SAFER): Remove.
5291
5292 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5293
5294         * MODULES.html.sh (File stream based Input/Output):
5295         Add fopen-safer, tmpfile-safer; remove stdio-safer.
5296         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
5297         * modules/fopen-safer, modules/tmpfile-safer: New files.
5298         * modules/stdio-safer: Remove.
5299
5300 2006-07-24  Bruno Haible  <bruno@clisp.org>
5301
5302         * modules/tmpdir: New file.
5303         * MODULES.html.sh (File system functions): Add it.
5304
5305 2006-07-24  Bruno Haible  <bruno@clisp.org>
5306
5307         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
5308         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
5309
5310 2006-07-24  Bruno Haible  <bruno@clisp.org>
5311
5312         * modules/clean-temp: New file.
5313
5314 2006-07-24  Bruno Haible  <bruno@clisp.org>
5315
5316         * m4/tmpdir.m4: New file, from GNU gettext.
5317
5318 2006-07-24  Bruno Haible  <bruno@clisp.org>
5319
5320         * lib/tmpdir.h: New file, from GNU gettext.
5321         * lib/tmpdir.c: New file, from GNU gettext.
5322
5323 2006-07-24  Bruno Haible  <bruno@clisp.org>
5324
5325         * lib/clean-temp.h: New file, from GNU gettext.
5326         * lib/clean-temp.c: New file, from GNU gettext.
5327
5328 2006-07-23  Eric Blake  <ebb9@byu.net>
5329
5330         * modules/stdio-safer (Files): Add tmpfile-safer.c.
5331         (Depends-on): Add binary-io.
5332
5333 2006-07-23  Eric Blake  <ebb9@byu.net>
5334
5335         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
5336
5337 2006-07-23  Eric Blake  <ebb9@byu.net>
5338
5339         * lib/tmpfile-safer.c: New file.
5340         * lib/stdio-safer.h (fopen_safer): Add prototype.
5341         * lib/stdio--.h (tmpfile): Make safer.
5342
5343 2006-07-23  Bruno Haible  <bruno@clisp.org>
5344
5345         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
5346         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
5347         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
5348         gl_linked_remove_at): Use it.
5349
5350 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5351         and Simon Josefsson <jas@extundo.com>
5352
5353         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
5354
5355         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
5356
5357 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5358
5359         * modules/close-stream: New file.
5360         * modules/closeout (Description): Make it clear that it exits
5361         with a diagnostic on error.
5362         (Depends-on): Add close-stream.  Remove fpending, stdbool.
5363         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
5364
5365 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5366
5367         * m4/close-stream.m4: New file.
5368
5369 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5370
5371         * lib/close-stream.c, lib/close-stream.h: New files.
5372
5373 2006-07-22  Bruno Haible  <bruno@clisp.org>
5374
5375         Merge from GNU gettext 0.15.
5376
5377         2006-05-01  Bruno Haible  <bruno@clisp.org>
5378
5379                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
5380
5381         2006-07-22  Bruno Haible  <bruno@clisp.org>
5382
5383                 * modules/javaversion: New file.
5384                 * MODULES.html.sh (Java): Add javaversion.
5385
5386         2006-03-12  Bruno Haible  <bruno@clisp.org>
5387
5388                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
5389
5390         2005-12-04  Bruno Haible  <bruno@clisp.org>
5391
5392                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
5393                 (untested).
5394
5395         2006-06-21  Bruno Haible  <bruno@clisp.org>
5396
5397                 Avoid warnings from recent versions of mcs.
5398                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
5399                 -o, -L, -r any more. Use options documented since mcs-1.0
5400                 instead. Similarly for -g.
5401
5402         2005-12-04  Bruno Haible  <bruno@clisp.org>
5403
5404                 * build-aux/csharpcomp.sh.in: Suffix for resources is
5405                 .resources, not .resource.
5406
5407         2005-07-09  Bruno Haible  <bruno@clisp.org>
5408
5409                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
5410                 add a .dll suffix.
5411                 Reported by Mark Junker <mjscod@gmx.de>.
5412
5413         2006-07-22  Bruno Haible  <bruno@clisp.org>
5414
5415                 * modules/gettext: Upgrade to gettext-0.15.
5416                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
5417                 m4/visibility.m4.
5418                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
5419
5420 2006-07-22  Bruno Haible  <bruno@clisp.org>
5421
5422         Merge from GNU gettext 0.15.
5423
5424         2006-03-25  Bruno Haible  <bruno@clisp.org>
5425
5426                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
5427
5428         2006-07-21  Bruno Haible  <bruno@clisp.org>
5429
5430                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
5431                 "1.1".
5432
5433         2006-05-09  Bruno Haible  <bruno@clisp.org>
5434
5435                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
5436                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
5437                 for the conftestver execution.
5438
5439         2006-05-01  Bruno Haible  <bruno@clisp.org>
5440
5441                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
5442                 optional target-version argument. Verify that the compiler
5443                 groks source of the specified source-version, or add -source
5444                 option as necessary. Verify that the compiler produces
5445                 bytecode in the specified target-version, or add -target and
5446                 -source options as necessary. Make the result of the test
5447                 available as variable CONF_JAVAC. Also log error output in
5448                 config.log.
5449
5450         2006-03-11  Bruno Haible  <bruno@clisp.org>
5451
5452                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
5453
5454         2006-05-09  Bruno Haible  <bruno@clisp.org>
5455
5456                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
5457                 CLASSPATH_SEPARATOR to a semicolon.
5458
5459         2006-03-12  Bruno Haible  <bruno@clisp.org>
5460
5461                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
5462                 available as variable CONF_JAVA, for subsequent autoconf
5463                 tests. Also log error output in config.log.
5464
5465         2006-07-19  Bruno Haible  <bruno@clisp.org>
5466
5467                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
5468                 that getline works on glibc2 systems. Needed to avoid trouble
5469                 in relocatable.c.
5470                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
5471
5472         2005-12-04  Bruno Haible  <bruno@clisp.org>
5473
5474                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
5475                 launcher (untested).
5476
5477         2005-12-04  Bruno Haible  <bruno@clisp.org>
5478
5479                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
5480
5481         2006-07-22  Bruno Haible  <bruno@clisp.org>
5482
5483                 * gettext.m4: Update from GNU gettext-0.15.
5484                 * nls.m4: Likewise.
5485                 * po.m4: Likewise.
5486                 * inttypes-pri.m4: Likewise.
5487                 * inttypes-h.m4: Renamed from inttypes.m4.
5488                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
5489
5490 2006-07-22  Bruno Haible  <bruno@clisp.org>
5491
5492         Merge from GNU gettext 0.15.
5493
5494         2005-07-05  Bruno Haible  <bruno@clisp.org>
5495
5496                 * printf-args.c (printf_fetchargs): Work around broken
5497                 definition of wint_t on mingw.
5498
5499         2005-02-12  Bruno Haible  <bruno@clisp.org>
5500
5501                 * xallocsa.h: Add extern "C" for C++.
5502
5503         2006-05-17  Bruno Haible  <bruno@clisp.org>
5504
5505                 Cygwin portability.
5506                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
5507
5508         2006-04-30  Bruno Haible  <bruno@clisp.org>
5509
5510                 * progreloc.c: Include <mach-o/dyld.h> if available.
5511                 (find_executable): Use _NSGetExecutablePath when possible.
5512
5513         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5514
5515                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
5516                 function.
5517
5518         2005-12-29  Bruno Haible  <bruno@clisp.org>
5519
5520                 * progreloc.c (set_program_name_and_installdir): Fix
5521                 compilation error.
5522
5523         2005-12-04  Bruno Haible  <bruno@clisp.org>
5524
5525                 Cygwin portability.
5526                 * progreloc.c: Include <windows.h> also on Cygwin.
5527                 (find_executable): Add support for Cygwin.
5528                 (set_program_name_and_installdir): Handle also platforms with
5529                 nonempty EXEEXT.
5530
5531         2006-07-11  Bruno Haible  <bruno@clisp.org>
5532
5533                 * javacomp.c: Fix a comment.
5534                 Reported by Jim Meyering.
5535
5536         2006-04-30  Bruno Haible  <bruno@clisp.org>
5537
5538                 * javacomp.h (compile_java_class): Add source_version,
5539                 target_version arguments.
5540                 * javacomp.c: Rewritten to choose only a compiler that
5541                 respects the specified source_version and target_version.
5542
5543         2006-06-27  Bruno Haible  <bruno@clisp.org>
5544
5545                 Assume correct S_ISDIR macro.
5546                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
5547
5548         2006-07-22  Bruno Haible  <bruno@clisp.org>
5549
5550                 * javaversion.h: New file, from GNU gettext.
5551                 * javaversion.c: New file, from GNU gettext.
5552                 * javaversion.java: New file, from GNU gettext.
5553                 * javaversion.class: New file, from GNU gettext.
5554
5555         2006-05-17  Bruno Haible  <bruno@clisp.org>
5556
5557                 Cygwin portability.
5558                 * javaexec.c (execute_java_class): Test for jview program
5559                 also on Cygwin.
5560
5561         2006-04-09  Bruno Haible  <bruno@clisp.org>
5562
5563                 * fatal-signal.c: Don't include string.h.
5564                 (at_fatal_signal): Use a copying loop instead of memcpy.
5565
5566         2005-12-04  Bruno Haible  <bruno@clisp.org>
5567
5568                 * csharpexec.c: Add support for 'clix' launcher (untested).
5569                 (execute_csharp_using_sscli): New function.
5570                 (execute_csharp_program): Call it.
5571
5572         2006-06-21  Bruno Haible  <bruno@clisp.org>
5573
5574                 Avoid warnings from recent versions of mcs.
5575                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
5576                 -o, -L, -r any more. Use options documented since mcs-1.0
5577                 instead. Similarly for -g.
5578
5579         2005-07-09  Bruno Haible  <bruno@clisp.org>
5580
5581                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
5582                 add a .dll suffix.
5583                 Reported by Mark Junker <mjscod@gmx.de>.
5584
5585         2006-06-17  Bruno Haible  <bruno@clisp.org>
5586
5587                 * config.charset: Update for NetBSD 3.0.
5588
5589         2006-05-17  Bruno Haible  <bruno@clisp.org>
5590
5591                 Cygwin portability.
5592                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
5593
5594         2006-05-16  Bruno Haible  <bruno@clisp.org>
5595
5596                 * localcharset.c [CYGWIN]: Include <windows.h>.
5597                 (get_charset_aliases): For Cygwin, return the same CPxxx
5598                 aliases list as under WIN32.
5599                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
5600                 the environment variables. Fall back to GetACP().
5601
5602         2006-04-05  Bruno Haible  <bruno@clisp.org>
5603
5604                 * config.charset: Update Juan Manuel Guerrero's address.
5605
5606         2005-02-12  Bruno Haible  <bruno@clisp.org>
5607
5608                 * allocsa.h: Add extern "C" for C++.
5609
5610         2005-02-10  Bruno Haible  <bruno@clisp.org>
5611
5612                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
5613                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
5614
5615         2006-07-22  Bruno Haible  <bruno@clisp.org>
5616
5617                 * gettext.h: Update to GNU gettext-0.15.
5618
5619 2006-07-22  Bruno Haible  <bruno@clisp.org>
5620
5621         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
5622         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
5623         lib-prefix.m4, longdouble.m4, ssize_t.m4.
5624
5625 2006-07-21  Eric Blake  <ebb9@byu.net>
5626
5627         * modules/stdlib-safer: New file.
5628         * MODULES.html.sh (File stream based Input/Output): Add
5629         stdlib-safer.
5630
5631 2006-07-21  Eric Blake  <ebb9@byu.net>
5632
5633         * lib/stdlib-safer.h: New file from coreutils, required by
5634         stdlib--.h.
5635
5636 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
5637
5638         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
5639
5640 2006-07-20  Bruno Haible  <bruno@clisp.org>
5641
5642         * gnulib-tool: Recognize new option --assume-autoconf.
5643         (autoconf_minversion): New variable.
5644         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
5645
5646 2006-07-20  Bruno Haible  <bruno@clisp.org>
5647
5648         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
5649
5650 2006-07-19  Derek R. Price  <derek@ximbiot.com>
5651
5652         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
5653         Reindent and repaginate.
5654
5655 2006-07-19  Derek Price  <derek@ximbiot.com>
5656
5657         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
5658         Correct grammar.
5659
5660 2006-07-17  Bruno Haible  <bruno@clisp.org>
5661
5662         * modules/list: New file.
5663         * modules/array-list: New file.
5664         * modules/carray-list, modules/carray-list-tests: New files.
5665         * modules/linked-list, modules/linked-list-tests: New files.
5666         * modules/avltree-list, modules/avltree-list-tests: New files.
5667         * modules/rbtree-list, modules/rbtree-list-tests: New files.
5668         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
5669         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
5670         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
5671         * modules/oset: New file.
5672         * modules/array-oset: New file.
5673         * modules/avltree-oset, modules/avltree-oset-tests: New files.
5674         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
5675         * tests/test-carray_list.c: New file.
5676         * tests/test-linked_list.c: New file.
5677         * tests/test-avltree_list.c: New file.
5678         * tests/test-rbtree_list.c: New file.
5679         * tests/test-linkedhash_list.c: New file.
5680         * tests/test-avltreehash_list.c: New file.
5681         * tests/test-rbtreehash_list.c: New file.
5682         * tests/test-avltree_oset.c: New file.
5683         * tests/test-rbtree_oset.c: New file.
5684         * MODULES.html.sh (Container data structures): New section.
5685
5686 2006-07-17  Bruno Haible  <bruno@clisp.org>
5687
5688         * m4/gl_list.m4: New file.
5689
5690 2006-07-17  Bruno Haible  <bruno@clisp.org>
5691
5692         * lib/gl_list.h: New file.
5693         * lib/gl_list.c: New file.
5694         * lib/gl_array_list.h: New file.
5695         * lib/gl_array_list.c: New file.
5696         * lib/gl_carray_list.h: New file.
5697         * lib/gl_carray_list.c: New file.
5698         * lib/gl_linked_list.h: New file.
5699         * lib/gl_linked_list.c: New file.
5700         * lib/gl_anylinked_list1.h: New file.
5701         * lib/gl_anylinked_list2.h: New file.
5702         * lib/gl_avltree_list.h: New file.
5703         * lib/gl_avltree_list.c: New file.
5704         * lib/gl_anyavltree_list1.h: New file.
5705         * lib/gl_anyavltree_list2.h: New file.
5706         * lib/gl_rbtree_list.h: New file.
5707         * lib/gl_rbtree_list.c: New file.
5708         * lib/gl_anyrbtree_list1.h: New file.
5709         * lib/gl_anyrbtree_list2.h: New file.
5710         * lib/gl_anytree_list1.h: New file.
5711         * lib/gl_anytree_list2.h: New file.
5712         * lib/gl_linkedhash_list.h: New file.
5713         * lib/gl_linkedhash_list.c: New file.
5714         * lib/gl_anyhash_list1.h: New file.
5715         * lib/gl_anyhash_list2.h: New file.
5716         * lib/gl_avltreehash_list.h: New file.
5717         * lib/gl_avltreehash_list.c: New file.
5718         * lib/gl_rbtreehash_list.h: New file.
5719         * lib/gl_rbtreehash_list.c: New file.
5720         * lib/gl_anytreehash_list1.h: New file.
5721         * lib/gl_anytreehash_list2.h: New file.
5722
5723         * lib/gl_oset.h: New file.
5724         * lib/gl_oset.c: New file.
5725         * lib/gl_array_oset.h: New file.
5726         * lib/gl_array_oset.c: New file.
5727         * lib/gl_avltree_oset.h: New file.
5728         * lib/gl_avltree_oset.c: New file.
5729         * lib/gl_rbtree_oset.h: New file.
5730         * lib/gl_rbtree_oset.c: New file.
5731         * lib/gl_anytree_oset.h: New file.
5732
5733 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5734
5735         * m4/mkancesdirs.m4: New file.
5736         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
5737         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
5738         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
5739         it.
5740
5741 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5742
5743         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
5744         * lib/mkancesdirs.h: New files.
5745         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
5746         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
5747         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
5748         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
5749         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
5750         callers changed.  Revamp internals significantly, by not
5751         attempting to create directories that are temporarily more
5752         permissive than the final results.  Do not attempt to use
5753         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
5754         This removes some race conditions, fixes some bugs, and simplifies
5755         things.  Use new dirchownmod function to do owner and mode changes.
5756         * lib/mkdir-p.h: Likewise.
5757         * lib/modechange.c (octal_to_mode): New function.
5758         (struct mode_change): New member mentioned.
5759         (make_node_op_equals): New arg mentioned.  All callers changed.
5760         (mode_compile): Keep track of which mode bits the user has explicitly
5761         mentioned.
5762         (mode_adjust): New arg DIR, so that we implement the X op correctly.
5763         New arg PMODE_BITS, to keep track of which mode bits the user
5764         mentioned; it treats S_ISUID and S_ISGID speciall.
5765         All callers changed.
5766         * lib/modechange.h: Likewise.
5767
5768 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5769
5770         * MODULES.html.sh: Add mkancestors.
5771         * modules/mkancesdirs: New module.
5772         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
5773         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
5774         The chdir-safer and afs files are now orphans; I'll remove them
5775         unless someone speaks up.
5776         Add lib/dirchownmod.c, lib/dirchownmod.h.
5777         (Depends-on): Remove alloca, chown, save-cwd, dirname.
5778         Add lchown, mkancesdirs.
5779         (Maintainer): Add self.
5780
5781 2006-07-15  Karl Berry  <karl@gnu.org>
5782
5783         * gnulib-tool: help message wording/arrangement.
5784
5785 2006-07-14  Simon Josefsson  <jas@extundo.com>
5786
5787         * doc/gnulib.texi (Libtool and Windows): New section.
5788
5789 2006-07-12  Simon Josefsson  <jas@extundo.com>
5790
5791         * modules/gendocs (License): Fix license, approved by Karl.
5792
5793 2006-07-12  Eric Blake  <ebb9@byu.net>
5794
5795         * MODULES.html.sh: Add gendocs.
5796
5797 2006-07-11  Eric Blake  <ebb9@byu.net>
5798
5799         * modules/fdl: New module, to install doc/fdl.texi.
5800         * MODULES.html.sh: Add new section for documentation modules.
5801         * gnulib-tool: Avoid space-tab.
5802         (--doc-base): New option, to manage files from doc.
5803
5804 2006-07-11  Eric Blake  <ebb9@byu.net>
5805
5806         * m4/absolute-header.m4: Fix comments to match recent change.
5807
5808 2006-07-11  Eric Blake  <ebb9@byu.net>
5809
5810         * gnulib-tool: List --doc-base before --tests-base.
5811
5812 2006-07-11  Derek R. Price  <derek@ximbiot.com>
5813
5814         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
5815
5816 2006-07-11  Bruno Haible  <bruno@clisp.org>
5817
5818         * README: Mention where to put documentation.
5819
5820 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5821
5822         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
5823
5824 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5825
5826         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
5827         to stdint.m4.
5828
5829 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5830
5831         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
5832         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
5833         "no/such/file/stdint.h" when there is no such file, so that
5834         the resulting C code can be parsed by dodgy compilers.
5835         Problems reported by Bob Proulx.
5836
5837 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5838
5839         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
5840         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5841         macros into the GNU _D_EXACT_NAMLEN.
5842         * lib/savedir.c:  Likewise.
5843         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
5844
5845 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5846         and Paul Eggert  <eggert@cs.ucla.edu>
5847
5848         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
5849         * m4/savedir.m4:
5850         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5851         macros into the GNU _D_EXACT_NAMLEN.
5852
5853 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5854
5855         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
5856         around the absolute name, to work around a problem with the HP-UX
5857         11.23 native C compiler, reported by Bob Proulx.
5858
5859 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5860
5861         * doc/maintain.texi, make-stds.texi: Sync from
5862         <http://savannah.gnu.org/projects/gnustandards>.
5863
5864 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5865
5866         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
5867
5868 2006-07-09  Jim Meyering  <jim@meyering.net>
5869
5870         * m4/glob.m4: Remove a doubled word in a comment.
5871
5872 2006-07-09  Jim Meyering  <jim@meyering.net>
5873
5874         * lib/argp-pv.c: Remove a doubled word in a comment.
5875         * lib/check-version.c (check_version): Likewise.
5876         * lib/javacomp.c (compile_java_class): Likewise.
5877
5878 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
5879
5880         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
5881         for the benefit of people using Autoconf 2.60.  If you want to
5882         support older Autoconf versions you can copy m4/onceonly_2_57.m4
5883         (or m4/onceonly.m4, if pre-2.57) manually.
5884
5885 2006-07-08  Jim Meyering  <jim@meyering.net>
5886
5887         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
5888         comment.
5889         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
5890         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
5891         comment.
5892
5893 2006-07-08  Jim Meyering  <jim@meyering.net>
5894
5895         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
5896
5897 2006-07-07  Simon Josefsson  <jas@extundo.com>
5898
5899         * tests/test-crc.c: Change expected crc value, the test vector
5900         were probably computed using the old broken crc.c?
5901
5902 2006-07-06  Simon Josefsson  <jas@extundo.com>
5903
5904         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
5905         now the canonical place for the M4 file).
5906
5907         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
5908         from the sys_socket dependency now.
5909
5910         * modules/inet_pton (Files): Ditto.
5911
5912         * modules/inet_ntop (Files): Ditto.
5913
5914 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
5915
5916         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
5917         not gl_PREREQ_GETUSERSHELL.
5918
5919 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5920
5921         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
5922         with only one argument, for Autoconf 2.60.
5923         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
5924         expand to nothing, so add a shell command to avoid syntax error.
5925         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
5926
5927 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5928
5929         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
5930
5931 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5932
5933         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
5934         no longer needed.  Check for isblank decl.
5935         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
5936         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
5937         of existence.
5938
5939 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5940
5941         * lib/getloadavg.c: Use __VMS, not VMS.
5942         * lib/getopt.c: Likewise.
5943         * lib/getpagesize.h: Likewise.
5944         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
5945         and probably does not work.
5946
5947 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5948
5949         * lib/.cppi-disable: Add wcwidth.
5950         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
5951         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
5952         (ISGRAPH): Remove.  All uses changed to isgraph.
5953         (FOLD) [!defined _LIBC]: Remove special case.
5954         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
5955         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
5956         HAVE_ISBLANK.
5957         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
5958         case.
5959
5960 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
5961
5962         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
5963         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
5964         brackets.  Other minor changes to suppress some compiler
5965         warnings.
5966
5967 2006-07-06  Derek R. Price  <derek@ximbiot.com>
5968         and Paul Eggert  <eggert@cs.ucla.edu>
5969
5970         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
5971         of invoking obsolescent AC_HEADER_DIRENT macro.
5972         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
5973         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
5974         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
5975         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
5976         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
5977         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5978         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
5979         * m4/readdir.m4: Remove; no longer needed.
5980
5981 2006-07-06  Derek R. Price  <derek@ximbiot.com>
5982         and Paul Eggert  <eggert@cs.ucla.edu>
5983
5984         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
5985         Don't worry about this obsolete case any more.
5986         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
5987         directories.
5988         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
5989         worry about this obsolete case any more.
5990         * lib/fts.c: Likewise.
5991         * lib/getcwd.c: Likewise.
5992         * lib/glob.h: Likewise.
5993         * lib/savedir.c: Likewise.
5994
5995 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
5996
5997         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
5998         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
5999         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
6000         needed.
6001         All uses removed.
6002         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6003         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6004         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
6005         needed.
6006         * m4/getdate.m4 (gl_GETDATE): Likewise.
6007         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6008         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6009         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6010         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6011         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6012         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6013         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
6014         needed.
6015
6016 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6017
6018         * lib/memcasecmp.c: Include <limits.h>.
6019         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
6020         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
6021         Don't assume isdigit succeeds only on '0' through '9'.
6022
6023 2006-07-05  Eric Blake  <ebb9@byu.net>
6024
6025         * modules/getaddrinfo (Depends-on): Add snprintf.
6026
6027 2006-07-05  Eric Blake  <ebb9@byu.net>
6028
6029         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
6030         to avoid 'header present but could not be compiled' on cygwin.
6031
6032 2006-07-05  Eric Blake  <ebb9@byu.net>
6033
6034         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
6035         missing from netdb.h.
6036         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
6037
6038 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6039
6040         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
6041         no longer needed.
6042         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
6043         * m4/getdate.m4 (gl_GETDATE): Likewise.
6044         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6045         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6046         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6047         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6048         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6049
6050 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6051
6052         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
6053         All uses of is_space replaced by isspace.
6054         * lib/exit.h: Don't talk about STDC_HEADERS.
6055         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
6056         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
6057         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
6058         replaced by isprint etc.
6059         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
6060         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6061         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
6062         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
6063         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
6064         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6065
6066 2006-07-05  Bruno Haible  <bruno@clisp.org>
6067
6068         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
6069         the function exists, before testing against AIX.
6070         Reported by Martin Lambers <marlam@marlam.de>.
6071
6072 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6073
6074         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
6075         From Mark D. Baushke.
6076
6077 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6078
6079         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
6080         to the absolute name, not just one, to bypass Sun C 5.8's
6081         "warning: #include of /usr/include/... may be non-portable".
6082
6083 2006-07-04  Eric Blake  <ebb9@byu.net>
6084
6085         * modules/dirname-tests: New test module.
6086         * tests/test-dirname.c: New file, replacing dirname.c
6087         TEST_DIRNAME section that was recently deleted.
6088
6089 2006-07-04  Bruno Haible  <bruno@clisp.org>
6090
6091         Assume ANSI C header files and <ctype.h> functions.
6092         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
6093         (mbsnwidth): Use isprint, iscntrl instead.
6094
6095 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6096
6097         Merge from coreutils.
6098         * MODULES.html.sh: Add xstrtold.
6099         * modules/xstrtold: New file.
6100         * modules/cycle-check (Files): Add lib/same-inode.h.
6101         * modules/dirname (Files): Add m4/double-slash-root.m4.
6102         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
6103         * modules/mkdir-p (Files): Add lib/same-inode.h.
6104         * modules/same (Files): Add lib/same-inode.h.
6105
6106 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6107
6108         * m4/absolute-header.m4: Renamed from full-header-path.m4.
6109         This is to keep the terminology clean; POSIX talks about
6110         "absolute pathnames", not "full pathnames", but the GNU
6111         Coding Standards say to use "path" for something else;
6112         so use "absolute" to keep both sides happy.
6113         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
6114         Set gl_absolute_header, not gl_full_header_path.
6115         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
6116         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
6117         All uses changed.
6118
6119         Merge from coreutils.
6120
6121         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6122
6123         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
6124         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
6125         want to require the building of c-strtod.o.
6126         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
6127         needs -lm directly.
6128         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
6129
6130         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6131
6132         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
6133         --as-needed option if available.  Problem reported by Albert Chin in
6134         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
6135         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
6136         cc merely issues a bunch of annoying warnings for --as-needed
6137         (this problem was reported by Bob Proulx).  Also, try linking with
6138         -lm to detect a bug in binutils 2.16 (this problem was reported
6139         by Ralf Wildenhues).
6140
6141         2006-06-18  Jim Meyering  <jim@meyering.net>
6142
6143         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
6144         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
6145         macro.
6146         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
6147         also check for glibc-2.4's abort-inducing bug.
6148
6149         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
6150         Low-probability clean-up should be to use rmdir to get rid of
6151         the just-created directory, not unlink.
6152
6153         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
6154         configure fail, and request a bug report to inform us about it.
6155         Add a comment that, barring reports to the contrary, in 2007 we'll
6156         assume ftruncate is universally available.
6157
6158         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6159
6160         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
6161
6162         2006-03-12  Jim Meyering  <jim@meyering.net>
6163
6164         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
6165         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
6166         * m4/same.m4 (gl_SAME): Likewise.
6167         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
6168
6169         2006-03-11  Eric Blake  <ebb9@byu.net>
6170
6171         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
6172         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
6173         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
6174         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
6175
6176 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6177
6178         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
6179         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
6180         reported by Mark D. Baushke, one in
6181         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
6182
6183         Merge from coreutils.
6184
6185         * lib/.cppi-disable: Add stdint_.h.
6186         * lib/.cvsignore: Add stdint.h.
6187
6188         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6189
6190         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
6191         both double and long double versions.
6192         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
6193         * lib/xstrtold.c: New file.
6194         * lib/xstrtod.h (xstrtold): New decl.
6195
6196         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
6197
6198         * lib/filemode.c (setst): Remove.
6199         (strmode): Rewrite to avoid setst.  This makes the code shorter,
6200         (arguably) clearer, and the generated code is a bit smaller on my
6201         Debian GNU/Linux stable x86 host.
6202
6203         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6204
6205         * lib/filemode.c: Include "filemode.h" first, to test the interface.
6206         Assume that filemode.h includes sys/types.h and sys/stat.h.
6207         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
6208         (ftypelet): Reorder to put common cases first, for efficiency.
6209         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
6210         to do 'M'.
6211         (strmode): Renamed from mode_string, and now stores 12 bytes instead
6212         of 10, for compatibility with FreeBSD.  All callers changed.
6213         (filemodestring): Now stores 12 bytes instead of 10, and sets file
6214         types that can't be deduced solely from st_mode.  First arg is now a
6215         const pointer.
6216         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
6217         (strmode): Renamed from mode_string.
6218         (filemodestring): New decl.
6219         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
6220         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
6221         needed.
6222         (S_ISPORT, S_ISWHT): New macros, if not already defined.
6223
6224         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
6225
6226         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
6227         fsusage.h now does that.  Include fsusage.h first, to test interface.
6228         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
6229         at most one method (the old code could have generated decls that
6230         didn't conform to C89, not that this was ever exercised).
6231         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
6232
6233         2006-03-19  Jim Meyering  <jim@meyering.net>
6234
6235         Work even in a chroot where d_ino values for entries in "/"
6236         don't match the stat.st_ino values for the same names.
6237         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
6238         number, iterate through all entries again, using lstat instead.
6239         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
6240         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
6241
6242         * lib/getcwd.c (__getcwd): Clarify a comment.
6243         Use memcpy in place of a call to strcpy.
6244
6245         2006-03-12  Jim Meyering  <jim@meyering.net>
6246
6247         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
6248         matches that of the current directory (which we're about to chdir ".."
6249         out of), then save the dev-ino of the parent, instead.
6250
6251         * lib/same-inode.h (SAME_INODE): New file/macro.
6252         * lib/chdir-safer.c (SAME_INODE): Remove definition.
6253         Include "same-inode.h", instead.
6254         * lib/same.c: Likewise.
6255         * lib/cycle-check.h: Include "same-inode.h".
6256         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
6257         * lib/cycle-check.c (SAME_INODE): Remove definition.
6258         * lib/root-dev-ino.h: Include "same-inode.h".
6259
6260         2006-03-11  Eric Blake  <ebb9@byu.net>
6261
6262         * lib/same.c (same_name): s/base_name/last_component/
6263         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
6264         * lib/filenamecat.c (file_name_concat): Likewise.
6265
6266         2006-03-11  Eric Blake  <ebb9@byu.net>,
6267                     Paul Eggert  <eggert@cs.ucla.edu>
6268
6269         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
6270         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
6271         drive prefix.
6272         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
6273         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
6274         (last_component): New method.
6275         * lib/dirname.c (dir_len): Determine when drive letters need a
6276         subsequent slash.  Preserve // when it is special.
6277         (dir_name): Don't append dot when drive letter is absolute.
6278         [TEST_DIRNAME]: Move into a full-blown gnulib test.
6279         * lib/basename.c (base_name): New semantics - malloc the result.
6280         Preserve // when it is special.  Preserve relative files that look
6281         like drive letters.
6282         (base_len): Preserve // when it is special.
6283         (last_component): New method, similar to old base_name semantics.
6284         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
6285         base_name.  Strip redundant slashes from ///.
6286
6287 2006-07-03  Jim Meyering  <jim@meyering.net>
6288
6289         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
6290         macro is used before the first cycle_check call.
6291
6292 2006-07-03  Eric Blake  <ebb9@byu.net>
6293
6294         * modules/dirname (Depends-on): Add xstrndup.
6295
6296 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6297
6298         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
6299         test cases, so that config.log is a bit easier to follow.
6300
6301 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6302
6303         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
6304         both are 64 bits, since this seems to be the tradition, and this
6305         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
6306         we ever run into a host that prefers long long to long in this
6307         case, we'll need another configure-time test.  Problem reported by
6308         Jim Meyering.
6309
6310 2006-07-02  Eric Blake  <ebb9@byu.net>
6311
6312         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
6313
6314 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6315
6316         * modules/inttypes (Depends-on): No longer depends on stdint.
6317         * modules/stdint (Description): Say more about assumptions.
6318         Say that the fast types might differ.  Say macros are used.
6319         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
6320         (Makefile.am): Revise list of substituted symbols to match
6321         new stdint.m4.
6322         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
6323         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
6324         * tests/test-stdint.c (verify_same_types)
6325         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
6326         the code conforms to C99/C89.
6327         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
6328         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
6329
6330 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6331
6332         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
6333         but fix a bug, by requiring at least 64 bits.
6334         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
6335         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
6336         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
6337         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
6338
6339         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
6340         changes.  Make 2.59 a prerequisite.  Check and substitute for
6341         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
6342         inttypes.h.  Do not use special include files; just use the
6343         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
6344         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
6345         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
6346         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
6347         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
6348         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
6349         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
6350         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
6351         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
6352         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
6353         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
6354         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
6355         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
6356         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
6357         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
6358         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
6359         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
6360         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
6361         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
6362         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
6363         WINT_MAX.  Check for C99 conformance more strictly, by detecting
6364         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
6365         not check for things that C99 does not require, e.g., int8_t.  If
6366         a test isn't needed unless <stdint.h> isn't working, and is
6367         unlikely to be needed for any other reason, then don't do it
6368         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
6369         size_t, since we assume C89 freestanding at least.  Do not check
6370         for sig_atomic_t, wchar_t, or wint_t, since the code now does
6371         the right thing even if the types are not defined.  Instead use:
6372         (gl_STDINT_TYPE_PROPERTIES): New macro.
6373         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
6374         testing whether <sys/types.h> clashes, as Autoconf does this for
6375         us now.  All uses removed.
6376         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
6377         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
6378         (gl_CHECK_TYPE_SAME):
6379         Remove; no longer needed.
6380         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
6381         exists, since we'll return 0 anyway in that case.
6382         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
6383
6384 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6385
6386         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
6387         possible collision with system files.
6388         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
6389         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
6390         WCHAR_MIN and WCHAR_MAX in this case.
6391         (<stddef.h>): Do not include; no longer needed.
6392         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
6393         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
6394         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
6395         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
6396         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
6397         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
6398         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
6399         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
6400         !defined(__c99))]: Include in this case too, since it's harmless
6401         now.
6402         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
6403         dangerous to do so.
6404         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
6405         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
6406         (_STDINT_MIN, _STDINT_MAX): New macros.
6407         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
6408         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
6409         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
6410         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
6411         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
6412         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
6413         macros, not typedefs; this simplifies things quite a bit.
6414         Use long int for all types narrower than int64_t.
6415         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
6416         Define in terms of long long int or int64_t or long int,
6417         not int64_t or int32_t.  This saves some compile-time testing.
6418         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
6419         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
6420         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
6421         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
6422         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
6423         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
6424         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
6425         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
6426         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
6427         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
6428         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6429         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6430         undef any previous version and define our own version, for
6431         simplicity and consistency with the new macros for types.
6432         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6433         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6434         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
6435         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
6436         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
6437         @WINT_T_SUFFIX@ to keep things simple here.
6438         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
6439         Simplify by assuming typical 8/16/32/64 host, since we're
6440         already doing that elsewhere anyway.
6441         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
6442         and assume long long int is 64 bits if available.  This
6443         speeds up 'configure'.
6444
6445 2006-07-01  Eric Blake  <ebb9@byu.net>
6446
6447         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
6448         Reported by Andreas Buening.
6449
6450 2006-07-01  Eric Blake  <ebb9@byu.net>
6451
6452         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
6453
6454 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6455
6456         * lib/getaddrinfo.c: fixed typo
6457
6458 2006-06-29  Jim Meyering  <jim@meyering.net>
6459
6460         * modules/strftime (Maintainer): Add my name, since with the
6461         FPRINTFTIME changes strftime.c has forked from glibc.
6462
6463 2006-06-29  Eric Blake  <ebb9@byu.net>
6464
6465         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
6466
6467 2006-06-29  Eric Blake  <ebb9@byu.net>
6468
6469         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
6470
6471 2006-06-29  Eric Blake  <ebb9@byu.net>
6472
6473         * lib/stat_.h: New file.
6474
6475 2006-06-29  Eric Blake  <ebb9@byu.net>
6476
6477         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
6478         unused static function.
6479
6480 2006-06-29  Eric Blake  <ebb9@byu.net>
6481
6482         * doc/functions.texi (Function Portability): Document missing lstat
6483         on mingw.
6484
6485 2006-06-29  Eric Blake  <ebb9@byu.net>
6486
6487         * MODULES.html.sh: Add sys_stat.
6488         * modules/sys_stat: New module.
6489         * modules/mkstemp (Depends-on): Add sys_stat.
6490
6491 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6492
6493         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
6494
6495 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6496
6497         * m4/c-bs-a.m4: Removed.
6498
6499 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6500
6501         * lib/strftime.c: Assume strftime() exists.
6502
6503 2006-06-29  Derek Price  <derek@ximbiot.com>
6504
6505         * modules/c-bs-a: Removed - \a is C89.
6506         * MODULES.html.sh: Remove c-bs-a.
6507
6508 2006-06-29  Bruno Haible  <bruno@clisp.org>
6509
6510         * modules/wcwidth (License): Change to LGPL.
6511
6512 2006-06-28  Simon Josefsson  <jas@extundo.com>
6513
6514         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
6515         on _WIN32.
6516
6517         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
6518         getnameinfo.
6519
6520 2006-06-28  Simon Josefsson  <jas@extundo.com>
6521
6522         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
6523
6524 2006-06-28  Simon Josefsson  <jas@extundo.com>
6525
6526         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
6527         functions there.  It will succeed on Windows XP, but on Windows
6528         2000 and (presumably) earlier, it will fail, and use the internal
6529         re-implementation.
6530         (use_win32_p): New function.
6531         (getaddrinfo): Use strtoul on servname, to support numeric ports.
6532         Support AI_NUMERICSERV to disable getservbyname.
6533         (getnameinfo): New function, only supports
6534         NI_NUMERICHOST|NI_NUMERICSERV for now.
6535
6536         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
6537         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
6538         getnameinfo.
6539
6540 2006-06-28  Eric Blake  <ebb9@byu.net>
6541
6542         * modules/wcwidth: New file.
6543         * modules/mbchar (Depends-on): Add wcwidth.
6544         * modules/mbswidth (Depends-on): Add wcwidth.
6545         * MODULES.html.sh: Add wcwidth.
6546
6547 2006-06-28  Eric Blake  <ebb9@byu.net>
6548
6549         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
6550         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
6551
6552 2006-06-28  Eric Blake  <ebb9@byu.net>
6553
6554         * lib/xvasprintf.h: Fix comments.
6555
6556 2006-06-28  Eric Blake  <ebb9@byu.net>
6557
6558         * lib/mbchar.h (wcwidth): Include wcwidth.h.
6559         * lib/mbswidth.c (wcwidth): Move from here...
6560         * lib/wcwidth.h: ...to this new file.
6561
6562 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6563
6564         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
6565
6566         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
6567         it's obsolete.
6568         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
6569
6570 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6571
6572         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
6573         Autoconf 2.60 says this stuff was obsolete.
6574
6575 2006-06-28  Bruno Haible  <bruno@clisp.org>
6576
6577         * modules/wcwidth (Files): Add m4/wchar_t.m4.
6578
6579 2006-06-28  Bruno Haible  <bruno@clisp.org>
6580
6581         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
6582         gt_TYPE_WCHAR_T.
6583
6584 2006-06-28  Bruno Haible  <bruno@clisp.org>
6585
6586         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
6587         declaration for wcwidth.
6588         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
6589
6590 2006-06-28  Bruno Haible  <bruno@clisp.org>
6591
6592         * lib/mkdtemp.c [MINGW]: Include <io.h>.
6593         (mkdir): Define using _mkdir.
6594
6595 2006-06-28  Bruno Haible  <bruno@clisp.org>
6596
6597         * lib/getaddrinfo.h: Fix POSIX URL.
6598         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
6599         _WIN32.
6600         (use_win32_p): Make static.
6601         (getaddrinfo): Reject service name if it is empty or does not consist
6602         solely of decimal digits, or if its value is > 65535.
6603         (getnameinfo): Remove useless casts.
6604
6605 2006-06-27  Simon Josefsson  <jas@extundo.com>
6606
6607         * modules/sys_select: New file, suggested by Bruno Haible, Paul
6608         Eggert and Martin Lambers.
6609
6610 2006-06-27  Simon Josefsson  <jas@extundo.com>
6611
6612         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
6613         Eggert and Martin Lambers.
6614
6615 2006-06-27  Bruno Haible  <bruno@clisp.org>
6616
6617         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
6618         result to 0, not to empty.
6619         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
6620
6621 2006-06-27  Bruno Haible  <bruno@clisp.org>
6622
6623         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
6624
6625 2006-06-26  Simon Josefsson  <jas@extundo.com>
6626
6627         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
6628         present.
6629
6630 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
6631
6632         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
6633         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
6634         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
6635
6636 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
6637
6638         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
6639
6640 2006-06-26  Bruno Haible  <bruno@clisp.org>
6641
6642         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
6643
6644 2006-06-26  Bruno Haible  <bruno@clisp.org>
6645
6646         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
6647
6648 2006-06-26  Bruno Haible  <bruno@clisp.org>
6649
6650         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
6651         SGI C compiler in pre-C99 mode.
6652         Suggested by Mark D. Baushke and Larry Jones.
6653
6654 2006-06-26  Bruno Haible  <bruno@clisp.org>
6655
6656         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
6657         WCHAR_MAX.
6658         Reported by Mark D. Baushke and Larry Jones.
6659
6660 2006-06-26  Bruno Haible  <bruno@clisp.org>
6661
6662         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
6663         in pre-C99 mode.
6664         Suggested by Mark D. Baushke and Larry Jones.
6665
6666 2006-06-23  Simon Josefsson  <jas@extundo.com>
6667             Bruno Haible  <bruno@clisp.org>
6668
6669         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
6670         Emit mostlyclean-local rule.
6671         (func_emit_tests_Makefile_am): Likewise.
6672         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
6673
6674 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
6675
6676         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
6677
6678 2006-06-23  Bruno Haible  <bruno@clisp.org>
6679
6680         * tests/test-stdint.c: Update to match ISO C 99 Technical
6681         Corrigendum 1.
6682
6683 2006-06-23  Bruno Haible  <bruno@clisp.org>
6684
6685         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
6686
6687 2006-06-23  Bruno Haible  <bruno@clisp.org>
6688
6689         * lib/stdint_.h: Treat IRIX like OpenBSD.
6690
6691 2006-06-23  Bruno Haible  <bruno@clisp.org>
6692
6693         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
6694         ISO C 99 Technical Corrigendum 1.
6695
6696 2006-06-22  Simon Josefsson  <jas@extundo.com>
6697
6698         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
6699         MinGW.
6700
6701 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
6702
6703         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
6704         needed.  Some compiler complained about some of them.  Problem reported
6705         by Larry Jones in
6706         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
6707
6708 2006-06-21  Simon Josefsson  <jas@extundo.com>
6709
6710         * tests/test-getaddrinfo.c: New file.
6711
6712         * modules/getaddrinfo-tests: New file.
6713
6714         * MODULES.html.sh: Add inet_pton.
6715
6716         * modules/inet_pton: New file.
6717
6718 2006-06-21  Simon Josefsson  <jas@extundo.com>
6719
6720         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
6721         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
6722         of using the (limited) gnulib implementation on Windows XP.
6723
6724         * m4/inet_pton.m4: New file.
6725
6726 2006-06-21  Simon Josefsson  <jas@extundo.com>
6727
6728         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
6729         variable.
6730
6731         * lib/socket_.h: Don't define WINVER.
6732
6733         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
6734         slightly modified to work in gnulib.
6735
6736 2006-06-21  Simon Josefsson  <jas@extundo.com>
6737
6738         * doc/gnulib.texi (Windows sockets): Add.
6739
6740 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
6741
6742         * lib/read-file.c (fread_file): Start with buffer allocation of
6743         0 bytes rather than 1 byte; this simplifies the code.
6744         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
6745         code to free buffer and save/restore errno.
6746         (internal_read_file): Remove unused local.
6747
6748 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
6749
6750         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
6751         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
6752         Problem reported by Denis Excoffier in
6753         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
6754
6755 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6756
6757         * modules/sys_socket, modules/socklen: Include sys/types since
6758         FreeBSD 4.x's sys/socket.h needs it.
6759
6760 2006-06-19  Simon Josefsson  <jas@extundo.com>
6761
6762         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
6763
6764 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6765
6766         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
6767
6768 2006-06-19  Bruno Haible  <bruno@clisp.org>
6769
6770         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
6771         and FULL_PATH_INTTYPES_H in angle brackets.
6772         Reported by Mark D. Baushke <mdb@gnu.org>.
6773
6774 2006-06-17  Eric Blake  <ebb9@byu.net>
6775
6776         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
6777         errno.
6778
6779 2006-06-17  Bruno Haible  <bruno@clisp.org>
6780
6781         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
6782         <sys/inttypes.h>.
6783
6784 2006-06-17  Bruno Haible  <bruno@clisp.org>
6785
6786         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
6787         whether errno is declared. Assume <errno.h> declares errno.
6788
6789 2006-06-17  Bruno Haible  <bruno@clisp.org>
6790
6791         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
6792
6793 2006-06-17  Bruno Haible  <bruno@clisp.org>
6794
6795         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
6796         problem on Solaris 2.5.1.
6797
6798 2006-06-16  Eric Blake  <ebb9@byu.net>
6799
6800         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
6801         * lib/unicodeio.c [!defined errno]: Likewise.
6802         * lib/strtol.c [!defined errno]: Likewise.
6803         * lib/strtod.c [!defined errno]: Likewise.
6804
6805 2006-06-15  Eric Blake  <ebb9@byu.net>
6806
6807         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
6808
6809 2006-06-15  Eric Blake  <ebb9@byu.net>
6810
6811         * config/srclist.txt (ssize_t.m4): Lose sync.
6812
6813 2006-06-15  Bruno Haible  <bruno@clisp.org>
6814
6815         * modules/stdint (Files): Include m4/full-header-path.m4,
6816         m4/size_max.m4, m4/wchar_t.m4.
6817         (Makefile.am): Many more substitutions.
6818         * modules/stdint-tests: New file.
6819         * tests/test-stdint.c: New file.
6820
6821 2006-06-15  Bruno Haible  <bruno@clisp.org>
6822
6823         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
6824         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
6825         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
6826         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
6827         gl_CHECK_TYPE_SAME): New macros.
6828
6829 2006-06-15  Bruno Haible  <bruno@clisp.org>
6830
6831         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
6832
6833 2006-06-15  Bruno Haible  <bruno@clisp.org>
6834
6835         * lib/stdint_.h: Rewritten to be fully auto-configured.
6836         Fixes bug on HP-UX/IA64.
6837
6838 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
6839
6840         * lib/getdate.y (__attribute__): Don't define if already defined.
6841         Problem reported by Larry Jones.
6842         * lib/utimens.c (__attribute__): Likewise.
6843
6844 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
6845
6846         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
6847         reported by Andreas Schwab.
6848
6849 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6850             Bruno Haible  <bruno@clisp.org>
6851
6852         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
6853         check for the declaration of strnlen and a run test that exposes the
6854         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
6855         rpl_strndup.
6856
6857 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6858             Bruno Haible  <bruno@clisp.org>
6859
6860         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
6861
6862 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6863
6864         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
6865         compile test, for Tru64 4.0D.
6866
6867 2006-05-28  Karl Berry  <karl@gnu.org>
6868
6869         * config/srclist.txt (printf-args.c): lose sync.
6870
6871 2006-05-26  Martin Lambers  <marlam@marlam.de>
6872
6873         * lib/getpass.c: Updates the test for the native W32 API, and adds
6874         missing includes, thus fixing compilation warnings.
6875
6876 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
6877
6878         * lib/exclude.c (exclude_fnmatch): New function.
6879         (excluded_file_name): Call exclude_fnmatch.
6880         * lib/exclude.h (excluded_file_name): New prototype
6881
6882 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
6883
6884         * lib/tempname.c (small_open, large_open): New macros.
6885         (__open, __open64) [!_LIBC]: Remove.
6886         (__gen_tempname): Use small_open and large_open instead of __open
6887         and __open64.  This fixes a portability bug on HP-UX 11.11i
6888         reported by Simon Wing-Tang in
6889         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
6890
6891 2006-05-24  Bruno Haible  <bruno@clisp.org>
6892
6893         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
6894         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
6895         Reported by Thorsten Maerz <torte@netztorte.de> via
6896         Aaron Stone <aaron@serendipity.cx>.
6897
6898 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6899
6900         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
6901         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
6902         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
6903         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
6904         not really conditional on the cache.
6905         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
6906
6907 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6908
6909         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
6910         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
6911         (my_usleep): Don't mishandle maximum value.
6912
6913 2006-05-19  Jim Meyering  <jim@meyering.net>
6914
6915         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
6916
6917 2006-05-17  Bruno Haible  <bruno@clisp.org>
6918
6919         Cygwin portability.
6920         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
6921
6922 2006-05-17  Bruno Haible  <bruno@clisp.org>
6923
6924         * lib/stdint_.h: Fix recognition of Cygwin.
6925
6926 2006-05-15  Bruno Haible  <bruno@clisp.org>
6927
6928         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
6929         on libtool patch by Ralf Wildenhues.
6930
6931 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
6932
6933         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
6934         test for C99 conformance; (bool) 0.5 is an integer constant
6935         expression, but (bool) -0.5 is not.  Problem reported by Fedor
6936         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
6937
6938 2006-05-11  Simon Josefsson  <jas@extundo.com>
6939
6940         * m4/xvasprintf.m4: Fix obvious typo.
6941
6942 2006-05-11  Jim Meyering  <jim@meyering.net>
6943
6944         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
6945         James Lemley.
6946
6947 2006-05-10  Simon Josefsson  <jas@extundo.com>
6948
6949         * lib/md4.c: Typo fix, update copyright years.
6950         (K1, K2): Don't use L because it turn computations into 64-bit on
6951         64-bit platforms.
6952
6953 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
6954
6955         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
6956         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
6957         unwanted sign propagation, e.g., on hosts with 64-bit int.
6958         There still are some problems with reeelly weird theoretical hosts
6959         (e.g., 33-bit int) but it's not worth worrying about now.
6960         * lib/sha1.c (rol): Likewise.
6961         (K1, K2, K3, K4): Remove unnecessary L suffix.
6962
6963 2006-05-10  Bruno Haible  <bruno@clisp.org>
6964
6965         * lib/des.c: Cast to avoid warnings.
6966
6967 2006-05-09  Bruno Haible  <bruno@clisp.org>
6968
6969         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
6970         (Depends-on): Depend also on xsize, stdarg.
6971         (configure.ac): Add gl_XVASPRINTF.
6972
6973 2006-05-09  Bruno Haible  <bruno@clisp.org>
6974
6975         * m4/xvasprintf.m4: New file.
6976
6977 2006-05-09  Bruno Haible  <bruno@clisp.org>
6978
6979         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
6980         (EOVERFLOW): Define fallback value.
6981         (xstrcat): New function.
6982         (xvasprintf): Recognize the special case of a string concatenation.
6983
6984 2006-05-08  Eric Blake  <ebb9@byu.net>
6985
6986         * gnulib-tool (func_version): Base copyright year on CVS date.
6987         (func_emit_copyright_notice): New function.
6988         (func_emit_lib_Makefile_am): Use it.
6989         (func_emit_tests_Makefile_am): Likewise.
6990         (func_import): Likewise.
6991
6992 2006-05-08  Bruno Haible  <bruno@clisp.org>
6993
6994         * modules/stdarg: New file.
6995         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
6996
6997 2006-05-08  Bruno Haible  <bruno@clisp.org>
6998
6999         * m4/stdarg.m4: New file, from GNU gettext.
7000
7001 2006-05-08  Bruno Haible  <bruno@clisp.org>
7002
7003         * config/srclist.txt (build-aux/config.rpath): different from latest
7004         release.
7005
7006 2006-05-08  Bruno Haible  <bruno@clisp.org>
7007
7008         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
7009
7010 2006-05-05  Jim Meyering  <jim@meyering.net>
7011
7012         * m4/warning.m4: New file, derived from bison's file by the same name.
7013
7014 2006-05-03  Bruno Haible  <bruno@clisp.org>
7015
7016         * lib/stdint_.h: Shorter URL.
7017         * lib/inttypes.h: Likewise.
7018
7019 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7020
7021         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
7022
7023 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7024
7025         * lib/verify.h: Document the internals better.  Most of this change
7026         was written by Bruno Haible.
7027
7028 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7029
7030         * doc/verify.texi: New file, partly based on a proposal by
7031         Bruno Haible.
7032
7033 2006-05-02  Bruno Haible  <bruno@clisp.org>
7034
7035         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
7036         test from here...
7037         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
7038
7039 2006-04-29  Bruno Haible  <bruno@clisp.org>
7040
7041         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
7042         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
7043
7044 2006-04-29  Bruno Haible  <bruno@clisp.org>
7045
7046         * gnulib-tool: Make --update option actually work.
7047
7048 2006-04-29  Bruno Haible  <bruno@clisp.org>
7049
7050         * doc/gcd.texi: New file.
7051         * doc/gnulib.texi: Include it.
7052
7053 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
7054
7055         * lib/getdate.y (get_date): When adding relative date, start with the
7056         initial time, not with the result of the first mktime call.
7057
7058 2006-04-25  Bruno Haible  <bruno@clisp.org>
7059
7060         * gnulib-tool (func_import): Output the include directives in three
7061         blocks, sorted separately.
7062         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7063
7064 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7065
7066         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
7067         to define main with arguments, for C++.  Reported by Eric Blake.
7068         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
7069         Prefer 'int main ()' to 'int main (void)', for C++.
7070         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
7071         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
7072         for 'main', for C99 and C++.
7073
7074 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7075
7076         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
7077         Don't assume that exit status -1 is valid.
7078         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7079         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
7080         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7081         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
7082         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
7083         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
7084         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
7085         functions can be used without declaring them, or that you can
7086         exit with status -1.
7087         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7088
7089 2006-04-24  Karl Berry  <karl@gnu.org>
7090
7091         * config/srclist.txt (longdouble.m4): sync lost.
7092
7093 2006-04-24  Eric Blake  <ebb9@byu.net>
7094
7095         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
7096
7097 2006-04-24  Bruno Haible  <bruno@clisp.org>
7098
7099         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
7100         poll() implementation in AIX.
7101         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7102
7103 2006-04-24  Bruno Haible  <bruno@clisp.org>
7104
7105         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
7106         assigned exactly once.
7107
7108 2006-04-23  Claudio Fontana  <claudio@gnu.org>
7109             Bruno Haible  <bruno@clisp.org>
7110
7111         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
7112         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
7113         for AM_CPPFLAGS.
7114
7115 2006-04-23  Bruno Haible  <bruno@clisp.org>
7116
7117         * modules/copy-file: Depend on unistd.
7118         * modules/execute: Likewise.
7119         * modules/fatal-signal: Likewise.
7120         * modules/findprog: Likewise.
7121         * modules/mkdtemp : Likewise.
7122         * modules/pipe: Likewise.
7123         * modules/wait-process: Likewise.
7124
7125 2006-04-23  Bruno Haible  <bruno@clisp.org>
7126
7127         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
7128         condition was already detected.
7129         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7130
7131 2006-04-23  Bruno Haible  <bruno@clisp.org>
7132
7133         * lib/copy-file.c: Include <unistd.h> unconditionally.
7134         * lib/execute.c: Likewise.
7135         * lib/fatal-signal.c: Likewise.
7136         * lib/findprog.c: Likewise.
7137         * lib/mkdtemp.c: Likewise.
7138         * lib/pipe.h: Likewise.
7139         * lib/pipe.c: Likewise.
7140         * lib/wait-process.h: Likewise.
7141
7142 2006-04-23  Bruno Haible  <bruno@clisp.org>
7143
7144         * gnulib-tool (func_usage): Fix --import description. Document
7145         --update.
7146         (func_import): Create temporary file in a temporary directory, if
7147         --dry-run is specified. Silence errors from 'grep' when there are no
7148         m4 files in $m4dir.
7149         (func_create_testdir): Silence errors from 'grep' when there are no
7150         m4 files in $m4dir.
7151         Reported by Karl Berry <karl@freefriends.org>.
7152
7153 2006-04-20  Bruno Haible  <bruno@clisp.org>
7154
7155         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
7156         one argument, so that the code will be portable to Autoconf 2.60.
7157         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
7158         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7159         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
7160
7161 2006-04-19  Derek Price  <derek@ximbiot.com>
7162             Eric Blake  <ebb9@byu.net>
7163
7164         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
7165         rather than "/full/path.h".  Update comment to match.  Shorten &
7166         generalize m4_translit call via AS_TR_CPP.
7167
7168 2006-04-19  Derek Price  <derek@ximbiot.com>
7169             Eric Blake  <ebb9@byu.net>
7170
7171         * lib/inttypes.h: Correct grammar in comment.
7172
7173 2006-04-18  Derek Price  <derek@ximbiot.com>
7174             Paul Eggert  <eggert@cs.ucla.edu>
7175
7176         * modules/inttypes: New file.
7177         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
7178
7179 2006-04-18  Derek Price  <derek@ximbiot.com>
7180             Paul Eggert  <eggert@cs.ucla.edu>
7181
7182         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
7183         New files.
7184
7185 2006-04-18  Derek Price  <derek@ximbiot.com>
7186             Paul Eggert  <eggert@cs.ucla.edu>
7187
7188         * lib/inttypes.h: New file.
7189         * lib/strtoimax.c: Assume <inttypes.h>.
7190
7191 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
7192
7193         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
7194         isn't mounted.  Problem reported by Kir Kolyshkin.
7195
7196 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
7197
7198         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
7199         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
7200         Derek R. Price.
7201         * lib/regex.h (RE_DUP_MAX): Update comment to match current
7202         implementation.
7203
7204 2006-04-12  Eric Blake  <ebb9@byu.net>
7205
7206         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
7207         is now done automatically by the corresponding Autoconf macro.
7208
7209 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
7210
7211         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
7212         time_r.h.
7213
7214 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7215
7216         Merge regex changes from libc, removing some of our
7217         POSIX-conformance changes that were rejected and redoing them in a
7218         less-intrusive way.
7219
7220         * lib/regcomp.c (re_compile_internal, init_dfa):
7221         Length arg is now size_t, not Idx.  All uses changed.
7222         (peek_token): Forward decl now says internal_function.
7223         (__re_error_msgid, __re_error_msgid_idx):
7224         Now static rather than extern with attribute_hidden.
7225         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
7226         For some reason libc prefers K&R style defns for external functions.
7227         (regerror) [!defined _LIBC]: Likewise.
7228         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
7229         (seek_collating_symbol_entry, lookup_collation_sequence_value):
7230         (build_range_exp, build_collating_symbol):
7231         Use K&R-style defn.
7232         (re_compile_fastmap): Use '\0' to memset, not 0.
7233         (utf8_sb_map): Make the calculations more obvious.
7234         (init_dfa, parse_bracket_exp, build_charclass_op):
7235         Call calloc and cast result, as glibc does.
7236         (init_word_char, fetch_token, peek_token, peek_token_bracket):
7237         (build_range_exp, build_collating_symbol):
7238         Now internal functions.
7239
7240         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
7241
7242         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
7243         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
7244         Don't depend on VMS; depend on __VMS instead, for POSIX
7245         namespace cleanness.
7246         (regoff_t): Define to ssize_t, not long int.
7247
7248         Remove the REG_ macros named below.  Instead, make the old names
7249         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
7250         __USE_GNU_REGEX.
7251         (REG_BACKSLASH_ESCAPE_IN_LISTS):
7252         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
7253         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
7254         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
7255         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
7256         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
7257         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
7258         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
7259         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
7260         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
7261         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
7262         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
7263         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
7264         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
7265         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
7266         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
7267         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
7268         (REG_NREGS):
7269         Remove.  All uses replaced by the old RE_* names.
7270         (RE_BACKSLASH_ESCAPE_IN_LISTS):
7271         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
7272         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
7273         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
7274         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
7275         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
7276         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
7277         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
7278         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
7279         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
7280         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
7281         Don't bother having these macros be independent of each others'
7282         values, since they no longer exist in the POSIX name space.
7283
7284         Rename the following member names back to their old names,
7285         unless !__USE_GNU_REGEX.  All uses changed back.
7286         (buffer): Renamed from re_buffer.
7287         (allocated): Renamed from re_allocated.
7288         (used): Renamed from re_used.
7289         (syntax): Renamed from re_syntax.
7290         (fastmap): Renamed from re_fastmap.
7291         (translate): Renamed from re_translate.
7292         (can_be_null): Renamed from re_can_be_null.
7293         (regs_allocated): Renamed from re_regs_allocated.
7294         (fastmap_accurate): Renamed from re_fastmap_accurate.
7295         (no_sub): Renamed from re_no_sub.
7296         (not_bol): Renamed from re_not_bol.
7297         (not_eol): Renamed from re_not_eol.
7298         (newline_anchor): Renamed from re_newline_anchor.
7299         (num_regs): Renamed from rm_num_regs.
7300         (start): Renamed from rm_start.
7301         (end): Renamed from rm_end.
7302
7303         (free_state): Move up a bit.
7304
7305         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
7306         #define to be empty.
7307         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
7308         when that is what is intended.
7309         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
7310         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
7311         (MAX): New macro.
7312         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
7313         All uses changed back to re_malloc, etc.  It's now the caller's
7314         responsibility to check for overflow; all callers changed.
7315         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
7316         (re_x2nrealloc): Remove.
7317         (free_state): Remove decl.
7318
7319         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
7320         (re_set_registers, re_exec):
7321         Use K&R-style defn.
7322
7323         2006-01-31  Roland McGrath  <roland@redhat.com>
7324
7325         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
7326         Reported by Mike Frysinger <vapier@gentoo.org>.
7327
7328         2006-01-15  Andreas Jaeger  <aj@suse.de>
7329
7330         [BZ #1950]
7331         * lib/regex_internal.c (re_string_reconstruct): Adjust for
7332         build_wcs_upper_buffer change.
7333         (build_wcs_upper_buffer): Change return type.
7334
7335         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
7336
7337         * lib/regex_internal.h: Include <stdint.h> if available.
7338
7339         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
7340
7341         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
7342
7343         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7344
7345         * lib/regcomp.c: Adjust for changed secondary hash function.
7346
7347         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
7348
7349         * lib/regex.h: Pretty printing.
7350         Clean up namespace a bit.
7351
7352         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
7353
7354         * lib/regexec.c (update_cur_sifted_state, check_arrival,
7355         check_arrival_add_next_nodes): Avoid using uninitialized variable.
7356
7357         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7358                     Ulrich Drepper  <drepper@redhat.com>
7359
7360         [BZ #1302]
7361         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
7362         changed.
7363         (bitset_word_t): Renamed from bitset_word.  All uses changed.
7364
7365         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
7366
7367         [BZ #281]
7368         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
7369         * lib/regcomp.c: Remove unnecessary uses of
7370         unsigned RE_TRANSLATE_TYPE.
7371         * lib/regex_internal.h: Likewise.
7372         * lib/regex_internal.c: Likewise.
7373         * lib/regexec.c: Likewise.
7374         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
7375
7376         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
7377
7378         * lib/regexec.c (find_recover_state): Remove unnecessary
7379         initialization.
7380         (transit_state_bkref): Make DFA a const pointer.
7381         (get_subexp): Likewise.
7382         (check_arrival): Likewise.
7383         (update_cur_sifted_state): Likewise.
7384         (re_search_internal): Likewise.
7385         (prune_impossible_nodes): Likewise.
7386         (acquire_init_state_context): Likewise.
7387         (proceed_next_node): Likewise.
7388         (set_regs): Likewise.
7389         (free_fail_stack_return): Likewise.
7390         (check_arrival_expand_ecl): Mark DFA parameter as const.
7391         (check_arrival_expand_ecl_sub): Likewise.
7392         (check_subexp_limits): Likewise.
7393         (sub_epsilon_src_nodes):  Likewise.
7394         (add_epsilon_src_nodes):  Likewise.
7395         (merge_state_array): Likewise.
7396         (update_regs): Likewise.
7397         (build_trtable): Likewise.
7398         (sift_states_backward): Mark MCTX parameter as const.
7399         (build_sifted_states): Likewise.
7400         (update_cur_sifted_state): Likewise.
7401         (sift_states_mkref): Likewise.
7402         (check_arrival_expand_ecl): Mark eclosure as const.
7403         (check_dst_limits_calc_pos_1): Likewise.
7404         * lib/regex_internal.h (re_match_context_t): Make dfa a const
7405         pointer.
7406
7407         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
7408
7409         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
7410         (transit_state_sb): Likewise.
7411         (transit_state_mb): Likewise.
7412         (sift_states_iter_mb): Likewise.
7413         (check_arrival_add_next_nodes): Likewise.
7414         (check_node_accept_bytes): Change first parameter to pointer-to-const.
7415         [_LIBC] (re_search_2_stub): Use mempcpy.
7416
7417         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
7418         mbrtowc for very simple UTF-8 case.
7419
7420         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
7421         a pointer-to-const.
7422         (re_acquire_state_context): Likewise.
7423         * lib/regex_internal.h: Adjust prototypes.
7424
7425         * lib/regex.c: Prevent using C++ compilers.
7426
7427         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
7428         (re_acquire_state_context): Likewise.
7429
7430 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7431
7432         * modules/regex (Depends-on): Add ssize_t.
7433
7434 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7435
7436         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
7437         translation table.
7438
7439 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7440
7441         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
7442
7443 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
7444             Bruno Haible  <bruno@clisp.org>
7445
7446         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
7447         <sys/types.h> and <inttypes.h>.
7448
7449 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7450
7451         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
7452         `__error_t_defined', so argp.h will not typedef the former.
7453
7454 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
7455
7456         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
7457         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
7458         glibc names.  Even if glibc is changed to conform to POSIX, the
7459         traditional names will be available anyway, since regex depends on
7460         the extensions module.  Also, fix a longstanding typo in the
7461         implementation of Spencer ERE test #75 from grep 2.3.  Problems
7462         reported by Emanuele Giaquinta.  Also, change sense of cached
7463         variable, so that the message makes sense.
7464
7465 2006-03-24  Simon Josefsson  <jas@extundo.com>
7466
7467         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
7468         including some doc fixes.
7469         (base64_encode_alloc): Fix +1 bug on allocation failures.
7470
7471 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7472
7473         * lib/base64.c (base64_encode): Do not read past end of array with
7474         unsanitized input on systems with CHAR_BIT > 8.
7475
7476 2006-03-24  Eric Blake  <ebb9@byu.net>
7477
7478         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
7479
7480 2006-03-22  Karl Berry  <karl@gnu.org>
7481
7482         * config/srclist.txt (*setenv.[ch]): get from coreutils.
7483         * config/srclistvars.sh (COREUTILS): new var.
7484
7485 2006-03-17  Jim Meyering  <jim@meyering.net>
7486
7487         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
7488         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
7489
7490 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7491
7492         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
7493         no longer needs it.  Instead, check that regoff_t is as least
7494         as wide as ptrdiff_t.
7495
7496         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
7497         so that our regex.h stays compatible with the installed regex.
7498         This is helpful for installers who configure --without-included-regex.
7499         Problem reported by Emanuele Giaquinta.
7500
7501 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7502
7503         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
7504         Typedef to long int, not to off_, as POSIX will likely change
7505         in that direction.
7506
7507 2006-03-15  Eric Blake  <ebb9@byu.net>
7508
7509         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
7510
7511 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7512
7513         * lib/argp-help.c (validate_uparams): Fix typo
7514         * lib/argp-parse.c (argp_default_options): Consistently begin help
7515         messages with a lowercase letter.
7516
7517 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
7518
7519         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
7520         overrun buffers and shouldn't be used (much as gets shouldn't be
7521         used).
7522         * lib/time_r.c (asctime_r, ctime_r): Likewise.
7523
7524 2006-03-08  Simon Josefsson  <jas@extundo.com>
7525
7526         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
7527         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7528
7529 2006-03-08  Simon Josefsson  <jas@extundo.com>
7530
7531         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
7532         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7533
7534 2006-03-08  Simon Josefsson  <jas@extundo.com>
7535
7536         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
7537         signal that configure disabled the device.
7538
7539 2006-03-08  Simon Josefsson  <jas@extundo.com>
7540
7541         * build-aux/maint.mk: Fix refresh-po, to handle no translated
7542         languages.
7543
7544 2006-03-07  Simon Josefsson  <jas@extundo.com>
7545
7546         * modules/getopt (Depends-on): Add unistd.
7547
7548         * modules/unistd: New file.
7549
7550 2006-03-07  Simon Josefsson  <jas@extundo.com>
7551
7552         * modules/gc-random: New file.
7553
7554 2006-03-07  Simon Josefsson  <jas@extundo.com>
7555
7556         * m4/unistd_h.m4: New file.
7557
7558 2006-03-07  Simon Josefsson  <jas@extundo.com>
7559
7560         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
7561         test to be side-effect free by storing the result in the cache
7562         variable gl_cv_lib_readline, and moving the assignment of
7563         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
7564         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7565
7566 2006-03-07  Simon Josefsson  <jas@extundo.com>
7567
7568         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
7569         error on missing devices (the functions will return an error).
7570
7571         * m4/gc.m4: Move random stuff to gc-random.m4
7572
7573 2006-03-07  Simon Josefsson  <jas@extundo.com>
7574
7575         * lib/unistd_.h: New file.
7576
7577 2006-03-07  Simon Josefsson  <jas@extundo.com>
7578
7579         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
7580
7581 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7582
7583         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
7584         Problem reported by Juan Manuel Guerrero.
7585
7586 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7587
7588         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
7589         the unistd module.
7590         * lib/getlogin_r.c: Likewise.
7591         * lib/getlogin_r.h: Likewise.
7592         * lib/glob.c: Likewise.
7593         * lib/pagealign_alloc.c: Likewise.
7594         * lib/unistd_.h: Remove; no longer needed.
7595
7596 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7597
7598         * MODULES.html.sh (Support for systems lacking POSIX:2001):
7599         Add unistd.
7600         * modules/c-stack (Depends-on): Add unistd.
7601         * modules/getlogin_r: Likewise.
7602         * modules/glob: Likewise.
7603         * modules/pagealign_alloc: Likewise.
7604         * modules/unistd (Files): Remove lib/unistd_.h.
7605         (EXTRA_DIST): Remove.
7606         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
7607         need unistd_.h.
7608         (MOSTLYCLEANFILES): Remove unistd.h-t.
7609
7610 2006-03-03  Simon Josefsson  <jas@extundo.com>
7611
7612         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
7613
7614 2006-03-03  Simon Josefsson  <jas@extundo.com>
7615
7616         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
7617         libidn and bison.
7618
7619 2006-03-03  Simon Josefsson  <jas@extundo.com>
7620
7621         * build-aux/maint.mk: Add indent target.
7622
7623 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
7624
7625         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
7626         our replacement poll.h in any case, to avoid a differing
7627         declaration from a system header.  Seen on AIX.
7628
7629 2006-03-01  Simon Josefsson  <jas@extundo.com>
7630
7631         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
7632         <kasal@ucw.cz>.
7633
7634 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7635
7636         * modules/gettime (Depends-on): Add extensions module.
7637         * modules/nanosleep (Depends-on): Likewise.
7638         * modules/settime (Depends-on): Likewise.
7639
7640 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7641
7642         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
7643         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
7644         pedantically.
7645         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7646         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
7647
7648         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
7649         not "==".  Reported by Ralf Wildenhues.
7650
7651 2006-03-01  Karl Berry  <karl@gnu.org>
7652
7653         * doc/Copyright/request-*: new files, synced from gnuorg.
7654
7655 2006-03-01  Karl Berry  <karl@gnu.org>
7656
7657         * config/srclist.txt (Copyright/*): new entries.
7658
7659 2006-02-28  Simon Josefsson  <jas@extundo.com>
7660
7661         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
7662
7663 2006-02-27  Simon Josefsson  <jas@extundo.com>
7664
7665         * lib/base64.h: Indent #define's.  From Jim Meyering
7666         <jim@meyering.net>.
7667
7668 2006-02-27  Jim Meyering  <jim@meyering.net>
7669
7670         Revert the change of 2006-02-24, so these files can continue
7671         to be sync'd from gettext.
7672         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
7673         of `config.h'.
7674
7675 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
7676
7677         * modules/intprops: New file.
7678         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7679         Add intprops.
7680         * modules/getloadavg (Files): Remove lib/intprops.h.
7681         (Depends-on): Add intprops.
7682         * modules/human: Likewise.
7683         * modules/inttostr: Likewise.
7684         * modules/openat: Likewise.
7685         * modules/sig2str: Likewise.
7686         * modules/userspec: Likewise.
7687         * modules/utimecmp: Likewise.
7688         * modules/xnanosleep: Likewise.
7689         * modules/xstrtol: Likewise.
7690
7691 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
7692
7693         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
7694         * modules/lock-tests (TESTS): Use $(EXEEXT).
7695         * modules/tls-tests: Likewise.
7696         * modules/argp-tests: Likewise.
7697         (check_PROGRAMS): New var, replacing...
7698         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
7699
7700 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7701
7702         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
7703         `config.h'.
7704
7705 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
7706
7707         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
7708
7709 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7710
7711         Sync from coreutils.
7712         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
7713         gl_CHDIR_SAFER.
7714
7715 2006-02-22  Jim Meyering  <jim@meyering.net>
7716
7717         Sync from coreutils.
7718         * m4/chdir-safer.m4: New file.
7719
7720 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
7721
7722         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
7723         AT_FDCWD exceeds INT_MAX.
7724         * lib/openat.h (AT_FDCWD): Likewise.
7725
7726 2006-02-17  Eric Blake  <address@hidden>
7727
7728         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
7729
7730 2006-02-16  Simon Josefsson  <jas@extundo.com>
7731
7732         * modules/getaddrinfo (Depends-on): Add sys_socket.
7733
7734 2006-02-15  Simon Josefsson  <jas@extundo.com>
7735
7736         * build-aux/maint.mk: Add dsyntax-check rule.
7737
7738 2006-02-15  Eric Blake  <ebb9@byu.net>
7739
7740         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
7741         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
7742         'present but cannot compile' warnings on cygwin.
7743         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
7744         use ws2tcpip.h if sys/socket.h works.
7745         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
7746         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
7747
7748 2006-02-14  Simon Josefsson  <jas@extundo.com>
7749
7750         * modules/maintainer-makefile (Files): Rename.
7751
7752         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
7753         and (the local) Makefile.cfg to maint-cfg.mk.
7754
7755         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
7756         to the latter.
7757
7758         * modules/maintainer-makefile: New module.
7759
7760         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
7761         severaly stripped to make it possible to build it up from scratch
7762         with reliable tests.
7763
7764         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
7765         fixes to permit overriding the default actions when configure and
7766         makefile are not available.
7767
7768 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
7769
7770         Sync from coreutils.
7771         * modules/lstat (Depends-on): Don't depend on xalloc.
7772         (License): Change from GPL to LGPL, since this is now simply a
7773         replacement for a libc function.
7774
7775 2006-02-14  Jim Meyering  <jim@meyering.net>
7776
7777         Sync from coreutils.
7778
7779         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
7780         failure on deficient systems, and simplify gnulib lgpl dependencies.
7781         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
7782         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
7783
7784         * lib/xalloc-die.c: Remove unused definition of N_.
7785
7786 2006-02-14  Jim Meyering  <jim@meyering.net>
7787
7788         Sync from coreutils.
7789         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
7790         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
7791         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
7792         double-quote uses of that variable, to accommodate the rare case in
7793         which getmntent is available in none of the libraries checked.  This
7794         happens at least on FreeBSD 5.0.
7795
7796 2006-02-13  Simon Josefsson  <jas@extundo.com>
7797
7798         * gnulib-tool (Usage): Fix --import, from
7799         karl@freefriends.org (Karl Berry).
7800
7801 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7802
7803         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
7804
7805 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
7806
7807         * lib/argp-namefrob.h: Restore changes accidentally lost during the
7808         "autoupdate" on 2005-12-12.
7809
7810 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7811
7812         * modules/closeout (Depends-on): Remove atexit.
7813
7814 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7815
7816         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
7817         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
7818
7819 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
7820
7821         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
7822         __EXTENSIONS__ if this causes compilation to fail.  Problem
7823         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
7824         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
7825
7826 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
7827
7828         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
7829         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
7830         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
7831         All uses changed.
7832
7833 2006-01-26  Simon Josefsson  <jas@extundo.com>
7834
7835         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
7836         prototype is visible on mingw32.
7837
7838         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
7839         for mingw32.
7840
7841         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
7842         mingw32).
7843
7844 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7845
7846         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
7847         attempt to open for write; this always fails, at least on POSIX
7848         hosts.  This reinstates the 2006-01-09 change, which was
7849         inadvertently removed.
7850
7851 2006-01-26  Bruno Haible  <bruno@clisp.org>
7852
7853         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
7854         Reported by Paul Eggert.
7855
7856 2006-01-26  Bruno Haible  <bruno@clisp.org>
7857             Paul Eggert  <eggert@cs.ucla.edu>
7858
7859         * lib/stdbool_.h (_Bool)
7860         [(! (defined __cplusplus || defined __BEOS__)
7861           && !defined __GNUC__
7862           && !(defined __HP_cc || defined __xlc__
7863                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
7864                || defined __sgi))]:
7865         #define to signed char in these cases too; this simplifies
7866         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
7867         etc., separately) and makes it more conservative.
7868
7869 2006-01-25  Simon Josefsson  <jas@extundo.com>
7870
7871         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
7872         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
7873         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
7874
7875 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7876
7877         * lib/argp-namefrob.h: Bugfix. Remove stray #
7878
7879 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
7880
7881         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
7882         so that we test the test.
7883         Check for yet another HP-UX cc bug involving *bool |= bool.
7884
7885 2006-01-25  Karl Berry  <karl@gnu.org>
7886
7887         * config/srclist.txt (vasnprintf.c): sync lost.
7888
7889 2006-01-25  Jim Meyering  <jim@meyering.net>
7890
7891         Sync from the stable (b5) branch of coreutils:
7892
7893         * lib/fts.c (fts_children): Don't let close() clobber errno from
7894         failed fchdir().
7895
7896         * lib/fts.c (fts_stat): When following a symlink-to-directory,
7897         don't necessarily interpret stat-fails+lstat-succeeds as indicating
7898         a dangling symlink.  That can also happen at least for ELOOP.
7899         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
7900         FYI, this bug predates the inclusion of fts.c in coreutils.
7901
7902         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
7903         in their own block, so pre-c99 compilers don't object.
7904
7905         Avoid the double-free (first in fts_read, second in fts_close) that
7906         would occur when an `active' directory is made inaccessible (e.g.,
7907         via chmod a-x) during a traversal.
7908         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
7909         before returning.  Reproduce this failure by
7910         mkdir -p a/b; cd a; chmod a-x . b
7911         Reported by Stavros Passas.
7912
7913 2006-01-25  Jim Meyering  <jim@meyering.net>
7914
7915         * lib/fileblocks.c: Remove more useless parentheses.
7916         * lib/readutmp.h: Likewise.
7917
7918 2006-01-25  Bruno Haible  <bruno@clisp.org>
7919
7920         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
7921         warnings.
7922         Reported by Paul Eggert.
7923
7924 2006-01-25  Bruno Haible  <bruno@clisp.org>
7925
7926         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
7927         rid of a trap command. For Solaris sh.
7928         Reported by Mark D. Baushke <mdb@gnu.org>.
7929
7930 2006-01-24  Simon Josefsson  <jas@extundo.com>
7931
7932         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
7933         Bruno.
7934
7935 2006-01-24  Karl Berry  <karl@gnu.org>
7936
7937         * config/srclist.txt (argp-namefrob.h): sync lost.
7938
7939 2006-01-24  Jim Meyering  <jim@meyering.net>
7940
7941         * modules/openat (Files): Add lib/intprops.h.
7942         From Mark D. Baushke.
7943
7944 2006-01-24  Jim Meyering  <jim@meyering.net>
7945
7946         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
7947         Reported by Mark D. Baushke.
7948
7949 2006-01-24  Jim Meyering  <jim@meyering.net>
7950
7951         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
7952
7953 2006-01-24  Bruno Haible  <bruno@clisp.org>
7954
7955         * modules/strnlen (Maintainer): Change from glibc to all.
7956
7957 2006-01-24  Bruno Haible  <bruno@clisp.org>
7958
7959         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
7960         Patch by Paul Eggert.
7961
7962 2006-01-24  Bruno Haible  <bruno@clisp.org>
7963
7964         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
7965         already has it.
7966         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
7967         2005-11-26.
7968
7969         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
7970         'signed char' to avoid problems with the built-in _Bool type.
7971         Reported by Paul Eggert on 2005-11-26.
7972
7973 2006-01-24  Bruno Haible  <bruno@clisp.org>
7974
7975         * gnulib-tool (func_import): Avoid constructing complicated sed
7976         expressions inside backquote.
7977         Report and solution by Mark D. Baushke <mdb@gnu.org>.
7978
7979 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
7980
7981         These changes imported from libc.
7982         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
7983         test and two separate function calls.
7984         * lib/strndup.c (__strndup): Add libc_hidden_def.
7985
7986 2006-01-23  Simon Josefsson  <jas@extundo.com>
7987
7988         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
7989         Remove the test_*_SOURCES variable: automake infers it by default.
7990         * modules/tls-tests: Likewise.
7991
7992 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7993
7994         Work around porting bugs reported by Dieter in
7995         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
7996         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
7997         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
7998         Include "getopt.h" first, to check interface.
7999         (getenv): Declare only if defined HAVE_DECL_GETENV &&
8000         !HAVE_DECL_GETENV.
8001         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
8002         (__strndup): Revert to K&R-style function dfns, the glibc style.
8003         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
8004         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
8005         Include strnlen.h first, to get prototype properly.
8006         (strnlen): Renamed from __strnlen.
8007         Remove weak alias.
8008
8009 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8010
8011         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
8012
8013 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8014
8015         * config/srclist.txt: Adjust to reflect glibc reorganization.
8016         This affects only comments.
8017
8018 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
8019
8020          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
8021          Reported by Bruce Korb <bkorb@gnu.org>.
8022
8023 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
8024
8025         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
8026         to pacify gcc -Wswitch-default.
8027
8028 2006-01-22  Bruno Haible  <bruno@clisp.org>
8029
8030         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
8031         temporary buffer for sprintf, take into account the precision also
8032         for 'd', 'i', 'u', 'o', 'x', 'X'.
8033
8034 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8035
8036         * modules/argp-tests: New module
8037         * tests/test-argp.c: New file
8038         * tests/test-argp-2.sh: New file
8039
8040 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8041
8042         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
8043         (__argp_base_name): Removed
8044         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
8045         typo.
8046         (__argp_base_name): Provide macro definition or extern declaration
8047         depending on the configuration
8048
8049 2006-01-20  Simon Josefsson  <jas@extundo.com>
8050
8051         * modules/inet_ntop (Depends-on): Depend on sys_socket.
8052
8053 2006-01-20  Simon Josefsson  <jas@extundo.com>
8054
8055         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
8056
8057 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
8058
8059         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
8060         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
8061         Suggested by Bruno Haible.
8062
8063 2006-01-20  Karl Berry  <karl@gnu.org>
8064
8065         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
8066         until changes propagate, I guess.
8067
8068 2006-01-19  Simon Josefsson  <jas@extundo.com>
8069
8070         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
8071
8072 2006-01-19  Simon Josefsson  <jas@extundo.com>
8073
8074         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
8075
8076 2006-01-19  Simon Josefsson  <jas@extundo.com>
8077
8078         * gnulib-tool: Set check_PROGRAMS.
8079
8080         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8081         modules/des-tests, modules/gc-arcfour-tests,
8082         modules/gc-arctwo-tests, modules/gc-des-tests,
8083         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8084         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8085         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8086         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8087         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8088         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
8089         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
8090         test_*_SOURCES.
8091
8092 2006-01-18  Simon Josefsson  <jas@extundo.com>
8093
8094         * modules/socklen (Depends-on): Depend on sys_socket.
8095
8096 2006-01-18  Simon Josefsson  <jas@extundo.com>
8097
8098         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8099         modules/des-tests, modules/gc-arcfour-tests,
8100         modules/gc-arctwo-tests, modules/gc-des-tests,
8101         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8102         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8103         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8104         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8105         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8106         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
8107         $(EXEEXT) to automake TESTS variable, for mingw32.
8108
8109 2006-01-17  Simon Josefsson  <jas@extundo.com>
8110
8111         * modules/socklen (Include): Need sys/socket.h.
8112
8113 2006-01-17  Bruno Haible  <bruno@clisp.org>
8114
8115         * modules/ssize_t (Include): Add <sys/types.h>.
8116
8117 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
8118
8119         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
8120         it's not portable and it doesn't work with cross-compiles.
8121         Problem reported by Bruno Haible.  Fix missing-$ typo in
8122         'test "gl_cv_ignore_unused_libraries" ...' that prevented
8123         -zignore from being used with Sun's C compiler.
8124
8125 2006-01-12  Simon Josefsson  <jas@extundo.com>
8126
8127         * lib/base64.c: Fix warning, reported by Bruno Haible
8128         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
8129
8130 2006-01-12  Bruno Haible  <bruno@clisp.org>
8131
8132         * modules/ldd: New file.
8133         * build-aux/ldd.sh.in: New file.
8134         * MODULES.html.sh (Support for building libraries and executables): Add
8135         ldd.
8136
8137 2006-01-12  Bruno Haible  <bruno@clisp.org>
8138
8139         * m4/ldd.m4: New file.
8140
8141 2006-01-12  Bruno Haible  <bruno@clisp.org>
8142
8143         * gnulib-tool (func_import, func_create_testdir): Don't go into an
8144         endless loop while replacing $auxdir with build-aux.
8145
8146 2006-01-11  Simon Josefsson  <jas@extundo.com>
8147
8148         * lib/stdint_.h (SIZE_MAX): Add missing (.
8149
8150 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
8151
8152         Sync from coreutils.
8153         * lib/md5.c: Fix commentary typos.
8154         (alignof, UNALIGNED_P): No need for a GCC-specific version.
8155         * lib/md5.h (__attribute__): Remove; unused.
8156         * lib/sha1.c: Fix commentary to match md5 better.
8157         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
8158         so that we don't need to worry about alignment.  All uses changed.
8159         This merges the 2005-10-28 md5 change into sha1.
8160
8161 2006-01-11  Jim Meyering  <jim@meyering.net>
8162
8163         Sync from coreutils.
8164         * lib/md5.c (OP): Fix spacing.
8165
8166 2006-01-11  Bruno Haible  <bruno@clisp.org>
8167
8168         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8169         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
8170         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
8171
8172 2006-01-11  Bruno Haible  <bruno@clisp.org>
8173
8174         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8175         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
8176         the "early" section as well.
8177
8178 2006-01-11  Bruno Haible  <bruno@clisp.org>
8179
8180         Avoid "ar: no archive members specified" error on MacOS X.
8181         * gnulib-tool (func_modules_add_dummy): New function.
8182         (func_import, func_create_testdir): Invoke it.
8183
8184 2006-01-11  Bruno Haible  <bruno@clisp.org>
8185
8186         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
8187         with $auxdir in AC_CONFIG_FILES statements.
8188
8189 2006-01-11  Bruno Haible  <bruno@clisp.org>
8190
8191         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8192         Initialize also noinst_HEADERS to empty.
8193
8194 2006-01-11  Bruno Haible  <bruno@clisp.org>
8195
8196         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
8197         variables.
8198         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
8199         autoreconf.
8200
8201 2006-01-11  Bruno Haible  <bruno@clisp.org>
8202
8203         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
8204         overridable by the user.
8205         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8206
8207 2006-01-10  Simon Josefsson  <jas@extundo.com>
8208
8209         * modules/sys_socket: New file.
8210
8211 2006-01-10  Simon Josefsson  <jas@extundo.com>
8212
8213         * m4/sys_socket_h.m4: New file.
8214
8215 2006-01-10  Simon Josefsson  <jas@extundo.com>
8216
8217         * lib/socket_.h: New file.
8218
8219 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8220
8221         * modules/readutmp (Maintainer): Add myself.
8222
8223 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8224
8225         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
8226         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
8227         People who are still concerned with buggy memcmp implementations
8228         can invoke gl_FUNC_MEMCMP themselves.
8229
8230 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8231
8232         * lib/regex_internal.h (BITSET_WORD_BITS):
8233         Work around a bug in 64-bit PGC (before version 6.1-2), where the
8234         preprocessor mishandles large unsigned values as if they were signed.
8235         Problem reported by Claudio Fontana in
8236         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
8237
8238 2006-01-10  Jim Meyering  <jim@meyering.net>
8239
8240         Avoid the double-free (first in fts_read, second in fts_close) that
8241         would occur when an `active' directory is made inaccessible (e.g.,
8242         via chmod a-x) during a traversal.
8243         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8244         before returning.  Reproduce this failure by
8245         mkdir -p a/b; cd a; chmod a-x . b
8246         Reported by Stavros Passas.
8247
8248         Sync from coreutils.
8249         * lib/sha1.c: Tweak grammar in a comment.
8250
8251 2006-01-10  Jim Meyering  <jim@meyering.net>
8252
8253         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
8254         Patch by Joerg Sonnenberger.
8255
8256 2006-01-10  Bruno Haible  <bruno@clisp.org>
8257
8258         * modules/readutmp: Depend on module free.
8259         * modules/strtok_r: Depend on module restrict.
8260
8261 2006-01-10  Bruno Haible  <bruno@clisp.org>
8262
8263         * modules/gettext (configure.ac): Add an invocation of
8264         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
8265
8266 2006-01-10  Bruno Haible  <bruno@clisp.org>
8267
8268         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
8269         Reported by Werner Lemberg <wl@gnu.org>.
8270
8271 2006-01-10  Bruno Haible  <bruno@clisp.org>
8272
8273         * lib/localcharset.c: Update from GNU gettext.
8274
8275 2006-01-10  Bruno Haible  <bruno@clisp.org>
8276
8277         * lib/argp.h (__const): Remove macro. Use const instead.
8278         * lib/argp-fmtstream.h (__const): Likewise.
8279         * lib/glob_.h (__const): Remove macro.
8280         * lib/glob-libc.h: Use const instead of __const.
8281
8282 2006-01-10  Bruno Haible  <bruno@clisp.org>
8283
8284         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
8285         variable.
8286         Needed to avoid an automake error regarding the 'gettext' module.
8287
8288 2006-01-09  Simon Josefsson  <jas@extundo.com>
8289
8290         * modules/inet_ntop (Depends-on): Add restrict.
8291
8292 2006-01-09  Simon Josefsson  <jas@extundo.com>
8293
8294         * modules/gc-rijndael-tests (License): Put under LGPL.
8295
8296         * modules/gc-des-tests (License): Likewise.
8297
8298         * modules/gc-arcfour-tests (License): Likewise.
8299
8300         * modules/gc-arctwo-tests (License): Likewise.
8301
8302         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
8303
8304         * modules/gc-hmac-sha1-tests (Files): Likewise.
8305
8306         * modules/gc-hmac-md5-tests (License): Likewise.
8307
8308         * modules/gc-sha1-tests (License): Likewise.
8309
8310         * modules/gc-md5-tests (License): Likewise.
8311
8312         * modules/gc-md4-tests (License): Likewise.
8313
8314         * modules/gc-md2-tests (License): Likewise.
8315
8316         * modules/gc-tests (License): Likewise.
8317
8318         * modules/des-tests (License): Likewise.
8319
8320         * modules/md4-tests (License): Likewise.
8321
8322         * modules/md2-tests (License): Likewise.
8323
8324 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8325
8326         Sync from coreutils:
8327
8328         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
8329         * modules/lib-ignore: New file.
8330         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
8331         chdir-safer.m4, lchmod.m4.
8332         * modules/openat: Add mkdirat.c, openat-priv.h.
8333
8334 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8335
8336         Sync from coreutils.
8337         * m4/lib-ignore.m4: New file.
8338         * m4/lchmod.m4: New file.
8339
8340 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8341
8342         Sync from coreutils.
8343         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
8344         for write access: POSIX says that must fail.
8345         * lib/fts.c (diropen): Likewise.
8346         * lib/save-cwd.c (save_cwd): Likewise.
8347         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
8348         well, for minor improvements on hosts that lack O_DIRECTORY.
8349         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
8350         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
8351         Fall back on chown if open failed with EACCES.
8352
8353         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
8354         Report an error at compile-time if only a 1-second nominal clock
8355         resolution is found.
8356
8357         * lib/lchmod.h: New file.
8358         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
8359         (make_dir_parents): Use lchown rather than chown, and
8360         lchmod rather than chmod.
8361
8362         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
8363         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
8364         "proc" reported by n0dalus.
8365
8366         * lib/mountlist.c: Include <limits.h>.
8367         (dev_from_mount_options)
8368         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
8369         New function.  It no longer assumes "dev=" has the System V meaning
8370         on Linux (since it doesn't).  It also parses "dev=" more carefully.
8371         (read_file_system_list)
8372         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
8373         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
8374         dev= in that case.
8375
8376         * lib/posixtm.h (PDS_PRE_2000): New macro.
8377         * lib/posixtm.c (year): Arg is now syntax_bits rather than
8378         allow_century.  All usages changed.  Reject dates outside the range
8379         1969-1999 if PDS_PRE_2000 is used.
8380
8381 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8382
8383         Sync from coreutils.
8384         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
8385         (Time of day items): Mention the possibility of leap seconds.
8386         Problem reported by Dr. David Alan Gilbert.
8387
8388 2006-01-09  Jim Meyering  <jim@meyering.net>
8389
8390         Sync from coreutils.
8391
8392         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
8393
8394         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
8395
8396         * lib/modechange.c (mode_compile): Reject an invalid mode string
8397         that starts with an octal digit.  From Andreas Gruenbacher.
8398
8399         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
8400         and dup to open_safer and dup_safer, respectively.
8401         (openat_permissive): Fix typo in comment.
8402
8403         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
8404         "gettext.h"; either no longer needed or are guaranteed by openat.h.
8405         (_): Remove; no longer needed.
8406         (openat): Renamed from rpl_openat; no need for rpl_openat
8407         since openat.h renames openat for us.
8408         Replace most of the body with a call to openat_permissive,
8409         to avoid duplicate code.
8410         Port to (probably hypothetical) environments were mode_t is
8411         wider than int.
8412         (openat_permissive): Require mode arg, so that we can check
8413         types better.  Put it just after flags.  Change cwd failure
8414         indicator from pointer-to-bool to pointer-to-errno-value.
8415         All callers changed.
8416         Invoke openat_save_fail and/or openat_restore_fail if
8417         cwd_errno is null, so that openat can call us.
8418         (openat_permissive, fdopendir, fstatat, unlinkat):
8419         Simplify errno handling to avoid some duplicate code,
8420         as it's OK to set errno on success.
8421         * lib/openat.h: Revamp code so that function macros depend on
8422         __OPENAT_PREFIX only, not also on AT_FDCWD.
8423         (openat_ro): Remove.  Caller changed to use openat_permissive.
8424         (openat_permissive): Now a macro, if not a function.
8425         (openat_restore_fail, openat_save_fail): Now always functions,
8426         since mkdirat needs them even if __OPENAT_PREFIX is defined.
8427
8428         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
8429         and openat.c.
8430         * lib/mkdirat.c: Include openat-priv.h.
8431         Remove definitions of macros defined therein.
8432         * lib/openat.c: Likewise.
8433
8434         * lib/mkdirat.c (mkdirat): New file and function.
8435         * lib/openat.h (mkdirat): Declare.
8436
8437         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
8438
8439         * lib/openat.h (openat_permissive): Declare.
8440         (openat_ro): Define.
8441
8442         * lib/openat.c (EXPECTED_ERRNO): New macro.
8443         (openat_permissive): New function -- used in remove.c rewrite.
8444         (all functions): Set errno just before returning, only if there
8445         was an actual failure.
8446         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
8447
8448         Emulate openat-family functions using Linux's procfs, if possible.
8449         Idea and some code based on Ulrich Drepper's glibc changes.
8450
8451         * lib/openat.c: (BUILD_PROC_NAME): New macro.
8452         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
8453         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
8454         before falling back on save_cwd and restore_cwd.
8455         (fdopendir, fstatat, unlinkat): Likewise.
8456
8457         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
8458         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
8459
8460         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
8461         as second argument to va_arg.  Otherwise, some versions of gcc
8462         warn that `if this code is reached, the program will abort'.
8463
8464 2006-01-09  Jim Meyering  <jim@meyering.net>
8465
8466         Sync from coreutils.
8467         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
8468         Require openat-priv.h.
8469
8470 2006-01-09  Bruno Haible  <bruno@clisp.org>
8471
8472         * modules/strnlen (Include): Use strnlen.h.
8473
8474 2006-01-09  Bruno Haible  <bruno@clisp.org>
8475
8476         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
8477
8478 2006-01-09  Bruno Haible  <bruno@clisp.org>
8479
8480         * lib/sysexit_.h (EX_OK): New macro.
8481         Suggested by Martin Lambers <marlam@marlam.de>.
8482
8483 2006-01-09  Bruno Haible  <bruno@clisp.org>
8484
8485         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
8486         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
8487
8488 2006-01-09  Bruno Haible  <bruno@clisp.org>
8489
8490         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
8491         numbers.
8492
8493 2006-01-09  Bruno Haible  <bruno@clisp.org>
8494
8495         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
8496         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
8497         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
8498         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
8499
8500 2006-01-09  Bruno Haible  <bruno@clisp.org>
8501
8502         * build-aux/javacomp.sh.in: New file, moved from lib/.
8503         * modules/javacomp-script (Files): Update.
8504         (configure.ac): Add AC_CONFIG_FILES invocation.
8505         (EXTRA_DIST): Remove variable.
8506
8507         * build-aux/javaexec.sh.in: New file, moved from lib/.
8508         * modules/javaexec (Files): Update.
8509         (configure.ac): Add AC_CONFIG_FILES invocation.
8510         (EXTRA_DIST): Remove javaexec.sh.in.
8511
8512         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
8513         * modules/csharpcomp-script (Files): Update.
8514         (configure.ac): Add AC_CONFIG_FILES invocation.
8515         (EXTRA_DIST): Remove variable.
8516
8517         * build-aux/csharpexec.sh.in: New file, moved from lib/.
8518         * modules/csharpexec (Files): Update.
8519         (configure.ac): Add AC_CONFIG_FILES invocation.
8520         (EXTRA_DIST): Remove csharpexec.sh.in.
8521
8522 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8523
8524         Sync from coreutils.
8525
8526         Add POSIX ACL support
8527         * lib/acl.h (copy_acl, set_acl): Add declarations.
8528         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
8529         systems other than Linux.
8530         (chmod_or_fchmod): New function: use fchmod when possible,
8531         and chmod otherwise.
8532         (file_has_acl): Add a POSIX ACL implementation, with a
8533         Linux-specific subcase.
8534         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
8535         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
8536         acls are unsupported.
8537         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
8538         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
8539         are unsupported.
8540
8541 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8542
8543         Sync from coreutils.
8544         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
8545
8546 2006-01-07  Bruno Haible  <bruno@clisp.org>
8547
8548         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
8549         gl_EARLY.
8550
8551 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8552
8553         * lib/strftime.c (tzname): Don't declare if it is already #defined.
8554         Problem reported for Mingw by Mark Junker.
8555
8556 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8557
8558         * README: Gnulib normally doesn't generate a tarball.
8559
8560 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
8561
8562         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
8563         long int, not int, for nanosecond counts, so that people who are
8564         used to POSIX struct timespec won't be surprised.  Reported by Jim
8565         Meyering.
8566
8567 2005-12-28  Bruno Haible  <bruno@clisp.org>
8568
8569         * build-aux/config.rpath: Update from GNU gettext.
8570
8571 2005-12-16  Jim Meyering  <jim@meyering.net>
8572
8573         * modules/fprintftime: New module.
8574         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
8575
8576 2005-12-16  Jim Meyering  <jim@meyering.net>
8577
8578         * m4/fprintftime.m4: New file.
8579
8580 2005-12-16  Jim Meyering  <jim@meyering.net>
8581
8582         * lib/fprintftime.c, lib/fprintftime.h: New files.
8583
8584 2005-12-15  Simon Josefsson  <jas@extundo.com>
8585
8586         * modules/socklen (configure.ac): Fix M4 macro name, to align with
8587         new m4/socklen.m4.
8588
8589 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8590
8591         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
8592         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
8593
8594 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8595
8596         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
8597         * lib/argp-help.c (fill_in_uparams): Check if the constructed
8598         struct uparams is valid. Fall back to the default values if it is
8599         not.
8600
8601 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8602
8603         * modules/argp (Files): Add argp-pin.c
8604         (Depends-on): dirname
8605         (lib_SOURCES): Add argp-pin.c
8606
8607 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8608
8609         * m4/argp.m4:  Check if program_invocation_name and
8610         program_invocation_short_name are declared and define appropriate
8611         macros if they are not.
8612
8613 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8614
8615         * lib/argp-help.c (__argp_base_name): New function
8616         (__argp_short_program_name): Rewrite using __argp_base_name
8617         * lib/argp-namefrob.h: Define program_invocation_name and
8618         program_invocation_short_name if requested
8619         (__argp_base_name): Add prototype
8620         * lib/argp-parse.c (argp_def): Use gettext wrappers
8621         (argp_default_parser): Use __argp_base_name
8622         * lib/argp-pin.c: New file. Defines program_invocation_name and
8623         program_invocation_short_name on systems that lack them.
8624
8625 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8626
8627         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
8628         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8629         porting problem reported by Georg Schwarz in
8630         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8631
8632 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8633
8634         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
8635         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8636         porting problem reported by Georg Schwarz in
8637         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8638
8639 2005-12-05  Bruno Haible  <bruno@clisp.org>
8640
8641         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
8642         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
8643         Reported by Mark Junker <mjscod@gmx.de>.
8644
8645 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
8646
8647         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
8648         Use implementation from Albert Chin, with some
8649         comments/corrections by Stepan Kasal and myself.
8650
8651 2005-12-02  Bruno Haible  <bruno@clisp.org>
8652
8653         * gnulib-tool (func_import): Accept GPLed build tool modules when
8654         --lgpl is given.
8655         * modules/csharpcomp-script: New file.
8656         * modules/csharpcomp: Depend on it.
8657         * modules/javacomp-script: New file.
8658         * modules/javacomp: Depend on it.
8659         Suggested by Simon Josefsson.
8660
8661 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
8662
8663         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
8664         statement, to work around an HP-UX 10.20 compiler bug reported by
8665         Peter O'Gorman.
8666
8667 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8668
8669         * modules/savedir (Depends-on): Add openat.
8670
8671 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8672
8673         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
8674         (uintmax_t) [defined uintmax_t]: Do not declare.
8675         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
8676         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
8677         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
8678         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
8679         sake of portability to weird hosts that C allows (though we don't
8680         know of any practical examples).
8681
8682         * lib/savedir.h (fdsavedir): New decl.
8683         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
8684         contains most of the former guts of savedir.
8685         (savedir): Use savedirstream.
8686         Include "openat.h".
8687
8688 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
8689
8690         * modules/obstack (Files): Add m4/ulonglong.m4.
8691         Problem reported by Davide Angelocola.
8692
8693 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
8694
8695         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
8696         coreutils no longer futzes with rounding modes.
8697
8698 2005-11-14  Jim Meyering  <jim@meyering.net>
8699
8700         * lib/mkstemp-safer.c: Include <config.h>, required for possible
8701         replacement of mkstemp.
8702
8703 2005-11-10  Simon Josefsson  <jas@extundo.com>
8704
8705         * lib/readline.c: Remove EOL.
8706
8707 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8708
8709         * modules/gethrxtime (Depends-on): Add gettime.
8710
8711 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8712
8713         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
8714         or gettimeofday; no longer needed.
8715
8716 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8717
8718         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
8719         time business.
8720         (gethrxtime) [! (HAVE_NANOUPTIME
8721         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
8722         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
8723         our own approximation.
8724
8725 2005-11-08  Eric Blake  <ebb9@byu.net>
8726
8727         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8728
8729 2005-11-08  Eric Blake  <ebb9@byu.net>
8730
8731         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8732
8733 2005-11-04  Bruno Haible  <bruno@clisp.org>
8734
8735         * gnulib-tool: Implement --update mode.
8736
8737 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8738
8739         Fix porting problem reported by Theodoros V. Kalamatianos.
8740         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
8741         Don't assume that futimes failing means we must fail.
8742
8743 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8744
8745         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
8746         variables to suggest the intended function of the PATH_MAX check.
8747
8748 2005-10-30  Kean Johnston  <jkj@sco.com>
8749
8750         Trivial changes to support SCO systems.
8751         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
8752         as PATH_MAX.
8753         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
8754         where __ptr is null when no I/O is pending.
8755
8756 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
8757
8758         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
8759         leave errno alone.  Problem reported by Dmitry V. Levin.
8760
8761 2005-10-28  Simon Josefsson  <jas@extundo.com>
8762
8763         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
8764         Test more.
8765
8766         * tests/test-gc-md2.c, tests/test-md2.c: New files.
8767
8768         * modules/md2, modules/md2-tests: New files.
8769
8770 2005-10-28  Simon Josefsson  <jas@extundo.com>
8771
8772         * m4/inet_ntop.m4: More tests.
8773
8774         * m4/gc-md2.m4, md2.m4: New file.
8775
8776 2005-10-28  Simon Josefsson  <jas@extundo.com>
8777
8778         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
8779         "restrict" keywords, as per POSIX.  Protect the function
8780         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
8781         Don't use K&R prototypes.  Check the sprintf return values.
8782         Re-define EAFNOSUPPORT if not present.  Indent.
8783
8784         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
8785         suggested by Bruno Haible <bruno@clisp.org>.
8786
8787         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
8788
8789         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
8790
8791         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
8792         libgcrypt).
8793
8794         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
8795
8796         * lib/md2.h, lib/md2.c: New files.
8797
8798 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
8799
8800         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
8801         errno alone.  Problem reported by Frederic Jolliton.
8802
8803 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8804
8805         * modules/verify (License): Change from GPL to LGPL.  This is a
8806         tiny module and there are apparently near-equivalents that are
8807         under the BSD license.
8808
8809 2005-10-24  Simon Josefsson  <jas@extundo.com>
8810
8811         * modules/sha1: Relicense to LGPL.
8812
8813 2005-10-24  Simon Josefsson  <jas@extundo.com>
8814
8815         * lib/md4.h: Shrink buffer size, now that we changed the type.
8816
8817 2005-10-23  Simon Josefsson  <jas@extundo.com>
8818
8819         * gnulib-tool (func_import): Fix --tests-base.
8820
8821 2005-10-22  Simon Josefsson  <jas@extundo.com>
8822
8823         * modules/arcfour (Depends-on): Need stdint.
8824
8825 2005-10-22  Simon Josefsson  <jas@extundo.com>
8826
8827         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
8828         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
8829
8830 2005-10-22  Simon Josefsson  <jas@extundo.com>
8831
8832         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
8833         suggested by Bruno Haible <bruno@clisp.org>.
8834
8835 2005-10-22  Simon Josefsson  <jas@extundo.com>
8836
8837         * lib/crc.h: Include stddef.h, for size_t.
8838
8839 2005-10-22  Simon Josefsson  <jas@extundo.com>
8840
8841         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
8842         arcfour_context struct (simplify test vector testing in GNU
8843         Shishi).
8844
8845 2005-10-21  Simon Josefsson  <jas@extundo.com>
8846
8847         * modules/des, modules/des-tests: New files.
8848
8849         * modules/gc-des, modules/gc-des-tests: New files.
8850
8851         * tests/test-des.c, tests/test-gc-des.c: New file.
8852
8853 2005-10-21  Simon Josefsson  <jas@extundo.com>
8854
8855         * modules/arctwo, modules/arctwo-tests: New files.
8856
8857         * tests/test-arctwo.c: New file.
8858
8859         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
8860
8861         * tests/test-gc-arctwo.c: New file.
8862
8863 2005-10-21  Simon Josefsson  <jas@extundo.com>
8864
8865         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
8866         Bruno Haible <bruno@clisp.org>.
8867
8868         * m4/gc-des.m4: New file.
8869
8870 2005-10-21  Simon Josefsson  <jas@extundo.com>
8871
8872         * m4/arctwo.m4: New file.
8873
8874         * m4/gc-arctwo.m4: New file.
8875
8876 2005-10-21  Simon Josefsson  <jas@extundo.com>
8877
8878         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
8879         block.
8880
8881 2005-10-21  Simon Josefsson  <jas@extundo.com>
8882
8883         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
8884         <bruno@clisp.org>.
8885
8886         * lib/hmac-sha1.c (hmac_sha1): Likewise.
8887
8888         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
8889         Bruno Haible <bruno@clisp.org>.
8890
8891         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
8892         <bruno@clisp.org>.
8893
8894 2005-10-21  Simon Josefsson  <jas@extundo.com>
8895
8896         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
8897
8898 2005-10-21  Simon Josefsson  <jas@extundo.com>
8899
8900         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
8901
8902 2005-10-21  Simon Josefsson  <jas@extundo.com>
8903
8904         * lib/des.h, lib/des.c: New files.
8905
8906         * lib/gc-gnulib.c: Support DES.c
8907
8908 2005-10-21  Simon Josefsson  <jas@extundo.com>
8909
8910         * lib/arctwo.h, lib/arctwo.c: New files.
8911
8912         * lib/gc-gnulib.c: Support ARCTWO.
8913
8914 2005-10-21  Simon Josefsson  <jas@extundo.com>
8915
8916         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
8917         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8918
8919 2005-10-21  Simon Josefsson  <jas@extundo.com>
8920
8921         * gnulib-tool (func_import, func_create_testdir): Define automake
8922         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
8923         Makefile.am snippet),
8924         suggested by Bruno Haible <bruno@clisp.org>.
8925
8926         * modules/gc (Makefile.am): Use it.
8927
8928 2005-10-21  Bruno Haible  <bruno@clisp.org>
8929
8930         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
8931         patch.
8932
8933 2005-10-19  Simon Josefsson  <jas@extundo.com>
8934
8935         * tests/test-gc-rijndael.c: New file.
8936
8937         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
8938
8939 2005-10-19  Simon Josefsson  <jas@extundo.com>
8940
8941         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
8942         interface too.
8943
8944 2005-10-19  Simon Josefsson  <jas@extundo.com>
8945
8946         * tests/test-gc-arcfour.c: New file.
8947
8948         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
8949
8950 2005-10-19  Simon Josefsson  <jas@extundo.com>
8951
8952         * modules/gc-md4, modules/gc-md4-tests: New file.
8953
8954         * tests/test-gc-md4.c: New file.
8955
8956 2005-10-19  Simon Josefsson  <jas@extundo.com>
8957
8958         * m4/gc-md4.m4: New file.
8959
8960 2005-10-19  Simon Josefsson  <jas@extundo.com>
8961
8962         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
8963         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
8964         <kasal@ucw.cz>.
8965
8966 2005-10-19  Simon Josefsson  <jas@extundo.com>
8967
8968         * m4/gc-arcfour.m4: New file.
8969
8970         * m4/gc-rijndael.m4: New file.
8971
8972 2005-10-19  Simon Josefsson  <jas@extundo.com>
8973
8974         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
8975
8976 2005-10-19  Simon Josefsson  <jas@extundo.com>
8977
8978         * lib/gc-gnulib.c: Support ARCFOUR.
8979
8980 2005-10-19  Simon Josefsson  <jas@extundo.com>
8981
8982         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
8983         support.
8984
8985         * lib/gc.h: Add ECB enum type.
8986
8987         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
8988
8989 2005-10-18  Simon Josefsson  <jas@extundo.com>
8990
8991         * tests/test-md5.c: New file.
8992
8993         * modules/md5-tests: New file.
8994
8995 2005-10-18  Simon Josefsson  <jas@extundo.com>
8996
8997         * tests/test-md4.c: New file.
8998
8999         * modules/md4, modules/md4-tests: New files.
9000
9001 2005-10-18  Simon Josefsson  <jas@extundo.com>
9002
9003         * m4/md4.m4: New file.
9004
9005 2005-10-18  Simon Josefsson  <jas@extundo.com>
9006
9007         * lib/md4.h, lib/md4.c: New files, based on md5.?.
9008
9009 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
9010
9011         * gnulib-tool (func_create_testdir): Omit the second check whether
9012         BUILT_SOURCES in nonempty.
9013
9014 2005-10-17  Simon Josefsson  <jas@extundo.com>
9015
9016         * tests/test-rijndael.c: New file.
9017
9018 2005-10-17  Simon Josefsson  <jas@extundo.com>
9019
9020         * modules/sha1: Depend on stdint instead of md5.
9021
9022         * modules/md5: Depend on stdint, remove uint32_t.
9023
9024 2005-10-17  Simon Josefsson  <jas@extundo.com>
9025
9026         * modules/gc-sha1-tests: New file.
9027
9028         * tests/test-gc-sha1.c: New file.
9029
9030 2005-10-17  Simon Josefsson  <jas@extundo.com>
9031
9032         * m4/md5.m4: Remove call to uint32_t.m4.
9033
9034 2005-10-17  Simon Josefsson  <jas@extundo.com>
9035
9036         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
9037
9038         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
9039         md5.h.
9040
9041         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
9042
9043         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
9044
9045 2005-10-17  Simon Josefsson  <jas@extundo.com>
9046
9047         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
9048
9049 2005-10-17  Simon Josefsson  <jas@extundo.com>
9050
9051         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
9052
9053 2005-10-17  Simon Josefsson  <jas@extundo.com>
9054
9055         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
9056
9057         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
9058
9059 2005-10-17  Bruno Haible  <bruno@clisp.org>
9060
9061         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
9062         that it can also be used in a test.
9063
9064 2005-10-16  Bruno Haible  <bruno@clisp.org>
9065
9066         * gnulib-tool (func_emit_tests_Makefile_am): Also define
9067         TESTS_ENVIRONMENT, so that individual tests can augment it.
9068
9069         * gnulib-tool (func_create_testdir): Use an intermediate target for
9070         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
9071         macros, like $(ALLOCA_H), which cannot be passed through the command
9072         line.
9073
9074 2005-10-15  Simon Josefsson  <jas@extundo.com>
9075
9076         * modules/rijndael-tests: New file.
9077
9078         * modules/rijndael: New file.
9079
9080 2005-10-15  Simon Josefsson  <jas@extundo.com>
9081
9082         * m4/rijndael.m4: New file.
9083
9084 2005-10-15  Simon Josefsson  <jas@extundo.com>
9085
9086         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
9087
9088         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
9089
9090 2005-10-14  Simon Josefsson  <jas@extundo.com>
9091
9092         * tests/test-arcfour.c: New file.
9093
9094         * modules/arcfour, modules/arcfour-tests: New files.
9095
9096 2005-10-14  Simon Josefsson  <jas@extundo.com>
9097
9098         * m4/arcfour.m4: New file.
9099
9100 2005-10-14  Simon Josefsson  <jas@extundo.com>
9101
9102         * lib/arcfour.h, lib/arcfour.c: New files.
9103
9104 2005-10-14  Roland McGrath  <roland@redhat.com>
9105
9106         Import from libc.  [BZ #1331]
9107         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
9108         macro argument.
9109         Reported by Matej Vela <vela@debian.org>.
9110
9111 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9112
9113         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
9114         include <wchar.h>; no longer needed.
9115
9116 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9117
9118         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
9119
9120 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
9121         and  Ulrich Drepper  <drepper@redhat.com>
9122
9123         Import from libc.
9124         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
9125         instead of inline stream orientation test and two separate
9126         function calls.  Pay no attention to USE_IN_LIBIO.
9127
9128 2005-10-13  Simon Josefsson  <jas@extundo.com>
9129
9130         * modules/gc-hmac-md5-tests: New file.
9131
9132         * tests/test-gc-hmac-sha1.c: New file.
9133
9134         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
9135
9136         * modules/gc-hmac-md5-tests: New file.
9137
9138         * tests/test-gc-md5.c: New file.
9139
9140         * modules/gc-md5-tests: New file.
9141
9142 2005-10-13  Simon Josefsson  <jas@extundo.com>
9143
9144         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
9145         Move memory allocation outside of loop.
9146
9147 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
9148
9149         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
9150         intermediate directory is in a read-only file system.  Problem
9151         reported by Eric Blake.
9152
9153 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
9154
9155         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
9156
9157 2005-10-12  Simon Josefsson  <jas@extundo.com>
9158
9159         * tests/test-hmac-sha1.c: New file.
9160
9161         * modules/hmac-sha1-tests: New file.
9162
9163         * modules/hmac-sha1: New file.
9164
9165 2005-10-12  Simon Josefsson  <jas@extundo.com>
9166
9167         * modules/gc-sha1: New file.
9168
9169 2005-10-12  Simon Josefsson  <jas@extundo.com>
9170
9171         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
9172
9173         * tests/test-gc-pbkdf2-sha1.c: New file.
9174
9175 2005-10-12  Simon Josefsson  <jas@extundo.com>
9176
9177         * modules/gc-md5, modules/gc-hmac-md5: New files.
9178
9179         * modules/gc (Files): Remove md5, memxor and hmac files.
9180
9181 2005-10-12  Simon Josefsson  <jas@extundo.com>
9182
9183         * m4/gc-pbkdf2-sha1.m4: New file.
9184
9185         * m4/gc-hmac-sha1.m4: New file.
9186
9187         * m4/gc-sha1: New file.
9188
9189         * m4/hmac-sha1.m4: New file.
9190
9191 2005-10-12  Simon Josefsson  <jas@extundo.com>
9192
9193         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
9194
9195         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
9196
9197 2005-10-12  Simon Josefsson  <jas@extundo.com>
9198
9199         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
9200         suggested by Bruno Haible <bruno@clisp.org>.
9201
9202 2005-10-12  Simon Josefsson  <jas@extundo.com>
9203
9204         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
9205
9206 2005-10-12  Simon Josefsson  <jas@extundo.com>
9207
9208         * lib/gc-pbkdf2-sha1.c: New file.
9209
9210         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
9211
9212 2005-10-12  Simon Josefsson  <jas@extundo.com>
9213
9214         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
9215
9216         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
9217
9218 2005-10-12  Simon Josefsson  <jas@extundo.com>
9219
9220         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
9221         GC_USE_HMAC_MD5, respectively.
9222
9223         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
9224         (gc_md5): Fix typo.
9225
9226         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
9227
9228         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
9229
9230         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
9231
9232 2005-10-12  Bruno Haible  <bruno@clisp.org>
9233
9234         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
9235         Reported by Stepan Kasal <kasal@ucw.cz>.
9236
9237 2005-10-11  Simon Josefsson  <jas@extundo.com>
9238
9239         * tests/test-crc.c: New file.
9240
9241         * modules/crc, modules/crc-tests: New files.
9242
9243 2005-10-11  Simon Josefsson  <jas@extundo.com>
9244
9245         * m4/crc.m4: New file.
9246
9247 2005-10-11  Simon Josefsson  <jas@extundo.com>
9248
9249         * lib/gc.h: Add gc_hash and gc_hash_buffer.
9250
9251         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
9252
9253         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
9254
9255 2005-10-11  Simon Josefsson  <jas@extundo.com>
9256
9257         * lib/crc.h, lib/crc.c: New files.
9258
9259         * lib/gc.h (gc_hash_buffer): Add doc.
9260
9261 2005-10-11  Bruno Haible  <bruno@clisp.org>
9262
9263         * modules/c-strcasestr: New file.
9264         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
9265
9266 2005-10-11  Bruno Haible  <bruno@clisp.org>
9267
9268         * modules/c-strcase: New file.
9269         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
9270
9271 2005-10-11  Bruno Haible  <bruno@clisp.org>
9272
9273         * lib/strcasecmp.c: Include limits.h.
9274         (strcasecmp): Avoid integer overflow on exotic platforms.
9275         * lib/strncasecmp.c: Include limits.h.
9276         (strncasecmp): Avoid integer overflow on exotic platforms.
9277         Reported by Paul Eggert.
9278
9279 2005-10-11  Bruno Haible  <bruno@clisp.org>
9280
9281         * lib/c-strcasestr.h: New file, from GNU gettext.
9282         * lib/c-strcasestr.c: New file, from GNU gettext.
9283
9284 2005-10-11  Bruno Haible  <bruno@clisp.org>
9285
9286         * lib/c-strcase.h: New file, from GNU gettext.
9287         * lib/c-strcasecmp.c: New file, from GNU gettext.
9288         * lib/c-strncasecmp.c: New file, from GNU gettext.
9289
9290 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9291
9292         * modules/mempcpy (License): GPL -> LGPL.
9293         * modules/strchrnul (License): Likewise.
9294         * modules/sysexits (License): Likewise.
9295
9296 2005-10-08  Simon Josefsson  <jas@extundo.com>
9297
9298         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
9299
9300 2005-10-07  Simon Josefsson  <jas@extundo.com>
9301
9302         * m4/memxor.m4: Remove gl_C_RESTRICT call.
9303
9304 2005-10-06  Simon Josefsson  <jas@extundo.com>
9305
9306         * tests/test-hmac-md5.c: New file.
9307
9308         * modules/hmac-md5-tests: New file.
9309
9310         * modules/hmac-md5: New file.
9311
9312 2005-10-06  Simon Josefsson  <jas@extundo.com>
9313
9314         * m4/hmac-md5.m4: New file.
9315
9316         * m4/memxor.m4: Require gl_C_RESTRICT.
9317
9318 2005-10-06  Simon Josefsson  <jas@extundo.com>
9319
9320         * lib/memxor.c (memxor): Avoid casts and warnings.
9321
9322 2005-10-06  Simon Josefsson  <jas@extundo.com>
9323
9324         * lib/hmac-md5.c: New file.
9325
9326         * lib/hmac.h: New file.
9327
9328 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9329
9330         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
9331         promotes to int, not unsigned int, to catch the AIX 5.3
9332         compiler bug.
9333
9334 2005-10-05  Simon Josefsson  <jas@extundo.com>
9335
9336         * modules/memxor: New file.
9337
9338         * modules/iconv (Files): Move config.rpath to havelib, it is used
9339         there.
9340
9341         * modules/havelib (Files): Add config.rpath.
9342
9343 2005-10-05  Simon Josefsson  <jas@extundo.com>
9344
9345         * m4/memxor.m4: New file.
9346
9347 2005-10-05  Simon Josefsson  <jas@extundo.com>
9348
9349         * lib/memxor.c (memxor): Fix compiler error.
9350
9351         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
9352         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
9353
9354         * lib/memxor.h, lib/memxor.c: New files.
9355
9356         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
9357         we assume all systems have it, suggested by Jim Meyering
9358         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
9359         any systems lack sys/socket.h; mingw32 is known to lack it, but we
9360         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
9361         same reasons.
9362
9363 2005-10-05  Simon Josefsson  <jas@extundo.com>
9364
9365         * config/srclist.txt: Add glibc bug 1423 for md5.h.
9366
9367 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9368
9369         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
9370         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
9371         needed, since the source code now assumes these .h files.
9372
9373 2005-10-05  Derek Price  <derek@ximbiot.com>
9374
9375         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
9376
9377 2005-10-05  Bruno Haible  <bruno@clisp.org>
9378
9379         * modules/stdint (License): Change to LGPL.
9380
9381 2005-10-04  Simon Josefsson  <jas@extundo.com>
9382
9383         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
9384         D. Baushke" <mdb@gnu.org>.
9385
9386 2005-10-04  Bruno Haible  <bruno@clisp.org>
9387
9388         * lib/verify.h (verify_true): Provide alternative definition for C++.
9389
9390 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
9391
9392         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
9393         (SSIZE_MAX): New macro, if not already defined.
9394         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
9395         than 2 GiB.
9396
9397 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9398
9399         Sync from coreutils.
9400         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
9401         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
9402         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
9403         ULLONG_MAX doesn't work with 2.7.2.1.
9404
9405 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9406
9407         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
9408         From Ben Pfaff.
9409
9410         * modules/exclude (Depends-on): Depend on verify.
9411         * modules/strtoimax (Depends-on): Likewise.
9412         * modules/utimecmp (Depends-on): Likewise.
9413
9414 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9415
9416         * lib/exclude.c: Include verify.h.
9417         (verify): Remove.  All callers changed to use verify.h's version.
9418         * lib/strtoimax.c: Likewise.
9419         * lib/utimecmp.c: Likewis.e
9420
9421         Sync from coreutils.
9422         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
9423         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
9424         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
9425         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
9426         bother returning ENOSYS if settimeofday or stime fails; just let
9427         them return whatever errno they want to return.
9428         * lib/utimens.c: Include unistd.h, for dup2.
9429         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
9430         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
9431
9432 2005-10-02  Jim Meyering  <jim@meyering.net>
9433
9434         Sync from coreutils.
9435         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
9436         from glibc-2.2.5 that fails for read-only files.
9437
9438 2005-10-02  Jim Meyering  <jim@meyering.net>
9439
9440         Sync from coreutils.
9441         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
9442         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
9443         `#if HAVE_CONFIG_H'.
9444         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
9445         Remove AT_FDCWD test.
9446         Do not consume the fd unless successful.
9447         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
9448         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
9449         block, so that we don't even try to compile it if settimeofday is
9450         available.  This works around a compilation failure on OSF1 V5.1,
9451         due to stime requiring a `long int*' while tv_sec is `int'.
9452
9453 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
9454
9455         Sync from coreutils.
9456         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
9457         against `yes', rather than just testing for nonempty.
9458
9459 2005-10-01  Simon Josefsson  <jas@extundo.com>
9460
9461         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
9462         and Darwin.
9463
9464         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
9465         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
9466         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
9467         freeaddrinfo and gai_strerror are declared by the POSIX headers.
9468         Check if struct addrinfo is declared.
9469
9470 2005-10-01  Simon Josefsson  <jas@extundo.com>
9471
9472         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
9473         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
9474         AI_* and EAI_* definitions.  Protect function declarations.
9475
9476 2005-10-01  Jim Meyering  <jim@meyering.net>
9477
9478         Sync from coreutils.
9479
9480         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
9481         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
9482         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
9483         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9484         in the inet and nsl libraries.  Required on Solaris 5.7.
9485
9486 2005-10-01  Jim Meyering  <jim@meyering.net>
9487
9488         Sync from coreutils.
9489         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9490         in the inet and nsl libraries.  Required on Solaris 5.7.
9491
9492 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
9493
9494         * lib/getdelim.c (getdelim): Remove unused variables.
9495
9496 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9497
9498         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
9499         so that the code works even with ancient cpp.  Portability problem
9500         with GCC 2.7.2.1 reported by Thomas M.Ott.
9501
9502 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9503
9504         * modules/regex (Depends-on): Add strcase.
9505
9506         * modules/gethostname (Licence): Change from GPL to LGPL, since
9507         gethostname.c is a trivial implementation of a standard library
9508         function.
9509         * modules/poll (License): Change from GPL to LGPL, since it's
9510         derived from LGPL code.
9511
9512 2005-09-27  Jim Meyering  <jim@meyering.net>
9513
9514         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
9515         HAVE_CONFIG_H.
9516
9517         * lib/intprops.h (signed_type_or_expr__): Define.
9518         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
9519         for unsigned types.
9520
9521 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9522
9523         * lib/verify.h (verify_expr): Remove, replacing with:
9524         (verify_true): New macro that returns true instead of void.
9525         (verify_type__): Remove.
9526         (verify): Use verify_true rather than verify_type__.
9527
9528 2005-09-26  Bruno Haible  <bruno@clisp.org>
9529
9530         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
9531         is necessary.
9532         (lib_SOURCES): Remove mbchar.c.
9533         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
9534         (Files): Add m4/mbrtowc.m4.
9535         * modules/mbiter: Likewise.
9536         * modules/mbuiter: Likewise.
9537
9538 2005-09-26  Bruno Haible  <bruno@clisp.org>
9539
9540         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
9541         compile mbchar.c if they are not both present.
9542         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
9543         * m4/mbiter.m4 (gl_MBITER): Likewise.
9544         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
9545         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
9546         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
9547
9548 2005-09-25  Jim Meyering  <jim@meyering.net>
9549
9550         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
9551         also uses socklen_t.
9552
9553 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
9554
9555         * lib/utimens.c (ENOSYS): Define if not already defined.
9556         (futimens): Support having a null PATH if the file descriptor
9557         is nonnegative.
9558
9559         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
9560         Remove.
9561         (__attribute): Define to empty unless GCC 3.1 or later.
9562         This works around a core dump on OpenBSD 3.4, which has GCC
9563         2.95.3, which dumps core when given __attribute__(()).  It also
9564         simplifies other tests, since we really don't want to bother with
9565         worrying about which ancient version of GCC supported what.
9566         Original problem reported by Yoann Vandoorselaere, with part of
9567         the fix suggested by Derek Price.
9568
9569 2005-09-24  Jim Meyering  <jim@meyering.net>
9570
9571         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
9572         so we can once again use a positive bitfield width of 1 -- now we
9573         don't have to explain why we were using a bitfield width of 2.
9574
9575 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9576
9577         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
9578         and similarly for the other external symbols.  Problem reported
9579         by James Gallager.
9580
9581         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
9582         bug reported by Jim Meyering.
9583
9584         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
9585         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
9586         not needed, since socklen is a prerequisite module.
9587
9588 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9589
9590         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
9591         Problem reported by Eric Blake.
9592         (getaddrinfo): Initialize se so that it's not garbage.
9593         Redo internal storage allocation so that it doesn't make unportable
9594         assumptions about alignment.
9595         Fix a memory leak.
9596
9597         * lib/utimens.c (futimens): Use futimesat if available.
9598         Prefer it to futimes since it doesn't have the futimes bug.
9599
9600         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
9601         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
9602         Instead, declare a function that returns a pointer to an array,
9603         and use verify_type__ to declare the size of the array.
9604         Problem and germ of a solution reported by Bruno Haible.
9605         (verify_type__): Use 2, not 1, for bitfield size, to avoid
9606         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
9607
9608 2005-09-23  Jim Meyering  <jim@meyering.net>
9609
9610         Sync from coreutils.
9611         Correct build failure (socklen_t not defined) on at least
9612         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
9613         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
9614
9615 2005-09-23  Jim Meyering  <jim@meyering.net>
9616
9617         * modules/getaddrinfo (Depends-on): Add socklen.
9618
9619 2005-09-23  Bruno Haible  <bruno@clisp.org>
9620
9621         * tests/test-verify.c: New file.
9622
9623 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9624
9625         Sync from coreutils.
9626
9627         * modules/argmatch (Depends-on): Add verify.
9628         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
9629         unistd-safer.
9630         * modules/save-cwd (Depends-on): Likewise.
9631
9632         * modules/openat (Files): Add lib/openat-die.c.
9633         (Depends-on): Remove error, exitfail.
9634         Add dirname.
9635
9636         * modules/verify: New file.
9637         * MODULES.html.sh (Diagnostics <assert.h>): New section,
9638         with "verify" module.
9639
9640 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9641
9642         Sync from coreutils.
9643
9644         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
9645         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
9646         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
9647         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
9648         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
9649         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
9650         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
9651         Don't bother checking for string.h, stdlib.h, unistd.h.
9652         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
9653         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
9654         module's job.
9655         * m4/jm-macros.m4 (gl_MACROS): Likewise.
9656         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
9657
9658         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
9659         (gl_GETDATE): Use it.
9660
9661         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
9662
9663 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9664
9665         Sync from coreutils.
9666
9667         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
9668         stat-time.h.
9669         * lib/argmatch.h: Include verify.h
9670         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
9671         (ARGMATCH_ASSERT): Remove; unused.
9672         * lib/canonicalize.c: Assume STDC_HEADERS.
9673         * lib/exclude.c: Include "strcase.h".
9674         * lib/regex_internal.h [!defined _LIBC]: Likewise.
9675         * lib/getusershell.c: Include stdio--.h rather than stdio.h
9676         and stdio-safer.h.
9677         (getusershell): Call fopen, not fopen_safer.
9678         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
9679         Do not include unistd-safer.h.
9680         (save_cwd): Don't call fd_safer; no longer needed
9681         now that we include fcntl--.h.
9682
9683         * lib/getdate.y (relative_time): New type.
9684         (RELATIVE_TIME_0): New constant.
9685         (parser_control): Use relative_time instead of doing it ourselves.
9686         (%union): Add new relative_time rel member.
9687         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
9688         Now typeless.
9689         (relunit, relunit_snumber): Now of type rel.
9690         (zone, rel, relunit, get_date): Adjust to above changes.
9691
9692         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
9693         Do not include unistd-safer.h.
9694         (getloadavg): Don't call fd_safer; no longer needed
9695         now that we include fcntl--.h.
9696
9697         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
9698         (make_dir_parents): Treat ENOSYS like EEXIST.
9699
9700         Improve quality of diagnostics on restore_cwd failure.
9701         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
9702         (make_dir_parents): Last arg is now int * (for errno), not bool *.
9703         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
9704         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
9705         each time through the loop.  Do not diagnose restore_cwd failure;
9706         that is the caller's job (and perhaps the caller does not care).
9707
9708         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
9709         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
9710         If the file already exists but is not a directory, don't bother
9711         to try to make its parents.
9712         Close potential file descriptor leak if we can't chdir("/") (!).
9713         Don't always return true if chdir($PWD) fails; return true only
9714         if the requested action was done successfully (except for the
9715         chdir($PWD)).
9716         Don't log final directory unless we actually made it.
9717         Refactor to avoid duplicate code to fix up permissions.
9718         Don't attempt to fix up parent permissions if chdir($PWD) fails.
9719
9720         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
9721         to make it a bit faster and (I hope) clearer.
9722         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
9723         Fix bug in formats like %2N.
9724
9725         * lib/verify.h: New file.
9726
9727 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9728
9729         Sync from coreutils.
9730         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
9731
9732 2005-09-22  Jim Meyering  <jim@meyering.net>
9733
9734         Sync from coreutils.
9735
9736         * m4/lstat.m4 (gl_FUNC_LSTAT):
9737         Use AC_LIBSOURCES to require lstat.c and lstat.h.
9738         Remove obsolete comment.
9739         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
9740         * m4/xstrtod.m4: Likewise.
9741
9742         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
9743
9744 2005-09-22  Jim Meyering  <jim@meyering.net>
9745
9746         Sync from coreutils.
9747
9748         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
9749
9750         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
9751         the .tm_year member, since otherwise gcc-4.0 would now warn about
9752         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
9753
9754         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
9755         order to avoid an unsuppressible warning from gcc on 64-bit systems.
9756
9757         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
9758         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
9759         when run in a time zone for which daylight savings time is in effect
9760         for the starting date.
9761
9762         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
9763         stop us from restricting permissions of just-created absolute-named
9764         directories.
9765         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
9766         to restore initial working directory.
9767         * lib/mkdir-p.c (make_dir_parents): New parameter:
9768         different_working_dir, to tell caller if/when we change the working
9769         directory and are unable to return to the initial one.
9770         * lib/mkdir-p.h (make_dir_parents): Update prototype.
9771         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
9772         `return false'.  This fixes a bug introduced on 2004-07-30.
9773
9774         * lib/openat.c (fdopendir): Be sure to close the supplied
9775         file descriptor before returning.  This makes our replacement
9776         implementation a little closer to Solaris's, where fdopendir
9777         ties the file descriptor to the returned DIR* pointer.
9778         * lib/openat.c (unlinkat): New function.
9779         * lib/openat.h (unlinkat): Add prototype.
9780         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
9781         (openat_restore_fail): Rename from openat_restore_die.
9782         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
9783
9784         Provide an alternative to exiting immediately upon save_cwd or
9785         restore_cwd failure.  Now, an application can arrange e.g.,
9786         to perform a longjump in that case.
9787         * lib/openat.c: Include dirname.h.
9788         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
9789         (rpl_openat, fdopendir, fstatat): Call openat_save_die
9790         and openat_restore_die rather than calling error directly.
9791         Don't include "error.h" or "exitfail.h"; they're no longer needed.
9792
9793         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
9794         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
9795         define.
9796
9797         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
9798         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
9799                             int utc, int nanoseconds);
9800         Background:
9801         date should not have to allocate a megabyte of virtual memory to
9802         handle a format argument like +%1048575T.  When implemented with
9803         strftime, it must allocate such a buffer, use strftime to fill it
9804         in, print it, then free it.
9805         With fprintftime, it simply prints everything and exits.
9806         With no need for memory allocation, that's one fewer way to fail.
9807         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
9808         optional field width, not before, so we accept %9:z, not %:9z.
9809         (my_strftime): Be sure to use L_('x') for literals.
9810
9811         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
9812         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
9813         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
9814         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
9815         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
9816         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
9817         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
9818         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
9819         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
9820         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
9821         * lib/xgethostname.c, lib/xreadlink.c:
9822         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
9823
9824         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
9825         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
9826         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
9827         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
9828         and don't include <sys/file.h>).
9829
9830 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
9831
9832         Sync from coreutils.
9833
9834         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
9835         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
9836         [!LDAV_DONE]: Avoid unused variable warning.
9837
9838 2005-09-21  Bruno Haible  <bruno@clisp.org>
9839
9840         * lib/unicodeio.h (unicode_to_mb): New declaration.
9841
9842 2005-09-20  Derek Price  <derek@ximbiot.com>
9843
9844         * lib/getaddrinfo.c: Don't include <netdb.h> included from
9845         getaddrinfo.h.
9846
9847 2005-09-20  Bruno Haible  <bruno@clisp.org>
9848
9849         * gnulib-tool: Remove trailing slashes from the values specified for
9850         --source-base, --m4-base, --tests-base, --aux-dir.
9851         Suggested by Simon Josefsson <jas@extundo.com>.
9852
9853 2005-09-20  Bruno Haible  <bruno@clisp.org>
9854
9855         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
9856         func_modules_to_filelist, func_import, func_create_testdir): Make all
9857         sorting results locale-independent, so that gnulib-cache.m4 doesn't
9858         change when gnulib-tool is invoked in a different locale.
9859
9860 2005-09-19  Simon Josefsson  <jas@extundo.com>
9861
9862         * m4/socklen.m4: Fix typo.
9863
9864 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9865
9866         Use a consistent style for including <config.h>.
9867         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
9868         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
9869         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
9870         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
9871         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
9872         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
9873         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
9874         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
9875         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
9876         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
9877         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
9878         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
9879         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
9880         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
9881         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
9882         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
9883         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
9884         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
9885         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
9886         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
9887         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
9888         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
9889         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
9890         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
9891         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
9892         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
9893         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
9894         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
9895         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
9896         lib/xstrtoumax.c, lib/yesno.c:
9897         Standardize inclusion of config.h.
9898         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
9899         lib/inttostr.h:  Removed inclusion of config.h from header files.
9900         * lib/inttostr.c:  Adjusted in-tree users.
9901         * lib/timespec.h: Remove superfluous warning to include config.h.
9902         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
9903         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
9904         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
9905         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
9906         config.h with HAVE_CONFIG_H.
9907
9908 2005-09-19  Jim Meyering  <jim@meyering.net>
9909
9910         * modules/pathmax (License): Change to LGPL.
9911
9912 2005-09-19  Derek Price  <derek@ximbiot.com>
9913
9914         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
9915
9916 2005-09-19  Bruno Haible  <bruno@clisp.org>
9917
9918         * gnulib-tool (import): Provide default for --tests-base.
9919
9920 2005-09-19  Bruno Haible  <bruno@clisp.org>
9921
9922         * doc/quote.texi: New file, extracted from gnulib.texi.
9923         * doc/ctime.texi: New file, extracted from gnulib.texi.
9924         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
9925         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
9926         * doc/gnulib.texi: Include them.
9927
9928 2005-09-18  Bruno Haible  <bruno@clisp.org>
9929
9930         Portability fix.
9931         * gnulib-tool (func_readlink): New function.
9932         (func_ln_if_changed): Use it.
9933
9934 2005-09-18  Bruno Haible  <bruno@clisp.org>
9935
9936         * gnulib-tool: Support --with-tests also with --import.
9937         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
9938         (func_import): Use variables $testsbase and $inctests. Emit a
9939         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
9940         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
9941         SUBDIRS += $testsdir.
9942         (func_create_testdir): Update.
9943
9944 2005-09-18  Bruno Haible  <bruno@clisp.org>
9945
9946         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
9947         instead of $dry_run.
9948         (func_cp_if_changed, func_mv_if_changed): Remove functions.
9949         (func_ln_if_changed): Don't handle dry-run here.
9950         (func_import): In dry-run mode, detect more precisely which actions
9951         would be performed, and don't use "...ing" verbs.
9952
9953 2005-09-18  Bruno Haible  <bruno@clisp.org>
9954
9955         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
9956         (func_import): Use join on two temporary files instead of three nested
9957         loops, in order to determine which files are new or old.
9958
9959 2005-09-18  Bruno Haible  <bruno@clisp.org>
9960
9961         * gnulib-tool (func_import): Comment out code that spits out the
9962         new files with --dry-run.
9963
9964 2005-09-18  Bruno Haible  <bruno@clisp.org>
9965
9966         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
9967
9968 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9969
9970         * lib/stat-time.h: New file.
9971         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
9972         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
9973         in a different way.
9974         (timespec_cmp): New function.
9975         * lib/utimecmp.c: Include stat-time.h.
9976         (SYSCALL_RESOLUTION): Depend on whether various struct stat
9977         members exist, not on the obsolescent ST_MTIM_NSEC.
9978         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
9979
9980 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9981
9982         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
9983
9984 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9985
9986         * MODULES.html.sh (File system functions): Add stat-time.
9987         * modules/stat-time: New file.
9988         * modules/timespec (Files): Remove m4/st_mtim.m4; this
9989         is now done in a different way, by the stat-time module.
9990         * modules/utimecmp (Depends-on): Add stat-time.
9991
9992 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
9993
9994         * m4/st_mtim.m4: Remove.  Superseded by...
9995         * m4/stat-time.m4: New file.
9996         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
9997         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
9998
9999 2005-09-15  Derek Price  <derek@ximbiot.com>
10000
10001         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
10002
10003 2005-09-15  Derek Price  <derek@ximbiot.com>
10004
10005         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
10006         * lib/regex_internal.c: Ditto, using this...
10007         (__GNUC_PREREQ): ...new macro.
10008         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
10009         using...
10010         (__GNUC_PREREQ): ...this new macro.
10011
10012         * lib/strstr.h: Include string.h. Define strstr as a macro here.
10013
10014 2005-09-15  Derek Price  <derek@ximbiot.com>
10015             Paul Eggert  <eggert@cs.ucla.edu>
10016
10017         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
10018         changes, consolidating in...
10019         * lib/regex_internal.h: ...this file.
10020
10021 2005-09-13  Jim Meyering  <jim@meyering.net>
10022
10023         * lib/canon-host.c: Filter through gnu indent and reword comments
10024         slightly.
10025         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
10026
10027 2005-09-13  Derek Price  <derek@ximbiot.com>
10028
10029         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
10030         failure.
10031         Reported by Jim Meyering  <jim@meyering.net>.
10032
10033 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10034
10035         * lib/base64.c: Typo.
10036         (base64_encode): Put b64str in initialized data section.
10037
10038 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
10039
10040         Merge glibc and coreutils changes into gnulib, plus a few
10041         extra fixes.
10042         * lib/md5.c: Use #error rather than a string.
10043         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
10044         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
10045         (__attribute__): Define to empty for non recent-GCC.
10046         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
10047         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
10048         Renamed from their non-__ counterparts, with new macros replacing
10049         them if not _LIBC.  Add __THROW attribute.
10050         (rol): Remove.
10051         (struct md5_ctx): Align buffer if using GCC.
10052         * lib/sha1.h (struct sha1_ctx): Likewise.
10053         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
10054         The old name was backwards.
10055         (NOTSWAP): Remove; not used.
10056         (rol): New macro, moved here from md5.h.
10057         (sha1_process_block): Remove a FIXME that doesn't make sense.
10058
10059 2005-09-12  Derek Price  <derek@ximbiot.com>
10060
10061         Return usable errors from canon-host.
10062         * lib/canon-host.h: New file.
10063         * lib/canon-host.c (canon_host): Wrap...
10064         (canon_host_r): ...this new function, which now relies exclusively on
10065         getaddrinfo.
10066         (ch_strerror): New function.
10067         (last_cherror): New global.
10068         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
10069         interface.
10070         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
10071         void *.
10072         (freeaddrinfo): Free ai->ai_canonname when set.
10073
10074 2005-09-12  Derek Price  <derek@ximbiot.com>
10075
10076         Make canon-host require getaddrinfo.
10077         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
10078         AC_LIBSOURCE canon-host.h.  Call...
10079         (gl_PREREQ_CANON_HOST): ...this new function, which requires
10080         gl_GETADDRINFO.
10081         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
10082
10083 2005-09-12  Derek Price  <derek@ximbiot.com>
10084
10085         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
10086         LGPL.
10087         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
10088
10089 2005-09-12  Derek Price  <derek@ximbiot.com>
10090
10091         * lib/gai_strerror.c: Include config.h when available.  Include
10092         getaddrinfo.h before other headers to test interface.
10093         Reported by Larry Jones <lawrence.jones@ugs.com>.
10094
10095 2005-09-12  Derek Price  <derek@ximbiot.com>
10096             Paul Eggert  <eggert@cs.ucla.edu>
10097
10098         * modules/glob (Files): Add glob-libc.h.
10099
10100 2005-09-12  Derek Price  <derek@ximbiot.com>
10101             Paul Eggert  <eggert@cs.ucla.edu>
10102
10103         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
10104         glob_.h, glob-libc.h.
10105         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
10106
10107 2005-09-12  Derek Price  <derek@ximbiot.com>
10108             Paul Eggert  <eggert@cs.ucla.edu>
10109
10110         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
10111         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
10112         protecting things that should be done only in gnulib contexts.
10113         * lib/glob_.h: New file, containing only the glob things needed for
10114         gnulib.
10115         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
10116         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
10117         (glob, globfree, glob_pattern_p): Now defined simply in terms of
10118         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
10119         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
10120         and to respect the namespace rules better.
10121
10122 2005-09-08  Simon Josefsson  <jas@extundo.com>
10123
10124         * modules/socklen: New file.
10125
10126 2005-09-08  Simon Josefsson  <jas@extundo.com>
10127
10128         * m4/socklen.m4: New file.
10129
10130 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10131
10132         * modules/utimens (Files): Add m4/utimbuf.m4, since
10133         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
10134         Reported by Sergey Poznyakoff.
10135
10136 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10137
10138         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
10139         definitions, since that's the preferred style in glibc.
10140         Fix a minor spacing issue, and update copyright notice to match
10141         glibc's.
10142
10143 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10144
10145         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
10146
10147 2005-09-06  Simon Josefsson  <jas@extundo.com>
10148
10149         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
10150         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
10151
10152 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10153
10154         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
10155         warning.
10156
10157 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10158
10159         * config/srclist.txt: Add glibc bug 1302.
10160
10161 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
10162
10163         Change bitset word type from unsigned int to unsigned long int,
10164         as this has better performance on typical 64-bit hosts.
10165         Port bitset code to hosts with unusual word sizes.
10166         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
10167         (build_collating_symbol):
10168         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
10169         argument is a bitset.  This is merely a style issue, but it makes
10170         it clearer that an entire array is expected.
10171         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
10172         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
10173         Port to the case where bitset_word is not the same as unsigned int.
10174         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10175         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
10176         Likewise.
10177         * lib/regexec.c (check_dst_limits_calc_pos_1,
10178         check_subexp_matching_top):
10179         (build_trtable, group_nodes_into_DFAstates):
10180         Likewise.
10181         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
10182         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
10183         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
10184         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
10185         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
10186         * lib/regcomp.c (optimize_subexps, lower_subexp):
10187         Work even if bitset_word has holes in its bitwise representation.
10188         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
10189         * lib/regexec.c (check_dst_limits_calc_pos_1,
10190         check_subexp_matching_top):
10191         Likewise.
10192         * lib/regex_internal.c (re_string_reconstruct):
10193         Don't assume UCHAR_MAX == 255.
10194         * lib/regex_internal.h (bitset_set_all): Likewise.
10195         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
10196         All uses changed.
10197         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
10198         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
10199         All uses changed.
10200         (BITSET_WORD_MAX): New macro.
10201         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
10202         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
10203         (bitset_empty, bitset_copy):
10204         Prefer sizeof (bitset) to multiplying it out ourselves.
10205         (bitset_not_merge): Remove; unused.
10206         (bitset_contain): Return bool, not unsigned int with one bit on.
10207         All callers changed.
10208         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
10209         alignment than re_node_set; do this by defining a new internal
10210         type struct dests_alloc and using it to allocate memory.
10211
10212 2005-09-05  Bruno Haible  <bruno@clisp.org>
10213
10214         * gnulib-tool (func_import): Fix comparison in handling of symbolic
10215         links.
10216
10217 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
10218
10219         * modules/size_max (Makefile.am): Add size_max.h
10220
10221 2005-09-04  Derek Price  <derek@ximbiot.com>
10222
10223         * gnulib-tool (func_import): Fix reversed $symbolic logic.
10224
10225 2005-09-03  Simon Josefsson  <jas@extundo.com>
10226
10227         * gnulib-tool: Fix typo.
10228
10229 2005-09-03  Simon Josefsson  <jas@extundo.com>
10230
10231         * config/srclist.txt: Add glibc bug 1293.
10232
10233 2005-09-03  Derek Price  <derek@ximbiot.com>
10234
10235         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
10236         From Larry Jones <lawrence.jones@ugs.com>.
10237
10238 2005-09-02  Simon Josefsson  <jas@extundo.com>
10239
10240         * modules/socklen: New file.
10241
10242 2005-09-02  Simon Josefsson  <jas@extundo.com>
10243
10244         * modules/havelib: New module.
10245
10246         * modules/gettext, modules/iconv, modules/lock, modules/readline:
10247         Use havelib.
10248
10249 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10250
10251         Check for arithmetic overflow when calculating sizes, to prevent
10252         some buffer-overflow issues.  These patches are conservative, in the
10253         sense that when I couldn't determine whether an overflow was possible,
10254         I inserted a run-time check.
10255         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
10256         macros.
10257         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
10258         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
10259         (re_xnrealloc, re_x2nrealloc): New inline functions.
10260         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
10261         parse_bracket_exp):
10262         (build_equiv_class, build_charclass): Check for arithmetic overflow
10263         in size expression calculations.
10264         * lib/regex_internal.c (re_string_realloc_buffers):
10265         (build_wcs_upper_buffer, re_node_set_add_intersect):
10266         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
10267         (re_dfa_add_node, register_state): Likewise.
10268         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
10269         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
10270         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
10271         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
10272
10273 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10274
10275         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
10276         m4/ulonglong.m4.  Problem reported by Martin Lambers.
10277
10278 2005-09-02  Bruno Haible  <bruno@clisp.org>
10279
10280         Support for lib vs. lib64 distinction on biarch platforms.
10281         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
10282         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
10283         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
10284
10285 2005-09-02  Bruno Haible  <bruno@clisp.org>
10286
10287         * gnulib-tool (import): In the other first-use case, provide defaults
10288         as well.
10289
10290 2005-09-02  Bruno Haible  <bruno@clisp.org>
10291
10292         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
10293         patches not yet found in the latest gettext release.
10294
10295 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10296
10297         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
10298         to avoid a collision with bits/local_lim.h in glibc.
10299         All uses changed.  Problem reported by Dmitry V. Levin in
10300         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
10301
10302         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
10303         bugs in int versus size_t comparisons.
10304         (re_string_context_at): Fix bug where the code assumed that
10305         Idx is signed.
10306
10307         Use bool where appropriate.
10308         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
10309         All callers changed.
10310         (calc_eclosure_iter): Likewise, for ROOT arg.
10311         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
10312         (build_charclass_op): Likewise, for NON_MATCH arg.
10313         * lib/regex_internal.c (re_string_allocate, re_string_construct):
10314         (re_string_construct_common): Likewise, for ICASE arg.
10315         * lib/regexec.c (re_search_2_stub, re_search_stub):
10316         Likewise, for RET_LEN arg.
10317         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
10318         (set_regs): Likewise, for FL_BACKTRACK arg.
10319         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
10320         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
10321         (calc_eclosure_iter, parse_bracket_exp):
10322         Use bool for internal variables that are booleans.
10323         * lib/regexec.c (re_search_internal, check_matching,
10324         proceed_next_node):
10325         (set_regs, build_sifted_states, sift_states_bkref):
10326         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
10327         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
10328         (find_collation_sequence_value):
10329         Likewise.
10330         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
10331         (re_node_set_compare):
10332         Return bool, not int. All callers changed.
10333         * lib/regexec.c (check_halt_node_context, check_dst_limits):
10334         (build_trtable, check_node_accept): Likewise.
10335         * lib/regex_internal.h: Include stdbool.h.
10336
10337         Fix bugs uncovered when converting to bool.
10338         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
10339         failure instead of charging ahead blindly.
10340         * lib/regex_internal.c (register_state): Likewise.
10341         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
10342         for freeing internal storage.
10343         (group_nodes_into_DFA_states): Use unsigned int, not int, for
10344         bitset pieces used as boolean, to avoid undefined behavior
10345         on hosts that do int overflow checking.
10346
10347 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10348
10349         * config/srclist.txt: Add glibc bugs 1285-1287.
10350
10351 2005-09-01  Jim Meyering  <jim@meyering.net>
10352
10353         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
10354         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
10355         Require gl_STAT_MACROS, too.
10356
10357 2005-09-01  Bruno Haible  <bruno@clisp.org>
10358
10359         * gnulib-tool (import): In the first-use case, provide defaults.
10360
10361 2005-09-01  Bruno Haible  <bruno@clisp.org>
10362
10363         * gnulib-tool (func_import): Remove the .tmp files.
10364
10365 2005-09-01  Bruno Haible  <bruno@clisp.org>
10366
10367         * gnulib-tool (func_import): Fix handling of symbolic links.
10368
10369 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10370
10371         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
10372         old glibc regex code mishandles strings longer than 2**31 bytes.
10373         This patch fixes this when the regex code is used in gnulib
10374         (i.e., outside glibc).
10375
10376         This patch should not affect the use of the regex code inside
10377         glibc.  No doubt this problem also needs to be handled for glibc
10378         as well, but the result will be an incompatible change to the
10379         glibc ABI, and the old ABI will have to be supported too.  That
10380         can be the the subject for another patch.
10381
10382         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
10383         governing whether the rest of this patch is active.  By default,
10384         the macro is disabled and the patch has no effect.
10385         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
10386         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
10387         (struct re_pattern_buffer, re_search, re_search_2, re_match):
10388         (re_match_2, re_set_registers): Use the new types.
10389         * lib/regex_internal.h (Idx, re_hashval_t): New types.
10390         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
10391         New macros.
10392         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
10393         (re_string_context_at, bin_tree_t, re_dfastate_t):
10394         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
10395         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
10396         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
10397         (re_string_char_size_at, re_string_wchar_at):
10398         (re_string_elem_size_at):
10399         Use the new types and macros to port to 64-bit hosts.
10400         Use unsigned types for internal values, so that the code
10401         mostly works even for arrays larger than SSIZE_MAX.
10402         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
10403         (search_duplicated_node, calc_eclosure_iter, fetch_number):
10404         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
10405         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
10406         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
10407         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
10408         (calc_inveclosure, parse_dup_op, build_range_exp):
10409         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
10410         (fetch_number, create_token_tree, mark_opt_subexp):
10411         Likewise.
10412         * lib/regex_internal.c (re_string_construct_common,
10413         create_ci_newstate):
10414         (create_cd_newstate, re_string_allocate, re_string_construct):
10415         (re_string_realloc_buffers, build_wcs_upper_buffer):
10416         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
10417         (re_string_reconstruct, re_string_peek_byte_case):
10418         (re_string_fetch_byte_case, re_string_context_at):
10419         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
10420         (re_node_set_init_copy, re_node_set_add_intersect):
10421         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10422         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10423         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
10424         (re_acquire_state, re_acquire_state_context, register_state):
10425         Likewise.
10426         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
10427         search_cur_bkref_entry):
10428         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
10429         (re_search_internal, re_search_2_stub, re_search_stub)
10430         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
10431         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
10432         (update_cur_sifted_state, check_dst_limits):
10433         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10434         (check_subexp_limits, sift_states_bkref, merge_state_array):
10435         (check_subexp_matching_top, get_subexp, get_subexp_sub):
10436         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
10437         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
10438         (expand_bkref_cache, check_node_accept_bytes):
10439         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
10440         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
10441         (acquire_init_state_context, check_halt_node_context):
10442         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
10443         (sift_states_backward, clean_state_log_if_needed):
10444         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
10445         (find_recover_state, transit_state_sb, transit_state_mb):
10446         (transit_state_bkref, build_trtable, match_ctx_clean):
10447         Likewise.
10448         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
10449         to work around an assumption that REG_MISSING is negative.
10450
10451         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
10452         (seek_collating_symbol_entry) [defined _LIBC]:
10453         (lookup_collation_sequence_value) [defined _LIBC]:
10454         (build_range_exp, build_collating_symbol) [defined _LIBC]:
10455         Use prototypes rather than old-style function definitions.
10456         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
10457         (transit_state_sb) [0]:
10458         (find_collation_sequence_value) [defined _LIBC]: Likewise.
10459
10460         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
10461         rm_eo.
10462
10463         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
10464         (optimize_subexps, lower_subexp):
10465         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
10466         since the signed shift might overflow.  Use 1u<<31 instead.
10467         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10468         Likewise.
10469         * lib/regexec.c (check_dst_limits_calc_pos_1,
10470         check_subexp_matching_top): Likewise.
10471
10472         * lib/regcomp.c (optimize_subexps, lower_subexp):
10473         Use CHAR_BIT rather than 8, for clarity.
10474         * lib/regexec.c (check_dst_limits_calc_pos_1):
10475         (check_subexp_matching_top): Likewise.
10476         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
10477         have to worry about portability issues when shifting it left.
10478         Remove no-longer-needed test for table_size > 0.
10479         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
10480         in a word, as the resulting behavior is undefined.
10481         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
10482         in one case, a <= should have been an <, and in another case the
10483         whole test was missing.
10484         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
10485         the standard name CHAR_BIT.
10486         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
10487         this is not true on one's complement and signed-magnitude hosts.
10488
10489         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
10490         next_last_offset.
10491         (struct re_dfa_t): Remove unused member states_alloc.
10492         * lib/regcomp.c (init_dfa): Don't initialize unused members.
10493
10494 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10495
10496         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
10497         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
10498         and large-file glibc and in 32-bit large-file Solaris.
10499
10500 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10501
10502         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
10503         lengths fit in regoff_t; this isn't true if regoff_t is the same
10504         width as size_t.
10505         * lib/regex.c (re_search_internal): 5th arg is LAST_START
10506         (= START + RANGE) instead of RANGE.  This avoids overflow
10507         problems when regoff_t is the same width as size_t.
10508         All callers changed.
10509         (re_search_2_stub): Check for overflow when adding the
10510         sizes of the two strings.
10511         (re_search_stub): Check for overflow when adding START
10512         to RANGE; if it occurs, substitute the extreme value.
10513
10514 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10515
10516         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
10517
10518 2005-08-31  Jim Meyering  <jim@meyering.net>
10519
10520         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
10521         a pointer-to-const.
10522         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
10523         (register_state): Likewise.
10524         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
10525         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10526         (group_nodes_into_DFAstates): Likewise.
10527
10528 2005-08-31  Jim Meyering  <jim@meyering.net>
10529
10530         * check-module: Add a FIXME comment.
10531
10532 2005-08-31  Eric Blake  <ebb9@byu.net>
10533
10534         * modules/unistd-safer (Files): Add unistd--.h.
10535         * modules/stdio-safer (Files): Add stdio--.h.
10536
10537 2005-08-31  Derek Price  <derek@ximbiot.com>
10538
10539         * lib/getdelim.c (getdelim): Return EOF on EOF.
10540         Reported by Larry Jones <lawrence.jones@ugs.com>.
10541
10542 2005-08-31  Bruno Haible  <bruno@clisp.org>
10543
10544         Avoid unnecessary diffs in the generated lib/Makefile.am.
10545         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
10546         the generated files.
10547         (func_import): Don't set cmd.
10548
10549 2005-08-31  Bruno Haible  <bruno@clisp.org>
10550
10551         * lib/strstr.c: Include <stddef.h>, for NULL.
10552         * lib/strcasestr.c: Likewise.
10553         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10554
10555 2005-08-31  Bruno Haible  <bruno@clisp.org>
10556
10557         * gnulib-tool: New option --macro-prefix.
10558         (func_import): Use macro_prefix.
10559         (import): Handle option --macro-prefix.
10560
10561 2005-08-31  Bruno Haible  <bruno@clisp.org>
10562
10563         * gnulib-tool (import): Rename most ac_* variables to cached_*.
10564         Also use new variables cached_lgpl, cached_libtool.
10565
10566 2005-08-31  Bruno Haible  <bruno@clisp.org>
10567
10568         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
10569         always instantiating them.
10570
10571 2005-08-31  Bruno Haible  <bruno@clisp.org>
10572
10573         * gnulib-tool (func_import): Read the previous cached settings
10574         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
10575         earlier added by gnulib but are now dropped. Warn when a gnulib file
10576         overwrites a non-gnulib file.
10577
10578 2005-08-31  Bruno Haible  <bruno@clisp.org>
10579
10580         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
10581         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
10582         projects that don't keep autogenerated files in CVS. Put into
10583         actioncmd only the specified modules, not the transitive closure.
10584
10585 2005-08-31  Bruno Haible  <bruno@clisp.org>
10586
10587         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
10588         Create directories that shall be filled.
10589         (import): Don't look for gl_* macros in configure.ac. Recurse across
10590         all directories containing a gnulib-cache.m4 files, if meaningful.
10591
10592 2005-08-31  Bruno Haible  <bruno@clisp.org>
10593
10594         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
10595         (import): Set seen_libtool when we see gl_LIBTOOL.
10596
10597 2005-08-31  Bruno Haible  <bruno@clisp.org>
10598
10599         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
10600         declaration macro definitions from generated gnulib.m4.
10601
10602 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
10603
10604         * lib/iconvme.h: Add prototype for iconv_alloc.
10605
10606 2005-08-29  Simon Josefsson  <jas@extundo.com>
10607
10608         * lib/iconvme.c: Fix errno.
10609
10610 2005-08-29  Bruno Haible  <bruno@clisp.org>
10611
10612         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
10613         that it works when the directory contains spaces.
10614
10615 2005-08-29  Bruno Haible  <bruno@clisp.org>
10616
10617         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
10618
10619 2005-08-29  Bruno Haible  <bruno@clisp.org>
10620
10621         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
10622         Emit more advice.
10623
10624 2005-08-29  Bruno Haible  <bruno@clisp.org>
10625         and Stepan Kasal  <kasal@ucw.cz>
10626
10627         * check-module: If more parameters are given, check each of them
10628         separately; add more exceptions, as noted by Jim Meyering.
10629         (check_module): New procedure.
10630         (%exempt_header): Now contains all exceptions.
10631
10632 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
10633
10634         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
10635
10636 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
10637
10638         * lib/iconvme.c: Split iconv_string into iconv_alloc.
10639
10640 2005-08-28  Bruno Haible  <bruno@clisp.org>
10641
10642         * m4/gnulib-tool.m4: New file.
10643
10644 2005-08-27  Jim Meyering  <jim@meyering.net>
10645
10646         * modules/unistd-safer (Files): Add pipe-safer.c.
10647         * modules/fcntl-safer (Files): Add creat-safer.c.
10648
10649 2005-08-27  Jim Meyering  <jim@meyering.net>
10650
10651         * m4/stdlib-safer.m4: New file.  From coreutils.
10652         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
10653         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
10654         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
10655         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
10656         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
10657
10658 2005-08-27  Jim Meyering  <jim@meyering.net>
10659
10660         * lib/fopen-safer.c: Merge minor changes from coreutils.
10661         * lib/dup-safer.c: Likewise.
10662         * lib/fd-safer.c: Likewise.
10663
10664         Merge from coreutils.
10665         * lib/stdio--.h: New file.
10666         * lib/stdlib--.h: New file.
10667         * lib/mkstemp-safer.c: New file.
10668
10669         GNU tar needs these.
10670         * lib/pipe-safer.c: New file.
10671         * lib/creat-safer.c: New file.
10672         * lib/fcntl--.h (creat): Define to creat_safer.
10673         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
10674         * lib/unistd--.h (pipe): Define to pipe_safer.
10675         * lib/unistd-safer.h: Declare pipe_safer.
10676
10677 2005-08-26  Simon Josefsson  <jas@extundo.com>
10678
10679         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
10680         Haible <bruno@clisp.org>.
10681
10682 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
10683
10684         * lib/regex_internal.h: Remove all references to
10685         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
10686         or better.
10687         (bitset_not, bitset_merge, bitset_not_merge):
10688         (bitset_mask, re_string_allocate, re_string_construct):
10689         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
10690         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
10691         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
10692         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
10693         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10694         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10695         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
10696         (re_acquire_state_context):
10697         Remove unnecessary forward decls.
10698         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
10699         Put __attribute at function definition,
10700         now that the function decl has been removed.
10701         * lib/regex_internal.c (re_string_peek_byte_case):
10702         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
10703         Likewise.
10704
10705 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
10706
10707         * m4/regex.m4: Add AC_PREREQ(2.50).
10708         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
10709
10710 2005-08-25  Simon Josefsson  <jas@extundo.com>
10711
10712         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
10713         __fsetlocking.
10714
10715 2005-08-25  Simon Josefsson  <jas@extundo.com>
10716
10717         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
10718         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
10719         GLIBC specific code.
10720
10721 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10722
10723         Make regex safe for g++.  This fixes one real bug (an "err"
10724         that should have been "*err").  g++ problem reported by
10725         Sam Steingold.
10726         * lib/regex_internal.h (re_calloc): New macro, consistent with
10727         re_malloc etc.  All callers of calloc changed to use re_calloc.
10728         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
10729         not int.  All callers changed.
10730         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
10731         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
10732         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
10733         (find_recover_state): Change "err" to "*err"; this fixes what
10734         appears to be a real bug.
10735         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
10736         versus int.
10737
10738 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10739
10740         * modules/regex (Depends-on): Add malloc, since the code
10741         assumes that !malloc(0) means failure.
10742
10743 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10744
10745         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
10746
10747         alloca modernization/simplification for regex.
10748         * lib/regex.c: Remove portability cruft for alloca.  This no longer
10749         needs to be at the start of the file, and can be moved into
10750         regex_internal.h and simplified.
10751         * lib/regex_internal.h: Include <alloca.h>.
10752         (__libc_use_alloca) [!defined _LIBC]: New macro.
10753         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
10754         now works outside glibc.
10755
10756 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10757
10758         * config/srclist.txt: Add glibc bugs 1241, 1245.
10759
10760 2005-08-25  Jim Meyering  <jim@meyering.net>
10761
10762         * lib/open-safer.c: Include <config.h>.
10763         Otherwise, we'd lose LARGEFILE support in any file using
10764         e.g. "fcntl--.h"
10765
10766 2005-08-25  Bruno Haible  <bruno@clisp.org>
10767
10768         * m4/minmax.m4: Require autoconf 2.52.
10769         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
10770         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
10771         alternatives of translit over the alphabet.
10772         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
10773
10774 2005-08-24  Simon Josefsson  <jas@extundo.com>
10775
10776         * tests/test-getpass.c: New file.
10777
10778 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10779
10780         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
10781         for GNU regex features.
10782
10783 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10784
10785         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
10786         * lib/regex.h (regerror): Likewise.
10787
10788         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
10789         requires this.  (The code never needed it.)
10790
10791         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
10792         All uses of recently-renamed identifiers changed to use the new,
10793         POSIX-compliant names.  The code will build and run just fine
10794         without these changes, but it's better to eat our own dog food
10795         and use the standard-conforming names.
10796
10797         * lib/regex.h: Fix a multitude of POSIX name space violations.
10798         These changes have an effect only for programs that define
10799         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
10800         do not change anything for programs compiled in the normal way.
10801         Also, there is no effect on the ABI.
10802
10803         (_REGEX_SOURCE): New macro.
10804         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
10805         defined and _GNU_SOURCE is not; this fixes a name space violation.
10806
10807         Rename the following macros to obey POSIX requirements.
10808         The old names are still visible as macros if _REGEX_SOURCE is defined.
10809         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
10810         RE_BACKSLASH_ESCAPE_IN_LISTS.
10811         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
10812         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
10813         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
10814         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
10815         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
10816         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
10817         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
10818         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
10819         (REG_INTERVALS): renamed from RE_INTERVALS.
10820         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
10821         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
10822         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
10823         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
10824         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
10825         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
10826         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
10827         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
10828         RE_UNMATCHED_RIGHT_PAREN_ORD.
10829         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
10830         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
10831         (REG_DEBUG): renamed from RE_DEBUG.
10832         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
10833         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
10834         unusual, since we can't clash with the POSIX REG_ICASE.
10835         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
10836         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
10837         (REG_NO_SUB): renamed from RE_NO_SUB.
10838         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
10839         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
10840         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
10841         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
10842         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
10843         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
10844         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
10845         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
10846         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
10847         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
10848         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
10849         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
10850         RE_SYNTAX_POSIX_MINIMAL_BASIC.
10851         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
10852         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
10853         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
10854         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
10855         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
10856         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
10857         (REG_FIXED): Renamed from REGS_FIXED.
10858         (REG_NREGS): Renamed from RE_NREGS.
10859
10860         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
10861         of other REG_* macros, since POSIX says the user is allowed to
10862         #undef these macros selectively.
10863
10864         (reg_errcode_t): Update comment stating what other tables need
10865         to be consistent.
10866
10867         Rename the following enum values to obey POSIX requirements.
10868         The old names are still visible as macros.
10869         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
10870         is not defined, since GNU is supposed to be a superset of POSIX as
10871         much as possible, and since we want reg_errcode_t to be a signed
10872         type for implementation consistency.
10873         (_REG_NOERROR): Renamed from REG_NOERROR.
10874         (_REG_NOMATCH): Renamed from REG_NOMATCH.
10875         (_REG_BADPAT): Renamed from REG_BADPAT.
10876         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
10877         (_REG_ECTYPE): Renamed from REG_ECTYPE.
10878         (_REG_EESCAPE): Renamed from REG_EESCAPE.
10879         (_REG_ESUBREG): Renamed from REG_ESUBREG.
10880         (_REG_EBRACK): Renamed from REG_EBRACK.
10881         (_REG_EPAREN): Renamed from REG_EPAREN.
10882         (_REG_EBRACE): Renamed from REG_EBRACE.
10883         (_REG_BADBR): Renamed from REG_BADBR.
10884         (_REG_ERANGE): Renamed from REG_ERANGE.
10885         (_REG_ESPACE): Renamed from REG_ESPACE.
10886         (_REG_BADRPT): Renamed from REG_BADRPT.
10887         (_REG_EEND): Renamed from REG_EEND.
10888         (_REG_ESIZE): Renamed from REG_ESIZE.
10889         (_REG_ERPAREN): Renamed from REG_ERPAREN.
10890         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
10891         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
10892         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
10893         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
10894
10895         (_REG_RE_NAME, _REG_RM_NAME): New macros.
10896         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
10897         changed.  But support the old name if the new one is not defined
10898         and if _REGEX_SOURCE.
10899
10900         Change the following member names in struct re_pattern_buffer.
10901         The old names are still supported if !_REGEX_SOURCE.
10902         The new names are always supported, regardless of _REGEX_SOURCE.
10903         (re_buffer): Renamed from buffer.
10904         (re_allocated): Renamed from allocated.
10905         (re_used): Renamed from used.
10906         (re_syntax): Renamed from syntax.
10907         (re_fastmap): Renamed from fastmap.
10908         (re_translate): Renamed from translate.
10909         (re_can_be_null): Renamed from can_be_null.
10910         (re_regs_allocated): Renamed from regs_allocated.
10911         (re_fastmap_accurate): Renamed from fastmap_accurate.
10912         (re_no_sub): Renamed from no_sub.
10913         (re_not_bol): Renamed from not_bol.
10914         (re_not_eol): Renamed from not_eol.
10915         (re_newline_anchor): Renamed from newline_anchor.
10916
10917         Change the following member names in struct re_registers.
10918         The old names are still supported if !_REGEX_SOURCE.
10919         The new names are always supported, regardless of _REGEX_SOURCE.
10920         (rm_num_regs): Renamed from num_regs.
10921         (rm_start): Renamed from start.
10922         (rm_end): Renamed from end.
10923
10924         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
10925         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
10926         Prepend __ to parameter names.
10927
10928         Undo yesterday's changes.
10929
10930 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10931
10932         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
10933         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
10934         lib/regex.c.
10935
10936 2005-08-24  Jim Meyering  <jim@meyering.net>
10937
10938         Sync from coreutils.
10939         * m4/fcntl-safer.m4: New file.
10940
10941         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
10942         and object files for this module.
10943
10944 2005-08-24  Jim Meyering  <jim@meyering.net>
10945
10946         Sync from coreutils.
10947         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
10948
10949 2005-08-24  Jim Meyering  <jim@meyering.net>
10950
10951         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
10952         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
10953
10954 2005-08-24  Jim Meyering  <jim@meyering.net>
10955
10956         * modules/fcntl-safer: New module.
10957         * modules/fts (Depends-on): Add fcntl-safer.
10958         * MODULES.html.sh (File descriptor based Input/Output):
10959         Add fcntl-safer.
10960
10961 2005-08-24  Bruno Haible  <bruno@clisp.org>
10962
10963         Support for unit test modules.
10964         * modules/README: Mention tests modules.
10965         * modules/TEMPLATE-TESTS: New file.
10966         * gnulib-tool: New options --extract-tests-module, --with-tests and
10967         --tests-base (unused for the moment).
10968         (testsbase, inctests): New variables.
10969         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
10970         (func_verify_module): Exclude TEMPLATE-TESTS.
10971         (func_verify_nontests_module, func_verify_tests_module): New functions.
10972         (func_get_dependencies): Add implicit dependency for tests modules.
10973         (func_get_tests_module): New function.
10974         (func_modules_transitive_closure): When --with-tests was specified,
10975         include the unit tests as well, unless explicitly avoided.
10976         (func_emit_lib_Makefile_am): Ignore the tests modules here.
10977         (func_emit_tests_Makefile_am): New function.
10978         (func_create_testdir): When --with-tests was specified, emit a
10979         tests/ directory.
10980         * MODULES.html.sh (Future developments): Update.
10981
10982 2005-08-24  Bruno Haible  <bruno@clisp.org>
10983
10984         * modules/tls-tests: New file.
10985         * tests/test-tls.c: New file, from GNU gettext.
10986
10987 2005-08-24  Bruno Haible  <bruno@clisp.org>
10988
10989         * modules/lock-tests: New file.
10990         * tests/test-lock.c: New file, from GNU gettext.
10991
10992 2005-08-24  Bruno Haible  <bruno@clisp.org>
10993
10994         * lib/lock.h: Add multiple inclusion guard.
10995         * lib/tls.h: Add multiple inclusion guard.
10996
10997 2005-08-24  Bruno Haible  <bruno@clisp.org>
10998
10999         * gnulib-tool: Add support for the --aux-dir option to
11000         --create-testdir, --create-megatestdir, --test, --megatest.
11001         (func_create_testdir, func_create_megatestdir): Optionally emit a
11002         AC_CONFIG_AUX_DIR directive.
11003         (create-testdir, create-megatestdir, test, megatest): Provide a
11004         default value for $auxdir.
11005
11006 2005-08-24  Bruno Haible  <bruno@clisp.org>
11007
11008         * gnulib-tool (import): Use compound statement instead of subshell
11009         where possible.
11010
11011 2005-08-24  Bruno Haible  <bruno@clisp.org>
11012
11013         * gnulib-tool (import): Change --aux-dir default to "build-aux".
11014
11015 2005-08-24  Bruno Haible  <bruno@clisp.org>
11016
11017         * gnulib-tool (func_version): Update.
11018
11019 2005-08-24  Bruno Haible  <bruno@clisp.org>
11020
11021         * gnulib-tool (func_import, func_create_testdir,
11022         func_create_megatestdir): Quote all autoconf macro arguments.
11023
11024 2005-08-24  Bruno Haible  <bruno@clisp.org>
11025
11026         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
11027         option --force, because --force causes the aclocal.m4 of each
11028         subdirectory to be newer than the corresponding config.h.in.
11029
11030 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11031
11032         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
11033         All contents moved to gl_REGEX.
11034         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
11035         assume that it does.
11036
11037 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11038
11039         * lib/regex.h (REG_NOSYS)
11040         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
11041         Define, since POSIX requires it as of 2001.
11042         (_REG_ENOSYS)
11043         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
11044         New private symbol, used to keep the enum signed in all cases.
11045         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
11046         Youngman in
11047         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
11048
11049         * lib/regex_internal.c (re_string_skip_chars, register_state):
11050         (calc_state_hash):
11051         Remove forward decls; no longer needed now that we use prototypes.
11052         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
11053         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
11054         (clean_state_log_if_needed): Likewise.
11055
11056 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11057
11058         * config/srclist.txt: Add glibc bugs 1231-1233.
11059
11060 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11061
11062         Fix problems reported by Sam Steingold in
11063         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
11064         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
11065         assumed that reg_errcode_t is a signed type, which is not
11066         necessarily true if _XOPEN_SOURCE is not defined.
11067         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
11068         since some compilers warn about it otherwise.
11069
11070 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11071
11072         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
11073         (init_word_char, create_initial_state, duplicate_node_closure):
11074         (fetch_token, peek_token_bracket, build_range_exp):
11075         (build_collating_symbol): Remove forward decls; no longer needed
11076         now that we use prototypes.
11077
11078         * lib/regcomp.c:
11079         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
11080         (re_compile_fastmap_iter, regcomp, regerror, regfree):
11081         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
11082         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
11083         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
11084         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
11085         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
11086         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
11087         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
11088         (build_range_exp, build_collating_symbol, parse_bracket_exp):
11089         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
11090         (build_charclass, build_charclass_op, fetch_number, create_tree):
11091         (create_token_tree, mark_opt_subexp, duplicate_tree):
11092         Use prototypes rather than old-style definitions.
11093
11094         * lib/regex_internal.c:
11095         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
11096         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
11097         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11098         (re_string_reconstruct, re_string_peek_byte_case):
11099         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
11100         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11101         (re_node_set_init_copy, re_node_set_add_intersect):
11102         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11103         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11104         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11105         (re_acquire_state, re_acquire_state_context, register_state):
11106         (create_ci_newstate, create_cd_newstate, free_state):
11107         Likewise.
11108         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
11109         re_search_2):
11110         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
11111         (re_search_internal, prune_impossible_nodes):
11112         (acquire_init_state_context, check_matching, static):
11113         (check_halt_node_context, check_halt_state_context, proceed_next_node):
11114         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
11115         (update_regs, sift_states_backward, build_sifted_states):
11116         (clean_state_log_if_needed, merge_state_array):
11117         (update_cur_sifted_state, add_epsilon_src_nodes):
11118         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
11119         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
11120         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
11121         (find_recover_state, check_subexp_matching_top, transit_state_mb):
11122         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
11123         (check_arrival, check_arrival_add_next_nodes):
11124         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11125         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11126         (check_node_accept_bytes, check_node_accept, extend_buffers):
11127         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
11128         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
11129         (sift_ctx_init):
11130         Likewise.
11131
11132         * lib/regex_internal.h:
11133         (re_string_allocate, re_string_construct, re_string_reconstruct):
11134         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
11135         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
11136         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
11137         (re_string_context_at, re_string_peek_byte_case):
11138         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
11139         is defined, since we now use prototypes always.
11140
11141         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
11142         C89 or better.  All uses removed.
11143
11144 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11145
11146         * config/srclist.txt: Add glibc bugs 1220-1227.
11147
11148 2005-08-20  Jim Meyering  <jim@meyering.net>
11149
11150         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
11151         of unused local, dfa.
11152
11153 2005-08-20  Bruno Haible  <bruno@clisp.org>
11154
11155         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
11156
11157 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11158
11159         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
11160         (re_node_set_insert_last, re_dfa_add_node):
11161         Rename local variables to avoid GCC shadowing warnings.
11162
11163 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11164
11165         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
11166         [defined lint]: Suppress bogus uninitialized-variable warnings.
11167
11168         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
11169         and let the caller return REG_ESPACE if out of space.  This
11170         removes an uninitialied-variable warning with GCC 4.0.1, and also
11171         avoids taking the address of a local variable.  All callers
11172         changed.
11173
11174 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11175
11176         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
11177         $LIBCSRC/posix/regexec.c.
11178         Add glibc bug 1217 for regcomp.c.
11179
11180 2005-08-19  Jim Meyering  <jim@meyering.net>
11181
11182         * lib/regexec.c (proceed_next_node): Redo local variables to
11183         avoid GCC shadowing warnings.
11184
11185 2005-08-18  Bruno Haible  <bruno@clisp.org>
11186
11187         * lib/strstr.c (strstr): Fix return value in multibyte case.
11188         * lib/strcasestr.c (strcasestr): Likewise.
11189
11190 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11191
11192         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
11193
11194 2005-08-17  Jim Meyering  <jim@meyering.net>
11195
11196         Make the %s format (seconds since the epoch) work for a negative
11197         number and when used with a zero-padded field width, e.g. %015s.
11198
11199         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
11200         label so that it precedes the code to set `digits'.  Otherwise,
11201         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
11202         print `00-22'.  Now, it prints `-0022', as it should.
11203
11204 2005-08-17  Bruno Haible  <bruno@clisp.org>
11205
11206         * modules/strstr (Files): Add m4/mbrtowc.m4.
11207         (Depends-on): Add mbuiter.
11208
11209 2005-08-17  Bruno Haible  <bruno@clisp.org>
11210
11211         * modules/strcasestr: New file.
11212         * MODULES.html.sh (String handling, based on ANSI C 89): Add
11213         strcasestr.
11214
11215 2005-08-17  Bruno Haible  <bruno@clisp.org>
11216
11217         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
11218
11219 2005-08-17  Bruno Haible  <bruno@clisp.org>
11220
11221         * modules/mbuiter: New file.
11222         * MODULES.html.sh (Extended multibyte and wide character utilities):
11223         Add mbuiter.
11224
11225 2005-08-17  Bruno Haible  <bruno@clisp.org>
11226
11227         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
11228         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
11229
11230 2005-08-17  Bruno Haible  <bruno@clisp.org>
11231
11232         * m4/strcasestr.m4: New file.
11233
11234 2005-08-17  Bruno Haible  <bruno@clisp.org>
11235
11236         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
11237         * lib/strstr.c: Completely rewritten, with multibyte locale support.
11238
11239 2005-08-17  Bruno Haible  <bruno@clisp.org>
11240
11241         * lib/strcasestr.h: New file.
11242         * lib/strcasestr.c: New file.
11243
11244 2005-08-17  Bruno Haible  <bruno@clisp.org>
11245
11246         * lib/strcasecmp.c: Use mbuiter.h.
11247
11248 2005-08-17  Bruno Haible  <bruno@clisp.org>
11249
11250         * lib/mbuiter.h: New file.
11251
11252 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11253
11254         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
11255         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
11256         and gl_GETOPT are both invoked via different paths (as happens
11257         with GNU tar CVS because it uses both argp and getopt), the former
11258         wins.
11259
11260 2005-08-16  Bruno Haible  <bruno@clisp.org>
11261
11262         * modules/tls: New file.
11263         * MODULES.html.sh (Multithreading): Add tls.
11264
11265 2005-08-16  Bruno Haible  <bruno@clisp.org>
11266
11267         * modules/strnlen1: New file.
11268         * MODULES.html.sh (String handling): Add strnlen1.
11269
11270 2005-08-16  Bruno Haible  <bruno@clisp.org>
11271
11272         * modules/strcase (Files): Add m4/mbrtowc.m4.
11273         (Depends-on): Add strnlen1, mbchar.
11274
11275 2005-08-16  Bruno Haible  <bruno@clisp.org>
11276
11277         * modules/mbiter: New file.
11278         * MODULES.html.sh (Extended multibyte and wide character utilities):
11279         Add mbiter.
11280
11281 2005-08-16  Bruno Haible  <bruno@clisp.org>
11282
11283         * modules/mbfile: New file.
11284         * MODULES.html.sh (Extended multibyte and wide character utilities):
11285         Add mbfile.
11286
11287 2005-08-16  Bruno Haible  <bruno@clisp.org>
11288
11289         * modules/mbchar: New file.
11290         * MODULES.html.sh (Extended multibyte and wide character utilities):
11291         New section.
11292
11293 2005-08-16  Bruno Haible  <bruno@clisp.org>
11294
11295         * m4/tls.m4: New file, from GNU gettext.
11296
11297 2005-08-16  Bruno Haible  <bruno@clisp.org>
11298
11299         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
11300         always.
11301         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
11302
11303 2005-08-16  Bruno Haible  <bruno@clisp.org>
11304
11305         * m4/mbiter.m4: New file.
11306
11307 2005-08-16  Bruno Haible  <bruno@clisp.org>
11308
11309         * m4/mbfile.m4: New file.
11310
11311 2005-08-16  Bruno Haible  <bruno@clisp.org>
11312
11313         * m4/mbchar.m4: New file.
11314
11315 2005-08-16  Bruno Haible  <bruno@clisp.org>
11316
11317         * lib/tls.h: New file, from GNU gettext.
11318         * lib/tls.c: New file, from GNU gettext.
11319
11320 2005-08-16  Bruno Haible  <bruno@clisp.org>
11321
11322         * lib/strnlen1.h: New file.
11323         * lib/strnlen1.c: New file.
11324
11325 2005-08-16  Bruno Haible  <bruno@clisp.org>
11326
11327         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
11328         (mbi_init): Update.
11329         (mbi_avail, mbi_advance): Let the iteration end before the terminating
11330         NUL byte, not after it.
11331
11332 2005-08-16  Bruno Haible  <bruno@clisp.org>
11333
11334         * lib/strcase.h (strcasecmp): Add note in comments.
11335         * lib/strncasecmp.c: Use code from strcasecmp.c.
11336         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
11337         (strcasecmp): Work correctly in multibyte locales.
11338
11339 2005-08-16  Bruno Haible  <bruno@clisp.org>
11340
11341         * lib/mbiter.h: New file.
11342
11343 2005-08-16  Bruno Haible  <bruno@clisp.org>
11344
11345         * lib/mbfile.h: New file.
11346
11347 2005-08-16  Bruno Haible  <bruno@clisp.org>
11348
11349         * lib/mbchar.h: New file.
11350         * lib/mbchar.c: New file.
11351
11352 2005-08-16  Bruno Haible  <bruno@clisp.org>
11353
11354         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
11355         the valid ones. Makes the comparison operations transitive:
11356         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
11357         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
11358
11359 2005-08-15  Simon Josefsson  <jas@extundo.com>
11360
11361         * modules/ssize_t (License): Change to 'unlimited'.
11362
11363         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
11364
11365 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11366
11367         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
11368         Add comments for each pending glibc patch.
11369
11370 2005-08-15  Bruno Haible  <bruno@clisp.org>
11371
11372         * lib/regex.h (__restrict_arr): Don't define to __restrict if
11373         __cplusplus is defined.
11374
11375 2005-08-14  Jim Meyering  <jim@meyering.net>
11376
11377         Sync from coreutils.
11378
11379         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
11380         Use the hash-table-based cycle-detection code not just when
11381         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
11382         Reported by James Youngman in
11383         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
11384         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
11385         FTS_TIGHT_CYCLE_CHECK.
11386         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
11387         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
11388         once again.
11389         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
11390         * lib/fts.c (fd_safer): Remove decl.
11391         Include fcntl--.h rather than unistd-safer.h
11392         (fts_safe_changedir): Don't call fd_safer; no longer needed
11393         now that we include fcntl--.h.
11394
11395 2005-08-12  Simon Josefsson  <jas@extundo.com>
11396
11397         * modules/getndelim2: Use ssize_t module.
11398         * modules/getnline: Likewise.
11399         * modules/safe-read: Likewise.
11400         * modules/xreadlink: Likewise.
11401
11402         * modules/ssize_t: New file.
11403
11404 2005-08-12  Simon Josefsson  <jas@extundo.com>
11405
11406         * m4/readline.m4: Look for termcap, curses or ncurses if required.
11407
11408 2005-08-12  Simon Josefsson  <jas@extundo.com>
11409
11410         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11411         ssize_t.
11412
11413 2005-08-12  Simon Josefsson  <jas@extundo.com>
11414
11415         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
11416         readline, getdelim and check_version.
11417         (Support for systems lacking ISO C 99: Sizes of integer types):
11418         Add size_max.
11419
11420 2005-08-12  Bruno Haible  <bruno@clisp.org>
11421
11422         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
11423
11424 2005-08-11  Simon Josefsson  <jas@extundo.com>
11425
11426         * modules/readline: New file.
11427
11428         * modules/strnlen (Files): Add strnlen.h.
11429
11430 2005-08-11  Simon Josefsson  <jas@extundo.com>
11431
11432         * m4/readline.m4: New file.
11433
11434 2005-08-11  Simon Josefsson  <jas@extundo.com>
11435
11436         * lib/readline.h, readline.c: New file.
11437
11438 2005-08-11  Simon Josefsson  <jas@extundo.com>
11439
11440         * doc/gnulib.texi (Initial import, Finishing touches): Mention
11441         gl_AVOID.
11442
11443 2005-08-11  Bruno Haible  <bruno@clisp.org>
11444
11445         * lib/strnlen.h (strnlen): Change parameter name to match comment.
11446
11447 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
11448
11449         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
11450
11451 2005-08-10  Simon Josefsson  <jas@extundo.com>
11452
11453         * tests/test-iconvme.c: New file.
11454
11455 2005-08-10  Simon Josefsson  <jas@extundo.com>
11456
11457         * m4/strnlen.m4: New file.
11458
11459         * m4/strndup.m4: Don't check for strnlen declaration, done in
11460         strnlen.m4.
11461
11462 2005-08-10  Simon Josefsson  <jas@extundo.com>
11463
11464         * lib/strndup.c: Use strnlen.h.
11465
11466         * lib/strnlen.h: New file.
11467
11468 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11469
11470         * README: Typos.
11471
11472 2005-08-02  Simon Josefsson  <jas@extundo.com>
11473
11474         * modules/readline: New file.
11475
11476 2005-08-02  Simon Josefsson  <jas@extundo.com>
11477
11478         * modules/getdelim: New file.
11479
11480         * modules/getline: Rewrite, don't use getndelim2.
11481
11482 2005-08-02  Simon Josefsson  <jas@extundo.com>
11483
11484         * m4/getline.m4: Separate out getdelim stuff into separate module.
11485
11486         * m4/getdelim.m4: New file.
11487
11488 2005-08-02  Simon Josefsson  <jas@extundo.com>
11489
11490         * lib/getline.h, getline.c: Rewrite.
11491
11492         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
11493
11494 2005-07-31  Bruno Haible  <bruno@clisp.org>
11495
11496         * lib/lock.h (gl_lock_initializer): New macro.
11497         (gl_lock_define_initialized): Use it.
11498         (gl_rwlock_initializer): New macro.
11499         (gl_rwlock_define_initialized): Use it.
11500         (gl_recursive_lock_initializer): New macro.
11501         (gl_recursive_lock_define_initialized): Use it.
11502
11503 2005-07-30  Karl Berry  <karl@gnu.org>
11504
11505         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
11506         Report from Ben Pfaff, regarding getopt.
11507
11508 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
11509
11510         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
11511         normal way.
11512         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
11513         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
11514         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
11515         (gl_GETOPT): Use the new macros.  Most of the implementation
11516         is moved to the new macros.  This is for programs like Emacs
11517         that don't want all the functionality of gl_GETOPT.
11518
11519 2005-07-26  Bruno Haible  <bruno@clisp.org>
11520
11521         * m4/lock.m4: Update from GNU gettext.
11522
11523 2005-07-26  Bruno Haible  <bruno@clisp.org>
11524
11525         * lib/lock.h: Update from GNU gettext.
11526         * lib/lock.c: Update from GNU gettext.
11527
11528 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
11529
11530         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
11531         obsolescent AC_TRY_RUN.  Include the default includes files, for
11532         'exit'.
11533
11534 2005-07-24  Bruno Haible  <bruno@clisp.org>
11535
11536         * modules/visibility: New file.
11537         * MODULES.html.sh (Misc): Add visibility.
11538
11539 2005-07-24  Bruno Haible  <bruno@clisp.org>
11540
11541         * m4/visibility.m4: New file.
11542
11543 2005-07-24  Bruno Haible  <bruno@clisp.org>
11544
11545         * doc/visibility.texi: New file.
11546
11547 2005-07-22  Bruno Haible  <bruno@clisp.org>
11548
11549         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
11550         $(ALLOCA_H), redundant through BUILT_SOURCES.
11551         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
11552         redundant through BUILT_SOURCES.
11553         * modules/byteswap (Makefile.am): Remove explicit dependency on
11554         $(BYTESWAP_H), redundant through BUILT_SOURCES.
11555         * modules/fnmatch (Makefile.am): Remove explicit dependency on
11556         $(FNMATCH_H), redundant through BUILT_SOURCES.
11557         * modules/getopt (Makefile.am): Remove explicit dependency on
11558         $(GETOPT_H), redundant through BUILT_SOURCES.
11559         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
11560         redundant through BUILT_SOURCES.
11561         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
11562         redundant through BUILT_SOURCES.
11563         * modules/stdbool (Makefile.am): Remove explicit dependency on
11564         $(STDBOOL_H), redundant through BUILT_SOURCES.
11565         * modules/stdint (Makefile.am): Remove explicit dependency on
11566         $(STDINT_H), redundant through BUILT_SOURCES.
11567         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
11568         Remove explicit dependency on $(SYSEXITS_H).
11569         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
11570
11571 2005-07-18  Simon Josefsson  <jas@extundo.com>
11572
11573         * lib/check-version.c (check_version): Accept identical versions too.
11574
11575 2005-07-18  Bruno Haible  <bruno@clisp.org>
11576
11577         * modules/lock: New file.
11578         * MODULES.html.sh (Multithreading): New section.
11579
11580 2005-07-18  Bruno Haible  <bruno@clisp.org>
11581
11582         * m4/lock.m4: New file, from GNU gettext.
11583
11584 2005-07-18  Bruno Haible  <bruno@clisp.org>
11585
11586         * lib/lock.h: New file, from GNU gettext.
11587         * lib/lock.c: New file, from GNU gettext.
11588
11589 2005-07-18  Bruno Haible  <bruno@clisp.org>
11590
11591         * lib/lock.h (gl_once_t): New type.
11592         (gl_once_define, gl_once): New macros.
11593         * lib/lock.c (fresh_once): New variable.
11594         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
11595         functions.
11596
11597 2005-07-16  Simon Josefsson  <jas@extundo.com>
11598
11599         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
11600         workaround, suggested by Bruno.
11601
11602 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11603
11604         * modules/xalloc (Depends-on): Add xalloc-die.
11605         * modules/xvasprintf (Depends-on): Add xalloc-die.
11606
11607 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11608
11609         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
11610         with a minor change.
11611
11612 2005-07-15  Bruno Haible  <bruno@clisp.org>
11613
11614         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
11615         When using lib/poll.c, define poll as rpl_poll.
11616
11617 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
11618
11619         * modules/argp (Depends-on): Remove unlocked-io.
11620
11621 2005-07-14  Derek Price  <derek@ximbiot.com>
11622
11623         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
11624         for glob symlink bug.
11625
11626 2005-07-14  Bruno Haible  <bruno@clisp.org>
11627
11628         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
11629         Instead, test for *_unlocked function declarations directly.
11630
11631 2005-07-11  Simon Josefsson  <jas@extundo.com>
11632
11633         * modules/size_max: New file.
11634
11635         * modules/xsize: Depend on size_max module for size_max.m4.
11636
11637 2005-07-11  Simon Josefsson  <jas@extundo.com>
11638
11639         * lib/size_max.h: New file.
11640
11641 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
11642
11643         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
11644         copyright symbol and the year.
11645         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
11646         (version_etc_va): Use parameterized copyright notice.
11647         Reword to conform to the current GNU coding standards.
11648
11649 2005-07-11  Karl Berry  <karl@gnu.org>
11650
11651         * doc/gnulib.texi (Quoting): new node.
11652         (Initial import): more info, from Patrice.
11653
11654 2005-07-11  Bruno Haible  <bruno@clisp.org>
11655
11656         * gnulib-tool (func_usage): Document option --avoid.
11657         (Command line options): Handle --avoid.
11658         (func_acceptable): New function.
11659         (func_modules_transitive_closure): Use it.
11660
11661 2005-07-11  Bruno Haible  <bruno@clisp.org>
11662
11663         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
11664         Reported by Jim Meyering.
11665
11666 2005-07-10  Bruno Haible  <bruno@clisp.org>
11667
11668         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
11669         Needed when size_t is smaller than 'unsigned int'.
11670         Reported by Paul Eggert.
11671
11672 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11673
11674         * modules/argp (Depends-on): Add unlocked-io
11675
11676 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11677
11678         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
11679         block of defines.
11680
11681 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11682
11683         * config/srclist.txt: Comment out regcomp.c, since we have a porting
11684         fix now.
11685
11686 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
11687         and Paul Eggert  <eggert@cs.ucla.edu>
11688
11689         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
11690         in wint_t, not wchar_t.  Remove now-unnecessary cast.
11691
11692 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11693
11694         * modules/regex (Files): Add lib/regex_internal.c,
11695         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
11696         (Depends-on): Add extensions.
11697         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
11698
11699 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11700
11701         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
11702         pathconf.
11703         * m4/same.m4 (gl_SAME): Likewise.
11704         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
11705
11706         * m4/regex.m4: Adjust to new libc regex implementation.
11707         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
11708         all the .c and .h parts of (the new) regex.
11709         Quote the m4 stuff better.
11710         Check for RE_ICASE bug of old gnulib.
11711         Check for REG_STARTEND of recent libc.
11712         Rename local variables from jm_* to gl_*.
11713         Quote operand of "test -f".
11714         Say "recent enough" version of libc, not "version 2".
11715         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
11716         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
11717         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
11718         Remove check for btowc, isascii.
11719         Require AM_LANGINFO_CODESET.
11720
11721 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11722
11723         * lib/regex.c, regex.h: Sync from libc.
11724         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
11725         * lib/regexec.c:
11726         New files, synced from libc, except that regex_internal.h
11727         currently has a small porting fix.
11728
11729 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11730
11731         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
11732         regex_internal.c, regexec.c.
11733         Add regex_internal.h too, but as a comment, since the libc version
11734         is currently broken in gnulib mode.
11735
11736 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11737
11738         Support programs like Emacs that use gnulib but not gettext.
11739         * MODULES.html.sh (Internationalization functions): Add gettext-h.
11740         * modules/gettext-h: New file.
11741         * modules/gettext (Files): Remove lib/gettext.h.
11742         (Depends-on): Add gettext-h.
11743         (Makefile.am): Remove lib_SOURCES.
11744         * modules/argmatch, modules/c-stack, modules/closeout:
11745         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
11746         * modules/execute, modules/file-type, modules/getaddrinfo:
11747         * modules/getopt, modules/human, modules/javacomp:
11748         * modules/javaexec, modules/mkdir-p, modules/obstack:
11749         * modules/openat, modules/pagealign_alloc, modules/pipe:
11750         * modules/quotearg, modules/regex, modules/rpmatch:
11751         * modules/unicodeio, modules/userspec, modules/version-etc:
11752         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
11753         * modules/xsetenv:
11754         Depend on gettext-h, not gettext.
11755
11756 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11757
11758         * gnulib-tool (func_import): Add support for 'public domain' license.
11759         * modules/alloca, modules/atexit, modules/memmove:
11760         Now public domain, not GPL.
11761         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
11762         * modules/realloc, modules/strerror, modules/strtod:
11763         Now LGPL, not GPL.
11764
11765 2005-07-05  Bruno Haible  <bruno@clisp.org>
11766
11767         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
11768         autoconf CVS. Needed for mingw.
11769
11770 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11771
11772         Remove the dependency of the strftime module on the tzset module.
11773         * modules/strftime (Depends-on): Remove dependency on tzset.
11774
11775 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11776
11777         Remove the dependency of the strftime module on the tzset module.
11778         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
11779         gl_FUNC_TZSET_CLOBBER.
11780
11781 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11782
11783         Remove the dependency of the strftime module on the tzset module.
11784         * lib/strftime.c (my_strftime)
11785         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
11786         Copy the input structure, to work around some of the bug with
11787         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
11788         Solaris releases, you should also use the tzset module, but we won't
11789         require it as a dependency any more since we don't want LGPLed code
11790         to depend on GPLed code.
11791
11792 2005-07-02  Jim Meyering  <jim@meyering.net>
11793
11794         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
11795         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
11796         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
11797         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
11798
11799 2005-07-02  Jim Meyering  <jim@meyering.net>
11800
11801         * lib/backupfile.c (backup_args): Change a `0' to NULL.
11802
11803 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11804
11805         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
11806         declares only 'struct timespec;' (!).
11807
11808 2005-07-01  Jim Meyering  <jim@meyering.net>
11809
11810         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
11811         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
11812         * lib/save-cwd.c, tempname.c:
11813         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
11814         and don't include <sys/file.h>).
11815
11816 2005-06-29  Jim Meyering  <jim@meyering.net>
11817
11818         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
11819         type name.  Use the variable name instead.
11820         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
11821         Likewise.
11822
11823 2005-06-28  Simon Josefsson  <jas@extundo.com>
11824
11825         * modules/check-version (Files): Add check-version.m4.
11826
11827 2005-06-28  Simon Josefsson  <jas@extundo.com>
11828
11829         * m4/check-version.m4: New file, suggested by Jim Meyering
11830         <jim@meyering.net>.
11831
11832 2005-06-28  Simon Josefsson  <jas@extundo.com>
11833
11834         * lib/check-version.h, lib/check-version.c: New files.
11835
11836 2005-06-28  Simon Josefsson  <jas@extundo.com>
11837
11838         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
11839         collision with global variable.  Better indentation.  Don't
11840         increment buffer pointer beyond buffer end.  Based on comments
11841         from Paul Eggert <eggert@cs.ucla.edu>.
11842
11843         * lib/base64.h: Indent.
11844
11845 2005-06-28  Simon Josefsson  <jas@extundo.com>
11846
11847         * doc/gnulib.texi (Library version handling): New section.
11848
11849 2005-06-28  Jim Meyering  <jim@meyering.net>
11850
11851         * check-module (find_included_lib_files): Hard-code another
11852         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
11853         but modules/fts-lgpl (correctly) does not list those files.
11854
11855         * modules/canonicalize (Files): Add lib/pathmax.h.
11856
11857 2005-06-25  Simon Josefsson  <jas@extundo.com>
11858
11859         * modules/check-version: New file.
11860
11861 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
11862
11863         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
11864         initializer of struct addrinfo, as an indication that we don't
11865         care how many members the structure has.
11866
11867 2005-06-24  Derek Price  <derek@ximbiot.com>
11868         and Bruno Haible  <bruno@clisp.org>
11869
11870         Remove stat module & update lstat.
11871         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
11872         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
11873         * m4/stat.m4: Remove this file.
11874
11875 2005-06-24  Derek Price  <derek@ximbiot.com>
11876         and Bruno Haible  <bruno@clisp.org>
11877
11878         Remove stat module & update lstat.
11879         * lib/stat.c: Remove this file...
11880         (slash_aware_lstat): ...moving this content and its support...
11881         * lib/lstat.c (rpl_lstat): ...into here.
11882         * lib/lstat.h: New file.
11883
11884 2005-06-24  Derek Price  <derek@ximbiot.com>
11885         and Bruno Haible  <bruno@clisp.org>
11886
11887         Remove stat module & update lstat.
11888         * config/srclist.txt (libc sources): Remove stat.
11889
11890 2005-06-24  Derek Price  <derek@ximbiot.com>
11891         and Bruno Haible  <bruno@clisp.org>
11892
11893         Remove stat module & update lstat.
11894         * MODULES.html.sh (stat): Remove.
11895         * MODULES.html: Regenerated.
11896         * modules/lstat (Description): Correct function name.
11897         (Files): Add "lstat.h".
11898         (Depends-on): Remove stat, add xalloc, stat-macros.
11899         * modules/stat: Remove this file.
11900         (Include): Add "lstat.h", remove <sys/stat.h>.
11901
11902 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
11903
11904         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
11905         (ranged_convert): Don't save conversion in a temporary struct.
11906         This causes a warning with GCC 4.0.0, and anyway in the typical
11907         case it's not worth the extra 100 bytes or so of code.
11908         (ranged_convert, __mktime_internal): When calling a function via a
11909         pointer P, use P () rather than (*P) (), as we now assume C89 or
11910         better.
11911
11912 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
11913
11914         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
11915         "who -r" failed to give output.  Problem reported by Tim Waugh.
11916
11917         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
11918         (xcalloc): Use it to avoid needless tests.
11919         Problem reported by Jim Meyering.
11920
11921 2005-06-20  Derek Price  <derek@ximbiot.com>
11922
11923         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
11924         unnecessary for Autoconfs > 2.59c.
11925
11926 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11927
11928         * lib/argp.h (__option_is_short): Check upper limit of
11929         __key. Isprint() requires its argument to have the value
11930         of an unsigned char or EOF.
11931
11932 2005-06-16  Jim Meyering  <jim@meyering.net>
11933
11934         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
11935         when either N or S is zero.
11936
11937 2005-06-16  Derek Price  <derek@ximbiot.com>
11938
11939         * m4/bison.m4: Declare YACC & YFLAGS precious.
11940
11941 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
11942
11943         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
11944         multibyte string or pattern, fall back on unibyte matching.
11945         Problem reported by James Youngman.
11946
11947 2005-06-08  Bruno Haible  <bruno@clisp.org>
11948
11949         * modules/csharpcomp: New file.
11950         * MODULES.html.sh (C#): Add csharpcomp.
11951
11952 2005-06-08  Bruno Haible  <bruno@clisp.org>
11953
11954         * m4/csharpcomp.m4: New file, from GNU gettext.
11955
11956 2005-06-08  Bruno Haible  <bruno@clisp.org>
11957
11958         * lib/csharpcomp.h: New file, from GNU gettext.
11959         * lib/csharpcomp.c: New file, from GNU gettext.
11960         * lib/csharpcomp.sh.in: New file, from GNU gettext.
11961
11962 2005-06-08  Bruno Haible  <bruno@clisp.org>
11963
11964         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
11965         warning on mingw.
11966
11967 2005-06-07  Derek Price  <derek@ximbiot.com>
11968
11969         Sync from CVS.
11970         * lib/glob_.h: Indent nested #ifdef.
11971
11972 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
11973
11974         Sync from coreutils.
11975         Use "file name" when talking about file names, instead of "filename"
11976         or "path", as per the GNU coding standards.
11977         * lib/mkdir-p.c: Renamed from makepath.c.
11978         (make_dir_parents): Renamed from make_path.  All callers changed.
11979         * lib/mkdir-p.h: Likewise.  All includers changed.
11980         * lib/filenamecat.c: Renamed from path-concat.c.
11981         (file_name_concat): Renamed from path_concat.  All callers changed.
11982         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
11983         * lib/filenamecat.h: Likewise.  All includers changed.
11984         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
11985         in comments or local variable names.
11986         * lib/basename.c: Likewise.
11987         * lib/canonicalize.c, canonicalize.h: Likewise.
11988         * lib/dirname.c, dirname.h: Likewise.
11989         * lib/euidaccess.c: Likewise.
11990         * lib/exclude.c: Likewise
11991         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
11992         * lib/fsusage.c, fsuage.h: Likewise.
11993         * lib/fts.c, fts_.h: Likewise.
11994         * lib/getcwd.c: Likewise.
11995         * lib/getloadavg.c: Likewise.
11996         * lib/mkstemp.c: Likewise.
11997         * lib/mountlist.c, mountlist.h: Likewise.
11998         * lib/openat.c, openat.h: Likewise.
11999         * lib/readlink-stub.c: Likewise.
12000         * lib/readutmp.c, readutmp.h: Likewise.
12001         * lib/rename.c: Likewise.
12002         * lib/rmdir.c: Likewise.
12003         * lib/same.c: Likewise.
12004         * lib/savedir.c: Likewise.
12005         * lib/stripslash.c: Likewise.
12006         * lib/tempname.c: Likewise.
12007         * lib/xreadlink.c: Likewise.
12008         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
12009         All uses changed.
12010         * lib/exclude.h: Likewise.
12011
12012         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
12013         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12014         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
12015         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12016         * lib/pathmax.h: Include <limits.h> unconditionally, since other
12017         files have been getting away with it for years (MORE/BSD 4.3
12018         is extinct now).
12019         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
12020         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12021
12022         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
12023         Define to 256, not 255, as per modern POSIX.
12024
12025 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12026
12027         Sync from coreutils.
12028         Use "file name" when talking about file names, instead of "filename"
12029         or "path", as per the GNU coding standards.
12030         * MODULES.html.sh: mkdir-p renamed from makepath.
12031         filenamecat renamed from path-concat.
12032         * modules/filenamecat: Renamed from modules/path-concat.
12033         (Files): filenamecat.h and filenamecat.c renamed from
12034         path-concat.h and path-concat.c.
12035         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
12036         (Include): filenamecat.h, not path-concat.h.
12037         * modules/mkdir-p: Renamed from modules/makepath.
12038         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
12039         makepath.c.
12040         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
12041         (Include): mkdir-p.h, not makepath.h.
12042
12043 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12044
12045         Sync from coreutils.
12046         * m4/mkdir-p.m4: Renamed from makepath.m4.
12047         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
12048         Rename files from makepath.c to mkdir-p.c, and from
12049         makepath.h to mkdir-p.h.
12050         * m4/filenamecat.m4: Renamed from path-concat.m4.
12051         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
12052         Rename files from path-concat.c to filenamecat.c,
12053         and from path-concat.h to filenamecat.h.
12054         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
12055         "file name" in local variables or comments.
12056         * m4/rename.m4: Likewise.
12057
12058 2005-06-01  Bruno Haible  <bruno@clisp.org>
12059
12060         * modules/csharpexec: New file.
12061         * MODULES.html.sh (C#): New section.
12062
12063 2005-06-01  Bruno Haible  <bruno@clisp.org>
12064
12065         * m4/csharp.m4: New file, from GNU gettext.
12066         * m4/csharpexec.m4: New file, from GNU gettext.
12067
12068 2005-06-01  Bruno Haible  <bruno@clisp.org>
12069
12070         * lib/csharpexec.h: New file, from GNU gettext.
12071         * lib/csharpexec.c: New file, from GNU gettext.
12072         * lib/csharpexec.sh.in: New file, from GNU gettext.
12073
12074 2005-05-31  Derek Price  <derek@ximbiot.com>
12075             Paul Eggert  <eggert@cs.ucla.edu>
12076
12077         Sync from cvs.
12078         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12079
12080 2005-05-31  Derek Price  <derek@ximbiot.com>
12081             Paul Eggert  <eggert@cs.ucla.edu>
12082
12083         Sync from cvs.
12084         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12085
12086 2005-05-29  Derek Price  <derek@ximbiot.com>
12087
12088         * config/srclist.txt (glob_.h, glob.c): Add these files.
12089
12090 2005-05-29  Derek Price  <derek@ximbiot.com>
12091
12092         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
12093         * modules/glob: New file.
12094         * modules/getlogin_r: Add link to POSIX spec in description.
12095
12096 2005-05-29  Derek Price  <derek@ximbiot.com>
12097             Paul Eggert  <eggert@cs.ucla.edu>
12098
12099         * m4/glob.m4: New file.
12100
12101 2005-05-29  Derek Price  <derek@ximbiot.com>
12102             Paul Eggert  <eggert@cs.ucla.edu>
12103
12104         * lib/glob_.h, lib/glob.c: New files.
12105
12106 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12107
12108         * modules/fts (Files): Remove m4/inttypes-pri.m4.
12109         * modules/fts-lgpl (Depends-on): Remove gettext.
12110
12111 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12112
12113         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
12114         and don't require gt_INTTYPES_PRI.
12115
12116 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12117
12118         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
12119
12120         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
12121         the configuration hassle isn't worth it.
12122         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
12123         (LONGEST_MODIFIER, PRIuMAX): Remove.
12124
12125 2005-05-27  Bruno Haible  <bruno@clisp.org>
12126
12127         * lib/getlogin_r.h: Remove second include of <stddef.h>.
12128
12129 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
12130
12131         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
12132         _POSIX_PTHREAD_SEMANTICS for Solaris.
12133
12134 2005-05-25  Derek Price  <derek@ximbiot.com>
12135
12136         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
12137
12138 2005-05-25  Derek Price  <derek@ximbiot.com>
12139             Paul Eggert  <eggert@cs.ucla.edu>
12140
12141         * modules/getlogin_r, m4/getlogin_r.m4: New files.
12142         * lib/getlogin_r.c, getlogin_r.h: New files.
12143
12144 2005-05-25  Bruno Haible  <bruno@clisp.org>
12145             Derek Price  <derek@ximbiot.com>
12146
12147         * lib/getlogin_r.h: Simplify API documentation.
12148
12149 2005-05-23  Derek Price  <derek@ximbiot.com>
12150
12151         * modules/minmax (Files): Add m4/minmax.m4.
12152         (configure.ac): Add gl_MINMAX.
12153
12154 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
12155
12156         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
12157         so that unistd-safer.h (GPL'ed code) need not be included.
12158
12159 2005-05-22  Bruno Haible  <bruno@clisp.org>
12160
12161         * m4/minmax.m4: New file.
12162         Based on a patch by Derek Price <derek@ximbiot.com>.
12163
12164 2005-05-22  Bruno Haible  <bruno@clisp.org>
12165
12166         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
12167         (INT64_MIN): Fix definition.
12168         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
12169
12170         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
12171         NEED_SIGNED_INT_TYPES.
12172
12173         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
12174         HAVE_SYSTEM_INTTYPES.
12175
12176 2005-05-22  Bruno Haible  <bruno@clisp.org>
12177
12178         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
12179         Also include <sys/param.h> if it defines MIN, MAX.
12180         Based on a patch by Derek Price <derek@ximbiot.com>.
12181
12182 2005-05-21  Jim Meyering  <jim@meyering.net>
12183
12184         * modules/fts (Files): Add m4/inttypes-pri.m4.
12185         (Depends-on): Add lstat and remove gettext.  Alphabetize.
12186
12187 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12188
12189         New fts module.
12190         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
12191         (setup_dir, free_dir): New functions.
12192         (enter_dir, leave_dir): Define trivial
12193         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
12194         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
12195         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
12196         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
12197         Move to fts-cycle.c.
12198         (fts_open): Use setup_dir.
12199         (fts_close): Use free_dir.
12200         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
12201         This adds a label and some gotos, but the alternatives were messier.
12202         Check for memory allocation failure when entering a dir.
12203         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
12204         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
12205         (FTS): New member fts_cycle, that is a union that contains the
12206         old active_dir_ht and cycle_state.  All uses changed to mention
12207         fts_cycle.ht and fts_cycle.state.
12208         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
12209         fts.c, with the following changes:
12210         (setup_dir, free_dir): New functions.
12211         (enter_dir): Now returns bool.  Return true if successful, false
12212         if memory exhausted.  All callers changed.
12213         Do not bother partly cleaning up on
12214         memory allocation failure; that is free_dir's job.
12215         However, free ad if hash_insert fails, to avoid memory leak.
12216         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
12217         fts->fts_options to see which union member to use.
12218
12219 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12220
12221         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
12222         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
12223
12224 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12225
12226         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
12227
12228 2005-05-20  Jim Meyering  <jim@meyering.net>
12229
12230         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
12231         Now a macro, to pacify GCC.
12232
12233 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12234
12235         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
12236         of -1.
12237
12238 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12239
12240         * lib/chown.c (rpl_chown): Return -1 on failure.
12241
12242 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12243
12244         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
12245         Don't check for stddef.h.
12246         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
12247         don't use its results.
12248         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
12249         since we include them unconditionally.  Don't require
12250         AM_STDBOOL_H, since stdbool is a prerequisite.
12251         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
12252         since we assume C89 or better.
12253         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
12254         as we don't use their results.
12255         Don't check for fchdir, memmove, memset, strrchr, as we use
12256         them unconditionally.
12257         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
12258         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
12259
12260 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12261
12262         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
12263         Include <stddef.h> unconditionally, since we assume C89 now.
12264         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
12265         * lib/fts.c: Include fts_.h first, to check interface.
12266         Do not include intprops.h; no longer needed.
12267         Include cycle-check.h and hash.h, since fts_.h no longer does.
12268         Remove unnecessary casts of closedir to void.
12269         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
12270         decide whether to decrement nlinks.
12271         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
12272         (FTS): Use struct hash_table * instead of Hash_table, so that
12273         we no longer need to include hash.h here.
12274
12275 2005-05-18  Jim Meyering  <jim@meyering.net>
12276
12277         * modules/dirfd (License): Change to LGPL.  Most of the code
12278         is already in the public domain.
12279
12280 2005-05-18  Jim Meyering  <jim@meyering.net>
12281
12282         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
12283         Reported by Yoann Vandoorselaere.
12284
12285 2005-05-17  Jim Meyering  <jim@meyering.net>
12286
12287         * m4/fts.m4: New file, from coreutils.
12288
12289 2005-05-17  Jim Meyering  <jim@meyering.net>
12290
12291         * lib/fts.c, lib/fts_.h: New files, from coreutils.
12292
12293 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12294
12295         Sync from coreutils.
12296         * m4/unlinkdir.m4: New file.
12297
12298 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12299
12300         Sync from coreutils.
12301         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
12302         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
12303         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
12304         White space changes only.
12305         * lib/makepath.c (make_path): Port to hosts where leading "//" is
12306         special.
12307         * lib/yesno.c: Include getline.h, not ctype.h.
12308         (yesno): Don't remove leading white space; POSIX doesn't allow it.
12309         Use getline to remove arbitrary restriction on response length.
12310
12311 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12312
12313         * config/srclist-update: Spell out "Street" in FSF postal
12314         mail address; this is the style the FSF seems to prefer.
12315
12316         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
12317         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
12318         this updates FSF postal mail address.
12319
12320         Sync from coreutils.
12321         * modules/unlinkdir: New file.
12322         * modules/yesno (Depends-on): Add getline.
12323         * MODULES.html.sh (File system functions): Add unlinkdir.
12324
12325 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12326
12327         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
12328         lib/strsep.h:
12329         Change the initial comment to refer to GPL, not LGPL.
12330         gnulib-tool will change it to LGPL as needed.
12331
12332         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
12333         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
12334         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
12335         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
12336         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
12337         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
12338         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
12339         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
12340         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
12341         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
12342         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
12343         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
12344         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
12345         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
12346         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
12347         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
12348         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
12349         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
12350         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
12351         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
12352         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
12353         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
12354         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
12355         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
12356         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
12357         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
12358         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
12359         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
12360         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
12361         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
12362         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
12363         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
12364         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
12365         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
12366         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
12367         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
12368         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
12369         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
12370         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
12371         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
12372         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
12373         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
12374         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
12375         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
12376         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
12377         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
12378         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
12379         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
12380         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
12381         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
12382         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12383         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
12384         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
12385         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
12386         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
12387         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
12388         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
12389         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
12390         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
12391         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
12392         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
12393         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
12394         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
12395         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
12396         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
12397         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
12398         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
12399         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
12400         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
12401         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
12402         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
12403         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
12404         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
12405         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
12406         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
12407         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
12408         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
12409         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
12410         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
12411         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
12412         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
12413         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
12414         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
12415         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
12416         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
12417         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
12418         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
12419         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
12420         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
12421         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
12422         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
12423         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
12424         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
12425         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
12426         lib/yesno.c, lib/yesno.h:
12427         Update FSF postal mail address.
12428
12429 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12430
12431         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
12432         tests/test-memmem.c, tests/test-stpncpy.c:
12433         Update FSF postal mail address.
12434
12435 2005-05-13  Bruno Haible  <bruno@clisp.org>
12436
12437         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
12438         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
12439         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
12440         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
12441         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
12442         Add support for 64-bit integers in the MSVC compiler.
12443
12444 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12445
12446         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
12447
12448 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
12449
12450         * gnulib-tool (func_import): Sort and uniquify recommended includes.
12451
12452 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
12453
12454         * doc/getdate.texi (General date syntax): Don't say that date
12455         date --iso-8601=ns generates acceptable dates; it doesn't yet.
12456         Problem reported by Nic Ferrier.
12457
12458 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12459
12460         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
12461         specified in ai_socktype. Fix invalid ai_protocol
12462         check. ai_protocol is usually set to 0 or depending on
12463         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
12464         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
12465         ai_socktype / ai_protocol in the returned addrinfo structure.
12466
12467 2005-05-10  Simon Josefsson  <jas@extundo.com>
12468
12469         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
12470         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12471
12472 2005-05-10  Karl Berry  <karl@gnu.org>
12473
12474         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
12475         (from http://www.gnu.org/licenses).
12476         * doc/COPYING.LIB: also rename to COPYING.LESSER.
12477         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
12478         fdl.texi suffices.
12479
12480 2005-05-10  Karl Berry  <karl@gnu.org>
12481
12482         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
12483         (COPYING.DOC): remove.
12484
12485         * config/srclist-update: new FSF address.
12486
12487 2005-05-10  Derek Price  <derek@ximbiot.com>
12488
12489         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
12490         possible.
12491
12492 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12493             Bruno Haible  <bruno@clisp.org>
12494
12495         * modules/inet_ntop: New file.
12496         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12497         inet_ntop.
12498
12499 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12500             Bruno Haible  <bruno@clisp.org>
12501
12502         * m4/inet_ntop.m4: New file.
12503
12504 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12505             Bruno Haible  <bruno@clisp.org>
12506
12507         * lib/inet_ntop.h: New file.
12508         * lib/inet_ntop.c: New file, from glibc with modifications.
12509
12510 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
12511
12512         * modules/time_r (License): Change to LGPL.
12513         * modules/extensions (License): Change to LGPL.  Actually,
12514         the license is more permissive than that, but currently gnulib-tool
12515         doesn't know how to handle more-permissive licenses.
12516
12517         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
12518         Problem reported by Dave Love.
12519
12520 2005-05-08  Jim Meyering  <jim@meyering.net>
12521
12522         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
12523         blank.
12524
12525 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12526
12527         * modules/argmatch (Depends-on): Add stdbool.
12528         * modules/backupfile (Depends-on): Likewise.
12529         * modules/chdir-long (Depends-on): Likewise.
12530         * modules/closeout (Depends-on): Likewise.
12531         * modules/cycle-check (Depends-on): Likewise.
12532         * modules/dirname (Depends-on): Likewise.
12533         * modules/fnmatch (Depends-on): Likewise.
12534         * modules/fsusage (Depends-on): Likewise.
12535         * modules/fwriteerror (Depends-on): Likewise.
12536         * modules/getcwd (Depends-on): Likewise.
12537         * modules/getloadavg (Depends-on): Likewise.
12538         * modules/hard-locale (Depends-on): Likewise.
12539         * modules/makepath (Depends-on): Likewise.
12540         * modules/mountlist (Depends-on): Likewise.
12541         * modules/nanosleep (Depends-on): Likewise.
12542         * modules/posixtm (Depends-on): Likewise.
12543         * modules/quotearg (Depends-on): Likewise.
12544         * modules/readtokens (Depends-on): Likewise.
12545         * modules/readtokens0 (Depends-on): Likewise.
12546         * modules/readutmp (Depends-on): Likewise.
12547         * modules/save-cwd (Depends-on): Likewise.
12548         * modules/strftime (Depends-on): Likewise.
12549         * modules/userspec (Depends-on): Likewise.
12550         * modules/utimecmp (Depends-on): Likewise.
12551         * modules/xgetcwd (Depends-on): Likewise.
12552         * modules/xnanosleep (Depends-on): Likewise.
12553         * modules/xstrtod (Depends-on): Likewise.
12554         * modules/yesno (Depends-on): Likewise.
12555
12556 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
12557
12558         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
12559         needless checks.
12560
12561 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12562
12563         Merge from coreutils.  Among other things,
12564         add bulletproofing for cases where stdin, stdout, or stderr are closed.
12565         * lib/fd-safer.c: New file.
12566         * lib/fcntl-safer.h, open-safer.c: Remove.
12567         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
12568         * lib/dup-safer.c: Include unistd-safer.h first.
12569         Don't include errno.h.
12570         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
12571         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
12572         * lib/file-type.c: Rely on file-type.h change.
12573         * lib/getloadavg.c: Include unistd-safer.h.
12574         (getloadavg): Use safer open.
12575         * lib/getusershell.c: Include "stdio-safer.h".
12576         (getusershell): Use safer fopen.
12577         * lib/long-options.c (long_options): Use NULL rather than 0.
12578         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
12579         'free'.
12580         * lib/modechange.c: Likewise.
12581         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
12582         (MODE_DONE): New constant.
12583         (struct mode_change): Remove 'next' member.
12584         (make_node_op_equals): New function; like the old one of the
12585         same name, except it allocates an array.
12586         (mode_compile, mode_create_from_ref): Use it.
12587         (mode_compile): Allocate result as an array, not a linked list.
12588         Parse octal string ourself, so that we catch mistakes like "+0".
12589         (mode_adjust): Arg is an array, not a linked list.
12590         * lib/modechange.c: Include stat-macros.h, xalloc.h.
12591         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
12592         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
12593         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
12594         Remove.  This is now stat-macros.h's job.
12595         (talloc): Remove.  All callers replaced by xalloc, so that
12596         our invokers don't have to worry about reporting memory failures.
12597         (make_node_op_equals): Remove.
12598         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12599         New constants.
12600         (struct mode_change): Moved here from modechange.h.
12601         (mode_append_entry): Remove.
12602         (mode_compile): Remove MASKED_OPS arg, since it encouraged
12603         apps to have incorrect behavior.  Use simpler algorithm for head
12604         and tail.  Don't futz with umask; that's now the job of mode_adjust.
12605         Detect more invalid usages rather than having somewhat-random behavior.
12606         Don't insert an "a=" action, as that leads to incorrect behavior.
12607         (mode_compile, mode_create_from_ref): Return NULL on error instead
12608         of an enum, since now there's only one way to have an error.  All
12609         callers changed.
12610         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
12611         at the correct time.  Simplify calculation of "+u" and its ilk.
12612         Don't mishandle "+X".
12613         (mode_free): Remove "register" and localize decls.
12614         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12615         (struct mode_change): Move to modechange.c; callers don't
12616         need to see this stuff.
12617         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
12618         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
12619         (mode_change, mode_adjust): Reflect the new signatures noted above.
12620         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
12621         that might redefine system include files.
12622         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
12623         (my_usleep): Use NULL rather than (void *) 0.
12624         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
12625         Use siginterrupt to specify that system calls should be interrupted.
12626         (rpl_nanosleep): Move initialization of suspended closer to call of
12627         my_usleep.
12628         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
12629         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
12630         (desirable_utmp_entry): New function.
12631         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
12632         using x2nrealloc, to simplify logic.
12633         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
12634         size calculation.  Do not assume utmp file is a regular file.
12635         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
12636         (READ_UTMP_CHECK_PIDS): New constant.
12637         * lib/save-cwd.c: Include unistd-safer.h.
12638         (save_cwd): Use fd_safer.
12639         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
12640         [!_LIBC] Include "stat-macros.h" instead.
12641         * lib/unistd-safer.h (fd_safer): New decl.
12642
12643 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12644
12645         * modules/getloadavg (Depends-on): Add unistd-safer.
12646         * modules/getusershell (Depends-on): Add stdio-safer.
12647         * modules/lstat (Depends-on): Remove xalloc.
12648         * modules/mkstemp (Depends-on): Add stat-macros.
12649         * modules/modechange (Depends-on): Remove xstrtol.
12650         Add stat-macros, xalloc.
12651         * modules/save-cwd (Depends-on): Add unistd-safer.
12652         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
12653         * modules/unistd-safer (Files): Add lib/fd-safer.c
12654         (Makefile.am): Remove lib_SOURCES.
12655
12656         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
12657         Remove fcntl-safer; unistd-safer supersedes it.
12658
12659 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12660
12661         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
12662         AC_HEADER_STAT.
12663         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
12664         (gl_PREREQ_CHOWN): Remove.
12665         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
12666         it.  Don't require AC_HEADER_STAT.
12667         (gl_PREREQ_LSTAT): Remove.
12668         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
12669         Don't require AC_HEADER_STAT.
12670         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
12671         (gl_PREREQ_RMDIR): Remove.
12672         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
12673         mention stat-macros.h or AC_HEADER_STAT, since we'll make
12674         the stat-macros module a prerequisite.
12675         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
12676         * m4/filemode.m4 (gl_FILEMODE): Likewise.
12677         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
12678         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
12679         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
12680         variable names.
12681         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
12682         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
12683         variable prefixes.
12684         * m4/fcntl-safer.m4: Remove.
12685         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
12686         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
12687         Invoke gl_PREREQ_FD_SAFER.
12688         (gl_PREREQ_FD_SAFER): New macro.
12689         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
12690         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
12691         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
12692         Remove duplicate call to AC_LIBOBJ(readutmp).
12693         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
12694
12695         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
12696         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
12697
12698 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12699
12700         * MODULES.html.sh (Misc): Add byteswap.
12701
12702 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12703
12704         * modules/getcwd (Depends-on): Add extensions.
12705         * modules/openat (Depends-on): Likewise.
12706
12707 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12708
12709         * modules/byteswap: New file.
12710
12711 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12712
12713         * m4/byteswap.m4: New file.
12714
12715 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12716
12717         * lib/byteswap_.h: New file.
12718
12719 2005-04-25  Karl Berry  <karl@gnu.org>
12720
12721         * m4/gettext.m4: Update from GNU gettext 0.14.4.
12722
12723 2005-04-25  Albert Chin  <china@thewrittenword.com>
12724
12725         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
12726         Toolkit C bug.
12727
12728 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
12729
12730         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
12731         (func_ln_if_changed) Remove forcibly for no error message
12732         in case file does not exist.
12733
12734 2005-04-19  Simon Josefsson  <jas@extundo.com>
12735
12736         * gnulib-tool (Options): Make --symlink mean --symbolic.
12737
12738 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
12739
12740         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
12741
12742 2005-04-16  Simon Josefsson  <jas@extundo.com>
12743
12744         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
12745
12746 2005-04-15  Simon Josefsson  <jas@extundo.com>
12747
12748         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
12749
12750 2005-04-15  Simon Josefsson  <jas@extundo.com>
12751
12752         * gnulib-tool: Rename --symlink to --symbolic.
12753
12754 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
12755
12756         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
12757         symbolic links to files instead of copying/moving.  Add --aux-dir,
12758         specifying directory relative --dir where auxiliary build tools
12759         are placed.
12760
12761 2005-04-14  Bruno Haible  <bruno@clisp.org>
12762
12763         * modules/allocsa (License): Change to LGPL.
12764         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
12765
12766 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12767
12768         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
12769         that "UTC +1 second" continues to work.  Problem reported
12770         by Dmitry V. Levin.
12771         (relunit_snumber): New rule.
12772         (relunit): Use it.
12773
12774 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
12775
12776         * lib/getdate.y (universal_time_zone_table): New constant.
12777         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
12778         universal_time_zone_table.
12779         (lookup_zone): Prefer universal_time_zone_table to
12780         local_time_zone_table, so that "GMT" time stamps are allowed in
12781         London during the summer.  Problem reported by Ian Abbott.
12782
12783 2005-04-12  Jim Meyering  <jim@meyering.net>
12784
12785         * lib/human.c (humblock): Set *options even when returning due to
12786         xstrtoumax conversion failure.  Thanks to a used-uninitialized
12787         warning from gcc-4.
12788
12789 2005-04-09  Jim Meyering  <jim@meyering.net>
12790
12791         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
12792         -Wuninitialized: initialize tm0.tm_year.
12793
12794 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
12795
12796         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
12797         count, since there's no maximum.  All uses changed.
12798         Add member dsts_seen.
12799         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
12800         not being INT_MAX.
12801         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
12802         Use pc_rels_seen to decide whther a date is absolute.
12803
12804         * lib/getdate.y (number): Don't overwrite year.
12805         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
12806         check.
12807
12808 2005-04-02  Simon Josefsson  <jas@extundo.com>
12809
12810         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
12811         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
12812
12813 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
12814
12815         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
12816         where no absolute path name can be longer than PATH_MAX.
12817
12818 2005-03-27  Jim Meyering  <jim@meyering.net>
12819
12820         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
12821
12822 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
12823
12824         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
12825         "one's complement" -> "ones' complement" in comment, as per Knuth.
12826         "value of type" -> "type or expression" in comment.
12827         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
12828
12829 2005-03-26  Jim Meyering  <jim@meyering.net>
12830
12831         Comment nits.
12832         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
12833         Correct typos: s/or/of/.
12834
12835 2005-03-26  Jim Meyering  <jim@meyering.net>
12836
12837         * modules/check-include-files: Move to ../ and rename to...
12838         * check-module: ...this.
12839
12840 2005-03-25  Jim Meyering  <jim@meyering.net>
12841
12842         * modules/xvasprintf (Files): Add xalloc.h.
12843
12844 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
12845
12846         * modules/gettext (Files): config/config.rpath ->
12847         build-aux/config.rpath
12848         * modules/iconv (Files): Likewise.
12849         Problem reported by Oskar Liljeblad.
12850
12851 2005-03-23  Jim Meyering  <jim@meyering.net>
12852
12853         * modules/check-include-files: New script to check for
12854         missing dependencies, multiple includes, etc.
12855
12856         * modules/c-strtold (Depends-on): Add xalloc.
12857         * modules/c-strtod (Depends-on): Add xalloc.
12858         * modules/hash (Depends-on): Add xalloc.
12859         (Files): Remove lib/xalloc.h.
12860
12861         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
12862         * modules/userspec (Files): Add lib/inttostr.h.
12863
12864 2005-03-23  Jim Meyering  <jim@meyering.net>
12865
12866         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
12867
12868 2005-03-22  Jim Meyering  <jim@meyering.net>
12869
12870         * modules/stat-macros: New module.
12871         * modules/canonicalize, modules/euidaccess, modules/file-type,
12872         * modules/filemode, modules/lchown, modules/makepath,
12873         * modules/rmdir, modules/stat: Depend on new stat-macros module
12874         rather than listing lib/stat-macros.h manually.
12875         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
12876
12877 2005-03-22  Jim Meyering  <jim@meyering.net>
12878
12879         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
12880
12881 2005-03-22  Bruno Haible  <bruno@clisp.org>
12882
12883         * config/srclist.txt: Replace target directory 'config' with
12884         'build-aux'.
12885         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
12886         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
12887         ../build-aux/.
12888
12889 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
12890
12891         * modules/chdir-long (Depends-on): Add mempcpy.
12892
12893         * modules/acl, modules/backupfile, modules/c-strtod,
12894         modules/c-strtold, modules/canon-host, modules/canonicalize,
12895         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
12896         modules/exclude, modules/exitfail, modules/file-type,
12897         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
12898         modules/getdate, modules/getline, modules/getpagesize,
12899         modules/getpass, modules/getugroups, modules/group-member,
12900         modules/hard-locale, modules/hash, modules/human, modules/idcache,
12901         modules/inttostr, modules/long-options, modules/makepath,
12902         modules/md5, modules/memcasecmp, modules/memcoll,
12903         modules/modechange, modules/mountlist, modules/path-concat,
12904         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
12905         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
12906         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
12907         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
12908         modules/strftime, modules/strndup, modules/strverscmp,
12909         modules/timespec, modules/unlocked-io, modules/userspec,
12910         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
12911         modules/yesno:
12912         Remove lib_SOURCES line from Makefile.am section, as this is now
12913         done automatically by the corresponding Autoconf macro.
12914
12915 2005-03-21  Jim Meyering  <jim@meyering.net>
12916
12917         Changes imported from coreutils.
12918
12919         * lib/cycle-check.c: Don't include xalloc.h.
12920
12921         * lib/path-concat.c: Don't include assert.h.
12922         (path_concat): Remove assertion that would have triggered
12923         for ABASE starting with more than one slash.
12924         Reported by Andreas Schwab.
12925
12926         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
12927         properly when ABASE is an absolute file name.
12928         Correct the description of this function.
12929         Include <assert.h>.
12930         Add an assertion and a test driver.
12931         This fixes a bug introduced on 2004-07-02.
12932         Andreas Schwab reported the resulting failure of cp --parents:
12933         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
12934
12935 2005-03-21  Jim Meyering  <jim@meyering.net>
12936
12937         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
12938         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
12939
12940 2005-03-21  Jim Meyering  <jim@meyering.net>
12941         and  Paul Eggert  <eggert@cs.ucla.edu>
12942
12943         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
12944         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
12945         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
12946         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
12947         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
12948         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
12949         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
12950         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
12951         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
12952         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
12953         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
12954         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
12955         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
12956         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
12957         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
12958         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
12959         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
12960         for these modules.
12961
12962 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
12963
12964         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
12965         (which shouldn't happen), generate nothing instead of returning 0
12966         immediately, so that nstrftime (NULL, ...) doesn't return 0.
12967
12968 2005-03-16  Bruno Haible  <bruno@clisp.org>
12969
12970         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
12971         HAVE_LONGLONG_64BIT.
12972
12973 2005-03-16  Bruno Haible  <bruno@clisp.org>
12974
12975         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
12976         HAVE_LONGLONG_64BIT.
12977
12978 2005-03-16  Bruno Haible  <bruno@clisp.org>
12979
12980         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
12981         HAVE_LONGLONG_64BIT.
12982
12983 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
12984
12985         * lib/strftime.c (my_strftime): Prepend space to format so that we can
12986         reliably distinguish strftime failure from empty output on POSIX
12987         hosts.
12988
12989 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
12990
12991         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
12992         (iconv_string): Don't guess a size-zero buffer, as that might cause
12993         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
12994         result would be 'too large', where 'too large' is (heuristically)
12995         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
12996         overflow concerns.  This will prevent some unwanted malloc failures
12997         when the inputs are very large.
12998
12999 2005-03-15  Karl Berry  <karl@gnu.org>
13000
13001         * config/srclist.txt (config.rpath): from gettext.
13002         * config/config.rpath: update.
13003
13004 2005-03-15  Bruno Haible  <bruno@clisp.org>
13005
13006         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
13007         to 'negate'.
13008
13009         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
13010         variable.
13011
13012         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
13013         results.
13014
13015 2005-03-14  Simon Josefsson  <jas@extundo.com>
13016
13017         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
13018         <fx@gnu.org>.
13019
13020 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
13021
13022         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
13023         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
13024         intprops.h.
13025         * lib/strtol.c: Likewise.
13026
13027 2005-03-14  Jim Meyering  <jim@meyering.net>
13028
13029         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
13030         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
13031         to be nonzero so that we (and caller) can detect the difference
13032         between a valid zero-length expansion and an error return, even
13033         when the underlying strftime fails before writing anything into
13034         that location.
13035
13036 2005-03-14  Bruno Haible  <bruno@clisp.org>
13037
13038         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
13039         Update from GNU gettext 0.14.3.
13040
13041 2005-03-10  Jim Meyering  <jim@meyering.net>
13042
13043         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
13044
13045 2005-03-10  Jim Meyering  <jim@meyering.net>
13046
13047         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
13048         so that this module works on systems without fchdir.
13049
13050 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
13051
13052         Factor int-properties macros into a single file, except for
13053         glibc-related files.
13054         * lib/intprops.h: New file.
13055         * lib/getloadavg.c: Include it instead of limits.h.
13056         (INT_STRLEN_BOUND): Remove.
13057         * lib/human.c: Include intprops.h.
13058         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
13059         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
13060         302/1000.
13061         * lib/inttostr.h: Include intprops.h instead of limits.h.
13062         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
13063         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
13064         for consistency with intprops.h.
13065         (time_t_is_integer, twos_complement_arithmetic): Use them.
13066         * lib/sig2str.h: Include <signal.h>, intprops.h.
13067         (INT_STRLEN_BOUND): Remove.
13068         * lib/strftime.c (TYPE_SIGNED): Remove.
13069         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
13070         * lib/strtol.c: Adjust comments to match intprops.h.
13071         * lib/userspec.c: Include intprops.h.
13072         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
13073         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
13074         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
13075         instead of rolling our own expressions.
13076         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
13077
13078         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
13079         instead of int.
13080         (my_strftime): Do not mishandle years close to INT_MAX, by doing
13081         the right thing even if adding 1900 would overflow.  Similarly
13082         for tm_mon + 1 and tm_yday + 1.
13083         Make %Y always equivalent to %C%y, and similarly for %G and %g.
13084         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
13085         (DO_SIGNED_NUMBER): New macro.
13086         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
13087
13088 2005-03-07  Bruno Haible  <bruno@clisp.org>
13089
13090         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
13091
13092 2005-03-07  Bruno Haible  <bruno@clisp.org>
13093
13094         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
13095
13096 2005-03-04  Derek R. Price  <derek@ximbiot.com>
13097
13098         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
13099         (func_import): Only replace files via --import when they have actually
13100         changed.
13101
13102 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13103
13104         * m4/mmap-anon.m4: New file.
13105         * m4/pagealign_alloc.m4: New file.
13106
13107 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13108             Bruno Haible  <bruno@clisp.org>
13109
13110         * modules/pagealign_alloc: New file.
13111         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
13112
13113 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13114             Bruno Haible  <bruno@clisp.org>
13115
13116         * lib/pagealign_alloc.h: New file.
13117         * lib/pagealign_alloc.c: New file.
13118
13119 2005-03-03  Bruno Haible  <bruno@clisp.org>
13120
13121         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
13122         Use an all-permissive copyright notice, recommended by RMS.
13123
13124 2005-03-02  Bruno Haible  <bruno@clisp.org>
13125
13126         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
13127         of AIX, the replacement has to be done only after <string.h> is
13128         included, therefore not in config.h. stpncpy.h does the replacement,
13129         and stpncpy.c uses it.
13130
13131 2005-03-02  Bruno Haible  <bruno@clisp.org>
13132
13133         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
13134         stpncpy.c uses it.
13135
13136 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13137
13138         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
13139         The workaround isn't strictly needed for POSIX conformance, and
13140         it's too much of a pain to configure and maintain.  We'll ask
13141         people to fix their kernels instead.
13142         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
13143         (NANOSLEEP_BUG_WORKAROUND): Remove.
13144         (xnanosleep): Remove the workaround.
13145
13146 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13147
13148         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
13149         Reported by Derek Price.
13150         (Include): Add "timespec.h".
13151
13152         * modules/xnanosleep (Depends-on): Remove gethrxtime.
13153
13154 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13155
13156         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
13157         to detect nanosleep bug.
13158
13159 2005-03-01  Bruno Haible  <bruno@clisp.org>
13160
13161         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
13162
13163 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13164
13165         * modules/gethrxtime: New file.
13166         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
13167         (Depends-on): Add gethrxtime.
13168         (configure.ac): Add gl_XNANOSLEEP.
13169         (Makefile.am): Remove lib_SOURCES line.
13170
13171 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13172
13173         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
13174         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
13175
13176 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13177
13178         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
13179         * lib/timespec.h (gettime): Return void, since it always
13180         succeeds now.  All uses changed.
13181         * lib/gettime.c (gettime) Likewise.
13182         [HAVE_NANOTIME]: Prefer nanotime.
13183         Assume gettimeofday succeeds, as POSIX requires.
13184         Assime time () succeeds, since other code already does.
13185         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
13186         (timespec_subtract): Remove.
13187         (NANOSLEEP_BUG_WORKAROUND): New constant.
13188         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
13189         things considerably.  Use it only on GNU/Linux hosts, since the
13190         workaround shouldn't be needed elsewhere.
13191
13192 2005-02-24  Bruno Haible  <bruno@clisp.org>
13193
13194         * modules/gettext (Files): Add m4/glibc2.m4.
13195
13196 2005-02-24  Bruno Haible  <bruno@clisp.org>
13197
13198         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
13199         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
13200         * m4/progtest.m4:
13201         Update from GNU gettext 0.14.2.
13202         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
13203
13204 2005-02-24  Bruno Haible  <bruno@clisp.org>
13205
13206         * lib/localcharset.c: Update from GNU gettext 0.14.2.
13207         * lib/config.charset: Update from GNU gettext 0.14.2.
13208
13209 2005-02-24  Bruno Haible  <bruno@clisp.org>
13210
13211         * lib/gettext.h: Update from GNU gettext 0.14.2.
13212
13213 2005-02-23  Simon Josefsson  <jas@extundo.com>
13214
13215         * m4/iconvme.m4: New file.
13216
13217 2005-02-23  Jim Meyering  <jim@meyering.net>
13218
13219         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
13220         change.
13221         Thanks to Bruno Haible for catching it.
13222
13223 2005-02-22  Simon Josefsson  <jas@extundo.com>
13224
13225         * modules/iconvme: New file.
13226
13227         * MODULES.html.sh: Add iconvme.
13228
13229 2005-02-22  Simon Josefsson  <jas@extundo.com>
13230
13231         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
13232
13233 2005-02-22  Simon Josefsson  <jas@extundo.com>
13234
13235         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
13236
13237 2005-02-22  Jim Meyering  <jim@meyering.net>
13238
13239         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
13240         s/ifndef/ifdef/.
13241
13242 2005-02-20  Neil Conway  <neilc@samurai.com>
13243
13244         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
13245         returned by OSX/Darwin if the specified buffer is not large
13246         enough for the hostname.
13247
13248 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13249
13250         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
13251         pass it to _help, otherwise the latter coredumps trying to
13252         dereference state.root_argp.
13253
13254 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13255
13256         * modules/chdir-long (Depends-on): Add memrchr.
13257         * modules/memrchr (Files): Add lib/memrchr.h.
13258         (Include): "memrchr.h".
13259
13260 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13261
13262         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
13263
13264 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13265
13266         * lib/memrchr.h: New file.
13267         * lib/chdir-long.c: Include it.
13268         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
13269         Don't bother including stddef.h.
13270
13271 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
13272
13273         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
13274         inclusion.
13275         Include <sys/types.h>, for dev_t.
13276         (ME_DUMMY, ME_REMOTE): Move from here....
13277         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
13278         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
13279         Dmitry V. Levin.
13280         Include mountlist.h first, to test the interface.
13281
13282 2005-01-29  Bruno Haible  <bruno@clisp.org>
13283
13284         * lib/progname.c (program_name): Initialize.
13285         Needed when linking statically on MacOS X.
13286
13287 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13288
13289         Sync from coreutils.
13290         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
13291         (Depends-on): Add c-strtod.
13292         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
13293
13294 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13295
13296         Sync from coreutils.
13297         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
13298
13299         Remove files that are specific to coreutils.
13300         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
13301
13302 2005-01-28  Bruno Haible  <bruno@clisp.org>
13303
13304         * modules/javacomp: New file.
13305         * MODULES.html.sh (Java): Add javacomp.
13306
13307 2005-01-28  Bruno Haible  <bruno@clisp.org>
13308
13309         * m4/javacomp.m4: New file, from GNU gettext.
13310
13311 2005-01-28  Bruno Haible  <bruno@clisp.org>
13312
13313         * lib/javacomp.sh.in: New file, from GNU gettext.
13314         * lib/javacomp.h: New file, from GNU gettext.
13315         * lib/javacomp.c: New file, from GNU gettext.
13316
13317 2005-01-26  Simon Josefsson  <jas@extundo.com>
13318
13319         * lib/gai_strerror.c: Use GPL in header.
13320
13321 2005-01-26  Bruno Haible  <bruno@clisp.org>
13322
13323         * modules/javaexec: New file.
13324         * MODULES.html.sh (Java): Add javaexec.
13325
13326 2005-01-26  Bruno Haible  <bruno@clisp.org>
13327
13328         * m4/javaexec.m4: New file, from GNU gettext.
13329
13330 2005-01-26  Bruno Haible  <bruno@clisp.org>
13331
13332         * lib/javaexec.sh.in: New file, from GNU gettext.
13333         * lib/javaexec.h: New file, from GNU gettext.
13334         * lib/javaexec.c: New file, from GNU gettext.
13335
13336 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13337
13338         * modules/lchown (Depends-on): Remove lchown.h
13339
13340 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13341
13342         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
13343         must be defined if the header file was not found, in order
13344         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
13345
13346 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13347
13348         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
13349         initializers for struct pentry_state.
13350         (__argp_error): Check return value of __asprintf
13351         (__argp_failure): Translate error message
13352
13353         * lib/argp-parse.c: Removed braces around the expansion of N_()
13354
13355 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13356
13357         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
13358         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
13359         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
13360         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
13361         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
13362         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
13363         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
13364         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
13365         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
13366         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
13367         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
13368         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
13369         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
13370         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
13371         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
13372         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
13373         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
13374         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
13375         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
13376         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
13377         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
13378         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
13379         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
13380         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
13381         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
13382         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
13383         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
13384         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
13385         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
13386         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
13387         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
13388         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
13389         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
13390         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
13391         xstrtol.m4, xstrtoumax.m4, yesno.m4:
13392         Use an all-permissive copyright notice, recommended by RMS.
13393
13394 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
13395
13396         * modules/chdir-long (Depends-on): Remove mempcpy.
13397
13398 2005-01-21  Jim Meyering  <jim@meyering.net>
13399
13400         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
13401         same value as for Solaris 9.
13402
13403         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
13404         component length.  This included changing the parameter to be
13405         of type `char *' rather than `char const *'.
13406         * lib/chdir-long.h (chdir_long): Update prototype.
13407
13408         * lib/openat.c (fdopendir, fstatat): New functions.
13409         * lib/openat.h: Include headers required for use of DIR and struct
13410         stat.
13411         [AT_SYMLINK_NOFOLLOW]: Define.
13412         (fdopendir, fstatat): Add prototypes.
13413
13414 2005-01-21  Bruno Haible  <bruno@clisp.org>
13415
13416         * modules/classpath: New file.
13417         * MODULES.html.sh (Java): Add classpath.
13418
13419 2005-01-21  Bruno Haible  <bruno@clisp.org>
13420
13421         * lib/classpath.h: New file, from GNU gettext.
13422         * lib/classpath.c: New file, from GNU gettext.
13423
13424 2005-01-20  Simon Josefsson  <jas@extundo.com>
13425
13426         * modules/version-etc-fsf: New file.
13427
13428 2005-01-20  Simon Josefsson  <jas@extundo.com>
13429
13430         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
13431         * lib/version-etc.c: Remove version_etc_copyright.
13432         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
13433         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
13434
13435 2005-01-20  Simon Josefsson  <jas@extundo.com>
13436
13437         * lib/base64.h (isbase64): Add.
13438
13439         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
13440         using a unsigned prototype, don't inline.
13441         (base64_decode): Use it.
13442
13443 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13444
13445         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
13446         it.
13447
13448 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13449
13450         * lib/save-cwd.c (save_cwd): Remove code to support the case
13451         where fchdir is missing or flaky.
13452
13453 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13454
13455         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
13456
13457 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
13458
13459         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
13460         AC_LIBSOURCES now does this.
13461         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
13462         with new ullong_max module.
13463
13464 2005-01-19  Bruno Haible  <bruno@clisp.org>
13465
13466         * modules/sh-quote: New file.
13467         * MODULES.html.sh (Executing programs): Add sh-quote.
13468
13469 2005-01-19  Bruno Haible  <bruno@clisp.org>
13470
13471         * lib/sh-quote.h: New file, from GNU gettext.
13472         * lib/sh-quote.c: New file, from GNU gettext.
13473
13474 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13475
13476         Merge from coreutils.
13477         * m4/ullong_max.m4: New file.
13478         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
13479         (gl_MACROS): Assume localeconv exists.
13480
13481 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13482
13483         Merge changes from coreutils, as described below in several
13484         changelogs dated today.
13485
13486         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
13487         (O_DIRECTORY): Remove; not needed here, since "." must be
13488         a directory.  All uses removed.
13489         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
13490         universal on Suns, and we also need to test for IRIX.
13491         Revamp code to use 'if' rather than '#if'.
13492         Avoid unnecessary comparison of cwd->desc to 0.
13493
13494         * lib/utimens.c (futimens): Robustify the previous patch, by checking
13495         for known valid error numbers rather than observed invalid ones.
13496
13497 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13498
13499         * modules/ullong_max: New file.
13500
13501         * modules/chdir-long, modules/openat: New files.
13502         * modules/save-cwd (Depends-on): Depend on chdir-long.
13503         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
13504
13505 2005-01-18  Jim Meyering  <jim@meyering.net>
13506
13507         Merge from coreutils.
13508         * m4/chdir-long.m4, m4/openat.m4: New files.
13509         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
13510         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
13511         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
13512         is sane and DOES follow symlinks.  Besides, testing 20 different
13513         systems found no broken chown implementations.
13514         Prompted by a change in rsync's copy of this macro.
13515         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
13516
13517         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
13518
13519         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
13520         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
13521         NULL-means-set-to-current-time semantics.
13522         Remove temporary file immediately, rather than waiting
13523         for configure's at-exit trap code to do it.
13524
13525 2005-01-18  Jim Meyering  <jim@meyering.net>
13526
13527         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13528
13529         * lib/utimens.c (futimens): Account for the fact that futimes
13530         can also fail with errno == ENOSYS or errno == ENOENT.
13531         Patch from Dmitry V. Levin.
13532
13533         Change the name of the robust chdir function from chdir to chdir_long.
13534         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
13535         (restore_cwd): Use chdir_long, not chdir.
13536         * lib/chdir-long.c: Renamed from chdir.c.
13537         * lib/chdir-long.h: Renamed from chdir.h.
13538         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
13539         Hurd.
13540
13541 2005-01-18  Bruno Haible  <bruno@clisp.org>
13542
13543         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
13544         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
13545         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
13546         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
13547         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
13548         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
13549         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
13550         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
13551         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
13552         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
13553         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
13554         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
13555         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
13556         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
13557         Use an all-permissive copyright notice, recommended by RMS.
13558
13559 2005-01-18  Bob Proulx  <bob@proulx.com>
13560
13561         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
13562         simplify offsetof() macro construct to avoid compile failure with
13563         native HP-UX 11.0 ANSI C compiler.
13564
13565 2005-01-17  Bruno Haible  <bruno@clisp.org>
13566
13567         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
13568         redundant because stpncpy.m4 takes care of it.
13569
13570 2005-01-17  Bruno Haible  <bruno@clisp.org>
13571
13572         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
13573
13574 2005-01-17  Bruno Haible  <bruno@clisp.org>
13575
13576         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
13577         used.
13578
13579 2005-01-17  Bruno Haible  <bruno@clisp.org>
13580
13581         * lib/fwriteerror.h (fwriteerror): Change specification to include
13582         fclose.
13583         * lib/fwriteerror.c: Include <stdbool.h>.
13584         (fwriteerror): At the end, close the file stream. Record whether
13585         stdout was already closed.
13586
13587 2005-01-17  Bruno Haible  <bruno@clisp.org>
13588
13589         * lib/execute.c (environ): Declare if needed.
13590         * lib/pipe.c (environ): Likewise.
13591         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
13592
13593 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13594
13595         * modules/argp: Depend on vsnprintf
13596
13597 2005-01-10  Jim Meyering  <jim@meyering.net>
13598
13599         * modules/closeout (Depends-on): Add atexit.
13600
13601 2005-01-06  Bruno Haible  <bruno@clisp.org>
13602
13603         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
13604
13605 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13606
13607         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
13608         definitions to be after all include files, to avoid collisions.
13609         Problem reported by Bob Proulx.
13610
13611 2005-01-04  Jim Meyering  <jim@meyering.net>
13612
13613         Changes imported from coreutils.
13614         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
13615         as the mkstemp template, use a temporary directory and an
13616         8.3-friendly template to avoid trouble on systems like DJGPP.
13617         Reported by Juan M. Guerrero via Stepan Kasal.
13618         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
13619         close. Remove the temporary directory right away, rather than waiting
13620         for configure's at-exit trap code to do it.
13621         Suggestion from Stepan Kasal.
13622
13623 2005-01-01  Simon Josefsson  <jas@extundo.com>
13624
13625         * gnulib-tool: Print #include directives when --import'ing.
13626
13627 2004-12-28  Simon Josefsson  <jas@extundo.com>
13628
13629         * tests/test-base64.c: Include required header files.  Remove
13630         unused variables.
13631
13632 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13633
13634         * modules/error (Depends-on): Remove gettext.
13635
13636 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13637
13638         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
13639         not needed.  This removes a dependency on the gettext module.
13640         [defined _LIBC]: Do not include <libintl.h>; not needed.
13641
13642 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13643
13644         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
13645         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
13646
13647 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13648
13649         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
13650         HAVE_DECL_STRTOLD.
13651
13652 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13653
13654         * modules/getdate (Depends-on): Remove alloca-opt.
13655
13656 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13657
13658         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
13659
13660 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13661
13662         * lib/argp-parse.c: Include <stddef.h>.
13663         (alignof, alignto): New macros.
13664         (parser_init): Don't assume that void * is aligned sufficiently
13665         for struct option.
13666
13667         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
13668         need to extend the stack.
13669         (YYINITDEPTH): New macro, so that the initial stack isn't overly
13670         large.
13671
13672 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13673
13674         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
13675
13676 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13677
13678         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
13679         (2004-10-24) change.  Apparently this was a false alarm.
13680
13681         * modules/getdate: Depend on alloca-opt, not alloca.
13682
13683 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13684
13685         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
13686         Remove now-obsolete comment about AIX.
13687         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
13688         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
13689         (YYMAXDEPTH): New macro.
13690
13691 2004-12-18  Simon Josefsson  <jas@extundo.com>
13692
13693         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
13694
13695 2004-12-18  Bruno Haible  <bruno@clisp.org>
13696
13697         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
13698
13699 2004-12-18  Bruno Haible  <bruno@clisp.org>
13700
13701         * lib/fatal-signal.c (fatal_signals): Make non-const.
13702         (init_fatal_signals): New function.
13703         (uninstall_handlers, install_handlers): Ignore signals that were set to
13704         SIG_IGN.
13705         (at_fatal_signal): Call init_fatal_signals.
13706         (init_fatal_signal_set): Likewise. Ignore signals that were set to
13707         SIG_IGN.
13708         Reported by Paul Eggert.
13709
13710 2004-12-18  Bruno Haible  <bruno@clisp.org>
13711
13712         * doc/alloca.texi: New file.
13713         * doc/alloca-opt.texi: New file.
13714
13715 2004-12-17  Jim Meyering  <jim@meyering.net>
13716
13717         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
13718         Otherwise, install-sh could exit with improper exit status when
13719         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
13720
13721 2004-12-16  Simon Josefsson  <jas@extundo.com>
13722
13723         * tests/test-base64.c: Add license.
13724
13725 2004-12-15  Stepan Kasal  <address@hidden>
13726
13727         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
13728
13729 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
13730
13731         * modules/getcwd (Files): Add m4/d-ino.m4.
13732         Suggested by Mark D. Baushke.
13733
13734 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13735
13736         * lib/getdate.y (textint): New member "negative".
13737         (time_zone_hhmm): New function.
13738         Expect 14 shift-reduce conflicts, not 13.
13739         (o_colon_minutes): New rule.
13740         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
13741         (yylex): Set the "negative" member of signed numbers.
13742
13743 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13744
13745         * doc/getdate.texi (Time of day items, Time zone items):
13746         Describe new formats +00:00, UTC+00:00.
13747
13748 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13749
13750         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
13751         spurious "-l"s.  Problem reported by Stepan Kasal.
13752
13753 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
13754
13755         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
13756         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
13757
13758 2004-12-04  Simon Josefsson  <jas@extundo.com>
13759
13760         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
13761         Vandoorselaere <yoann@prelude-ids.org>.
13762
13763 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13764
13765         Changes imported from coreutils.
13766         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
13767         exist.
13768         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
13769
13770 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13771
13772         Changes imported from coreutils.
13773         * lib/hard-locale.c: Assume <locale.h> exists.
13774         Include "strdup.h".
13775         (GLIBC_VERSION): New macro.
13776         (hard_locale): Assume setlocale exists.
13777         Rewrite to avoid #ifdef.
13778         Use strdup rather than malloc + strcpy.
13779         * lib/human.c: Assume <locale.h> exists.
13780         (human_readable): Assume localeconv exists.
13781
13782 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13783
13784         * modules/hard-locale (Depends-on): Add strdup.
13785
13786 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
13787
13788         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
13789         convert T2, not T.  (Imported from libc.)
13790
13791 2004-11-30  Simon Josefsson  <jas@extundo.com>
13792
13793         * modules/restrict (License): Change to LGPL.
13794
13795 2004-11-30  Simon Josefsson  <jas@extundo.com>
13796
13797         * m4/restrict.m4: Add copyright and copying conditions.
13798
13799 2004-11-30  Simon Josefsson  <jas@extundo.com>
13800
13801         * m4/base64.m4: New file.
13802
13803 2004-11-30  Simon Josefsson  <jas@extundo.com>
13804
13805         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
13806         base64.
13807
13808         * tests/test-base64.c: New file.
13809
13810         * modules/base64: New file.
13811
13812 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13813
13814         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
13815         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
13816
13817         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
13818
13819 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13820
13821         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
13822         (__getcwd.c): Don't restore errno; glibc doesn't.
13823         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
13824         first, falling back to our code only if its results look suspicious.
13825         Ensure that the resulting buffer is only as large as necessary.
13826
13827         * lib/readutmp.c: Include readutmp.h first.
13828         Include <errno.h>, since readutmp.h no longer does that.
13829         * lib/readutmp.h: Don't include <errno.h>,
13830         <sys/param.h>, <time.h>; not needed to establish interface.
13831         (errno): Remove decl.
13832         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
13833         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
13834         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
13835
13836 2004-11-28  Simon Josefsson  <jas@extundo.com>
13837
13838         * lib/base64.h, base64.c: New file.
13839
13840 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
13841
13842         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
13843
13844 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
13845
13846         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
13847         (Depends-on): Remove pathmax, same.  Add mempcpy.
13848         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
13849         (Makefile.am): Append getcwd.h to lib_SOURCES.
13850         (Include): Add getcwd.h.
13851         (Maintainer): Change from Jim Meyering to "all, glibc",
13852         since getdate now uses intended-for-glibc code.
13853         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
13854         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
13855
13856 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13857
13858         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
13859         HP's ANSI C compiler.
13860         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
13861         Declaring int functions causes warnings on some modern systems and
13862         shouldn't be needed to compile on ancient ones.
13863         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
13864         defined.
13865
13866         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
13867         with the following changes.
13868         (__set_errno): Parenthesize properly.
13869         Include <stdbool.h>.
13870         (MIN, MAX, MATCHING_INO): New macros.
13871         (__getcwd): Define with prototype, not K&R form.
13872         Use heuristics to allocate default buffer on stack if possible.
13873         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
13874         behavior, and to avoid the PATH_MAX limit when computing
13875         ../../../../...
13876         Use MATCHING_INO to compare inode number to file.
13877         Check for arithmetic overflow in size calculations.
13878         Fix bug in reallocation of dot array that caused getcwd to fail
13879         on directories nested deeper than 75.
13880         Be more careful about saving errno on error.
13881         Do not use realloc; use only free+malloc, as this is a bit
13882         more flexible and avoids a needless copy operation.
13883         Do not inspect st_dev and st_ino for symbolic links; POSIX
13884         doesn't specify the latter.
13885         Check for closedir errors.
13886         Avoid needless casts.
13887         Use "#ifdef weak_alias" around weak_alias, to be like other
13888         glibc code.
13889         The following changes to getcwd.c have effect only when used in
13890         gnulib; they have no effect inside glibc proper.
13891         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
13892         as alloca isn't used.
13893         (alloca, __alloca): Likewise.
13894         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
13895         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
13896         unconditionally, as gnulib assumes C89 or better.
13897         Do not include <sys/param.h>.
13898         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
13899         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
13900         better.
13901         (NULL) [!defined NULL]: Remove; we assume C89 or better.
13902         Include <dirent.h> in a way that is compatible with modern Autoconf.
13903         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
13904         New macros, if not already defined.
13905         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
13906         Use "_LIBC", not "defined _LIBC", for consistency.
13907         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
13908         a mempcpy module.
13909         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
13910         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
13911         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
13912         credit only to Jim Meyering and adjust the copyright dates.
13913         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
13914         <stdlib.h>, <unistd.h>, "pathmax.h".
13915         Instead, include "xgetcwd.h" (first) and "getcwd.h".
13916         (INITIAL_BUFFER_SIZE): Remove.
13917         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
13918
13919 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13920
13921         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
13922         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
13923         Use the _ONCE methods, for efficiency.
13924         Check for fcntl.h.  In test program, include <errno.h>
13925         and <fcntl.h> if available.  Remove old K&R cruft from
13926         test program.  Check for common errors in GNU/Linux,
13927         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
13928         don't do AC_LIBOBJ, as that's getcwd.m4's job.
13929         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
13930         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
13931         name accordingly.
13932         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
13933         accommodate new getcwd.c.
13934         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
13935         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
13936         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
13937         that's all we need now.
13938
13939 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13940
13941         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
13942         argp-parse.c depends on getopt internals, that means we should
13943         always use our getopt, to be on the safe side.
13944         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
13945         order not to spoil the result of an eventual previous invocation
13946         of gl_GETOPT_SUBSTITUTE.
13947
13948 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13949
13950         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
13951         redefinition warnings. To avoid them, include the defines
13952         in `#if !defined __need_getopt ... #endif'. The only place
13953         where __getopt_argv_const is used is in definitions
13954         of getopt_long and getopt_long_only below, which are as well
13955         protected by `#ifndef __need_getopt'.
13956         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
13957         __need_getopt after including <stdio.h> and <unistd.h> These
13958         headers might have defined it.
13959
13960 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
13961
13962         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
13963
13964 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
13965
13966         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
13967         (futimens): New function, which uses futimes if available.
13968         (futimens, utimens): Support timespec==NULL, with same semantics
13969         as utime and utimens.
13970         * lib/utimens.h (futimens): New decl.
13971
13972 2004-11-23  Jim Meyering  <jim@meyering.net>
13973
13974         * lib/getopt_.h: Remove trailing blanks.
13975
13976 2004-11-23  Jim Meyering  <jim@meyering.net>
13977
13978         * lib/__fpending.c: Add comment.
13979
13980 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
13981
13982         * modules/canonicalize (Depends-on): Add xreadlink.
13983         Problem reported by James Youngman.
13984
13985 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
13986
13987         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
13988         New macros.
13989         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
13990         optopt): Use them instead of invoking ## directly; otherwise, the
13991         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
13992
13993 2004-11-19  Bruno Haible  <bruno@clisp.org>
13994
13995         * lib/strtok_r.c: Move comments from here...
13996         * lib/strtok_r.h: ... to here.
13997
13998 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
13999
14000         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
14001         implementations that mishandle size_t overflow.
14002
14003 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14004
14005         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
14006         might fail.  Problem reported by Yoann Vandoorselaere.
14007         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
14008         implementations that mishandle size_t overflow.
14009
14010 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14011
14012         * modules/canon-host (Depends-on): Add strdup.
14013
14014 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14015
14016         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
14017
14018 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14019
14020         * lib/canon-host.c: Include "strdup.h".
14021         (canon_host): Use getaddrinfo if available, so that IPv6 works.
14022         Use strdup instead of malloc/strcpy to duplicate strings.
14023
14024         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
14025         (human_space_before_unit): New constant.
14026         * lib/human.c (human_readable): Support it.
14027
14028         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
14029         (xgetcwd): Set errno correctly when failing.
14030         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
14031         the failure is actually due to a PATH_MAX problem.
14032
14033         Further getopt changes to make it more likely that glibc will
14034         buy the changes back.
14035         * lib/getopt.c (POSIXLY_CORRECT): New constant.
14036         (getopt): Use it, so to preserve glibc semantic
14037         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
14038         when compiling for libc.
14039         * lib/getopt_.h (__getopt_argv_const): Bring it back.
14040         (getopt_long, getopt_long_only): Use it.
14041
14042         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14043         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
14044         (getopt): Argv is now char * const *, as per standard.
14045         (_getopt_internal_r, _getopt_internal): Argv is now char **,
14046         not char *__getopt_argv_const *.
14047         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14048         _getopt_long_only_r): Likewise.
14049         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
14050         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14051         _getopt_long_r, _getopt_long_only_r): Likewise.
14052         * lib/getopt_.h (__getopt_argv_const): Remove.
14053         (getopt): Argv is now char * const *, as per standard.
14054
14055         * lib/getdate.y (tORDINAL): New token.
14056         (day, relunit): Allow it for relative times.
14057         (relative_time_table): Use tORDINAL for ordinals.
14058
14059 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14060
14061         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
14062         Document that "second" isn't allowed as an ordinal number.
14063
14064 2004-11-16  Jim Meyering  <jim@meyering.net>
14065
14066         * modules/closeout (Depends-on): Add fpending.
14067
14068 2004-11-15  Jim Meyering  <jim@meyering.net>
14069
14070         * lib/closeout.c: Include "__fpending.h" once again.
14071         Include <stdbool.h>.
14072         (close_stdout): Don't fail just because stdout was closed initially,
14073         since some programs don't write to stdout in the normal course of
14074         operation (other than --version and --help), and we don't want this
14075         function to make e.g. `touch file >&-' fail.
14076         But do fail if it was closed and someone has tried to write to it.
14077         E.g., `printf foo >&-' must fail.
14078
14079 2004-11-13  Jim Meyering  <jim@meyering.net>
14080
14081         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
14082
14083 2004-11-12  Simon Josefsson  <jas@extundo.com>
14084
14085         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
14086         small doc fix is still pending.
14087
14088 2004-11-11  Simon Josefsson  <jas@extundo.com>
14089
14090         * modules/strtok_r: New file.
14091
14092         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14093         strtok_r.
14094
14095 2004-11-11  Simon Josefsson  <jas@extundo.com>
14096
14097         * m4/strtok_r.m4: New file.
14098
14099         * m4/getopt.m4: Replace opterr.
14100
14101 2004-11-11  Simon Josefsson  <jas@extundo.com>
14102
14103         * lib/strtok_r.h, strtok_r.c: New file.
14104
14105 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14106
14107         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
14108         of replacing opterr, getopt, etc.  This should handle the
14109         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
14110
14111 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14112
14113         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
14114         we can stop lying to compilers about the constness of argv when we
14115         are compiled outside glibc.
14116         (getopt, getopt_long, getopt_long_only): Use it.
14117         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14118         _getopt_internal, getopt): Likewise.
14119         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14120         _getopt_long_only_r): Likewise.
14121         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14122         _getopt_long_r, _getopt_long_only_r): Likewise.
14123
14124         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
14125         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
14126         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
14127         the other external symbols.
14128         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
14129         declaration, since the above renaming now works around collisions.
14130
14131 2004-11-11  Jim Meyering  <jim@meyering.net>
14132
14133         * lib/linebreak.c: Remove trailing blanks.
14134         * lib/alloca_.h: Likewise.
14135         * lib/acosl.c: Likewise.
14136         * lib/euidaccess.c: Likewise.
14137         * lib/allocsa.h: Likewise.
14138
14139 2004-11-10  Simon Josefsson  <jas@extundo.com>
14140
14141         * m4/getaddrinfo.m4: New file.
14142
14143 2004-11-10  Simon Josefsson  <jas@extundo.com>
14144
14145         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
14146
14147 2004-11-10  Simon Josefsson  <jas@extundo.com>
14148
14149         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14150         getaddrinfo.
14151
14152         * modules/getaddrinfo: New file.
14153
14154 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14155
14156         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
14157
14158 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14159
14160         * lib/mktime.c (SHR): New macro, which is a portable
14161         substitute for >> that should work even on Crays.
14162         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
14163         Problem reported by Mark D. Baushke in
14164         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
14165         * lib/getdate.y (SHR): Likewise.
14166         (tm_diff): Use it.
14167         * lib/strftime.c (SHR): Likewise.
14168         (tm_diff): Use it.
14169         * lib/quotearg.c (struct quoting_options): Use unsigned int for
14170         quote_these_too, so that right shifts are well defined.  All uses
14171         changed.
14172
14173 2004-11-10  Jim Meyering  <jim@meyering.net>
14174
14175         Ensure that no close failure goes unreported.
14176         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
14177         return early when it seems there's nothing to flush.
14178         Don't include __fpending.h.
14179
14180 2004-11-10  Jim Meyering  <jim@meyering.net>
14181
14182         * modules/closeout (Depends-on): Remove fpending.
14183
14184 2004-11-10  Jim Meyering  <jim@meyering.net>
14185
14186         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
14187
14188 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14189
14190         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
14191         gl_FUNC_STRFTIME.
14192         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
14193         and AC_REQUIRE when possible, to avoid duplicate checks.
14194         Check for <wchar.h>.
14195
14196 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14197
14198         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
14199
14200 2004-11-09  Bruno Haible  <bruno@clisp.org>
14201
14202         * m4/sockpfaf.m4: New file.
14203
14204 2004-11-05  Bruno Haible  <bruno@clisp.org>
14205
14206         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
14207         Reported by Mark D. Baushke <mdb@cvshome.org>.
14208
14209 2004-11-04  Bruno Haible  <bruno@clisp.org>
14210
14211         2004-09-11  Bruno Haible  <bruno@clisp.org>
14212                 * allocsa.valgrind: New file.
14213         2004-02-06  Bruno Haible  <bruno@clisp.org>
14214                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
14215                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
14216                 Reported by Christopher Seip <chris.seip@hp.com>.
14217
14218 2004-11-04  Bruno Haible  <bruno@clisp.org>
14219
14220         * modules/allocsa (Files): Add lib/allocsa.valgrind.
14221         (Makefile.am): Distribute it.
14222
14223 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
14224
14225         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
14226         with errno == ERANGE if the buffer is too small.
14227         Problem reported by Mark D. Baushke.
14228
14229 2004-11-03  Albert Chin  <china@thewrittenword.com>
14230             Paul Eggert  <eggert@cs.ucla.edu>
14231
14232         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
14233         equivalent, substitute $ac_type for equivalent type rather than
14234         blindly using uint32_t *always* which won't work if uint32_t is not
14235         available.  Define _UINT32_T to work around typedef of uint32_t if
14236         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
14237         2.5.1.
14238
14239 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14240
14241         * m4/jm-macros.m4: Sync from coreutils.
14242         (gl_MACROS): Check for mbrlen, for pathchk.
14243         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
14244
14245 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14246
14247         * lib/xreadlink.c (MAXSIZE): New macro.
14248         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
14249         size does not exceed MAXSIZE.  Avoid cast.
14250         As suggested by Mark D. Baushke in
14251         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
14252         if readlink fails with buffer size just under MAXSIZE, try again
14253         with MAXSIZE.
14254
14255 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14256
14257         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
14258
14259 2004-11-02  Derek R. Price  <derek@ximbiot.com>
14260         and  Paul Eggert  <eggert@cs.ucla.edu>
14261
14262         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
14263         (get_date): Overparenthesize to avoid GCC warning.
14264
14265 2004-11-02  Bruno Haible  <bruno@clisp.org>
14266
14267         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
14268         returns void.
14269
14270 2004-11-02  Bruno Haible  <bruno@clisp.org>
14271
14272         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
14273         function returns void.
14274
14275 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14276
14277         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
14278         fflush_unlocked, flockfile, funlockfile, funlockfile,
14279         fputs_unlocked, putc_unlocked.
14280
14281 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14282
14283         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14284         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
14285         already declared.
14286
14287 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14288
14289         * modules/getdate (Files): Add doc/getdate.texi.
14290         (Depends-on): Add setenv, xalloc.
14291
14292 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14293
14294         * lib/getdate.y: Add support for TZ="foo" within a date string.
14295         Fix some bugs near time_t boundaries.  Reject dates with
14296         out-of-range components, e.g., "Sept 31".
14297         Include <stdlib.h>, "setenv.h", "xalloc.h".
14298         (ISDIGIT_LOCALE): Remove; unused.
14299         Note that the TZ and time functions used here are not reentrant.
14300         (mktime_ok, get_tz): New functions.
14301         (TZBUFSIZE): New constant.
14302         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
14303         This requires that we sometimes generate our own TZ="XXX..." setting.
14304
14305 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14306
14307         * doc/getdate.texi: New file, from coreutils with modifications for
14308         the new TZ parsing.
14309
14310 2004-10-27  Derek R. Price  <derek@ximbiot.com>
14311
14312         * lib/mktime.c (not_equal_tm): Remove redundant check.
14313
14314 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14315
14316         * modules/regex (lib_SOURCES): Add regex.c.
14317         Reported by James Youngman in
14318         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
14319
14320 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14321
14322         * lib/getdate.y: Use Bison 1.875 features, and some minor
14323         code cleanups.  This change does not affect semantics.
14324         Don't include <stdlib.h>; no longer needed.
14325         Don't include unlocked-io.h; only the "#if TEST" code uses
14326         stdio, and performance isn't crucial there.
14327         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
14328         Bison 1.875 features as described below.
14329         All uses of "PC." replaced by "pc->".
14330         (YYSTYPE): Add a forward declaration.
14331         (yylex, yyerror): Use full prototypes in forward decls.
14332         Use "%pure-parser" rather than obsolescent "%pure_parser".
14333         Use %parse-param and %lex-param instead of obsolescent
14334         YYPARSE_PARAM and YYLEX_PARAM.
14335         (meridian_table, month_and_day_table, time_units_table,
14336         relative_time_table, time_zone_table, military_table,
14337         lookup_zone, lookup_word, get_date):
14338         Use NULL instead of 0 where appropriate.
14339         (to_hour): Avoid abort (), to avoid a dependency on
14340         stdlib.h.
14341         (yyerror, yylex): Now accepts parser_control * arg.
14342         (main) [TEST]: Use '\0' rather than 0 for char.
14343
14344 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14345
14346         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
14347
14348 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14349
14350         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
14351         It's now the caller's responsibility to handle the case where
14352         !HAVE_GETPAGESIZE && !defined getpagesize.
14353
14354         * lib/mktime.c (leapyear): Arg is long int, not int.
14355
14356 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
14357
14358         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
14359
14360 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
14361
14362         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
14363         missing.  Problem reported by James Youngman.
14364
14365 2004-10-16  Simon Josefsson  <jas@extundo.com>
14366
14367         * gnulib-tool: Fix comments.  Fix parse problem.
14368         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
14369
14370 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
14371
14372         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
14373         implementation of getopt_long.  Problem reported by Alexander Taler in:
14374         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
14375
14376 2004-10-15  Bruno Haible  <bruno@clisp.org>
14377
14378         * gnulib-tool: Untabify. Initialize supplied_libname.
14379         (func_usage): More homogenous output.
14380         (func_modules_transitive_closure, func_modules_to_filelist,
14381         func_emit_lib_Makefile_am): New functions.
14382         (func_import): New function, extracted from big case statement. Use
14383         func_get_license, func_modules_transitive_closure,
14384         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
14385         opt_lgpl. Don't use test -a, as it's not portable.
14386         (func_create_testdir): Use func_modules_transitive_closure,
14387         func_modules_to_filelist, func_emit_lib_Makefile_am.
14388
14389 2004-10-15  Bruno Haible  <bruno@clisp.org>
14390
14391         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
14392
14393 2004-10-15  Bruno Haible  <bruno@clisp.org>
14394
14395         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
14396         the portions belonging to each module.
14397         Suggested by Derek Robert Price <derek@ximbiot.com>.
14398
14399 2004-10-12  Simon Josefsson  <jas@extundo.com>
14400
14401         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14402         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
14403         to real functions.
14404
14405 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14406
14407         * modules/vsnprintf: New file.
14408
14409 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14410
14411         * m4/vsnprintf.m4: New file.
14412
14413 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14414
14415         * lib/vsnprintf.h: New file.
14416         * lib/vsnprintf.c: New file.
14417
14418 2004-10-11  Bruno Haible  <bruno@clisp.org>
14419
14420         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
14421         vsnprintf.
14422
14423 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14424
14425         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
14426
14427 2004-10-07  Bruno Haible  <bruno@clisp.org>
14428
14429         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
14430         fits into the provided buffer.
14431
14432 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14433
14434         * lib/diacrit.c, diacrit.h: Add GPL notice.
14435
14436         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
14437         notice.
14438         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
14439         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
14440         This avoids a potential constant-folding bug.
14441
14442 2004-10-05  Bruno Haible  <bruno@clisp.org>
14443
14444         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
14445         for the declaration of strsep.
14446
14447 2004-10-05  Bruno Haible  <bruno@clisp.org>
14448
14449         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
14450
14451 2004-10-04  Simon Josefsson  <jas@extundo.com>
14452
14453         * modules/memmem: New file.
14454         * tests/test-memmem.c: New file.
14455         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
14456
14457 2004-10-04  Simon Josefsson  <jas@extundo.com>
14458
14459         * m4/memmem.m4: New file.
14460
14461 2004-10-04  Simon Josefsson  <jas@extundo.com>
14462
14463         * lib/memmem.h: New file.
14464         * lib/memmem.c: New file, taken from glibc.
14465
14466 2004-10-04  Simon Josefsson  <jas@extundo.com>
14467
14468         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
14469         '#ifdef USE_UNLOCKED_IO'.
14470
14471 2004-10-04  Simon Josefsson  <jas@extundo.com>
14472
14473         * config/srclist.txt: Add memmem from glibc.
14474
14475 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14476
14477         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
14478
14479         * modules/argmatch, modules/argp, modules/closeout, modules/error,
14480         modules/exclude, modules/getdate, modules/getline,
14481         modules/getndelim2, modules/getpass, modules/getpass-gnu,
14482         modules/getusershell, modules/linebuffer, modules/md5,
14483         modules/mountlist, modules/posixtm, modules/readtokens,
14484         modules/readutmp, modules/regex, modules/sha1,
14485         modules/version-etc, modules/yesno:
14486         Remove dependency on unlocked-io.
14487
14488 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14489
14490         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
14491
14492         * m4/unlocked-io.m4: Add copyright notice.
14493         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
14494
14495 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14496
14497         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
14498         * lib/xmalloc.c (xmemdup): Likewise.
14499         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
14500         XFREE): Remove these long-obsolescent macros.
14501         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
14502         * lib/xstrdup.c: Remove.
14503
14504         * lib/regex.c (re_comp): Cast gettext return value to char *,
14505         Problem reported by Martin Neitzel via Mark D. Baushke.
14506
14507 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14508
14509         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
14510         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
14511         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
14512         regex.c, sha1.c, version-etc.c, yesno.c:
14513         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
14514         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
14515         the includer's responsibility.
14516
14517         Sync from coreutils.
14518
14519         * lib/modechange.c (mode_compile): Don't decrement a pointer that
14520         points to the start of a string, as the C Standard says the
14521         resulting behavior is undefined.
14522
14523         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
14524         simple -> simple_backups, numbered_existing ->
14525         numbered_existing_backups, numbered -> numbered_backups
14526         to avoid shadowing problems.  All uses changed.
14527         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
14528         * lib/backupfile.c (check_extension, numbered_backup):
14529         Rename locals to avoid shadowing 'basename'.
14530         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
14531         once.
14532
14533         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
14534         * lib/.cvsignore: Add getopt.h.
14535
14536 2004-10-04  Bruno Haible  <bruno@clisp.org>
14537
14538         * modules/README: New file.
14539         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
14540         not a module.
14541
14542 2004-10-02  Jim Meyering  <jim@meyering.net>
14543
14544         * lib/dirfd.h, getpagesize.h: Add copyright notice.
14545
14546 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14547
14548         * modules/strsep: New file.
14549
14550 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14551
14552         * m4/strsep.m4: New file.
14553
14554 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14555
14556         * lib/strsep.h: New file.
14557         * lib/strsep.c: New file.
14558
14559 2004-10-01  Simon Josefsson  <jas@extundo.com>
14560
14561         * lib/snprintf.c (snprintf): Handle size==0.
14562
14563 2004-10-01  Simon Josefsson  <jas@extundo.com>
14564             Bruno Haible  <bruno@clisp.org>
14565
14566         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
14567         (snprintf): Declare 'args'.
14568
14569 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
14570
14571         * lib/snprintf.c: Remove comments as to why each header is needed.
14572
14573 2004-10-01  Bruno Haible  <bruno@clisp.org>
14574
14575         * MODULES.html.sh: Add strsep.
14576
14577 2004-09-30  Simon Josefsson  <jas@extundo.com>
14578
14579         * modules/snprintf: New file.
14580
14581 2004-09-30  Simon Josefsson  <jas@extundo.com>
14582
14583         * m4/snprintf.m4: New file.
14584
14585 2004-09-30  Simon Josefsson  <jas@extundo.com>
14586
14587         * lib/snprintf.h, lib/snprintf.c: New files.
14588
14589 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14590
14591         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
14592         (hol_entry_help): Never translate an empty string.
14593         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
14594         * lib/argp.h (OPTION_NO_TRANS): New option.
14595
14596 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14597
14598         * modules/argp (Maintainer): Replace Simon Josefsson
14599         by Sergey Poznyakoff.
14600
14601 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14602
14603         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
14604         changes merged back into glibc.
14605
14606 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14607
14608         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
14609
14610 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14611
14612         * lib/xvasprintf.c: Include xalloc.h.
14613         (xvasprintf): Use xalloc_die, not xmalloc_die.
14614
14615 2004-09-29  Bruno Haible  <bruno@clisp.org>
14616
14617         * modules/alloca-opt: New file, derived from modules/alloca.
14618         * modules/allocsa: Depend on alloca-opt instead of alloca.
14619         * modules/setenv: Likewise.
14620         * modules/vasnprintf: Likewise.
14621         * MODULES.html.sh: Add alloca-opt.
14622
14623 2004-09-28  Simon Josefsson  <jas@extundo.com>
14624
14625         * gnulib-tool: New parameter --lgpl, to asseert that modules are
14626         LGPL, and to replace license template from GPL to LGPL.
14627
14628 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14629
14630         * modules/dummy: Change license to LGPL.
14631
14632 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14633
14634         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
14635
14636 2004-09-24  Simon Josefsson  <jas@extundo.com>
14637
14638         * modules/minmax (License): Change from GPL to LGPL.
14639
14640 2004-09-23  Simon Josefsson  <jas@extundo.com>
14641
14642         * gnulib-tool (--import): Typo.
14643
14644 2004-09-23  Simon Josefsson  <jas@extundo.com>
14645
14646         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
14647
14648 2004-09-22  Bruno Haible  <bruno@clisp.org>
14649
14650         * modules/*: Add 'License' field.
14651         * gnulib-tool: Accept --extract-license option.
14652         (func_get_license): New function.
14653
14654 2004-09-21  Bruno Haible  <bruno@clisp.org>
14655
14656         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
14657         Reported by Simon Josefsson.
14658
14659 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14660
14661         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
14662         gl_AC_TYPE_LONG_LONG.
14663
14664 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14665
14666         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
14667
14668 2004-09-18  Simon Josefsson  <jas@extundo.com>
14669         and  Paul Eggert  <eggert@cs.ucla.edu>
14670
14671         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
14672         calls with autoreconf.  Define GL_LIB.
14673
14674 2004-09-14  Karl Berry  <karl@gnu.org>
14675
14676         * config/srclist.txt: unsync setenv.c, sigh.
14677
14678 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14679
14680         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
14681         Problem reported by Bruno Haible in:
14682         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
14683
14684 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14685
14686         * config/srclist.txt: Comment out argp-pvh.c.
14687
14688 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
14689
14690         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
14691         in case some system header has #define'd it.  Problem reported by
14692         Soeren D. Schulze in
14693         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
14694
14695 2004-09-09  Karl Berry  <karl@gnu.org>
14696
14697         * regex.[ch]: delete from the root.  These were supposed to be
14698                 synced with emacs cvs, but this has not happened for about
14699                 a year, and anyway nothing else uses emacs regex.[ch].
14700                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
14701                 lib/regex[.ch] is untouched.
14702
14703 2004-09-09  Bruno Haible  <bruno@clisp.org>
14704
14705         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
14706
14707 2004-09-09  Bruno Haible  <bruno@clisp.org>
14708
14709         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
14710         modifications.
14711         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
14712
14713 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14714
14715         * modules/xvasprintf: New file.
14716         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
14717
14718 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14719
14720         * lib/xvasprintf.h: New file.
14721         * lib/xvasprintf.c: New file.
14722         * lib/xasprintf.c: New file.
14723
14724 2004-09-08  Bruno Haible  <bruno@clisp.org>
14725
14726         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
14727
14728 2004-09-08  Bruno Haible  <bruno@clisp.org>
14729
14730         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
14731         length is > INT_MAX.
14732         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
14733         more.
14734
14735 2004-09-08  Bruno Haible  <bruno@clisp.org>
14736
14737         * lib/stdint_.h: New file, taken from GNU clisp.
14738
14739 2004-09-08  Bruno Haible  <bruno@clisp.org>
14740             Oskar Liljeblad  <oskar@osk.mine.nu>
14741
14742         * modules/stdint: New file.
14743         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
14744
14745 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14746
14747         Import from coreutils.
14748         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
14749         strings on unbounded length.  alloca's performance benefits aren't
14750         that important here.
14751         (V_STRDUP): Remove.
14752         (parse_with_separator): New function, with most of the internals
14753         of the old parse_user_spec.  Allow user to omit both user and group,
14754         for compatibility with FreeBSD.
14755         Clone only the user name, not the entire spec.
14756         Do not set *uid, *gid unless entirely successful.
14757         Avoid memory leak in some failing cases.
14758         Fix regression for USER.GROUP reported by Dmitry V. Levin in
14759         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
14760         (parse_user_spec): Rewrite to use parse_with_separator.
14761
14762 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14763
14764         * modules/userspec: Don't depend on alloca.
14765
14766 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14767
14768         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
14769
14770 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
14771
14772         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
14773         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
14774         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
14775
14776 2004-08-16  Simon Josefsson  <jas@extundo.com>
14777
14778         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
14779         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
14780         Add --dry-run for --import.
14781         Let user provided command line parameters override configure.ac
14782         settings.
14783
14784 2004-08-12  Simon Josefsson  <jas@extundo.com>
14785
14786         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
14787         as discussed with Paul Eggert in threads rooted at
14788         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
14789         and
14790         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
14791         Before, the test was empty, and relied on ELIDE_CODE in source
14792         code.)
14793         (gl_PREREQ_GETOPT): New macro.
14794         (gl_GETOPT): Use them.
14795
14796 2004-08-12  Simon Josefsson  <jas@extundo.com>
14797
14798         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
14799         * lib/getopt_.h: Renamed from getopt.h.
14800
14801 2004-08-12  Simon Josefsson  <jas@extundo.com>
14802
14803         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
14804         Change default library name from libfoo to libgnu.
14805         Now, if you have a configure.ac that says:
14806                 gl_SOURCE_BASE(gl)
14807                 gl_M4_BASE(gl/m4)
14808                 gl_MODULES(error getopt etcetera)
14809                 gl_INIT
14810         you can import all you need by running:
14811                 ../gnulib/gnulib-tool --import
14812
14813         * modules/getopt (Files): Rename getopt.h to getopt_.h.
14814         (Makefile.am): Rewrite, use logic from argz.
14815         (Include): Use <getopt.h> instead of "getopt.h".
14816
14817 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14818
14819         * modules/argp (Files): Add m4/unlocked-io.m4.
14820         (Depends-on): Add extensions.
14821
14822 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14823
14824         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
14825         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
14826         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
14827         Check for program_invocation_name, program_invocation_short_name,
14828         flockfile, funlockfile, features.h, _getopt_long_only_r.
14829
14830 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14831
14832         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
14833         its complicated substitute.
14834         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
14835         and program_invocation_name.
14836         (__argp_basename) [!_LIBC]: Remove; the only use was
14837         replaced by its body.
14838         (__argp_short_program_name): Change condition from
14839         !defined __argp_short_program_name to
14840         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
14841         to match argp-namefrob.h.
14842         (__argp_failure): Don't assume strerror_r returns char *.
14843         * lib/argp-parse.c (N_): Define unconditionally.
14844         (argp_default_options): Fill out initializers with 0 to avoid
14845         gcc warnings.
14846
14847 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14848
14849         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
14850         getopt1.c.
14851
14852 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14853
14854         Merge from coreutils.
14855
14856         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
14857
14858         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
14859         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
14860
14861 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14862
14863         Merge from coreutils.
14864
14865         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
14866         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
14867         for Reliant Unix 5.43.
14868
14869         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
14870         (union fooround): Use uintmax_t, not long int.
14871         The rest is a merge from libc:
14872         [defined _LIBC]: Include <shlib-compat.h>.
14873         (_obstack) [defined _LIBC]: Remove after 2.3.4.
14874
14875         * lib/settime.c (settime): Recode to avoid warning with
14876         Sun Forte C 6U2.
14877
14878         * lib/strverscmp.c: Convert to UTF-8.
14879
14880 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14881
14882         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14883         m4/uintmax_t.m4.
14884
14885 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14886
14887         * modules/xalloc-die: New file.
14888         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
14889
14890         * modules/md5 (Files): Add m4/uint32_t.m4.
14891         * modules/sha1: Renamed from modules/sha.
14892         (Files):
14893         Rename lib/sha.h to lib/sha1.h.
14894         Rename lib/sha.c to lib/sha1.c.
14895         Rename m4/sha.m4 to m4/sha1.m4.
14896         (lib_SOURCES): Likewise.
14897         (configure.ac): Rename gl_SHA to gl_SHA1.
14898         (Include): sha.h -> sha1.h.
14899
14900 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14901
14902         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
14903         * m4/sha1.m4: Renamed from sha.m4.
14904         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
14905
14906 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14907
14908         * lib/obstack.h (obstack_empty_p):
14909         Don't assume that chunk->contents is suitably aligned.
14910         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
14911         Likewise. Problem reported by Benno in
14912         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
14913
14914         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
14915         readable.  This could be improved further but it'd take some work.
14916
14917 2004-08-08  Simon Josefsson  <jas@extundo.com>
14918
14919         * modules/xgethostname (Depends-on): Remove exit and error (not
14920         used).
14921
14922         * modules/getpass-gnu: Add getpass.h.
14923         (Depends-on): Add stdbool.
14924         * modules/getpass: Add getpass.h.
14925
14926 2004-08-08  Simon Josefsson  <jas@extundo.com>
14927
14928         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
14929         Check getpass declaration.
14930
14931 2004-08-08  Simon Josefsson  <jas@extundo.com>
14932
14933         * lib/xgethostname.c: Don't include error.h (not used).
14934
14935         * lib/getpass.h: Add.
14936         * lib/getpass.c: Include getpass.h first.
14937
14938 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
14939
14940         * lib/xalloc-die.c: New file.
14941         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
14942         All uses removed.
14943         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
14944         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
14945         xalloc-die.c.
14946         (_, N_, xalloc_die): Move to xalloc-die.c.
14947         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
14948         so that we needn't mess with xalloc_msg_memory_exhausted.
14949
14950         * lib/sha1.h: Renamed from sha.h.
14951         (SHA1_H): Renamed from _SHA_H.
14952         (sha1_ctx): Renamed from sha_ctx.
14953         (sha1_init_ctx): Renamed from sha_init_ctx.
14954         (sha1_process_block): Renamed from sha_process_block.
14955         (sha1_process_bytes): Renamed from sha_process_bytes.
14956         (sha1_finish_ctx): Renamed from sha_finish_ctx.
14957         (sha1_read_ctx): Renamed from sha_read_ctx.
14958         (sha1_stream): Renamed from sha_stream.
14959         (sha1_buffer): Renamed from sha_buffer.
14960         * lib/sha1.c: Likewise; renamed from sha.c.
14961         Do not include <sys/types.h>.
14962         Include <stddef.h> rather than <stdlib.h>.
14963
14964 2004-08-08  Bruno Haible  <bruno@clisp.org>
14965
14966         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
14967         FILESYSTEM_PREFIX_LEN.
14968         * lib/progreloc.c: Likewise.
14969         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
14970
14971 2004-08-06  Simon Josefsson  <jas@extundo.com>
14972
14973         * modules/progname (Depends-on): Don't depend on stdbool.
14974
14975 2004-08-06  Simon Josefsson  <jas@extundo.com>
14976
14977         * modules/getsubopt: New file.
14978         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14979         getsubopt.
14980
14981 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
14982
14983         More merge from coreutils.
14984
14985         * m4/utimens.m4, m4/utimecmp.m4: New files.
14986         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
14987         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
14988         prereq.m4, sha.m4: Import changes from coreutils.
14989
14990 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
14991
14992         More merge from coreutils.
14993         * modules/raise, modules/readtokens0, modules/utimens:
14994         * modules/utimecmp, module/xnanosleep: New files.
14995         * modules/strftime: Add lib/strftime.h.
14996         Change include from <time.h> to "strftime.h".
14997         * modules/yesno: Add lib/yesno.h.
14998         * modules/backupfile: Remove lib/addext.c.
14999         * modules/euidaccess: Add stat-macros.h.
15000         * modules/canonicalize, modules/euidaccess,
15001         modules/filemode, modules/lchown, modules/makepath,
15002         modules/rmdir, modules/stat: Likewise.
15003
15004 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15005
15006         Merge from tar.
15007         * lib/argp-help.c (make_hol, hol_append): Don't assume that
15008         SIZE_MAX is a valid preprocessor constant.
15009         (__argp_basename): Change from "#ifndef _LIBC"
15010         to "#ifndef __argp_short_program_name", so that
15011         we don't compile these functions for tar.
15012
15013         More merges from coreutils.
15014         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
15015         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
15016         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
15017         * lib/addext.c: Remove; no longer needed.
15018         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
15019         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
15020         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
15021         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
15022         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
15023         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
15024         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
15025         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
15026         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
15027         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15028         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
15029         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
15030         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
15031         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
15032         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
15033         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
15034         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
15035         Import changes from coreutils.
15036
15037 2004-08-05  Simon Josefsson  <jas@extundo.com>
15038
15039         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
15040
15041 2004-08-05  Simon Josefsson  <jas@extundo.com>
15042
15043         * m4/getsubopt.m4: New file.
15044
15045 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15046
15047         Merge from coreutils.
15048
15049         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
15050         * m4/getcwd-path-max.m4: New files.
15051
15052         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
15053         FILESYSTEM_PREFIX_LEN ->
15054         FILE_SYSTEM_PREFIX_LEN.
15055         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
15056         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
15057         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
15058         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
15059
15060         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
15061         prerequisite modules now handle the DOS stuff.
15062         Don't check for unistd.h.
15063
15064 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15065
15066         Merge from coreutils.
15067
15068         * lib/.gdb-history: Remove; this doesn't belong here.
15069
15070         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
15071         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
15072         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
15073         * lib/getcwd.c: New files.
15074
15075         * lib/dirname.h: Include <stdbool.h>.
15076         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
15077         for consistency with POSIX terminology.  All uses changed.
15078         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
15079         (strip_trailing_slashes): Use bool for booleans.
15080         * lib/stripslash.c (strip_trailing_slashes): Likewise.
15081
15082         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
15083         sometimes returns a positive errno value even when it succeeds.
15084         (print_errno_message) [!LIBC]: Fall back on strerror if
15085         __strerror_r fails.
15086
15087         * lib/path-concat.c (mempcpy): Don't define if a system header defines
15088         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
15089         (longest_relative_suffix): New function.
15090         (path_concat): Use it.  Assume first argument is not NULL.
15091         Port to DOS.  Omit redundant separators.
15092         Report an error instead of returning NULL.
15093         Use mempcpy instead of memcpy.
15094         (xpath_concat): Remove: not declared or used.
15095
15096         * lib/same.h: Include <stdbool.h>
15097         (same_name): Return bool, not int.
15098         * lib/same.c (same_name): Likewise.
15099         (errno): Don't declare; we assume C89 or better now.
15100
15101         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
15102         if not already defined.
15103
15104         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
15105         * lib/dup-safer.c (errno): Likewise.
15106
15107 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15108
15109         Merge from coreutils.
15110         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
15111         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
15112         * modules/path-concat: Don't depend on strdup.
15113
15114 2004-08-03  Simon Josefsson  <jas@extundo.com>
15115
15116         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
15117         * lib/progname.h: Don't include stdbool.h.
15118
15119 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15120
15121         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
15122         * MODULES.html.sh (func_all_modules): Remove fatal.
15123
15124 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15125
15126         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
15127
15128 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15129
15130         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
15131         working.
15132
15133 2004-08-02  Simon Josefsson  <jas@extundo.com>
15134
15135         * lib/getsubopt.h: New file, with comments from Bruno Haible.
15136         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
15137         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
15138
15139 2004-08-01  Simon Josefsson  <jas@extundo.com>
15140
15141         * lib/xgetdomainname.c: Include stdlib.h, for free().
15142
15143 2004-07-19  Bruno Haible  <bruno@clisp.org>
15144
15145         * MODULES.html.sh (func_all_modules): Add dummy.
15146
15147 2004-07-16  Simon Josefsson  <jas@extundo.com>
15148
15149         * modules/dummy: New file.
15150
15151 2004-07-16  Simon Josefsson  <jas@extundo.com>
15152
15153         * lib/dummy.c: New file.
15154
15155 2004-07-16  Bruno Haible  <bruno@clisp.org>
15156
15157         * lib/backupfile.h: Add extern "C" for C++.
15158         * lib/closeout.h: Likewise.
15159         * lib/copy-file.h: Likewise.
15160         * lib/findprog.h: Likewise.
15161         * lib/full-write.h: Likewise.
15162         * lib/pathname.h: Likewise.
15163         * lib/progname.h: Likewise.
15164         * lib/stpcpy.h: Likewise.
15165         * lib/stpncpy.h: Likewise.
15166         * lib/strcase.h: Likewise.
15167         * lib/strstr.h: Likewise.
15168         * lib/xalloc.h: Likewise.
15169
15170         * lib/mbswidth.h: Add extern "C" for C++.
15171         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
15172
15173 2004-07-13  Robert Millan  <robertmh@gnu.org>
15174
15175         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
15176
15177 2004-07-09  Simon Josefsson  <jas@extundo.com>
15178
15179         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
15180         failed without this.)
15181
15182 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15183
15184         * modules/chown (Files): Add lib/fchown-stub.c, since
15185         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
15186
15187 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15188
15189         * lib/fchown-stub.c: New file.
15190
15191 2004-06-24  Jim Meyering  <jim@meyering.net>
15192
15193         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
15194
15195 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15196
15197         * modules/argz: Omit "#include".
15198
15199         * MODULES.html.sh (func_all_modules): Add calloc, to match
15200         2004-06-01 addition of calloc module.
15201
15202 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15203
15204         * m4/argz.m4: New file, which is autoupdated from libtool.
15205
15206 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15207
15208         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
15209         libtool.
15210
15211 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15212
15213         * config/srclist-update: Don't insist on "USA." before the
15214         close-comment, as libtool omits the period and puts the */ on a
15215         separate line.
15216         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
15217         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
15218
15219 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
15220
15221         * modules/argz: New file.
15222         * MODULES.html.sh (func_all_modules): Add argz.
15223
15224 2004-06-12  Jim Meyering  <jim@meyering.net>
15225         and  Paul Eggert  <eggert@cs.ucla.edu>
15226
15227         * modules/hash (Files): Add lib/xalloc.h.
15228         * modules/pipe (Depends-on): Add wait-process.
15229         * modules/stat (Depends-on): Add xalloc.
15230         * modules/userspec (Files): Add lib/userspec.h.
15231         * modules/xstrto
15232
15233         Upgrade from gettext-0.13.
15234         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
15235         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
15236         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
15237
15238 2004-06-10  Jim Meyering  <jim@meyering.net>
15239
15240         * lib/calloc.c: New file.
15241
15242 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
15243
15244         * lib/getdate.y (yylex): Allow space between sign and number.
15245         Problem reported by Dan Jacobson.
15246
15247 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15248
15249         Merge from coreutils CVS.
15250
15251         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
15252         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
15253         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
15254         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
15255         xstrtol.m4: Fix copyright date and/or serial number.
15256
15257         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
15258         See if we need an fchown replacement.
15259         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
15260         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
15261         and use the replacement function if we detect either defect.
15262
15263         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
15264         gl_UTIMECMP.
15265
15266 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15267         and  Jim Meyering  <jim@meyering.net>
15268
15269         Merge from coreutils CVS.
15270
15271         * lib/stat-macros.h: New file, with contents from file-type.h
15272         and coreutils' system.h.
15273         * lib/file-type.c: Include "stat-macros.h".
15274         * lib/file-type.h (file_type): Move all macro definitions to new file,
15275         stat-macros.h.
15276
15277         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
15278         Wrap old code with this conditional.
15279         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
15280         function that does not dereference symlinks.
15281         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
15282
15283         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
15284         dependency problems.
15285         (xreadlink): Accept new arg SIZE, for efficiency.
15286         All decls and uses changed.
15287         * lib/xreadlink.h: Include <stddef.h>, for size_t.
15288
15289         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
15290         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
15291
15292         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
15293         sysexits.h.
15294
15295 2004-06-01  Jim Meyering  <jim@meyering.net>
15296
15297         * m4/calloc.m4: New file.
15298
15299 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
15300
15301         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
15302         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
15303         Also, fix a typo in a diagnostic.
15304
15305 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15306
15307         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
15308         or AC_FUNC_REALLOC.
15309
15310 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15311
15312         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
15313         macros to be defined.
15314         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
15315         the allocator returns NULL because the requested size is zero.
15316
15317 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15318
15319         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
15320         var.  Add comment explaining why libc still defines it.  This
15321         merges the following patch from glibc:
15322         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
15323
15324 2004-05-20  Andreas Schwab  <schwab@suse.de>
15325
15326         * m4/free.m4: Replace free if it not known to work, not the other
15327         way round.
15328
15329 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
15330
15331         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
15332         present in glibc since revision 1.1 of this file.
15333         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
15334         obstack_alignment_mask, obstack_alloc, obstack_base,
15335         obstack_blank, obstack_blank_fast, obstack_chunk_size,
15336         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
15337         obstack_grow0, obstack_init, obstack_int_grow,
15338         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
15339         obstack_next_free, obstack_object_size, obstack_ptr_grow,
15340         obstack_ptr_grow_fast, obstack_room): Remove declarations of
15341         nonexistent functions.
15342
15343 2004-05-18  Karl Berry  <karl@gnu.org>
15344
15345         * config/srclist.txt: break link for vasnprintf.c.
15346
15347 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15348
15349         Port obstack to the AS/400, where pointers are 16 bytes wide and
15350         you cannot cast an integer to a valid pointer.  This patch is
15351         currently waiting to be integrated into glibc; see
15352         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
15353
15354         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
15355         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
15356         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
15357         (struct obstack): temp member is now a union of a pointer and
15358         an integer, instead of an integer.  All integer uses changed.
15359         This does not affect the physical layout of struct obstack,
15360         except on hosts (like the AS/400) where the size or alignment of
15361         void * is greater than that of ptrdiff_t.
15362         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
15363         __STDC__)]: Store temporary in pointer member of union, not
15364         integer member.
15365         * lib/obstack.c: Include <stddef.h>, for offsetof.
15366         (struct fooalign): Remove; it doesn't need a name.
15367         (union fooround): Change double to long double, and add void *.
15368         (DEFAULT_ALIGNMENT): Use offsetof to compute.
15369         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
15370         not a macro.  Hence the values are always int; so remove all
15371         casts-to-int in uses.
15372
15373 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15374
15375         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
15376         we can get this patch merged into glibc.
15377
15378 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15379             Paul Eggert  <eggert@cs.ucla.edu>
15380
15381         * m4/argp: Depend on alloca.
15382
15383 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15384             Paul Eggert  <eggert@cs.ucla.edu>
15385
15386         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
15387         freecoding.
15388
15389 2004-05-17  Bruno Haible  <bruno@clisp.org>
15390
15391         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
15392         precision that consists of a '.' followed by an empty digit string.
15393         Patch by Tor Lillqvist <tml@iki.fi>.
15394
15395 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15396
15397         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
15398         for backward compatibility with older code.  We need our own
15399         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
15400         it under some other name, and our alloca.h will define it.
15401
15402 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15403             Derek Price  <derek@ximbiot.com>
15404
15405         * lib/alloca.c: Include <alloca.h>, to get our interface.
15406         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
15407         include <alloca.h> first.  Use C89 prototype for alloca; this
15408         requires including <stddef.h> for size_t.  Use extern "C" if C++.
15409         Use #elif for simplicity, since we can assume C89 now.
15410         Don't try to source the system alloca.h since it will not be found
15411         and to prevent recursively including its replacement.
15412         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
15413         * lib/regex.c: Likewise.
15414
15415 2004-05-16  Derek Price  <derek@ximbiot.com>
15416             Paul Eggert  <eggert@cs.ucla.edu>
15417
15418         getline cleanup.  This changes the getndelim2 API: both order of
15419         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
15420         no delimiter).
15421
15422         * lib/getline.c: Don't include stddef.h or stdio.h, since our
15423         interface does that.
15424         (getline): Always use getdelim, so that we don't have two
15425         copies of this code.
15426         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
15427         if available.
15428         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
15429         (GETNDELIM2_MAXIMUM): New macro.
15430         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
15431         instead of the old practice of delim2==0.  All callers changed.
15432         Return -1 on overflow, instead of returning junk.
15433         Do not set *linesize unless allocation succeeds.
15434         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
15435         that we include sys/types.h.
15436         * lib/getnline.h: Likewise.
15437         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
15438         (getndelim2): Reorder arguments.
15439         * lib/getnline.c (getnline, getndelim):
15440         Don't discard the NMAX argument.
15441         (getnline): Invoke getndelim, to avoid code duplication.
15442         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
15443         of (size_t) -1 by callers of the getnline family.
15444
15445 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15446
15447         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
15448         Check for gettimeofday.
15449         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
15450         Check for settimeofday, stime.
15451
15452 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15453
15454         * lib/nanosleep.c (suspended): Change its type from int to
15455         sig_atomic_t volatile.
15456         (first_call): Make it private to rpl_nanosleep, and have it
15457         be zero initially as that's a bit faster.
15458         (my_usleep): Round up fractional times instead of truncating them,
15459         as this is the usual meaning for 'sleep'.
15460
15461         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
15462         doesn't work.
15463         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
15464         (ENOSYS): Define if not defined.
15465         (settime): Fall back on stime if it exists and settimeofday fails.
15466         But don't bother with fallbacks if a method fails with errno == EPERM.
15467
15468 2004-05-11  Jim Meyering  <jim@meyering.net>
15469
15470         Prior to this change, the save_cwd caller required read access to the
15471         current directory on most systems (ones with the fchdir function).
15472
15473         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
15474         fails, try write-only, and finally, resort to using xgetcwd.
15475
15476 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15477
15478         * lib/obstack.c, obstack.h: Import changes from libc.
15479
15480 2004-04-28  Bruno Haible  <bruno@clisp.org>
15481
15482         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
15483         also implicitly appends .exe to executables.
15484         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
15485         accepts Windows pathnames.
15486         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15487         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15488         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15489         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15490         Reported by Derek Robert Price <derek@ximbiot.com>.
15491
15492 2004-04-21  Karl Berry  <karl@gnu.org>
15493
15494         * config/srclist.txt (localcharset.c): break sync.
15495
15496 2004-04-20  Paul Eggert  <eggert@twinsun.com>
15497
15498         * m4/host-os.m4: Add a copyright notice.
15499
15500 2004-04-20  Jim Meyering  <jim@meyering.net>
15501
15502         Change UTILS_ to gl_ in AC_DEFINE'd names.
15503         Change utils_- and jm_-prefixed variables, too.
15504         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
15505         UTILS_FUNC_MKDIR_TRAILING_SLASH.
15506         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
15507
15508         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
15509         Don't emit trailing blanks.
15510         Also rename jm_-prefixed variables to have gl_ prefix.
15511
15512         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
15513         Also rename jm_-prefixed variables to have gl_ prefix.
15514
15515         * m4/jm-macros.m4: Reflect the renamings.
15516         * m4/prereq.m4: Likewise.
15517
15518 2004-04-20  Jim Meyering  <jim@meyering.net>
15519
15520         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
15521         memory.
15522
15523 2004-04-20  Jim Meyering  <jim@meyering.net>
15524             Bruno Haible  <bruno@clisp.org>
15525
15526         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
15527         memory when realloc fails.
15528
15529 2004-04-19  Jim Meyering  <jim@meyering.net>
15530
15531         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
15532         now that readutmp.c may call `free (0)'.
15533
15534 2004-04-19  Bruno Haible  <bruno@clisp.org>
15535
15536         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
15537         * m4/inttypes_h.m4: Likewise.
15538         * m4/stdint_h.m4: Likewise.
15539         * m4/intmax_t.m4: Likewise.
15540         * m4/uintmax_t.m4: Likewise.
15541
15542 2004-04-18  Jim Meyering  <jim@meyering.net>
15543
15544         * m4/prereq.m4: Don't forbid jm_ prefix.
15545
15546         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
15547         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
15548         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
15549         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
15550         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
15551         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
15552         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
15553         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
15554         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
15555         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
15556         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
15557         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
15558         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
15559         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
15560         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
15561         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
15562         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
15563         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
15564         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
15565
15566 2004-04-18  Jim Meyering  <jim@meyering.net>
15567
15568         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
15569         failure, don't leak memory and do call END_UTMP_ENT.
15570
15571 2004-04-16  Jim Meyering  <jim@meyering.net>
15572
15573         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
15574         coreutils' stat program.
15575         (gl_PREREQ): Don't require jm_PREREQ_STAT.
15576
15577 2004-04-11  Paul Eggert  <eggert@twinsun.com>
15578
15579         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
15580         C89.
15581         (CHAR_BIT): Remove, since we assume C89.
15582         Include <stdint.h> if available, as per current Autoconf CVS advice.
15583
15584 2004-03-31  Jim Meyering  <jim@meyering.net>
15585
15586         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
15587         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
15588         * m4/xalloc.m4: Likewise.
15589
15590 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15591
15592         Merge from coreutils.
15593
15594         * m4/inttostr.m4: New file.
15595         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
15596         Require AM_STDBOOL_H and gl_TIMESPEC instead.
15597         Require gl_CLOCK_TIME.
15598         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
15599
15600 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15601
15602         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
15603         not bool, to be more consistent with Unix conventions.
15604         Suggested by Bruno Haible.
15605
15606         Merge from coreutils.
15607
15608         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
15609         * lib/umaxtostr.c: New files.
15610
15611         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
15612         the usual <time.h> dance.
15613         (get_date): Change signature to support fractional time stamps.
15614         All callers changed.
15615         * lib/getdate.y: Include "getdate.h" first, as we can now
15616         assume C89 and don't need to worry about 'const'.
15617         Similarly, include "unlocked-io.h" near start, not in middle.
15618         Include <limits.h>.
15619         (textint.value): Use long int rather than int.
15620         (textint.digits): Use size_t rather than int.
15621         (BILLION, LOG10_BILLION): New constants.
15622         (parser_control): New member rel_ns.  Members day_ordinal,
15623         time_zone, month, day, hour, minutes, rel_year, rel_month,
15624         rel_day, rel_hour, rel_minutes, rel_seconds
15625         are now long int, not int.  Member seconds is now struct timespec,
15626         not int.  New member timespec_seen.  Members dates_seen, days_seen,
15627         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
15628         not int.
15629         (%union.intval): Now long int, not int.
15630         New member timespec.
15631         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
15632         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
15633         (spec): Now is a timespec or an item list.
15634         (timespec, items): New nonterminals.
15635         (time, rel, relunit, number, get_date):
15636         Add support for fractional seconds.
15637         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
15638         (gmtime, localtime, mktime): Remove decls; not needed with C89.
15639         (to_hour): First arg is now long int, not int.
15640         (to_year): Returns long int, not int.
15641         Don't treat year -70 like 70.
15642         (tm_diff): Returns long int, not int.
15643         (lookup_word): Use bool instead of int when appropriate.
15644         (yylex): Use size_t for count, not int.
15645         Detect overflow when parsing large integer constants.
15646         Add support for fractions.
15647         (get_date): Make pointers 'const' if possible.
15648         Use more-portable code to detect integer overflow.
15649         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
15650         Don't use ctime; it's not reliable if the year has >4 digits.
15651
15652         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
15653         This is for compatibility with BSD.
15654
15655         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
15656         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
15657         From coreutils' system.h.
15658
15659         * lib/userspec.c: Don't include "posixver.h".
15660         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
15661         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
15662         compatible extension.  Simplify code by removing a boolean int
15663         that was always nonzero if a string was nonnull.
15664
15665 2004-03-30  Jim Meyering  <jim@meyering.net>
15666
15667         Merge from coreutils.
15668
15669         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
15670         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
15671         on some systems one must include <grp.h> before it.
15672         Reported by Christian Krackowizer.
15673
15674 2004-03-30  Jim Meyering  <jim@meyering.net>
15675
15676         Merge from coreutils.
15677
15678         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
15679
15680         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
15681         an empty input stream.
15682
15683         * lib/readtokens.c: Include <stdbool.h>.
15684         (readtoken): Use `size_t' rather than int/long.
15685         All callers adjusted.
15686         Use `bool' rather than `int' where appropriate.
15687         Use memset rather than an explicit loop.
15688         Use x2nrealloc rather than xrealloc.
15689         Allow the use of `\0' as a delimiter.
15690         (readtokens): Likewise.
15691         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
15692
15693 2004-03-30  Jim Meyering  <jim@meyering.net>
15694
15695         * m4/realloc.m4: Remove file, since now it does no more than
15696         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
15697         the `configure.ac' section of module/realloc.
15698         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
15699
15700 2004-03-30  Bruno Haible  <bruno@clisp.org>
15701
15702         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
15703         nonnull.
15704
15705 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15706
15707         Merge changes to getloadavg.c from coreutils and Emacs.
15708
15709         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
15710         Define to an expression, not to the empty string.
15711         Include cloexec.h and xalloc.h.
15712         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
15713         Use set_cloexec_flag rather than rolling our own.
15714         * lib/cloexec.c, lib/cloexec.h: New files.
15715
15716 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15717
15718         * m4/cloexec.m4: New file.
15719
15720 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15721
15722         * lib/getopt.h: Sync with libc CVS.
15723
15724 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15725             Bruno Haible  <bruno@clisp.org>
15726
15727         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
15728         mbswidth.
15729
15730 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15731             Bruno Haible  <bruno@clisp.org>
15732
15733         * lib/mbswidth.h: Include <wchar.h> only if
15734         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
15735         <wchar.h>.
15736         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
15737
15738 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15739
15740         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
15741         Sync with libc CVS.
15742         * lib/getopt_int.h: New file, also synced from libc.
15743
15744 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15745
15746         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
15747         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
15748         Bring back getopt.c, getopt.h, getopt1.c.
15749
15750 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15751
15752         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
15753         All uses changed.  Check for sa_sigaction member; this fixes
15754         a bug first reported by Jason Andrade in
15755         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15756
15757 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15758
15759         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
15760         '#if' expressions.  Unlike the code it replaces, it does not
15761         depend on (defined _SC_PAGESIZE).  However, it does depend on
15762         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
15763         first reported by Jason Andrade in
15764         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15765
15766 2004-02-25  Simon Josefsson  <jas@extundo.com>
15767
15768         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
15769
15770 2004-02-25  Simon Josefsson  <jas@extundo.com>
15771
15772         * lib/strdup.h: New file.
15773         * lib/strdup.c: Include it.
15774         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
15775         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
15776
15777 2004-02-23  Karl Berry  <karl@gnu.org>
15778
15779         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
15780         (from fencepost.gnu.org:/gd/gnuorg).
15781
15782 2004-02-23  Karl Berry  <karl@gnu.org>
15783
15784         * config/srclistvars.sh (GNUORG) [karl]: redefine.
15785         * config/srclist.txt: add maintain/standards documents.
15786
15787 2004-02-18  Bruno Haible  <bruno@clisp.org>
15788
15789         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
15790         Reported by Derek Robert Price <derek@ximbiot.com>.
15791
15792 2004-02-16  Karl Berry  <karl@gnu.org>
15793
15794         * config/mkinstalldirs, install-sh: update from automake.
15795
15796 2004-02-06  Karl Berry  <karl@gnu.org>
15797
15798         * m4/po.m4: update from gettext 0.14.1.
15799
15800 2004-02-06  Karl Berry  <karl@gnu.org>
15801
15802         * lib/config.charset: update from gettext 0.14.1.
15803
15804 2004-02-05  Paul Eggert  <eggert@twinsun.com>
15805
15806         Add comments and code, prompted by suggestions from Bruno Haible
15807         for sh-quote.
15808         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
15809         describing the enum quoting_style values.
15810         * lib/quotearg.c (quotearg_alloc): New function.
15811         (quotearg_buffer_restyled): Treat lone { and } as special.
15812         Treat = as special.  Work around bug with older shells
15813         that "see" a '\' that is really the 2nd byte of a multibyte char.
15814         Quote empty string with shell_quoting_style.
15815
15816 2004-02-03  Bruno Haible  <bruno@clisp.org>
15817
15818         * m4/pipe.m4: New file, from GNU gettext.
15819
15820 2004-02-03  Bruno Haible  <bruno@clisp.org>
15821
15822         * lib/pipe.h: New file, from GNU gettext.
15823         * lib/pipe.c: New file, from GNU gettext.
15824
15825 2004-01-27  Bruno Haible  <bruno@clisp.org>
15826
15827         * m4/execute.m4: New file, from GNU gettext.
15828
15829 2004-01-27  Bruno Haible  <bruno@clisp.org>
15830
15831         * lib/execute.h: New file, from GNU gettext.
15832         * lib/execute.c: New file, from GNU gettext.
15833         * lib/w32spawn.h: New file, from GNU gettext.
15834
15835 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15836
15837         Merge from diffutils.
15838
15839         * lib/file-type.c (file_type): Add typed memory objects.
15840         * lib/file-type.h (S_TYPEISTMO): New macro.
15841
15842         * lib/c-stack.h (c_stack_action): Remove argv argument.
15843         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
15844         (die): Don't calculate message unless segv_action returns.
15845         (get_stack_location, min_address_from_argv, max_address_from_argv,
15846         volatile stack_base, volatile_stack_size): Remove.
15847         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
15848         that every segmentation violation is a stack overflow.  (Ouch!)
15849         See Debian bug 136249 (still outstanding) for more info about why
15850         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
15851
15852 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15853
15854         Exit-status fix from coreutils.
15855
15856         Use exit_failure consistently in place of EXIT_FAILURE,
15857         so that program exit statuses are consistent on failure.
15858
15859         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
15860         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
15861         * lib/argmatch.h: Comment fix to match the above.
15862         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
15863         Now a macro referring to exit_failure, instead of a separate
15864         variable.  Include "exitfail.h" to get it.
15865         * lib/xstrtol.h: Include "exitfail.h".
15866         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
15867
15868         * lib/long-options.c (parse_long_options): Use prototype
15869         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
15870         for clarity.
15871
15872 2004-01-21  Jim Meyering  <jim@meyering.net>
15873
15874         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
15875         so as not to conflict with a different-sized __mktime_internal
15876         function in GNU libc.
15877         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
15878         Problem building statically-linked `ls' reported by Michael Brunnbauer.
15879
15880 2004-01-20  Karl Berry  <karl@gnu.org>
15881
15882         * config/config.guess: update from config.
15883
15884         * config/srclistvars.sh: GNUWWWLICENSES for karl.
15885
15886 2004-01-20  Bruno Haible  <bruno@clisp.org>
15887
15888         Safer stack allocation.
15889         * lib/setenv.c: Include allocsa.h.
15890         (alloca): Remove fallback definition.
15891         (freea): Remove macro.
15892         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
15893         instead of freea.
15894
15895 2004-01-20  Bruno Haible  <bruno@clisp.org>
15896
15897         * m4/eealloc.m4: New file, from GNU gettext.
15898
15899 2004-01-20  Bruno Haible  <bruno@clisp.org>
15900
15901         * m4/allocsa.m4: New file, from GNU gettext.
15902
15903 2004-01-20  Bruno Haible  <bruno@clisp.org>
15904
15905         * lib/xallocsa.h: New file, from GNU gettext.
15906         * lib/xallocsa.c: New file, from GNU gettext.
15907
15908 2004-01-20  Bruno Haible  <bruno@clisp.org>
15909
15910         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
15911
15912 2004-01-20  Bruno Haible  <bruno@clisp.org>
15913
15914         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
15915         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
15916         specially.
15917
15918 2004-01-20  Bruno Haible  <bruno@clisp.org>
15919
15920         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
15921         patch.
15922
15923 2004-01-20  Bruno Haible  <bruno@clisp.org>
15924
15925         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
15926
15927 2004-01-20  Bruno Haible  <bruno@clisp.org>
15928
15929         * lib/eealloc.h: New file.
15930
15931 2004-01-20  Bruno Haible  <bruno@clisp.org>
15932
15933         * lib/binary-io.h: Avoid warnings on Cygwin.
15934
15935 2004-01-20  Bruno Haible  <bruno@clisp.org>
15936
15937         * lib/allocsa.h: New file, from GNU gettext.
15938         * lib/allocsa.c: New file, from GNU gettext.
15939
15940 2004-01-18  Karl Berry  <karl@gnu.org>
15941
15942         * doc/gpl.texi, doc/lgpl.texi: new files.
15943
15944 2004-01-18  Karl Berry  <karl@gnu.org>
15945
15946         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
15947         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
15948
15949 2004-01-15  Paul Eggert  <eggert@twinsun.com>
15950
15951         Merge from coreutils.
15952
15953         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
15954         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
15955         (gl_DEFAULT_POSIX2_VERSION): Move
15956         the documentation from 'configure' into 'config.hin',
15957         so that 'configure --help' isn't burdened by it and
15958         we don't have to worry about its formatting there.
15959         Reword the documentation so that it's more succinct
15960         and can be run together into a single paragraph.
15961         * m4/same.m4 (gl_SAME): Check for pathconf.
15962
15963 2004-01-15  Paul Eggert  <eggert@twinsun.com>
15964
15965         Merge from coreutils.
15966
15967         * lib/posixver.c: Include posixver.h.
15968
15969         * lib/same.c: Include <stdbool.h>, <limits.h>.
15970         (_POSIX_NAME_MAX): Define if not defined.
15971         (MIN): New macro.
15972         (same_name): If file names are silently truncated, report
15973         that the file names are the same if they are the same after
15974         the silent truncation.
15975
15976         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
15977         conversion function.
15978         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
15979         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
15980         longer needed.
15981
15982 2004-01-15  Jim Meyering  <jim@meyering.net>
15983
15984         Merge from coreutils.
15985
15986         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
15987         if no library is required.
15988         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
15989         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
15990         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
15991         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
15992         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
15993         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
15994         value, $ac_cv_search_crypt, if it's "none required".
15995         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
15996         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
15997         not gl_FUNC_GETLOADAVG.
15998         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
15999         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
16000
16001 2004-01-15  Jim Meyering  <jim@meyering.net>
16002
16003         Merge from coreutils.
16004
16005         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
16006         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
16007         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
16008
16009         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
16010         optional configure-time default.
16011
16012         * lib/version-etc.c (version_etc_copyright): Update copyright date.
16013
16014         * lib/xreadlink.c (xreadlink): Correct outdated comment.
16015
16016 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
16017
16018         Merge from coreutils.
16019
16020         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
16021         value, $ac_cv_search_nanosleep, if it's "none required".
16022
16023 2004-01-14  Paul Eggert  <eggert@twinsun.com>
16024
16025         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
16026         with like-named macro in fnmatch.c.
16027         (EXT): Use an internal constant instead.
16028
16029         Merge fnmatch patches from glibc.
16030         * lib/fnmatch.c (mbsinit): Remove define.
16031         Add libc_hidden_ver (__fnmatch, fnmatch).
16032         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
16033         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
16034
16035 2004-01-14  Karl Berry  <karl@gnu.org>
16036
16037         * config/install-sh: update from automake.
16038
16039 2004-01-13  Karl Berry  <karl@gnu.org>
16040
16041         * config/install-sh: update from automake.
16042
16043 2004-01-09  Karl Berry  <karl@gnu.org>
16044
16045         * config/install-sh: update from automake.
16046
16047 2004-01-05  Karl Berry  <karl@gnu.org>
16048
16049         * config/config.{sub,guess}: update from config.
16050
16051 2003-12-31  Karl Berry  <karl@gnu.org>
16052
16053         * config/depcomp: update from automake.
16054
16055 2003-12-14  Karl Berry  <karl@gnu.org>
16056
16057         * lib/config.charset: update from gettext-runtime.
16058
16059 2003-12-03  Paul Eggert  <eggert@twinsun.com>
16060
16061         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
16062         Bug reported by Alfred M. Szmidt.
16063
16064 2003-12-03  Bruno Haible  <bruno@clisp.org>
16065
16066         * m4/gettext.m4: Upgrade from gettext-0.13.
16067         * m4/po.m4: Upgrade from gettext-0.13.
16068         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
16069         * m4/intmax.m4: New file, from gettext-0.13.
16070         * m4/printf-posix.m4: New file, from gettext-0.13.
16071
16072 2003-11-29  Karl Berry  <karl@gnu.org>
16073
16074         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
16075
16076 2003-11-25  Paul Eggert  <eggert@twinsun.com>
16077             Bruno Haible  <bruno@clisp.org>
16078
16079         * lib/printf-parse.h: Don't include sys/types.h.
16080         (ARG_NONE): New macro.
16081         (char_directive): Change type of *arg_index fields to size_t.
16082         * lib/printf-parse.c: Don't include sys/types.h.
16083         (SSIZE_MAX): Remove macro.
16084         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
16085         Remove unnecessary overflow check.
16086         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
16087         fields.
16088
16089 2003-11-25  Bruno Haible  <bruno@clisp.org>
16090
16091         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
16092
16093 2003-11-25  Bruno Haible  <bruno@clisp.org>
16094
16095         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
16096         gt_TYPE_SSIZE_T.
16097
16098 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16099
16100         * modules/alloca: Remove dependency on xalloc.
16101
16102 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16103
16104         * lib/alloca.c: Remove dependency on xalloc module.
16105         (xalloc_die): Remove.
16106         (memory_full) [!defined emacs]: New macro.
16107         [!defined emacs]: Don't include xalloc.h.
16108         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
16109         address arithmetic overflows.  Change datatypes a bit to avoid
16110         unnecessary casts.
16111
16112 2003-11-22  Jim Meyering  <jim@meyering.net>
16113
16114         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
16115         s/size/size_t/.
16116
16117 2003-11-21  Karl Berry  <karl@gnu.org>
16118
16119         * config/config.{sub,guess}: update from config.
16120
16121 2003-11-18  Karl Berry  <karl@gnu.org>
16122
16123         * config/config.{sub,guess}: update from config.
16124
16125         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
16126
16127 2003-11-17  Paul Eggert  <eggert@twinsun.com>
16128
16129         * README: Mention that S+T cannot overflow if S is the size of
16130         an existing object and T is sufficiently small.
16131
16132 2003-11-17  Jim Meyering  <jim@meyering.net>
16133
16134         On systems without utime and without a utimes function capable of
16135         dealing with a NULL struct utimbuf* argument, this utime replacement
16136         could -- in unusual circumstances -- leak a file descriptor.
16137         * lib/utime.c: Include <unistd.h> and <errno.h>.
16138         (utime_null): Be sure to close `fd' and to preserve errno.
16139         Reported by Geoff Collyer via Arnold Robbins.
16140
16141 2003-11-17  Bruno Haible  <bruno@clisp.org>
16142
16143         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
16144         (Depends-on): Add xsize.
16145
16146 2003-11-17  Bruno Haible  <bruno@clisp.org>
16147
16148         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
16149
16150 2003-11-17  Bruno Haible  <bruno@clisp.org>
16151
16152         * lib/vasnprintf.c (alloca): Remove fallback definition.
16153         (freea): Remove definition.
16154         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
16155         Reported by Paul Eggert.
16156
16157 2003-11-16  Paul Eggert  <eggert@twinsun.com>
16158             Bruno Haible  <bruno@clisp.org>
16159
16160         Protect against address arithmetic overflow.
16161         * lib/printf-args.h: Include stddef.h.
16162         (arguments): Change type of field 'count' to size_t.
16163         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
16164         'unsigned int' where appropriate.
16165         * lib/printf-parse.h: Include sys/types.h.
16166         (char_directive): Change type of *arg_index fields to ssize_t.
16167         (char_directives): Change type of fields 'count', max_*_length to
16168         size_t.
16169         * lib/printf-parse.c: Include sys/types.h and xsize.h.
16170         (SSIZE_MAX): Define fallback value.
16171         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
16172         instead of 'int' where appropriate. Check a_allocated, d_allocated
16173         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
16174         * lib/vasnprintf.c: Include xsize.h.
16175         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
16176         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
16177         overflow. Avoid wraparound when converting a width or precision from
16178         decimal to binary.
16179
16180 2003-11-16  Bruno Haible  <bruno@clisp.org>
16181
16182         Update from GNU gettext.
16183         * lib/printf-parse.c: Generalize to it can be compiled for wide
16184         strings.
16185         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
16186         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
16187         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
16188         SNPRINTF): New macros.
16189         Don't include <alloca.h> if the file is used inside libintl.
16190         (local_wcslen): New function, for Solaris 2.5.1.
16191         (VASNPRINTF): Use it instead of wcslen.
16192
16193 2003-11-16  Bruno Haible  <bruno@clisp.org>
16194
16195         * lib/xsize.h (xmax): New function.
16196         (xsum, xsum3, xsum4): Declare as "pure" functions.
16197
16198 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16199
16200         * modules/xalloc (Files): Undo latest change, since xalloc.h
16201         no longer needs SIZE_MAX or PTRDIFF_MAX.
16202
16203 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16204
16205         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
16206         gl_PTRDIFF_MAX.
16207
16208 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16209
16210         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
16211         "return", to pacify some unknown compiler.  Problem reported
16212         by Joerg Schilling.
16213
16214 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16215
16216         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
16217         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
16218         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
16219         heuristic is just as accurate as far as we know, and it removes a
16220         dependency on size_max.m4 and ptrdiff_max.m4.
16221
16222 2003-11-11  Bruno Haible  <bruno@clisp.org>
16223
16224         * modules/xsize (Files): Add m4/size_max.m4.
16225         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
16226
16227 2003-11-11  Bruno Haible  <bruno@clisp.org>
16228
16229         * m4/size_max.m4: New file.
16230         * m4/ptrdiff_max.m4: New file.
16231         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
16232         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
16233         (gl_XALLOC): Invoke it.
16234
16235 2003-11-11  Bruno Haible  <bruno@clisp.org>
16236
16237         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
16238         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
16239         defined.
16240
16241 2003-11-10  Paul Eggert  <eggert@twinsun.com>
16242
16243         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
16244         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
16245         rejected some allocations of exactly SIZE_MAX - 2 bytes.
16246         From Bruno Haible.
16247         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
16248         not (size_t) -1, since it's defined here.
16249
16250 2003-11-09  Karl Berry  <karl@gnu.org>
16251
16252         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
16253
16254 2003-11-06  Paul Eggert  <eggert@twinsun.com>
16255
16256         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
16257         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
16258         Reject sizes of exactly SIZE_MAX bytes.
16259         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
16260         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
16261
16262 2003-11-05  Bruno Haible  <bruno@clisp.org>
16263
16264         * lib/xsize.h: Include limits.h, to avoid a possible collision with
16265         SIZE_MAX defined in <limits.h> on Solaris.
16266
16267 2003-11-04  Jim Meyering  <jim@meyering.net>
16268
16269         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
16270         variable names, rather than @VAR@.
16271         * modules/poll: Likewise.
16272
16273 2003-11-04  Bruno Haible  <bruno@clisp.org>
16274
16275         * modules/xsize: New file.
16276         * modules/linebreak: Depend on xsize.
16277         * MODULES.html.sh (func_all_modules): Add xsize.
16278
16279 2003-11-04  Bruno Haible  <bruno@clisp.org>
16280
16281         * m4/xsize.m4: New file.
16282
16283 2003-11-04  Bruno Haible  <bruno@clisp.org>
16284
16285         * lib/xsize.h: New file.
16286         * lib/linebreak.c: Include xsize.h.
16287         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
16288         argument for overflow.
16289         Suggested by Paul Eggert.
16290
16291 2003-11-03  Karl Berry  <karl@gnu.org>
16292
16293         * config/config.{guess,sub}: update from config.
16294
16295 2003-11-03  Jim Meyering  <jim@meyering.net>
16296
16297         * modules/userspec (lib_SOURCES): Add userspec.h.
16298         (Include): Add "userspec.h".
16299         Improve description.
16300
16301 2003-11-03  Jim Meyering  <jim@meyering.net>
16302
16303         * lib/userspec.c: Include "userspec.h".
16304         * lib/userspec.h: New file.
16305
16306 2003-11-03  Bruno Haible  <bruno@clisp.org>
16307
16308         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
16309
16310 2003-11-03  Bruno Haible  <bruno@clisp.org>
16311
16312         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
16313         available, to avoid (extremely rare) race condition.
16314         Suggested by Paul Eggert.
16315
16316 2003-11-02  Karl Berry  <karl@gnu.org>
16317
16318         * config/srclist.txt (vasprintf.c): sync broken, sigh.
16319
16320 2003-10-31  Paul Eggert  <eggert@twinsun.com>
16321
16322         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
16323         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
16324         (read_filesystem_list): Set and use me_type_malloced.
16325         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
16326         whatever the type happens to be), for brevity and consistency.
16327         Check for size calculation overflow on Alphas running OSF/1.
16328
16329 2003-10-31  Jim Meyering  <jim@meyering.net>
16330
16331         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
16332
16333         * lib/linebuffer.c: Include <string.h> for declaration of memset.
16334
16335 2003-10-30  Paul Eggert  <eggert@twinsun.com>
16336             Bruno Haible  <bruno@clisp.org>
16337
16338         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
16339         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
16340
16341 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16342
16343         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
16344         netbsd*-gnu*.  Suggested by Robert Millan.
16345
16346 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16347
16348         * modules/group-member: Depend on stdbool.
16349
16350 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16351
16352         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
16353
16354 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16355
16356         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
16357         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
16358         after the 'gnu' in these cases.  This fixes some bugs in the
16359         previous change, and is based on suggestions by Robert Millan.
16360
16361 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16362
16363         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
16364         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
16365         no longer needed.
16366         * lib/quotearg.c (quotearg_n_options): Use it.
16367         * lib/group-member.c: Include <stdbool.h>.
16368         (free_group_info): Arg is now const *; don't free arg.
16369         (get_group_info): Now returns bool and accepts struct group_info *,
16370         rather than returning a malloc'ed struct group_info *.
16371         All uses changed.  Check for overflow in internal size calculation.
16372
16373         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
16374         rather than xmalloc/xrealloc.
16375         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
16376         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
16377         conformance bug: the old code used a pointer after freeing the
16378         storage that it addressed.
16379         * lib/hash.c (hash_initialize): Simplify the code by using
16380         xalloc_oversized rather than doing it by hand.
16381         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
16382         the buffer preserved.  Use free and xmalloc instead.
16383         * lib/quotearg.c (quotearg_n_options): Likewise.
16384         Use a simpler test for size overflow.  Don't use xalloc_oversized
16385         because unsigned int might be wider than size_t (!); this suggests
16386         that we should switch from unsigned int to size_t for slot numbers.
16387
16388 2003-10-28  Paul Eggert  <eggert@twinsun.com>
16389
16390         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
16391         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
16392         NetBSD kernels.  Requested by Richard Stallman.
16393
16394 2003-10-27  Paul Eggert  <eggert@twinsun.com>
16395
16396         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
16397         to allocate the returned structure.  Do not allocate a subarray,
16398         as x2nrealloc will do that.
16399         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
16400         instead of xnrealloc.
16401         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
16402
16403 2003-10-27  Bruno Haible  <bruno@clisp.org>
16404
16405         * lib/stdbool_.h: Better support for BeOS.
16406
16407 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16408
16409         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
16410         now uses inline.
16411
16412 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16413
16414         * lib/xalloc.h (xalloc_oversized): New static inline function, for
16415         callers that want to do their own size-overflow checking.  Include
16416         <stdbool.h>, since xalloc_oversized returns bool.
16417         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
16418         to use xalloc_oversized.
16419
16420         Add two functions x2realloc, x2nrealloc, for programs that grow
16421         arrays dynamically by doubling their sizes.
16422         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
16423         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
16424         New functions.
16425
16426         Port to C99 semantics for 'inline' of external functions.
16427         Bug reported by Bruno Haible.
16428         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
16429         with the old contents of xnmalloc.
16430         (xnmalloc, xmalloc): Use it.
16431         (xnrealloc_inline): New static inline function,
16432         with the old contents of xnrealloc.
16433         (xnrealloc, xrealloc): Use it.
16434
16435         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
16436         that.
16437
16438 2003-10-26  Karl Berry  <karl@gnu.org>
16439
16440         * config/srclist.txt (COPYING.DOC): no longer available from
16441         /gd/gnuorg; don't know where the ultimate source is.
16442
16443 2003-10-25  Paul Eggert  <eggert@twinsun.com>
16444
16445         Fix several address-calculation bugs in the hash modules,
16446         plus some minor code cleanup.
16447
16448         * lib/hash.h: Include <stdbool.h>, for bool.
16449         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
16450         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
16451         hash_get_n_entries, hash_get_max_bucket_length,
16452         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
16453         hash_rehash): Use size_t rather than unsigned.
16454         * lib/hash.c (struct hash_table, hash_get_n_buckets,
16455         hash_get_n_buckets_used, hash_get_n_entries,
16456         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
16457         hash_get_entries, hash_do_for_each, hash_string, is_prime,
16458         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
16459         Likewise.
16460         (SIZE_MAX): Define if not defined.
16461         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
16462         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
16463         hash_print):
16464         Use const * when possible.
16465         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
16466         (check_tuning): Fix bug: if tuning parameters were very close to
16467         0 or 1, rounding errors could have caused subscript violations.
16468         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
16469         (hash_initialize): Add 'fail:' label
16470         to free table and return NULL, and use it to simplify code.
16471         Use calloc rather than clearing the storage ourself.
16472         (hash_initialize, hash_rehash): Check for arithmetic overflow in
16473         buffer size calculations.
16474         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
16475         Include <stddef.h>, for size_t.
16476         * lib/hash-pjw.c (hash_pjw): Likewise.
16477         Switch to method described by Bruno Haible.
16478         Include <limits.h>, for CHAR_BIT.
16479         (SIZE_BITS): New macro.
16480
16481 2003-10-23  Paul Eggert  <eggert@twinsun.com>
16482
16483         * m4/getline.m4 (AM_FUNC_GETLINE):
16484         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
16485         hosts.  Problem reported by Derek Robert Price in
16486         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
16487         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
16488         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
16489
16490 2003-10-21  Paul Eggert  <eggert@twinsun.com>
16491
16492         * lib/getndelim2.c (getndelim2): When size calculation overflows,
16493         ceiling the allocation at NMAX bytes rather than silently
16494         discarding input bytes before NMAX is reached.  This makes
16495         a difference only if NMAX exceeds SIZE_MAX / 2.
16496
16497         * lib/obstack.c: Merge from glibc.
16498         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
16499         Add libc_hidden_def (_obstack_newchunk).
16500         (_obstack_free) [! defined _LIBC]: Remove.
16501         [defined _LIBC]: Make a strong alias from obstack_free, rather than
16502         a clone of the function body.
16503         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
16504         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
16505
16506         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
16507         glibc.
16508         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
16509         arg to memcpy.
16510
16511         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
16512         (obstack_ptr_grow_fast, obstack_int_grow_fast):
16513         Don't use lvalue casts, as GCC plans to remove support for them
16514         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
16515         was also present in the non-GCC version, indicating that this
16516         code had always been buggy and had never been widely used.
16517         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
16518         Use the fast variant of each macro, rather than copying the
16519         definiens of the fast variant; that way, we'll be more likely to
16520         catch future bugs in the fast variants.
16521
16522 2003-10-20  Bruno Haible  <bruno@clisp.org>
16523
16524         * modules/wait-process: New file.
16525         * MODULES.html.sh (func_all_modules): Add wait-process.
16526
16527 2003-10-20  Bruno Haible  <bruno@clisp.org>
16528
16529         * m4/wait-process.m4: New file.
16530
16531 2003-10-20  Bruno Haible  <bruno@clisp.org>
16532
16533         * lib/wait-process.h: New file, from GNU gettext.
16534         * lib/wait-process.c: New file, from GNU gettext.
16535
16536 2003-10-19  Jim Meyering  <jim@meyering.net>
16537
16538         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
16539         HPUX 10.20.
16540
16541 2003-10-18  Karl Berry  <karl@gnu.org>
16542
16543         * config/config.guess: update from config.
16544
16545 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16546
16547         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
16548         (getgroups): First arg is int, not size_t.
16549         Don't let 'free' mangle errno.
16550
16551 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16552
16553         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
16554
16555 2003-10-16  Karl Berry  <karl@gnu.org>
16556
16557         * config/config.{guess,sub}: update from config.
16558
16559 2003-10-16  Jim Meyering  <jim@meyering.net>
16560
16561         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
16562         memcpy.
16563
16564 2003-10-15  Paul Eggert  <eggert@twinsun.com>
16565
16566         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
16567         (SIZE_MAX): Remove.
16568         (new_exclude, add_exclude_file): Initial size no longer needs to
16569         be a power of 2.
16570         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
16571         our own address arithmetic overflow checking.
16572
16573         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
16574         (fnmatch): Do not alloca more than 2000 wide characters;
16575         instead, use malloc for large buffers.
16576         Check for address arithmetic overflow, and return -1
16577         with errno set to ENOMEM in that case.
16578         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
16579         (NEW_PATTERN): Do not alloca more than 8000 bytes;
16580         instead, return -1.  Check for address arithmetic overflow.
16581
16582 2003-10-14  Paul Eggert  <eggert@twinsun.com>
16583
16584         Handle invalid suffixes and overflow independently, so that
16585         callers can treat them independently as needed.  Fix some bugs in
16586         suffix handling, e.g., "100k@" was not diagnosed as an invalid
16587         suffix for a human-readable blocksize.  The major caller-visible
16588         change is the addition of a new
16589         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
16590         that both overflow and suffix chars were found.
16591
16592         * lib/human.c (humblock): Don't check separately for invalid suffix
16593         char; that is xstrtoumax's job (now that its bug is fixed).
16594         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
16595         INTMAX_MAX]: New macros.
16596         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
16597         TYPE_MAXIMUM): New macros.
16598         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
16599         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
16600         if overflow occurs, as it's what __strtol does and it's more useful
16601         in practice.
16602         (__xstrtol): If __strtol reports some error other than ERANGE,
16603         reflect it to the caller as LONGINT_INVALID.  If it reports
16604         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
16605         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
16606         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
16607         value.
16608         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
16609         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
16610         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
16611         [defined UINTMAX_MAX]: New macros.
16612
16613 2003-10-14  Bruno Haible  <bruno@clisp.org>
16614
16615         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
16616
16617 2003-10-14  Bruno Haible  <bruno@clisp.org>
16618
16619         * m4/sig_atomic_t: New file, from GNU gettext.
16620         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
16621
16622 2003-10-14  Bruno Haible  <bruno@clisp.org>
16623
16624         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
16625         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
16626         Also use volatile where needed.
16627
16628 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16629
16630         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
16631         Change maintainer from Bruno Haible to 'all'.
16632
16633 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16634
16635         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
16636
16637 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16638
16639         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
16640         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
16641         and define in terms of the other primitives.
16642         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
16643         (SIZE_MAX): Define if not already defined.
16644         (array_size_overflow): New function.
16645         (xalloc_die): Abort instead of exiting if 'error' returns.
16646         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
16647         (xmalloc, xrealloc): Use them.
16648         (xcalloc): Check for address arithmetic overflow.
16649         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
16650         a bit faster than strcpy.
16651
16652 2003-10-10  Simon Josefsson  <jas@extundo.com>
16653
16654         * modules/argp (Depends-on): Add restrict and strcase.
16655
16656 2003-10-10  Simon Josefsson  <jas@extundo.com>
16657
16658         * m4/argp.m4: Add AC_C_INLINE.
16659
16660 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16661
16662         Merge getpass from libc, plus a few fixes.
16663
16664         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
16665         Include <stdbool.h>.
16666         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
16667         __fsetlocking to empty.
16668         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
16669         do include <bits/libc-lock.h>.
16670         Do not include <fcntl.h>; not needed.
16671         [_LIBC]: Include <wchar.h>.
16672         (NOTCANCEL_MODE): New macro.
16673         (flockfile, funlockfile) [_LIBC]: New macros.
16674         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
16675         [!_LIBC]: New macros.
16676         (call_fclose): New function.
16677         (getpass): Use it.  Save tty stream separately; this simplifies the
16678         code and makes it more reliable if stdin happens to equal stdout.
16679         Invoke __fsetlocking on tty.
16680         Handle thread cancellation if needed.
16681         Namespace cleanup (use __tcgetattr, __getline).
16682         Use bool for Booleans.
16683         [USE_IN_LIBIO]: Handle wide streams.
16684         [!_LIBC]: Unconditionally do the fseek, since we don't know what
16685         stream might go where.
16686
16687         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
16688         doesn't have to include <stdio.h> before us.
16689         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
16690         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
16691         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
16692         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
16693         if not declared, so that we can use getpass.c code from libc without
16694         rewriting it.
16695         (flockfile, ftrylockfile, funlockfile): New macros.
16696
16697 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16698
16699         * modules/getpass: Depend on stdbool.
16700
16701 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16702
16703         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
16704
16705 2003-10-07  Karl Berry  <karl@gnu.org>
16706
16707         * config/config.{guess,sub}: update from config.
16708
16709 2003-10-06  Jim Meyering  <jim@meyering.net>
16710             Bruno Haible  <bruno@clisp.org>
16711
16712         This lets translators provide better translations for the
16713         "Written by ..." part of --version output.
16714         * lib/version-etc.h: Include stdarg.h.
16715         (version_etc_copyright): Declare as readonly.
16716         (version_etc): Make this function variadic with a NULL-terminated list
16717         of author name strings.
16718         (version_etc_va): New declaration.
16719         * lib/version-etc.c: Include stdarg.h, stdlib.h.
16720         (version_etc_copyright): Declare as readonly.
16721         (version_etc_va): New function. Provide a different translatable string
16722         for each possible number of authors < 10. Abbreviate when there are 10
16723         authors or more.
16724         (version_etc): Make this function variadic. Call version_etc_va.
16725         Suggestion from Gary V. Vaughan.
16726
16727         * lib/long-options.h (parse_long_options): Change prototype: the
16728         authors string is moved to the end and becomes variadic.
16729         * lib/long-options.c: Include stdarg.h.
16730         (parse_long_options): Make this function variadic, too.
16731         Call version_etc_va, not version_etc.
16732
16733 2003-10-06  Bruno Haible  <bruno@clisp.org>
16734
16735         * modules/version-etc-2: Remove file.
16736         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
16737
16738 2003-10-06  Bruno Haible  <bruno@clisp.org>
16739
16740         * modules/fatal-signal: New file.
16741         * MODULES.html.sh (func_all_modules): Add fatal-signal.
16742
16743 2003-10-06  Bruno Haible  <bruno@clisp.org>
16744
16745         * m4/fatal-signal.m4: New file.
16746         * m4/signalblocking.m4: New file, from GNU gettext.
16747
16748 2003-10-06  Bruno Haible  <bruno@clisp.org>
16749
16750         * lib/version-etc-2.h: Remove file.
16751         * lib/version-etc-2.c: Remove file.
16752
16753 2003-10-06  Bruno Haible  <bruno@clisp.org>
16754
16755         * lib/fatal-signal.h: New file, from GNU gettext.
16756         * lib/fatal-signal.c: New file, from GNU gettext.
16757
16758 2003-10-05  Paul Eggert  <eggert@twinsun.com>
16759
16760         * README: Rework advice for preventing empty .o files.
16761         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
16762         not <sys/types.h>.
16763
16764 2003-10-04  Karl Berry  <karl@gnu.org>
16765
16766         * lib/argp*: update from libc.
16767
16768 2003-10-04  Karl Berry  <karl@gnu.org>
16769
16770         * config/config.{guess,sub}: update from config.
16771
16772 2003-10-02  Bruno Haible  <bruno@clisp.org>
16773
16774         * modules/lchown (Include): Add lchown.h.
16775         * modules/time_r (Include): Use "..." syntax.
16776         * modules/xgetdomainname (Include): Add xgetdomainname.h.
16777
16778 2003-10-01  Simon Josefsson  <jas@extundo.com>
16779
16780         * MODULES.html.sh (func_all_modules): Move gethostname from section
16781         'based on' to section 'lacking' POSIX:2001.
16782
16783 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
16784
16785         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
16786         to output mode on the same stream.
16787
16788 2003-09-29  Paul Eggert  <eggert@twinsun.com>
16789
16790         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
16791         Fix arg typo in previous patch.
16792
16793 2003-09-28  Jim Meyering  <jim@meyering.net>
16794
16795         * lib/error.c: Correct cpp indentation.
16796
16797 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16798
16799         * modules/free: New file.
16800
16801 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16802
16803         * m4/free.m4: New file.
16804
16805 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16806
16807         * lib/minmax.h (MIN, MAX)
16808         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
16809         Omit the special code that used __typeof__, since we worry that
16810         it could be more trouble than it's worth.  See:
16811         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
16812         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
16813
16814         * lib/free.c: New file.
16815
16816 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
16817
16818         Trivial fixes to Makefile.am parts of module listings.
16819         * modules/strstr: Append strstr.h to lib_SOURCES.
16820         * modules/strcase: Likewise, for strcase.h.
16821
16822 2003-09-27  Karl Berry  <karl@gnu.org>
16823
16824         * config/mkinstalldirs: update from automake.
16825
16826 2003-09-26  Paul Eggert  <eggert@twinsun.com>
16827
16828         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
16829         (error_tail): Do not loop, reallocating temporary buffer, since
16830         the output cannot contain more wide characters than the input
16831         contains bytes, the size must be big enough already.  This avoids
16832         one potential size overflow calculation.  Check for size overflow
16833         when calculating temporary buffer size.  Free temporary buffer
16834         when done, if it was allocated with malloc; this plugs a memory
16835         leak.  Remove casts from void * to pointers, that are no longer
16836         needed now that we're assuming C89 or better.
16837
16838         Merge error changes from glibc.
16839
16840         * lib/error.c, error.h: Update copyright notice header to match glibc.
16841         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
16842         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
16843         Disable cancellation while printing error.
16844         * lib/error.h: Prepend __ to parameter names.
16845
16846 2003-09-26  Jim Meyering  <jim@meyering.net>
16847
16848         * lib/error.c (error_tail): Move some declarations
16849         into inner scope where the local variables are used.
16850
16851 2003-09-26  Bruno Haible  <bruno@clisp.org>
16852
16853         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
16854         stpncpy().
16855         Don't define stpncpy through config.h; it's now done through stpncpy.h.
16856
16857 2003-09-26  Bruno Haible  <bruno@clisp.org>
16858
16859         * lib/stpncpy.h (gnu_stpncpy): New declaration.
16860         (stpncpy): Define as alias for gnu_stpncpy.
16861         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
16862
16863 2003-09-25  Simon Josefsson  <jas@extundo.com>
16864
16865         * lib/xgetdomainname.h: New file.
16866         * lib/xgetdomainname.c: New file.
16867
16868 2003-09-25  Simon Josefsson  <jas@extundo.com>
16869             Bruno Haible  <bruno@clisp.org>
16870
16871         * modules/getdomainname: New file.
16872         * modules/xgetdomainname: New file.
16873         * MODULES.html.sh (func_all_modules): Add getdomainname,
16874         xgetdomainname.
16875
16876 2003-09-25  Simon Josefsson  <jas@extundo.com>
16877             Bruno Haible  <bruno@clisp.org>
16878
16879         * m4/getdomainname.m4: New file.
16880
16881 2003-09-25  Simon Josefsson  <jas@extundo.com>
16882             Bruno Haible  <bruno@clisp.org>
16883
16884         * lib/getdomainname.h: New file.
16885         * lib/getdomainname.c: New file.
16886
16887 2003-09-25  Karl Berry  <karl@gnu.org>
16888
16889         * lib/argp-fmtstream.c, argp-help.c: update from libc.
16890
16891 2003-09-25  Karl Berry  <karl@gnu.org>
16892
16893         * config/install-sh: update from automake.
16894
16895 2003-09-25  Bruno Haible  <bruno@clisp.org>
16896
16897         * modules/version-etc-2: New file, from modules/version-etc with
16898         modifications.
16899         * MODULES.html.sh (func_all_modules): Add version-etc-2.
16900
16901 2003-09-25  Bruno Haible  <bruno@clisp.org>
16902
16903         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
16904         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
16905
16906 2003-09-24  Simon Josefsson  <jas@extundo.com>
16907
16908         * modules/xgethostname: Add xgethostname.h.
16909
16910 2003-09-24  Paul Eggert  <eggert@twinsun.com>
16911
16912         * lib/linebuffer.c (freebuffer): Don't free the argument, just
16913         the buffer associated with the argument.  Bug reported by
16914         Simon Josefsson.
16915
16916 2003-09-24  Paul Eggert  <eggert@twinsun.com>
16917
16918         * README: Document assumptions that 'int' is at least 32 bits
16919         wide, that integer arithmetic is 2's complement without overflow,
16920         that there are no holes in integer values, that adding sizes of
16921         two nonoverlapping objects can't overflow, and that all-bits-zero
16922         yields scalar zero.  Fix spelling and capitalization typos.
16923
16924 2003-09-19  Karl Berry  <karl@gnu.org>
16925
16926         * lib/argp.h: update from libc.
16927
16928 2003-09-17  Paul Eggert  <eggert@twinsun.com>
16929
16930         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
16931         to avoid spurious warnings like "AC_RUN_IFELSE was called before
16932         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
16933
16934 2003-09-17  Paul Eggert  <eggert@twinsun.com>
16935
16936         * gnulib-tool: Use "test -h", not "test -L", for portability
16937         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
16938         (tags_regexp): Remove, since \| doesn't conform to POSIX.
16939         (sed_extract_prog): Issue s commands one-by-one, rather than
16940         using \| in one s command.
16941
16942 2003-09-16  Paul Eggert  <eggert@twinsun.com>
16943
16944         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
16945         input error, instead of returning NULL the next time we are called
16946         (and therefore losing track of errno).
16947
16948 2003-09-16  Bruno Haible  <bruno@clisp.org>
16949
16950         * gnulib-tool (func_create_testdir): Warn about duplicated
16951         dependencies.
16952
16953 2003-09-15  Paul Eggert  <eggert@twinsun.com>
16954
16955         * modules/argmatch, modules/fatal, modules/obstack,
16956         modules/xalloc, modules/xgethostname: Sort dependencies by
16957         importance, not alphabetically.
16958
16959 2003-09-15  Paul Eggert  <eggert@twinsun.com>
16960
16961         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
16962         fails, so that the caller gets the proper errno.
16963
16964         * lib/readutmp.c (read_utmp): Likewise.
16965         Check for fstat error.  Close stream and free storage
16966         when failing.
16967
16968 2003-09-14  Karl Berry  <karl@gnu.org>
16969
16970         * config/srclist.txt (strdup.c): disable for c89 changes.
16971
16972 2003-09-14  Jim Meyering  <jim@meyering.net>
16973
16974         * lib/getloadavg.c: Correct cpp indentation.
16975         * lib/strdup.c: Likewise.
16976         * lib/vasnprintf.c: Likewise.
16977
16978 2003-09-14  Bruno Haible  <bruno@clisp.org>
16979
16980         * modules/fwriteerror: New file.
16981         * MODULES.html.sh (func_all_modules): Add fwriteerror.
16982
16983 2003-09-14  Bruno Haible  <bruno@clisp.org>
16984
16985         * lib/fwriteerror.h: New file.
16986         * lib/fwriteerror.c: New file.
16987
16988 2003-09-12  Paul Eggert  <eggert@twinsun.com>
16989
16990         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
16991         modules/xgethostname, modules/xalloc: Depend on exit.
16992
16993 2003-09-12  Paul Eggert  <eggert@twinsun.com>
16994
16995         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
16996
16997         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
16998         and AC_MINIX, too, so that their extensions are available.
16999
17000         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
17001         This macro has been superseded by gl_BACKUPFILE.
17002
17003         More patches to assume C89 or better.
17004
17005         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
17006
17007         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
17008         unconditionally.
17009         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
17010         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
17011         Include <string.h>, <stdlib.h> unconditionally.
17012         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
17013         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
17014         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
17015         headers or for string.h.
17016         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
17017         or strtoul.
17018
17019         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
17020         headers.
17021         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
17022         * m4/userspec.m4 (gl_USERSPEC): Likewise.
17023         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
17024         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
17025         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
17026         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
17027         memcpy, memset.
17028         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
17029         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
17030         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
17031         strtol.
17032         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
17033         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
17034         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
17035         strtoul.
17036
17037 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17038
17039         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
17040         * lib/obstack.c [!defined _LIBC]: Likewise.
17041         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
17042         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
17043         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
17044
17045         More changes to assume C89 or better.
17046
17047         * lib/error.c (error_tail): Assume vprintf.
17048
17049         * lib/argmatch.c (getenv): Remove decl.
17050         * lib/progreloc.c (get_full_program_name): Define via prototype.
17051         * lib/setenv.c (clearenv): Likewise.
17052         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
17053         needed.
17054         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
17055         (malloc, memcpy): Remove decls.
17056         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
17057         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
17058         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17059         (memcpy): Remove macro.
17060         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
17061         (__P): Remove.  All uses removed.
17062         (PTR): Remove.  All uses changed to void *.
17063         (CHAR_BIT, NULL): Remove.
17064         (spaces, zeros, memset_space, memset_zero)
17065         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
17066         Remove.
17067         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
17068         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
17069         Define with prototype.
17070         Remove now-unnecessary prototype decl.
17071         (extra_args_spec): Assume ANSI C.  All uses changed.
17072         (extra_args_spec_iso): Remove.
17073         (my_strftime, emacs_strftimeu): Define via prototype.
17074         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
17075         unconditionally.
17076         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
17077         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
17078         (strtoul, strtol): Remove decls.
17079         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
17080         LONG_MAX): Remove.
17081         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17082         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
17083         (LOCALE_PARAM_PROTO): New macro.
17084         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
17085         (INTERNAL (strtol), strtol): Define with a prototype.
17086         (PARAMS): Remove.  All uses removed.
17087         * lib/tempname.c: Include <string.h> unconditionally.
17088         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
17089         * lib/xgethostname.c (main): Define with a prototype.
17090         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
17091         Include <stdlib.h> unconditionally.
17092         (calloc, malloc, realloc, free): Remove decls.
17093         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
17094         Include <stdlib.h> unconditionally.  Sort include file names.
17095         (strtod): Remove.
17096         (xstrtod): Define with a prototype.
17097         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
17098         (strtol, strtoul): Remove decls.
17099
17100 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17101
17102         More patches to assume C89 or better.
17103         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
17104         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
17105         string.h, memchr, STDC_HEADERS.
17106
17107 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17108
17109         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
17110         Include <stdlib.h>, <string.h> unconditionally.
17111         Remove now-unnecessary cast to char *.
17112         * lib/strnlen.c: Include <string.h> unconditionally.
17113         * lib/yesno.c (yesno): Define with a prototype.
17114
17115 2003-09-11  Bruno Haible  <bruno@clisp.org>
17116
17117         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
17118
17119 2003-09-10  Jim Meyering  <jim@meyering.net>
17120
17121         * lib/error.c: Correct indentation of cpp directives.
17122
17123 2003-09-10  Bruno Haible  <bruno@clisp.org>
17124
17125         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
17126         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
17127         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
17128         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
17129         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
17130         <stdlib.h> and <string.h> checks.
17131         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
17132         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
17133
17134 2003-09-10  Bruno Haible  <bruno@clisp.org>
17135
17136         * lib/strcspn.c: Include <string.h> unconditionally.
17137         * lib/strpbrk.c: Include <string.h> unconditionally.
17138         * lib/strstr.c: Include <string.h> unconditionally.
17139         * lib/unicodeio.c: Include <string.h> unconditionally.
17140         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
17141         * lib/unsetenv.c: Likewise.
17142         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
17143         * lib/yesno.c: Include <stdlib.h> unconditionally.
17144         (rpmatch): Add prototype.
17145
17146 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17147
17148         More patches to assume C89 or better.
17149         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
17150         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
17151         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
17152         or for string.h.
17153         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
17154         stdlib.h.
17155         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
17156         C headers.
17157         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
17158         string.h.
17159         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
17160         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
17161         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
17162         or for string.h.
17163         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
17164         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
17165         C headers.
17166         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
17167         memcpy.
17168         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
17169         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
17170         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
17171         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
17172         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
17173         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
17174         string.h, free.
17175         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
17176         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
17177         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
17178         C headers, or for string.h.
17179         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
17180         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
17181         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
17182         headers, memory.h, stdlib.h, string.h, strings.h.
17183         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
17184         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
17185         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
17186         strchr.
17187         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
17188         headers, memory.h, string.h.
17189         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
17190         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
17191         free.
17192         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
17193         headers.
17194         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
17195         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
17196         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
17197         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
17198         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
17199
17200 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17201
17202         More K&R removal.
17203
17204         * lib/acosl.c (main): Use a prototype.
17205         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
17206         tanl.c: Likewise.
17207
17208         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
17209
17210         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
17211         (getopt, etopt_long, getopt_long_only, _getopt_internal)
17212         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
17213         with a prototype.
17214         * lib/getopt.c (const): Remove macro.
17215         Include <string.h> unconditionally.
17216         (my_index): Remove; all uses changed to strchr.
17217         (strlen): Remove decl.
17218         (exchange): Remove forward decl; no longer needed.
17219         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
17220         Define with prototype.
17221         * lib/getopt1.c (const): Remove macro.
17222         (getopt_long, getopt_long_only, main): Define with prototype.
17223
17224         * lib/getugroups.c: Include <string.h> unconditionally.
17225
17226         * lib/getusershell.c: Include <stdlib.h> unconditionally.
17227         (getusershell, setusershell, endusershell, readname, main):
17228         Define with prototypes.
17229
17230         * lib/group-member.c: Include group-member.h first.
17231         Include <stdlib.h> unconditionally.
17232
17233         * lib/hard-locale.c: Include hard-locale.h first.
17234         Include <stdlib.h>, <string.h> unconditionally.
17235
17236         * lib/hash.c (free, malloc): Remove decls.
17237         Include <stdlib.h> unconditionally.
17238
17239         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
17240         (getenv): Do not declare.
17241
17242         * lib/idcache.c: Include <string.h> unconditionally.
17243
17244         * lib/long-options.c: Include long-options.h first, to test interface.
17245         Include <stdlib.h> unconditionally.
17246
17247         * lib/makepath.c: Include makepath.h first, to test interface.
17248         Include <stdlib.h> and <string.h> unconditionally.
17249
17250         * lib/linebuffer.c: Include <stdlib.h>.
17251         (free): Remove decl.
17252
17253         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
17254         stddef.h. rpl_malloc returns void *, not char *.
17255         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
17256         prototype.
17257
17258         * lib/md5.h: Include <limits.h> unconditionally.
17259         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
17260         (__P): Remove; all uses removed.
17261         * lib/md5.c: Include "md5.h" first.
17262         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
17263         md5_buffer, md5_process_bytes, md5_process_block):
17264         Define with prototypes.
17265         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
17266         * lib/sha.c: Include "sha.h" first.
17267         Include <stdlib.h>, <string.h> unconditionally.
17268
17269         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
17270         * lib/memcmp.c (__ptr_t): Likewise.
17271         * lib/memrchr.c (__ptr_t): Likewise.
17272         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
17273         Include <string.h> unconditionally.
17274         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
17275         * lib/memchr.c: Include <stdlib.h> unconditionally.
17276         * lib/memchr.c (LONG_MAX): Remove.
17277         * lib/memrchr.c (LONG_MAX): Likewise.
17278         * lib/memchr.c (__memchr): Define via a prototype.
17279         * lib/memrchr.c (__memrchr): Likewise.
17280         * lib/memcmp.c (__P): Remove, and remove all uses.
17281         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
17282         Remove forward decls; no longer needed.
17283         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
17284         Use types required by C89 in prototype.
17285
17286         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
17287         * lib/savedir.c: Likewise.
17288         * lib/mkdir.c (free): Remove decl.
17289         * lib/rmdir.c (rmdir): Define with a prototype.
17290         * lib/savedir.c: Include savedir.h first, to test interface.
17291
17292         * lib/mktime.c (STDC_HEADERS): Remove.
17293         Include <stdlib.h>, <string.h> unconditionally.
17294
17295         * lib/modechange.c: Include <stdlib.h> unconditionally.
17296         (malloc): Remove decl.
17297
17298         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
17299         (free): Remove decl.
17300
17301         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
17302         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
17303         (This type really should be intptr_t, but that's a C99ism.)
17304         (_obstack_memcpy): Remove: all uses changed to memcpy.
17305         Include <string.h> unconditionally.
17306         (struct obstack): Assume __STDC__ for types of members
17307         chunkfun, freefun, extra_arg.
17308         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
17309         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
17310         obstack_begin, obstack_specify_allocation,
17311         obstack_specify_allocation_with_arg, obstack_chunkfun,
17312         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
17313         Remove unprototyped decls and the macros that use them.
17314         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
17315         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
17316         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
17317         (defined __STDC__ && __STDC__)]:
17318         Remove nonprototyped code.
17319         Include <stdlib.h> unconditionally.
17320         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
17321         _obstack_allocated_p, _obstack_free, obstack_free,
17322         _obstack_memory_used, print_and_abort):
17323         Define using prototypes.
17324         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
17325         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
17326         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
17327         obstack_next_free, obstack_object_size, obstack_room) [0]:
17328         Remove unused, unprototyped code.
17329
17330         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
17331
17332         * lib/physmem.c (physmem_total, physmem_available, main): Define
17333         with prototypes.
17334
17335         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
17336         (main): Define with a prototype.
17337
17338         * lib/posixver.c (getenv): Remove decl.
17339
17340         * lib/putenv.c (malloc): Returns void *, not char *.
17341         Include <string.h> unconditionally.
17342         (strchr, memcpy, NULL): Do not define.
17343
17344         * lib/readtokens.c: Include readtokens.h first, to test interface.
17345         Include <stdlib.h>, <string.h> unconditionally.
17346         (init_tokenbuffer): Define with a prototype.
17347
17348         * lib/regex.c (PARAMS): Remove.  All uses removed.
17349         All uses of _RE_ARGS removed, too.
17350         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17351         unconditionally.
17352         (bzero): Assume memset exists.
17353         (memcmp, memcpy, NULL): Remove.
17354         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
17355         char, or assignments to local vars of type signed char.
17356         (init_syntax_once, PREFIX(extract_number_and_incr),
17357         PREFIX(print_partial_compiled_pattern),
17358         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
17359         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
17360         PREFIX(regex_grow_registers), PREFIX(regex_compile),
17361         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
17362         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
17363         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
17364         wcs_compile_range, byte_compile_range, truncate_wchar,
17365         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
17366         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
17367         count_mbs_length, wcs_re_match_2_internal,
17368         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
17369         PREFIX(alt_match_null_string_p),
17370         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
17371         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
17372         regfree, PREFIX(extract_number)): Define with prototype.  Remove
17373         now-unnecessary declaration, if any.
17374         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
17375         regcomp, regexec):
17376         Remove now-unnecessary casts among pointer types.
17377         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
17378
17379         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
17380         (free): Remove decl.
17381
17382         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
17383
17384         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
17385         (free): Remove decl.
17386
17387         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
17388         * lib/xgetcwd.c: Likewise.
17389
17390         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
17391         (free): Remove decl.
17392
17393         * lib/strchrnul.c (strchrnul): Define with a prototype.
17394         Fix bug: c_in was not converted to char before searching.
17395
17396         The following changes are not K&R related:
17397
17398         * lib/group-member.h: Include <sys/types.h>, so that this file is
17399         self-contained.
17400         * lib/makepath.h: Likewise.
17401
17402         * lib/getusershell.c (readname, default_index, line_size, readname):
17403         Use size_t, not int, for sizes.
17404         (readname): If the size overflows, report an error instead of
17405         looping forever.
17406
17407 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17408
17409         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
17410         libc.
17411
17412 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17413
17414         * README: New section: portability guidelines.
17415
17416 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17417
17418         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
17419         C89 spec.
17420
17421 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17422
17423         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
17424
17425 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17426
17427         Assume C89 or better; remove K&R cruft.
17428         A few of these changes were first proposed by Derek Robert Price
17429         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
17430
17431         * lib/addext.c: Include <string.h> unconditionally.
17432         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
17433         Don't declare getenv or malloc.
17434
17435         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
17436         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
17437         (NULL): Remove.
17438         (find_stack_direction, alloca): Use prototypes.
17439
17440         * lib/atexit.c (atexit): Define using a prototype.
17441
17442         * lib/basename.c, dirname.c, stripslash.c:
17443         Include <string.h> unconditionally.
17444
17445         * lib/bcopy.c: Include <stddef.h>.
17446         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
17447
17448         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
17449
17450         * lib/error.h (error, error_at_line, error_print_progname)
17451         [! (defined (__STDC__) && __STDC__)]: Remove decls.
17452         * lib/error.c: Include error.h first, to check interface.
17453         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17454         (VA_START): Remove; all uses changeed to va_start.
17455         (exit, strerror): Remove decls.
17456         (error_print_progname): Prototype uncondionally.
17457         Don't include <errno.h>; no longer needed.
17458         (private_strerror): Remove.
17459         (error_tail): Always define.
17460         (error, error_at_line): Assume C89 or better; always use prototypes.
17461         * lib/fatal.c: Include "fatal.h" first, to test interface.
17462         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17463         (VA_START): Remove; all uses changed to va_start.
17464         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
17465         this case.
17466         (exit): Remove decl.
17467         (fatal): Prototype unconditionally.  Assume va_start works.
17468         Abort at end, to pacify gcc.
17469
17470         * lib/euidaccess.c (main): Define with a prototype.
17471
17472         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
17473
17474         * lib/exitfail.c: Include <stdlib.h> unconditionally.
17475
17476         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
17477         prototypes.
17478         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
17479         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
17480         (getenv): Remove decl.
17481         (fnmatch): Define using a prototype.
17482         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
17483         (FCT): Define using a prototype.
17484
17485         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
17486
17487         * lib/gethostname.c: Include <stddef.h>.
17488         (gethostname): Define with prototype.  Length is size_t, not int.
17489
17490 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17491
17492         Assume C89 or better; remove K&R cruft.
17493         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
17494         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
17495         string.h, getenv, malloc.
17496         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
17497         headers.
17498         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
17499         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
17500         do not check for strerror.
17501         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
17502         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
17503         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
17504         do not check for doprnt or vprintf.
17505         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
17506         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
17507
17508 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17509
17510         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
17511         getversion.c should have been removed then, but was accidentally
17512         preserved.
17513
17514         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
17515         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
17516
17517 2003-09-08  Karl Berry  <karl@gnu.org>
17518
17519         * config/config.sub, config.guess, srclistvars.sh: update from savannah
17520                 config, forget about prep.
17521
17522         * config/depcomp, missing: update from automake.
17523
17524 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17525
17526         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
17527         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17528
17529 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17530
17531         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
17532         copy_tm_result.  Bug reported by Simon Josefsson in
17533         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17534
17535 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17536
17537         * m4/time_r.m4: New file.
17538         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
17539         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
17540         is. Check for timegm declaration.
17541         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
17542         Do not check for gmtime_r.
17543         Replace mktime if __mktime_internal does not exist and if mktime
17544         hasn't been replaced already.
17545
17546 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17547
17548         * lib/time_r.c, lib/time_r.h: New files.
17549
17550         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
17551         __localtime_r.
17552         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
17553         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
17554
17555         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
17556         __gmtime_r.
17557         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
17558         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
17559         Include <time_r.h>.
17560
17561         * lib/timegm.c: Switch to glibc implementation, with the following
17562         changes:
17563         [defined HAVE_CONFIG_H]: Include <config.h>.
17564         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
17565         (__mktime_internal) [!defined _LIBC]: New decl.
17566         (__gmtime_r) [!defined _LIBC]: New macro and function.
17567         (timegm): Use a prototype, since gnulib assumes C89.
17568         Do not bother declaring tmp to be const, as it's not really usefu.
17569         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
17570         (timegm): Declare only if HAVE_DECL_TIMEGM.
17571
17572 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17573
17574         * MODULES.html.sh (func_all_modules): Add time_r.
17575         * modules/time_r: New file.
17576         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
17577         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
17578
17579 2003-09-03  Paul Eggert  <eggert@twinsun.com>
17580
17581         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
17582         Bug reported by Lute Kamstra in
17583         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
17584
17585         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
17586         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
17587         course with correspondingly smaller numbers for tomorrow and
17588         yesterday.  From Tadayoshi Funaba.  Originally installed into
17589         sh-utils on 1999-08-07, but the patch got lost (I guess during the
17590         coreutils merge?).
17591
17592 2003-08-31  Simon Josefsson  <jas@extundo.com>
17593
17594         * modules/timegm: New file.
17595         * MODULES.html.sh (func_all_modules): Add timegm.
17596
17597 2003-08-31  Simon Josefsson  <jas@extundo.com>
17598
17599         * m4/timegm.m4: New file.
17600
17601 2003-08-31  Simon Josefsson  <jas@extundo.com>
17602
17603         * lib/timegm.h: New file.
17604         * lib/timegm.c: New file.  Based on
17605         wget-1.8.2/src/http.c:mktime_from_utc.
17606
17607 2003-08-31  Karl Berry  <karl@gnu.org>
17608
17609         * lib/argp.h: update from libc.
17610
17611 2003-08-28  Bruno Haible  <bruno@clisp.org>
17612
17613         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
17614         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
17615         followed by '#define fnmatch fnmatch_posix' gives an error.
17616
17617 2003-08-28  Bruno Haible  <bruno@clisp.org>
17618
17619         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
17620         warning on QNX, which defines O_BINARY to 000000.
17621
17622 2003-08-27  Jim Meyering  <jim@meyering.net>
17623
17624         * m4/mkstemp.m4: Require that the system mkstemp be able to create
17625         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
17626         would fail after 32.  Reported by Danny Levinson.  Details here:
17627         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
17628
17629 2003-08-24  Bruno Haible  <bruno@clisp.org>
17630
17631         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
17632         MSVC7 <stdio.h> is included later.
17633
17634 2003-08-22  Simon Josefsson  <jas@extundo.com>
17635
17636         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
17637
17638 2003-08-20  Karl Berry  <karl@gnu.org>
17639
17640         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
17641
17642 2003-08-20  Bruno Haible  <bruno@clisp.org>
17643
17644         * modules/progname: New file.
17645         * MODULES.html.sh (func_all_modules): Add progname.
17646
17647 2003-08-20  Bruno Haible  <bruno@clisp.org>
17648
17649         * lib/progname.h: New file, from GNU gettext.
17650         * lib/progname.c: New file, from GNU gettext.
17651         * lib/progreloc.c: New file, from GNU gettext.
17652
17653 2003-08-19  Jim Meyering  <jim@meyering.net>
17654
17655         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
17656         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
17657
17658 2003-08-19  Bruno Haible  <bruno@clisp.org>
17659
17660         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
17661         more.
17662
17663 2003-08-19  Bruno Haible  <bruno@clisp.org>
17664
17665         * lib/xstrdup.c: Assume <string.h> exists.
17666
17667 2003-08-18  Paul Eggert  <eggert@twinsun.com>
17668
17669         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
17670         in makefile rules.
17671
17672 2003-08-18  Jim Meyering  <jim@meyering.net>
17673
17674         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
17675         * m4/lib-ld.m4: Likewise.
17676
17677 2003-08-18  Jim Meyering  <jim@meyering.net>
17678
17679         * lib/setenv.h: Indent nested cpp directive.
17680         * lib/vasnprintf.c: Remove trailing blanks.
17681
17682 2003-08-17  Simon Josefsson  <jas@extundo.com>
17683
17684         * modules/xstrndup: New file.
17685         * MODULES.html.sh (func_all_modules): Add xstrndup.
17686
17687 2003-08-17  Simon Josefsson  <jas@extundo.com>
17688
17689         * modules/argp: Fix autoconf macro name. Add more dependencies.
17690
17691 2003-08-17  Simon Josefsson  <jas@extundo.com>
17692
17693         * m4/xstrndup.m4: New file.
17694
17695 2003-08-17  Simon Josefsson  <jas@extundo.com>
17696
17697         * m4/argp.m4: New file.
17698
17699 2003-08-17  Simon Josefsson  <jas@extundo.com>
17700             Bruno Haible  <bruno@clisp.org>
17701
17702         * lib/xstrndup.h: New file.
17703         * lib/xstrndup.c: New file.
17704
17705 2003-08-17  Bruno Haible  <bruno@clisp.org>
17706
17707         * modules/strndup (Files, Include): Add lib/strndup.h.
17708
17709 2003-08-17  Bruno Haible  <bruno@clisp.org>
17710
17711         * modules/euidaccess (Files): Add lib/euidaccess.h.
17712
17713 2003-08-17  Bruno Haible  <bruno@clisp.org>
17714
17715         * lib/strndup.h: New file.
17716
17717 2003-08-17  Bruno Haible  <bruno@clisp.org>
17718
17719         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
17720         like AC_GNU_SOURCE.
17721         * modules/extensions (configure.ac): Comment out the invocation of
17722         gl_USE_SYSTEM_EXTENSIONS.
17723
17724 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17725
17726         Merges from coreutils, etc.
17727         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
17728         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
17729         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
17730         fixing a typo.
17731         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
17732         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
17733
17734 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17735
17736         Document merge from coreutils.
17737         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
17738         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
17739         * modules/utime: Add m4/utimes-null.m4.
17740
17741 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17742
17743         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
17744         space, undoing this 2003-08-12 change:
17745         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17746
17747 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17748
17749         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
17750         strtoul.c from libc, undoing this 2003-08-12 change:
17751         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17752
17753 2003-08-16  Jim Meyering  <jim@meyering.net>
17754
17755         Merges from coreutils.
17756         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
17757         prefix.  Adjust cache variables similarly.  Create 500 rather than
17758         just 300 files, to exercise bug on Darwin6.5, too.
17759         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
17760         $missing_dir.
17761         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
17762         AM_SYS_POSIX_TERMIOS.
17763         Reported by mkc@mathdogs.com.
17764         Also change use of $am_cv_sys_posix_termios
17765         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
17766         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
17767         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
17768         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
17769         in /proc/mounts until it finds one with matching device number.  This
17770         is unnecessary when the FILE argument *is* a mount point.  No stat call
17771         is necessary in that case.  So, disable the statvfs-testing code on
17772         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
17773         as RedHat bug# 84846.
17774         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17775         to 1MB, so as not to render systems with no stack size limit (e.g.,
17776         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17777         Include <unistd.h>.  On some systems,
17778         it is required for the definition of _SC_PAGESIZE.
17779
17780 2003-08-16  Jim Meyering  <jim@meyering.net>
17781
17782         Merge from coreutils.
17783         * lib/xstrtoimax.c: #else #if -> #elif.
17784         * lib/xstrtoumax.c: Likewise.
17785
17786 2003-08-16  Jim Meyering  <jim@meyering.net>
17787
17788         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
17789         * m4/utimes.m4: Removed.
17790         * m4/utimes-null.m4: Renamed from utimes.m4.
17791
17792         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17793         to 1MB, so as not to render systems with no stack size limit (e.g.,
17794         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17795         Include <unistd.h>.  On some systems,
17796         it is required for the definition of _SC_PAGESIZE.
17797
17798 2003-08-16  Jim Meyering  <jim@meyering.net>
17799         and Paul Eggert  <eggert@cs.ucla.edu>
17800
17801         Merges from coreutils, etc.
17802
17803         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
17804         using the latest version from cvs.  This avoids problems with #line
17805         directives using a vendor (Sun) compiler.
17806         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
17807         Don't set GETGROUPS_LIB here; now it's
17808         done via getgroups.m4's wrapper function.
17809         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
17810         rather than just in sh-util/configure.in, so that the
17811         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
17812         same.
17813         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
17814         AC_FUNC_GETLOADAVG where to find getloadavg.c.
17815         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
17816         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
17817         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
17818         Remove code that is now done by the newly-required macros.
17819         Append $(EXEEXT) to DF_PROG.
17820         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
17821         Do not invoke or require the following here,
17822         since prereq.m4 or some gnulib .m4 now does this for us:
17823         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
17824         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
17825         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
17826         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
17827         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
17828         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
17829         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
17830         AC_FUNC_OBSTACK.
17831         Do not replace the following functions, as this is now the job
17832         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
17833         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
17834         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
17835         atexit getpass, strdup, getpagesize.
17836         Replace 'raise'.
17837         Do not check for the following functions, as this is now the job
17838         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
17839         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
17840         setregid.
17841         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
17842         Check for sys/sysctl.h.
17843         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
17844         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
17845         of checking for ssize_t ourselves.
17846
17847         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
17848         Require every macro that gnulib/modules/* suggests for us.
17849         (jm_PREREQ_ADDEXT): New macro.
17850         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
17851         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
17852
17853         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
17854         (gl_PHYSMEM): Use it.
17855         Also check for `table' function.
17856         Check for new headers and functions.
17857         Add check for sys/sysmp.h.
17858         With suggestions from Kaveh Ghazi.
17859         Ignore headers that are present but cannot be compiled.  This
17860         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
17861         C 5.4.
17862
17863 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17864
17865         Document merge from coreutils.
17866         * modules/userspec: Depend on posixver.
17867         * modules/strftime: Depend on tzset.
17868
17869 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17870
17871         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
17872         rather than tab, after '#' in shell-script copyright notices.
17873         Suggested by Bruno Haible.
17874
17875 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17876
17877         * config/srclist-update: Use three spaces, rather than tab, after '#'
17878         in shell-script copyright notices.  Suggested by Bruno Haible.
17879         Remove unnecessary parenthesization in regular expression.
17880
17881 2003-08-15  Jim Meyering  <jim@meyering.net>
17882
17883         Merge from coreutils.
17884         * lib/xgethostname.c: Include <stdlib.h>.
17885         (xghostname): Don't exit for anything other than memory-related
17886         failure; just return NULL.
17887         * lib/userspec.c: Include "posixver.h".
17888         (parse_user_spec): Accept `.' as a separator only
17889         in pre-POSIX-200112 mode.
17890         * lib/strtoimax.c: Use #elif rather than #else #if.
17891         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
17892         Remove function, now that we can rely on a working tzset function.
17893         [!_LIBC]: Ensure that the required autoconf test has been run.
17894         [!defined _NL_CURRENT && HAVE_STRFTIME]:
17895         Use underlying_strftime for %r.
17896         * lib/sha.c: Merge in some clean-up and optimization changes from
17897         glibc.
17898         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
17899         Ensure that it is a multiple of 64.
17900         Rearrange loop exit tests so as to avoid performing an
17901         additional fread after encountering an error or EOF.
17902         * lib/realloc.c: Update copyright date.
17903
17904 2003-08-15  Jim Meyering  <jim@meyering.net>
17905         and Paul Eggert  <eggert@twinsun.com>
17906
17907         Merge from coreutils.
17908         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
17909         member but strut utmpx does not.  Needed for AIX 4.3.3.
17910         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
17911
17912 2003-08-15  Jim Meyering  <jim@meyering.net>
17913         and Paul Eggert  <eggert@cs.ucla.edu>
17914
17915         Merges from coreutils, etc.
17916         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
17917         Require gl_FUNC_TZSET_CLOBBER.
17918         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
17919         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
17920         members.
17921
17922 2003-08-14  Paul Eggert  <eggert@twinsun.com>
17923
17924         Help the merge from coreutils.
17925         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
17926         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
17927         * m4/tzset.m4: Use it too.
17928
17929 2003-08-14  Paul Eggert  <eggert@twinsun.com>
17930
17931         * modules/tzset: New file.
17932
17933 2003-08-14  Jim Meyering  <jim@meyering.net>
17934
17935         Merges from coreutils.
17936         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
17937         variable names, rather than @FNMATCH_H@.
17938         * modules/alloca: Likewise for $(ALLOCA_H).
17939
17940         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
17941         the three copies of the literal target, `fnmatch.h'.
17942         * modules/alloca (alloca.h): Likewise.
17943
17944 2003-08-14  Jim Meyering  <jim@meyering.net>
17945
17946         Merge from coreutils.
17947         * m4/tzset.m4: New file.
17948         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
17949         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
17950         otherwise, AIX 5.1 systems would end up using the latter.
17951         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
17952         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
17953         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
17954         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
17955
17956 2003-08-14  Jim Meyering  <jim@meyering.net>
17957
17958         Merge from coreutils.
17959         * lib/obstack.h: Whitespace changes.
17960         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
17961         and xcalloc return values.
17962         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
17963         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
17964         hang on OSF/1 5.1 for DIR on both local and remote file systems.
17965         Reported by (and fix confirmed by) Nelson H. F. Beebe.
17966         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
17967         error from mntctl.
17968         Use mntctl's return value to drive the entry-processing loop, since
17969         we can't rely on the value of the vmt_length member in the last
17970         entry.  On some systems doing so could result in exhausting
17971         virtual memory.  Based in part on a patch from Mike Jetzer.
17972
17973 2003-08-14  Jim Meyering  <jim@meyering.net>
17974         and Paul Eggert  <eggert@twinsun.com>
17975
17976         Merges from coreutils, plus other fixes.
17977         * lib/physmem.c: Merge in portability changes from gcc/libiberty
17978         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
17979         for credits and details.  Thanks to Kaveh Ghazi for helping
17980         to keep these files in sync.
17981         (ARRAY_SIZE): Define it.
17982         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
17983         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
17984         (memcasecmp): Don't assume size_t fits in unsigned int.
17985         Remove casts and duplicate code.
17986         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
17987         (memcpy): Remove definition.
17988         Merge in some clean-up and optimization changes from glibc.
17989         [BLOCKSIZE]: Move definition to top of file.
17990         Ensure that it is a multiple of 64.
17991         Rearrange loop exit tests so as to avoid performing an
17992         additional fread after encountering an error or EOF.
17993         * lib/md5.h (md5_uintptr): Define.
17994         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
17995         return to the initial working directory.  Preserve errno
17996         for caller.
17997         * lib/idcache.c: Include "xalloc.h".
17998         (xmalloc, xrealloc): Remove decls.
17999         (getuser): Remove casts no longer required in C89.
18000         * lib/human.c: Include stdio.h, for sprintf.
18001         * lib/group-member.c: Include "xalloc.h".
18002         (xmalloc, xrealloc): Remove decls.
18003         (get_group_info): Remove casts no longer required in C89.
18004         * lib/getusershell.c (readname): Remove casts no longer required in
18005         C89.
18006         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
18007         * lib/getline.c: Whitespace fix, from coreutils.
18008
18009 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18010
18011         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
18012         Check for isascii.
18013
18014         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18015         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18016         Undo previous (whitespace-only) change.
18017
18018 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18019
18020         * lib/exclude.c: Include <ctype.h>
18021         (IN_CTYPE_DOMAIN): New macro.
18022         (is_space): New fn.
18023         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
18024         and empty lines.
18025
18026         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18027         Undo previous (whitespace-only) change.
18028
18029 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18030
18031         * config/srclist-update: Change update back to the old behavior,
18032         leaving whitespace alone.  Use one 'sed' command rather than a
18033         pipeline.
18034         (fixlicense): Now a variable, not a function.
18035         (remove_trailing_blanks): Remove.
18036         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
18037         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18038         Undo previous (whitespace-only) change.
18039
18040 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18041
18042         Merge from coreutils.
18043         * modules/euidaccess: Add lib_SOURCES, include for new
18044         file euidaccess.h
18045
18046 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18047
18048         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18049         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18050         Normalize leading white space and remove trailing white space.
18051
18052         Merge from coreutils
18053         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
18054
18055         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
18056         0.12.1.  These files are now being upgraded automatically by
18057         ../config/srclist-update.
18058
18059 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18060
18061         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18062         Normalize leading white space and remove trailing white space.
18063         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
18064         notice, as per ../config/srclist-update.
18065
18066         Merge from coreutils.
18067         * lib/euidaccess.h: New file.
18068         * lib/euidaccess.c: Include it.
18069         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
18070         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
18071         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
18072
18073 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18074
18075         * config/srclist-update: Add copyright notice.
18076         (remove_id_lines, remove_trailing_blanks): New constants.
18077         (fixfile): Use them to normalize spacing a bit in copied files.
18078         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18079         Normalize leading white space and remove trailing white space.
18080
18081         * config/texinfo.tex: Sync with texinfo.
18082
18083         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
18084         strtoul.c from libc, to merge coreutils whitespace changes.
18085
18086         * config/srclist.txt: Get the following m4 files from gettext:
18087         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
18088         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
18089         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
18090         wint_t.m4.
18091
18092 2003-08-12  Karl Berry  <karl@gnu.org>
18093
18094         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
18095         been made.
18096
18097 2003-08-11  Paul Eggert  <eggert@twinsun.com>
18098
18099         * modules/gnu-source, m4/gnu-source.m4:
18100         Remove; we're assuming Autoconf 2.54 or later now.
18101         Suggested by Bruno Haible.
18102         * MODULES.html.sh (func_all_modules): Remove gnu-source.
18103
18104 2003-08-11  Bruno Haible  <bruno@clisp.org>
18105
18106         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
18107
18108 2003-08-11  Bruno Haible  <bruno@clisp.org>
18109
18110         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
18111         (vasnprintf): Use it instead of wcslen.
18112
18113 2003-08-11  Bruno Haible  <bruno@clisp.org>
18114
18115         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
18116         value to ensure that _Bool promotes to int. Use #define for _Bool when
18117         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
18118
18119 2003-08-10  Karl Berry  <karl@gnu.org>
18120
18121         * lib/regex.h: update from libc (whitespace fix).
18122
18123 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18124
18125         Merge some files from coreutils.  These changes were
18126         originally made by Jim Meyering.
18127         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
18128         many older Unixes require this.
18129         * lib/alloca.c (alloca): Remove cast to argument of free;
18130         no longer needed in C89.
18131         * lib/alloca_.h, regex.h: Fix white space to match
18132         what GNU indent does.
18133
18134 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18135
18136         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
18137         apparently Emacs's Unicode mode got confused before my 2003-08-05
18138         checkin.
18139
18140 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18141
18142         * m4/extensions.m4: New file.
18143         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
18144         Require gl_USE_SYSTEM_EXTENSIONS.
18145         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
18146         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
18147
18148 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18149
18150         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
18151         * modules/extensions, modules/gnu-source: New files.
18152         * modules/timespec, modules/unlocked-io: Depend on extensions.
18153
18154 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18155
18156         * modules/restrict: New file.
18157         * MODULES.html.sh (func_all_modules): Add restrict.
18158         * modules/regex: Depend on restrict.
18159
18160 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18161
18162         * m4/restrict.m4: New file.
18163         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
18164
18165 2003-08-07  Bruno Haible  <bruno@clisp.org>
18166
18167         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
18168         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
18169
18170 2003-08-07  Bruno Haible  <bruno@clisp.org>
18171
18172         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
18173         makes the module 'getndelim2' compatible with the module 'getline'.
18174
18175 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18176
18177         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
18178         byte with "\201" to avoid glitches when editing that source file
18179         with multi-gnome-terminal.
18180
18181 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18182
18183         * lib/bumpalloc.h: Remove.
18184
18185 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18186
18187         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
18188         * modules/bumpalloc: Remove.
18189
18190 2003-08-04  Paul Eggert  <eggert@twinsun.com>
18191
18192         * lib/getloadavg.c: Change copyright notice and spacing to conform to
18193         GNU coding style.
18194
18195         Merge from coreutils.
18196         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
18197         1. From glibc.
18198         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
18199         from Karl Berry, implemented by Jim Meyering.
18200         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
18201         from Dmitry V. Levin.
18202         Remove anachronistic cast of xrealloc.
18203         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
18204         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
18205         type. Otherwise, it wouldn't compile with at least /bin/cc on
18206         ymp-cray-unicos9.0.2.X.
18207         Combine two mostly-identical uses of alloca into one.
18208         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
18209
18210 2003-08-04  Dave Love  <d.love@dl.ac.uk>
18211
18212         [From Emacs.]
18213
18214         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
18215         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
18216         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
18217         obsolete NLIST_NAME_UNION.
18218         [__GNU__]: Undef BSD and FSCALE.
18219         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
18220
18221 2003-08-03  Paul Eggert  <eggert@twinsun.com>
18222
18223         * lib/stdbool_.h (_Bool): Make it signed char, instead of
18224         an enum type, so that it's guaranteed to promote to int.  See:
18225         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
18226
18227 2003-08-03  Karl Berry  <karl@gnu.org>
18228
18229         * config/depcomp: update from automake.
18230
18231 2003-07-31  Paul Eggert  <eggert@twinsun.com>
18232
18233         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
18234         (strerror): Don't assume that a printable int fits in 14 bytes.
18235
18236 2003-07-31  Bruno Haible  <bruno@clisp.org>
18237
18238         * modules/getpass-gnu: New file.
18239         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
18240
18241 2003-07-31  Bruno Haible  <bruno@clisp.org>
18242
18243         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
18244
18245 2003-07-24  Karl Berry  <karl@gnu.org>
18246
18247         * config/missing: update from automake.
18248
18249 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
18250             Bruno Haible  <bruno@clisp.org>
18251
18252         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
18253         * lib/getline.c (getline, getdelim): Likewise.
18254         Remove _GNU_SOURCE define; now it's defined in config.h through
18255         m4/getline.m4.
18256
18257 2003-07-23  Karl Berry  <karl@gnu.org>
18258
18259         * config/config.sub: update from prep.
18260
18261 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18262
18263         * modules/xalloc (Depends-on): Add exitfail.
18264         * modules/xmemcoll: Likewise.
18265
18266 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18267
18268         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
18269         over-parenthesization in macros.
18270
18271         Sync with coreutils.
18272
18273         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
18274         required by C99.
18275
18276         Use `exit_failure' for xalloc and xmemcoll instead of their own
18277         private exit-failure variables.
18278         * lib/xalloc.h (xalloc_exit_failure): Remove.
18279         * lib/xmalloc.c: Likewise.  Include exitfail.h.
18280         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
18281         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
18282         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
18283         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
18284
18285 2003-07-20  Jim Meyering  <jim@meyering.net>
18286
18287         * modules/closeout (Depends-on): Add exitfail.
18288         Suggestion from Bruno Haible.
18289
18290 2003-07-19  Karl Berry  <karl@gnu.org>
18291
18292         * config/config.sub: update from prep.
18293
18294 2003-07-18  Paul Eggert  <eggert@twinsun.com>
18295
18296         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
18297         Remove.
18298         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
18299         to test that it can stand by itself.  Include "exitfail.h".
18300         Clients should set exit_failure instead.
18301         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
18302
18303 2003-07-18  Bruno Haible  <bruno@clisp.org>
18304
18305         * modules/getndelim2: New file.
18306         * modules/getline: Share files with module getndelim2.
18307         * modules/getnline: Depend on getndelim2 instead of sharing files with
18308         it. Add getnline.c to lib_SOURCES.
18309         * MODULES.html.sh (func_all_modules): Add getndelim2.
18310
18311 2003-07-18  Bruno Haible  <bruno@clisp.org>
18312
18313         * m4/getndelim2.m4: New file.
18314         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
18315         invoke gl_PREREQ_GETNDELIM2.
18316         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
18317         gl_PREREQ_GETNDELIM2.
18318         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
18319         gl_GETNDELIM2.
18320
18321 2003-07-18  Bruno Haible  <bruno@clisp.org>
18322
18323         * lib/getndelim2.h: New file.
18324         * lib/getndelim2.c: Make into a module of its own. Include config.h,
18325         getndelim2.h.
18326         (getndelim2): Make non-static. Change return type to ssize_t.
18327         * lib/getline.h: Change argument names.
18328         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
18329         * lib/getnline.c: Include getndelim2.h.
18330
18331 2003-07-18  Andreas Schwab  <schwab@suse.de>
18332
18333         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
18334
18335 2003-07-17  Karl Berry  <karl@gnu.org>
18336
18337         * config/config.sub: update from prep.
18338
18339 2003-07-17  Bruno Haible  <bruno@clisp.org>
18340
18341         * modules/getnline: New file.
18342         * modules/getline: Add lib/getndelim2.c to source file list.
18343         * MODULES.html.sh (func_all_modules): Add getnline.
18344
18345 2003-07-17  Bruno Haible  <bruno@clisp.org>
18346
18347         * m4/getnline.m4: New file.
18348
18349 2003-07-17  Bruno Haible  <bruno@clisp.org>
18350
18351         * m4/Makefile.am.in: Remove file.
18352         * m4/Makefile.am: Remove file.
18353         * m4/Makefile.in: Remove file.
18354
18355 2003-07-17  Bruno Haible  <bruno@clisp.org>
18356
18357         * lib/getnline.h: New file.
18358         * lib/getnline.c: New file.
18359         * lib/getndelim2.c: New file, extracted from getline.c.
18360         (getndelim2): Renamed from getdelim2, with added nmax argument.
18361         * lib/getline.c: Include getndelim2.c.
18362         (getdelim2): Moved out to getndelim2.c.
18363         (getline, getdelim): Update.
18364
18365 2003-07-17  Bruno Haible  <bruno@clisp.org>
18366
18367         * lib/Makefile.am: Remove file.
18368         * lib/Makefile.in: Remove file.
18369
18370 2003-07-17  Bruno Haible  <bruno@clisp.org>
18371
18372         * configure.in: Remove file.
18373         * Makefile.in: Remove file.
18374
18375 2003-07-17  Bruno Haible  <bruno@clisp.org>
18376
18377         * MODULES.html.sh: Put the </BODY> right before </HTML>.
18378
18379 2003-07-16  Karl Berry  <karl@gnu.org>
18380
18381         * config/srclist-update: was running fixlicense twice, which caused
18382                 texinfo.tex to be nullified for some reason.  Simplify,
18383                 $gplsrc is no longer needed as far as I can see?
18384
18385 2003-07-16  Jim Meyering  <jim@meyering.net>
18386
18387         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
18388
18389 2003-07-15  Paul Eggert  <eggert@twinsun.com>
18390
18391         * config/srclist.txt: Get the following files from gettext-runtime/intl
18392         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
18393         ref-del.sin.  From Bruno Haible.
18394         * config/srclist-update (fixfile): Change grep pattern again, since the
18395         previous fix didn't work (there was another trailing $).  Use
18396         '[$]' to escape the $s.
18397
18398 2003-07-15  Karl Berry  <karl@gnu.org>
18399
18400         * lib/vasnprintf.c: update from gettext.
18401
18402 2003-07-15  Karl Berry  <karl@gnu.org>
18403
18404         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
18405         gets expanded when surrounded by '$'.
18406
18407 2003-07-15  Jim Meyering  <jim@meyering.net>
18408
18409         * modules/save-cwd: Don't depend on error.  From Derek Price.
18410
18411 2003-07-15  Jim Meyering  <jim@meyering.net>
18412
18413         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
18414
18415 2003-07-14  Simon Josefsson  <jas@extundo.com>
18416
18417         * modules/mempcpy: New file.
18418         * MODULES.html.sh (func_all_modules): Add mempcpy.
18419
18420 2003-07-14  Simon Josefsson  <jas@extundo.com>
18421
18422         * m4/mempcpy.m4: New file.
18423
18424 2003-07-14  Simon Josefsson  <jas@extundo.com>
18425
18426         * lib/mempcpy.h: New file.
18427         * lib/mempcpy.c: New file.
18428
18429 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18430
18431         * modules/getdate, modules/posixtm: Depend on mktime.
18432
18433 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18434
18435         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
18436         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
18437         unicodeio.c, unicodeio.h, unlocked-io.h:
18438         Switch from LGPL to GPL.
18439
18440 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18441
18442         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
18443         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
18444         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
18445         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
18446         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
18447         updated automatically by ../config/srclist-update.  This changes
18448         their license from LPGL to GPL.
18449
18450 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18451
18452         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
18453         assumed to refer to the root of the most recent stable gettext version.
18454         * config/srclistvars.sh: Add defaults for eggert.
18455         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
18456         Match "This program" as well as "The program".  This is needed
18457         for gettext.
18458
18459 2003-07-14  Jim Meyering  <jim@meyering.net>
18460
18461         Don't emit diagnostics.  Let callers do that.
18462         * lib/save-cwd.c: Don't include "error.h".
18463         (save_cwd): Don't call error.  Ensure that errno is valid
18464         when returning nonzero.
18465
18466         * lib/save-cwd.h (restore_cwd): Update prototype.
18467         * lib/save-cwd.c (restore_cwd): Remove two parameters.
18468         Simplify.  Don't call error upon failure.  Let callers do that.
18469         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
18470         when auditing is enabled.  But don't bother updating the #if.
18471
18472 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
18473
18474         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
18475         it breaks C++ compilation.
18476         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
18477
18478 2003-07-10  Simon Josefsson  <jas@extundo.com>
18479
18480         * modules/strchrnul (Makefile.am): Add strchrnul.h.
18481
18482 2003-07-10  Jim Meyering  <jim@meyering.net>
18483
18484         * m4/clock_time.m4: Remove trailing blank.
18485         * m4/intmax_t.m4: Likewise.
18486
18487 2003-07-10  Jim Meyering  <jim@meyering.net>
18488
18489         * lib/vasnprintf.c: Remove trailing blanks.
18490         Make cpp indentation consistent.
18491
18492 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18493
18494         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
18495         posixver.c, strftime.c, strnlen.c, strverscmp.c:
18496         Switch from LGPL to GPL.
18497
18498 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18499
18500         * config/srclist.txt: Sort sublists.  Add
18501         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
18502         that differ from gnulib for one reason or another; we'd like this list
18503         to be smaller but for now let's document what we have.
18504
18505 2003-07-08  Paul Eggert  <eggert@twinsun.com>
18506
18507         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
18508         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
18509         and sweeter "eval x=$x".
18510         * config/srclist.txt: Get lib/argp* from glibc.
18511
18512 2003-07-07  Paul Eggert  <eggert@twinsun.com>
18513
18514         * lib/mktime.c: Fix some boundary cases and remove need for floating
18515         point.
18516
18517         Issue a compile-time diagnostic if time_t is floating point, or if
18518         two's complement arithmetic is not in effect, or if arithmetic
18519         right shift does not propagate the sign.  These assumptions were
18520         all in the original code but they weren't checked.
18521
18522         (TIME_T_MIDPOINT, verify): New macros.
18523         (__isleap): Remove; it has integer overflow problems.
18524         (leapyear): New function, without those problems.
18525         (ydhms_tm_diff): Remove; splitting into two parts.
18526         (ydhms_diff): New function, containing the arithmetic part of
18527         the old ydhms_tm_diff function.  Issue a compile-time
18528         diagnostic if we are not using C99 integer division.
18529         Avoid casts when possible.
18530         (guess_time_tm): New function, containing the checking part of
18531         the old ydhms_tm_diff function.  Return the new value, rather than
18532         the difference between it and the old.  Accept a new argument T
18533         so that *T specifies the old value.  Check for overflow in the result.
18534
18535         (__mktime_internal): Use a time_t offset, not a long int offset.
18536         This undoes the 2003-06-04 change, which is no longer needed now
18537         that we have better overflow checking.
18538         (localtime_offset): Likewise.
18539
18540         (__mktime_internal): Avoid harmful overflow on hosts where time_t
18541         and long are 64-bit but int is only 32-bit.
18542         (ydhms_diff): Use long int to store year1 and yday1.
18543         Issue a compile-time diagnostic if long int is not wide enough.
18544
18545         (__mktime_internal): Use long int to store adjusted year and yday.
18546         Use plain C rather than preprocessor commands, if that doesn't
18547         affect efficiency.
18548         Check for overflow (and try to repair) after each probe
18549         rather than checking only at the very end.  This avoids some bugs
18550         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
18551         does not equal GMT offset at maximum time).
18552         Use integer to check for overflow rather than floating point; this
18553         is more portable to non-IEEE hosts, and is a tad faster.
18554         When we detect that we are oscillating between two values,
18555         don't check whether tm_isdst has the requested value, since
18556         we already know the answer.  When tm_isdst has the wrong value,
18557         use a different heuristic to find the right one, based on the
18558         extreme values actually observed in practice in tz2003a,
18559         rather than the (overly optimistic) "previous 3 calendar quarters".
18560
18561         (not_equal_tm, print_tm, check_result): Use "const T" rather than
18562         "T const" to accommodate glibc style.
18563         (check_result): Use less-confusing report format.  "long" -> "long int.
18564         (main): Likewise.
18565         Don't loop if the iteration overflows time_t.
18566         Allow a negative step in the iteration.
18567
18568 2003-07-06  Karl Berry  <karl@gnu.org>
18569
18570         * config/depcomp: update from automake.
18571         * config/config.sub: update from prep.
18572
18573 2003-07-03  Karl Berry  <karl@gnu.org>
18574
18575         * config/config.guess: update from prep.
18576
18577 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18578
18579         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
18580         xreadlink.c now includes it unconditionally.
18581
18582 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18583
18584         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
18585         having it depend on HAVE_SYS_TYPES_H.
18586
18587 2003-07-01  Bruno Haible  <bruno@clisp.org>
18588
18589         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
18590         <sys/types.h> should be sufficient.
18591         Reported by Paul Eggert.
18592
18593 2003-06-26  Karl Berry  <karl@gnu.org>
18594
18595         * config/depcomp: update from automake.
18596
18597 2003-06-26  Bruno Haible  <bruno@clisp.org>
18598
18599         * modules/human: Depend on module stdbool.
18600
18601 2003-06-25  Bruno Haible  <bruno@clisp.org>
18602
18603         * modules/readlink: New file.
18604         * modules/xreadlink: Depend on it.
18605         * MODULES.html.sh (func_all_modules): Add readlink.
18606
18607 2003-06-25  Bruno Haible  <bruno@clisp.org>
18608
18609         * m4/readlink.m4: New file.
18610
18611 2003-06-25  Bruno Haible  <bruno@clisp.org>
18612
18613         * lib/readlink.c: New file.
18614
18615 2003-06-22  Karl Berry  <karl@gnu.org>
18616
18617         * config/srclist.txt: update mkinstalldirs from automake.
18618         * config/mkinstalldirs: update.
18619
18620 2003-06-22  Bruno Haible  <bruno@clisp.org>
18621
18622         Portability to mingw32.
18623         * m4/ssize_t.m4: New file, from GNU gettext.
18624         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
18625         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
18626
18627 2003-06-22  Bruno Haible  <bruno@clisp.org>
18628
18629         * modules/safe-read: Add m4/ssize_t.m4.
18630         * modules/xreadlink: Add m4/ssize_t.m4.
18631
18632 2003-06-20  Bruno Haible  <bruno@clisp.org>
18633
18634         Assume C89, so PARAMS isn't needed.
18635         * lib/unicodeio.h (PARAMS): Remove.
18636         * lib/unicodeio.c: Don't use PARAMS.
18637
18638 2003-06-18  Karl Berry  <karl@gnu.org>
18639
18640         * config/config.{guess,sub}: update from prep.
18641
18642 2003-06-18  Jim Meyering  <jim@meyering.net>
18643
18644         Merge changes from coreutils.
18645         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
18646         Remove explicit declarations of xmalloc and realloc.
18647         Include xalloc.h.
18648         (read_utmp): Remove anachronistic cast of xmalloc.
18649
18650 2003-06-17  Paul Eggert  <eggert@twinsun.com>
18651
18652         Assume C89, so PARAMS isn't needed.
18653         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
18654         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
18655         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
18656         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
18657         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
18658         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
18659         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
18660         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
18661         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
18662         lib/xstrtod.h, lib/xstrtol.h: Likewise.
18663         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
18664         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
18665         no longer needed. Anyway, config.h should always be included before any
18666         other file.
18667
18668 2003-06-11  Simon Josefsson  <jas@extundo.com>
18669
18670         * modules/sysexits: New file.
18671         * MODULES.html.sh (func_all_modules): Add sysexits.
18672
18673 2003-06-11  Simon Josefsson  <jas@extundo.com>
18674
18675         * lib/sysexit_.h: New file.
18676
18677 2003-06-11  Derek Price  <derek@ximbiot.com>
18678
18679         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
18680         necessary.
18681
18682 2003-06-11  Bruno Haible  <bruno@clisp.org>
18683
18684         * m4/sysexits.m4: New file.
18685
18686 2003-06-10  Simon Josefsson  <jas@extundo.com>
18687
18688         * lib/argp.h: New file, from glibc.
18689         * lib/argp-ba.c: New file, from glibc.
18690         * lib/argp-eexst.c: New file, from glibc.
18691         * lib/argp-fmtstream.c: New file, from glibc.
18692         * lib/argp-fmtstream.h: New file, from glibc.
18693         * lib/argp-fs-xinl.c: New file, from glibc.
18694         * lib/argp-help.c: New file, from glibc.
18695         * lib/argp-namefrob.h: New file, from glibc.
18696         * lib/argp-parse.c: New file, from glibc.
18697         * lib/argp-pv.c: New file, from glibc.
18698         * lib/argp-pvh.c: New file, from glibc.
18699         * lib/argp-xinl.c: New file, from glibc.
18700
18701 2003-06-10  Simon Josefsson  <jas@extundo.com>
18702
18703         * modules/strchrnul: New file.
18704
18705 2003-06-10  Simon Josefsson  <jas@extundo.com>
18706
18707         * modules/argp: New file.
18708
18709 2003-06-10  Simon Josefsson  <jas@extundo.com>
18710
18711         * m4/strchrnul.m4: New file.
18712
18713 2003-06-10  Simon Josefsson  <jas@extundo.com>
18714
18715         * lib/strchrnul.h: New file.
18716         * lib/strchrnul.c: New file.
18717
18718 2003-06-10  Bruno Haible  <bruno@clisp.org>
18719
18720         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
18721
18722 2003-06-07  Karl Berry  <karl@gnu.org>
18723
18724         * config/config.{guess,sub}: update from prep.
18725
18726 2003-06-07  Jim Meyering  <jim@meyering.net>
18727
18728         * modules/strtod: Use $(...) notation, not @...@ for
18729         AC_REPLACE'd variables.
18730         * modules/localcharset: Likewise.
18731
18732 2003-06-07  Jim Meyering  <jim@meyering.net>
18733
18734         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
18735         in place of my name in the copyright comment.
18736         Remove definition and uses of __P.
18737
18738         From coreutils.
18739         * lib/stat.c: Don't declare xmalloc explicitly.
18740         Instead, include "xalloc.h".
18741         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
18742         xrealloc, and xcalloc return values.
18743         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
18744         Improve comment.
18745         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
18746
18747 2003-06-07  Bruno Haible  <bruno@clisp.org>
18748
18749         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
18750         avoid AC_CONFIG_LINKS.
18751         * modules/fnmatch (Makefile.am): Use explicit creation rule for
18752         fnmatch.h, to avoid AC_CONFIG_LINKS.
18753         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
18754
18755 2003-06-07  Bruno Haible  <bruno@clisp.org>
18756
18757         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
18758         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
18759         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18760         directory.
18761         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
18762         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18763         directory.
18764
18765 2003-06-06  Jim Meyering  <jim@meyering.net>
18766
18767         Merge from coreutils.
18768         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
18769         Consolidate declarations and initializations of *_base* locals.
18770
18771         Merge from coreutils.
18772         This avoids a core dump on systems without GNU putenv,
18773         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
18774         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
18775         (unsetenv): New static function, from GNU libc.
18776         (rpl_putenv): Use it.
18777
18778         * lib/modechange.c: Remove trailing blanks.
18779
18780         Merge from coreutils.
18781         * lib/fsusage.c: Remove declaration of statfs.
18782         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
18783
18784         * lib/posixtm.c: Include <stdbool.h> unconditionally.
18785
18786 2003-06-06  Jim Meyering  <jim@meyering.net>
18787
18788         * lib/stdbool_.h: Renamed from stdbool.h.in.
18789
18790 2003-06-06  Jim Meyering  <jim@meyering.net>
18791             Bruno Haible  <bruno@clisp.org>
18792
18793         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
18794         Adjust Makefile.am snippet not to redirect directly to target.
18795         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
18796
18797 2003-06-05  Paul Eggert  <eggert@twinsun.com>
18798
18799         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
18800         mismatch, look in future quarters as well as past.  This fixes a
18801         bug when processing fall-backwards gaps immediately after a long
18802         period of daylight-saving time.
18803
18804         * lib/mktime.c: Assume freestanding C89 or better.
18805         (HAVE_LIMITS_H): Remove.  Assume it's 1.
18806         (__P): Remove; not used.
18807         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
18808         (mktime, not_equal_tm, print_tm, check_result,
18809         main): Use prototypes.  Use const * where appropriate.
18810         (main): Fix typo in testing code that uncovered by above changes.
18811         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
18812
18813 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18814
18815         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
18816         locale.h, localeconv.  This merges changes from coreutils.
18817
18818         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
18819         It can be removed after the next Autoconf is released.
18820         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
18821         needed.
18822
18823 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18824
18825         * lib/mktime.c: Fix Debian bug 177940
18826         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
18827         (localtime_offset): Now long int, not time_t, because we want it
18828         to be guaranteed to be signed.  All uses changed.
18829         (__mktime_internal): If overflow would occur when adding offset,
18830         don't add it.
18831
18832         Merge 'human' changes from coreutils.  Rewrite to support
18833         locale-specific notations like thousands separators.
18834         * lib/human.c: Simplify authorship notice.
18835         Include human.h immediately after config.h.
18836         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
18837         <limits.h>: Do not include, since human.h does.
18838         (SIZE_MAX, UINTMAX_MAX): New macros.
18839         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
18840         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
18841         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
18842         (power_letter): Renamed from suffixes.
18843         (generate_suffix_backwards): Remove.
18844         (adjust_value): Now takes int style (because of human.h changes)
18845         and long double value (for greater precision on some platforms).
18846         (group_number): New function.
18847         (human_readable): Use it.  Use integer options, not enum.
18848         Put the options before the sizes in the arg list.
18849         Support all the new options.
18850         The old human_readable function has been removed;
18851         use inttostr.h instead.
18852         (human_readable, default_block_size, humblock):
18853         Use uintmax_t, not int, for block sizes.
18854         (human_readable_inexact, block_size_types): Remove.
18855         (block_size_opts): New constant.
18856         (human_options): Renamed from human_block_size, with new signature
18857         that allows block sizes up to UINTMAX_MAX.  All callers changed.
18858         * lib/human.h: Add copyright and authorship notice.
18859         Include <limits.h> and <stdbool.h> unconditionally.
18860         (PARAMS): Remove.  All uses removed.
18861         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
18862         (enum human_inexact_style): Remove tag; now a nameless enum.
18863         (human_floor, human_ceiling, human_round_to_even): Now have
18864         values 2, 0, 1 rather than -1, 1, 0.
18865         (human_group_digits, human_suppress_point_zero, human_autoscale,
18866         human_base_1024, human_SI, human_B): New constants.
18867         (human_readable_inexact, human_block_size): Remove.
18868         (human_readable): Size args are now uintmax_t, not int.
18869         (human_options): New decl.
18870
18871         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
18872         unnecessary now that we assume C89 or better.  This change
18873         imported from coreutils.
18874
18875         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
18876         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
18877         in the 2003-05-30 sync from glibc.
18878
18879         .h files should stand alone, but we shouldn't include <sys/types.h>
18880         if we can get away with just <stddef.h>.
18881
18882         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
18883         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
18884         rather than <sys/types.h>, as we merely need size_t.
18885         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
18886         to get size_t.
18887         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
18888         Include <stdio.h>, to get FILE.
18889         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
18890         memcasecmp.h has included <stddef.h> and all we need is size_t.
18891         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
18892         our interface, instead of including <sys/types.h>
18893
18894 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18895
18896         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
18897         now, as glibc mktime is buggy on non-glibc systems.
18898
18899 2003-06-03  Karl Berry  <karl@gnu.org>
18900
18901         * config/config.sub: update from prep.
18902
18903 2003-06-02  Paul Eggert  <eggert@twinsun.com>
18904
18905         [from coreutils]
18906         Fix some minor time-related bugs with POSIX time arguments.
18907         Some valid time stamps were being rejected (notably -1, and
18908         time stamps before 1900 on 64-bit hosts).  And some invalid
18909         time stamps were being accepted, e.g. September 31.
18910
18911         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
18912         that we can return (time_t) -1 successfully.
18913         * lib/posixtm.c: Likewise.
18914         [HAVE_STDBOOL_H]: Include <stdbool.h>.
18915         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
18916         (t): Remove static var.
18917         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
18918         of static var.  All uses changed.
18919         (year): Do not reject years before 1900; they can occur with
18920         64-bit time_t.
18921         (posix_time_parse): Do not check for out-of-range components;
18922         that is now the caller's responsibility, since our checks were
18923         only approximations.
18924         (posixtime): Use mktime to check for out-of-range components,
18925         since it knows them exactly.
18926         If mktime returns (time_t) -1, check whether an error actually occurred
18927         by invoking localtime on -1.
18928         (main) [TEST_POSIXTIME]: Check for input data errors, and report
18929         posixtime failures better.
18930         Improve the test data (in comments only).
18931
18932 2003-06-02  Karl Berry  <karl@gnu.org>
18933
18934         * config/mkinstalldirs (version): new variable.
18935         (--version): new option.
18936         (usage): improve message.
18937
18938 2003-05-30  Karl Berry  <karl@gnu.org>
18939
18940         * lib/mktime.c: update from libc.
18941
18942 2003-05-30  Bruno Haible  <bruno@clisp.org>
18943
18944         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
18945         * config/config.rpath: Upgrade to gettext-0.12.1.
18946
18947 2003-05-30  Bruno Haible  <bruno@clisp.org>
18948
18949         * m4/gettext.m4: Upgrade to gettext-0.12.1.
18950         * m4/nls.m4: New file, from gettext-0.12.1.
18951         * m4/po.m4: New file, from gettext-0.12.1.
18952         * m4/progtest.m4: Upgrade to gettext-0.12.1.
18953
18954 2003-05-30  Bruno Haible  <bruno@clisp.org>
18955
18956         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
18957         * lib/localcharset.h: Likewise.
18958         * lib/localcharset.c: Likewise.
18959
18960 2003-05-29  Karl Berry  <karl@gnu.org>
18961
18962         * config/config.rpath: update from gettext.
18963
18964 2003-05-28  Paul Eggert  <eggert@twinsun.com>
18965
18966         Assume the headers required for C89 freestanding compilers.
18967         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
18968         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
18969         * m4/human.m4 (gl_HUMAN): Likewise.
18970         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
18971         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
18972         * m4/userspec.m4 (gl_USERSPEC): Likewise.
18973         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
18974         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
18975         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
18976
18977 2003-05-28  Paul Eggert  <eggert@twinsun.com>
18978
18979         Assume the headers required for C89 freestanding compilers.
18980         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
18981         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
18982         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
18983         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
18984         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
18985         define, since <limits.h> is guaranteed to do that.
18986         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
18987         * lib/exclude.c: Include <stdbool.h> unconditionally.
18988         * lib/tempname.c: Include <stddef.h> unconditionally.
18989         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
18990         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
18991         <stddef.h> does that.
18992         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
18993         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
18994         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
18995         needed.
18996         * lib/xstrtol.c: Likewise.
18997         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
18998         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
18999
19000         * lib/addext.c (addext): Use assignment rather than cast, to avoid
19001         warnings on some platforms.
19002
19003         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19004         arbitrarily.
19005
19006 2003-05-26  Jim Meyering  <jim@meyering.net>
19007
19008         Merge in a change from coreutils:
19009         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
19010         that is guaranteed to be `no'.  Use `no_such_member' to indicate
19011         that condition, rather than `-1' which is slightly misleading.
19012         Change the name of the cache variable to have the gl_ prefix.
19013         Prompted by a patch from Richard Dawe for DJGPP.
19014
19015 2003-05-24  Karl Berry  <karl@gnu.org>
19016
19017         * config/config.guess: update from prep.
19018
19019 2003-05-22  Karl Berry  <karl@gnu.org>
19020
19021         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
19022
19023 2003-05-20  Karl Berry  <karl@gnu.org>
19024
19025         * config/config.guess: update from prep.
19026
19027 2003-05-18  Karl Berry  <karl@gnu.org>
19028
19029         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
19030         might actually be set by the user.
19031
19032         * config/depcomp, install-sh, mdate-sh: update from automake.
19033
19034 2003-05-17  Bruno Haible  <bruno@clisp.org>
19035
19036         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
19037         invalid expansion for AC_EGREP_CPP.
19038         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
19039         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
19040         Suggested by Akim Demaille <akim@epita.fr> in
19041         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
19042
19043 2003-05-12  Jim Meyering  <jim@meyering.net>
19044
19045         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
19046         the space-padded-by-default conversion specifiers, %e, %k, %l.
19047
19048 2003-05-12  Bruno Haible  <bruno@clisp.org>
19049
19050         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
19051         the string is longer than 4 KB.
19052
19053 2003-05-11  Karl Berry  <karl@gnu.org>
19054
19055         * config/config.{guess,sub}: update from prep.
19056
19057 2003-05-09  Bruno Haible  <bruno@clisp.org>
19058
19059         * modules/error: Add m4/strerror_r.m4 to file list.
19060
19061 2003-05-03  Bruno Haible  <bruno@clisp.org>
19062
19063         Upgrade to Unicode-4.0.
19064         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
19065         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
19066         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
19067         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
19068         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
19069         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
19070         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
19071         Change width of U+E0100..U+E01EF from 1 to 0.
19072
19073 2003-04-25  Jim Meyering  <jim@meyering.net>
19074
19075         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
19076         of type size_t, not int.
19077
19078 2003-04-25  Bruno Haible  <bruno@clisp.org>
19079
19080         * lib/copy-file.c: Include <stddef.h>, for size_t.
19081
19082 2003-04-21  Paul Eggert  <eggert@twinsun.com>
19083
19084         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
19085         code which expansion is under static control.  Patch imported from
19086         Akim Demaille's patch to Bison; see
19087         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
19088
19089 2003-04-14  Bruno Haible  <bruno@clisp.org>
19090
19091         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
19092
19093 2003-04-11  Jim Meyering  <jim@meyering.net>
19094
19095         Merge changes from Coreutils.
19096
19097         2003-03-22  Jim Meyering  <jim@meyering.net>
19098
19099         * lib/strftime.c (widen): Cast alloca return value to proper type.
19100
19101         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
19102
19103         From GNU libc.
19104         * lib/strftime.c (my_strftime): Handle very large width
19105         specifications for numeric values correctly.  Improve checks for
19106         overflow.
19107
19108         2003-01-19  Jim Meyering  <jim@meyering.net>
19109
19110         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
19111         definitions.
19112         (nl_get_alt_digit) [! defined my_strftime]: Define.
19113         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
19114         _nl_get_alt_digit and _nl_get_walt_digit.
19115
19116         * lib/strftime.c (my_strftime): Merge in locale-related changes from
19117         libc. These changes have no effect outside of _LIBC.
19118
19119 2003-04-10  Bruno Haible  <bruno@clisp.org>
19120
19121         * modules/findprog: New file.
19122         * MODULES.html.sh (func_all_modules): Add it.
19123
19124 2003-04-10  Bruno Haible  <bruno@clisp.org>
19125
19126         * m4/findprog.m4: New file.
19127         * m4/eaccess.m4: New file.
19128
19129 2003-04-10  Bruno Haible  <bruno@clisp.org>
19130
19131         * lib/findprog.h: New file, from GNU gettext.
19132         * lib/findprog.c: New file, from GNU gettext.
19133
19134 2003-04-05  Jim Meyering  <jim@meyering.net>
19135
19136         Merge changes from Coreutils.
19137
19138         * lib/exclude.h (PARAMS): Remove definition and uses.
19139         * lib/exclude.c: Remove uses of `PARAMS'.
19140
19141         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
19142         Add test-cases for DOS filenames. Declare program_name.
19143         (main): Set up program_name.  Patch by Rich Dawe.
19144
19145         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19146         error from mntctl.
19147         Use mntctl's return value to drive the entry-processing loop, since
19148         we can't rely on the value of the vmt_length member in the last
19149         entry.  On some systems doing so could result in exhausting
19150         virtual memory.  Based in part on a patch from Mike Jetzer.
19151
19152 2003-04-04  Bruno Haible  <bruno@clisp.org>
19153
19154         * modules/linebreak: New file.
19155         * MODULES.html.sh (func_all_modules): Add it.
19156
19157 2003-04-04  Bruno Haible  <bruno@clisp.org>
19158
19159         * m4/linebreak.m4: New file.
19160
19161 2003-04-04  Bruno Haible  <bruno@clisp.org>
19162
19163         * lib/linebreak.h: New file, from GNU gettext.
19164         * lib/linebreak.c: New file, from GNU gettext with slight
19165         modifications.
19166         * lib/lbrkprop.h: New file, from GNU gettext.
19167
19168 2003-04-03  Bruno Haible  <bruno@clisp.org>
19169
19170         * modules/utf8-ucs4: New file.
19171         * modules/utf16-ucs4: New file.
19172         * modules/ucs4-utf8: New file.
19173         * modules/ucs4-utf16: New file.
19174         * MODULES.html.sh (func_all_modules): Add them.
19175
19176 2003-04-03  Bruno Haible  <bruno@clisp.org>
19177
19178         * m4/utf-ucs4.m4: New file.
19179         * m4/ucs4-utf.m4: New file.
19180
19181 2003-04-03  Bruno Haible  <bruno@clisp.org>
19182
19183         * lib/utf8-ucs4.h: New file, from GNU gettext.
19184         * lib/utf16-ucs4.h: New file, from GNU gettext.
19185         * lib/ucs4-utf8.h: New file, from GNU gettext.
19186         * lib/ucs4-utf16.h: New file, from GNU gettext.
19187
19188 2003-04-02  Bruno Haible  <bruno@clisp.org>
19189
19190         * modules/binary-io: New file.
19191         * MODULES.html.sh (func_all_modules): Add it.
19192
19193 2003-04-02  Bruno Haible  <bruno@clisp.org>
19194
19195         * lib/binary-io.h: New file, from GNU gettext.
19196
19197 2003-04-01  Bruno Haible  <bruno@clisp.org>
19198
19199         * modules/pathname: New file.
19200         * MODULES.html.sh (func_all_modules): Add it.
19201
19202 2003-04-01  Bruno Haible  <bruno@clisp.org>
19203
19204         * lib/pathname.h: New file, from GNU gettext.
19205         * lib/concatpath.c: New file, from GNU gettext.
19206
19207 2003-03-30  Bruno Haible  <bruno@clisp.org>
19208
19209         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
19210
19211 2003-03-30  Bruno Haible  <bruno@clisp.org>
19212
19213         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
19214         function chown() doesn't exist.
19215
19216 2003-03-28  Bruno Haible  <bruno@clisp.org>
19217
19218         * modules/copy-file: New file.
19219         * MODULES.html.sh (func_all_modules): Add it.
19220
19221 2003-03-28  Bruno Haible  <bruno@clisp.org>
19222
19223         * m4/copy-file.m4: New file.
19224
19225 2003-03-28  Bruno Haible  <bruno@clisp.org>
19226
19227         * lib/copy-file.h: New file, from GNU gettext.
19228         * lib/copy-file.c: New file, from GNU gettext.
19229
19230 2003-03-18  Jim Meyering  <jim@meyering.net>
19231
19232         * lib/quote.c (quote_n): Fix typo in comment.
19233
19234 2003-03-18  Bruno Haible  <bruno@clisp.org>
19235
19236         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
19237         checking.
19238         * m4/onceonly_2_57.m4: Likewise.
19239
19240 2003-03-17  Bruno Haible  <bruno@clisp.org>
19241
19242         * m4/onceonly.m4: Require autoconf 2.54 or newer.
19243         (m4_quote): Remove macro.
19244         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
19245
19246 2003-03-14  Jim Meyering  <jim@meyering.net>
19247
19248         Merge changes from Coreutils.
19249         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
19250         to be const, in order to avoid warnings.
19251         (obstack_room): Likewise.
19252         (obstack_empty_p): Likewise.
19253
19254 2003-03-14  Bruno Haible  <bruno@clisp.org>
19255
19256         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
19257         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
19258
19259 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19260
19261         Merge changes from Bison.
19262         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
19263         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
19264         when compiling Bison 1.875's `bitset bset = obstack_alloc
19265         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
19266         * lib/hash.c: Include <stdbool.h> unconditionally.
19267
19268 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19269
19270         * m4/onceonly.m4 (m4_quote): New macro.
19271         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
19272         Quote AC_FOREACH variable-expansions properly.
19273
19274 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19275
19276         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
19277
19278 2003-03-09  Paul Eggert  <eggert@twinsun.com>
19279
19280         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
19281         Reported by Bruce Becker; see:
19282         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
19283
19284 2003-03-03  Paul Eggert  <eggert@twinsun.com>
19285             Bruno Haible  <bruno@clisp.org>
19286
19287         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
19288         Reported by John Hughes, see
19289         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
19290
19291 2003-02-20  Bruno Haible  <bruno@clisp.org>
19292
19293         * MODULES.html.sh (func_all_modules): Add poll.
19294
19295 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19296
19297         * modules/poll: New file.
19298
19299 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19300
19301         * lib/poll_.h: New file.
19302         * lib/poll.c: New file.
19303
19304 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19305
19306         * m4/poll.m4: New file.
19307
19308 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19309
19310         * modules/mathl: New file.
19311
19312 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19313
19314         * lib/mathl.h: New file.
19315         * lib/acosl.c: New file.
19316         * lib/asinl.c: New file.
19317         * lib/atanl.c: New file.
19318         * lib/ceill.c: New file.
19319         * lib/cosl.c: New file.
19320         * lib/expl.c: New file.
19321         * lib/floorl.c: New file.
19322         * lib/frexpl.c: New file.
19323         * lib/ldexpl.c: New file.
19324         * lib/logl.c: New file.
19325         * lib/sincosl.c: New file.
19326         * lib/sinl.c: New file.
19327         * lib/sqrtl.c: New file.
19328         * lib/tanl.c: New file.
19329         * lib/trigl.c: New file.
19330         * lib/trigl.h: New file.
19331
19332 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19333
19334         * m4/mathl.m4: New file.
19335
19336 2003-02-18  Bruno Haible  <bruno@clisp.org>
19337
19338         * MODULES.html.sh (func_all_modules): Add mathl.
19339
19340 2003-02-17  Bruno Haible  <bruno@clisp.org>
19341
19342         * modules/mkdtemp: New module.
19343         * MODULES.html.sh (func_all_modules): Add it.
19344
19345 2003-02-17  Bruno Haible  <bruno@clisp.org>
19346
19347         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
19348
19349 2003-02-17  Bruno Haible  <bruno@clisp.org>
19350
19351         * lib/mkdtemp.h: New file, from GNU gettext.
19352         * lib/mkdtemp.c: New file, from GNU gettext.
19353
19354 2003-02-02  Jim Meyering  <jim@meyering.net>
19355
19356         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
19357         e.g. glibc-2.2.93.
19358
19359 2003-01-31  Bruno Haible  <bruno@clisp.org>
19360
19361         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
19362         'rpl_rename'.
19363         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
19364         'rpl_strnlen'.
19365         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
19366         'rpl_strtod'.
19367         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
19368         'rpl_utime'.
19369
19370 2003-01-31  Bruno Haible  <bruno@clisp.org>
19371
19372         * lib/rename.c: #undef rename before defining rpl_rename.
19373         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
19374
19375 2003-01-30  Bruno Haible  <bruno@clisp.org>
19376
19377         * modules/vasnprintf, modules/vasprintf: New modules.
19378         * MODULES.html.sh (func_all_modules): Add them.
19379
19380 2003-01-30  Bruno Haible  <bruno@clisp.org>
19381
19382         * m4/signed.m4: New file, from GNU gettext.
19383         * m4/longdouble.m4: New file, from GNU gettext.
19384         * m4/wchar_t.m4: New file, from GNU gettext.
19385         * m4/wint_t.m4: New file, from GNU gettext.
19386         * m4/vasnprintf.m4: New file.
19387         * m4/vasprintf.m4: New file.
19388
19389 2003-01-30  Bruno Haible  <bruno@clisp.org>
19390
19391         * lib/printf-args.h: New file, from GNU gettext.
19392         * lib/printf-args.c: New file, from GNU gettext.
19393         * lib/printf-parse.h: New file, from GNU gettext.
19394         * lib/printf-parse.c: New file, from GNU gettext.
19395         * lib/vasnprintf.h: New file, from GNU gettext.
19396         * lib/vasnprintf.c: New file, from GNU gettext.
19397         * lib/asnprintf.c: New file, from GNU gettext.
19398         * lib/vasprintf.h: New file, from GNU gettext with modifications.
19399         * lib/vasprintf.c: New file, from GNU gettext.
19400         * lib/asprintf.c: New file, from GNU gettext.
19401
19402 2003-01-29  Bruno Haible  <bruno@clisp.org>
19403
19404         * modules/stpncpy: New module.
19405         * MODULES.html.sh (func_all_modules): Add it.
19406
19407 2003-01-29  Bruno Haible  <bruno@clisp.org>
19408
19409         * m4/stpncpy.m4: New file.
19410
19411 2003-01-29  Bruno Haible  <bruno@clisp.org>
19412
19413         * lib/stpncpy.h: New file, from GNU gettext with modifications.
19414         * lib/stpncpy.c: New file, from GNU gettext with modifications.
19415
19416 2003-01-28  Bruno Haible  <bruno@clisp.org>
19417
19418         * modules/c-ctype: New module.
19419         * MODULES.html.sh (func_all_modules): Add it.
19420
19421 2003-01-28  Bruno Haible  <bruno@clisp.org>
19422
19423         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
19424         Paul Eggert.
19425         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
19426         Paul Eggert.
19427
19428 2003-01-27  Bruno Haible  <bruno@clisp.org>
19429
19430         * modules/xsetenv: New module.
19431         * MODULES.html.sh (func_all_modules): Add it.
19432
19433 2003-01-27  Bruno Haible  <bruno@clisp.org>
19434
19435         * lib/xsetenv.h: New file, from GNU gettext.
19436         * lib/xsetenv.c: New file, from GNU gettext.
19437
19438 2003-01-23  Jim Meyering  <jim@meyering.net>
19439
19440         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
19441         from working on systems without dirfd (at least Irix and OSF1/Tru64).
19442
19443 2003-01-23  Bruno Haible  <bruno@clisp.org>
19444
19445         * modules/minmax: New module.
19446         * MODULES.html.sh (func_all_modules): Add it.
19447
19448 2003-01-23  Bruno Haible  <bruno@clisp.org>
19449
19450         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
19451         Eggert.
19452
19453 2003-01-22  Bruno Haible  <bruno@clisp.org>
19454
19455         * modules/exit: New module.
19456         * MODULES.html.sh (func_all_modules): Add it.
19457
19458 2003-01-22  Bruno Haible  <bruno@clisp.org>
19459
19460         * lib/exit.h: New file, from GNU gettext.
19461
19462 2003-01-19  Bruno Haible  <bruno@clisp.org>
19463
19464         * gnulib-tool: Recognize option --extract-maintainer.
19465         (func_get_maintainer): New function.
19466         * modules/*: Add Maintainer entry.
19467
19468 2003-01-16  Jim Meyering  <jim@meyering.net>
19469
19470         * m4/regex.m4: The `regex' struct is both input and output.
19471         Initialize it before each use.  Patch by Tim Waugh.
19472
19473 2003-01-16  Bruno Haible  <bruno@clisp.org>
19474
19475         * MODULES.html.sh: Add a table of contents. Add the module name as
19476         leftmost column. Add hyperlinks.
19477
19478 2003-01-15  Bruno Haible  <bruno@clisp.org>
19479
19480         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
19481
19482 2003-01-15  Bruno Haible  <bruno@clisp.org>
19483
19484         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
19485         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
19486         suffix.
19487
19488 2003-01-15  Bruno Haible  <bruno@clisp.org>
19489
19490         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
19491
19492 2003-01-15  Bruno Haible  <bruno@clisp.org>
19493
19494         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
19495         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
19496
19497 2003-01-14  Jim Meyering  <jim@meyering.net>
19498
19499         * lib/same.c (same_name): Tweak a comment.
19500
19501 2003-01-14  Bruno Haible  <bruno@clisp.org>
19502
19503         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
19504         when a string comparison is sufficient.
19505
19506 2003-01-14  Bruno Haible  <bruno@clisp.org>
19507
19508         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
19509         'unsigned int'.
19510
19511 2003-01-14  Bruno Haible  <bruno@clisp.org>
19512
19513         * lib/hash-pjw.c: Add comment about low quality of this function.
19514
19515 2003-01-13  Bruno Haible  <bruno@clisp.org>
19516
19517         * modules/stpcpy: Distribute lib/stpcpy.h.
19518         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
19519
19520 2003-01-13  Bruno Haible  <bruno@clisp.org>
19521
19522         * modules/*: Add a description.
19523         * modules/strpbrk: Fix Makefile.am snippet.
19524         * modules/strtoimax: Fix dependencies.
19525         * modules/strtoumax: Likewise.
19526
19527 2003-01-13  Bruno Haible  <bruno@clisp.org>
19528
19529         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
19530         * modules/alloca (Makefile.am): All object files depend on alloca.h.
19531         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
19532
19533 2003-01-13  Bruno Haible  <bruno@clisp.org>
19534
19535         * gnulib-tool (func_create_testdir): Store config/* files in the main
19536         directory.
19537         * config.rpath: Move to ...
19538         * config/config.rpath: ... here.
19539         * modules/gettext: Contains config/config.rpath, not config.rpath.
19540         * modules/iconv: Likewise.
19541
19542 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19543
19544         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19545         to avoid collisions with libcurses and libreadline.
19546
19547         * m4/getstr.m4: Remove.
19548         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
19549
19550 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19551
19552         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19553         to avoid collisions with libcurses and libreadline.
19554
19555         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
19556         * lib/getstr.h, getstr.c: Remove.
19557         * lib/getline.c: Include "getline.h", to check interface.
19558         Move body of old getstr.c here: this defines MIN_CHUNK and
19559         declares getdelim2, which is renamed from getstr.
19560         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
19561
19562         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
19563         All uses changed.
19564         * lib/linebuffer.h: Likewise.
19565         (readline): Remove backward-compatibility macro.
19566
19567 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19568
19569         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19570         to avoid collisions with libcurses and libreadline.
19571         * getstr: Remove.
19572         * MODULES.html.sh: Remove getstr.
19573         * modules/getline: Depend on unlocked-io, not getstr.
19574
19575 2003-01-12  Jim Meyering  <jim@meyering.net>
19576
19577         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
19578
19579 2003-01-10  Bruno Haible  <bruno@clisp.org>
19580
19581         * modules/alloca: Change Makefile.am requirements. Simplify Include
19582         requirements. Add lib/alloca_.h to file list.
19583
19584 2003-01-10  Bruno Haible  <bruno@clisp.org>
19585
19586         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
19587
19588 2003-01-10  Bruno Haible  <bruno@clisp.org>
19589
19590         * lib/alloca_.h: New file.
19591         * lib/getdate.y: Unconditionally include alloca.h.
19592         * lib/makepath.c: Likewise.
19593         * lib/setenv.c: Likewise.
19594         * lib/userspec.c: Likewise.
19595
19596 2003-01-09  Karl Berry  <karl@gnu.org>
19597
19598         * MODULES.html.sh: include `dirname $0` in PATH, to find
19599         gnulib-tool.
19600
19601 2003-01-09  Bruno Haible  <bruno@clisp.org>
19602
19603         * modules/stdbool: Change configure.ac, Makefile.am requirements.
19604         Simplify Include requirements. Add lib/stdbool.h.in to file list.
19605
19606 2003-01-09  Bruno Haible  <bruno@clisp.org>
19607
19608         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
19609
19610 2003-01-09  Bruno Haible  <bruno@clisp.org>
19611
19612         * lib/stdbool.h.in: New file.
19613
19614 2003-01-09  Bruno Haible  <bruno@clisp.org>
19615
19616         * gnulib-tool (func_all_modules): Ignore files ending in ~.
19617         * MODULES.html.sh: Likewise.
19618
19619 2003-01-08  Jim Meyering  <jim@meyering.net>
19620
19621         * lib/full-write.c: Undefine and define-away `const' after inclusion
19622         of errno.h, not before.  Suggestion from Bruno Haible.
19623
19624 2003-01-08  Bruno Haible  <bruno@clisp.org>
19625
19626         * modules/full-read: Depend on full-write.
19627
19628 2003-01-08  Bruno Haible  <bruno@clisp.org>
19629
19630         * lib/safe-read.c: Include specification header first, to ensure its
19631         selfcontainedness.
19632         * lib/full-write.c: Likewise.
19633
19634 2003-01-07  Jim Meyering  <jim@meyering.net>
19635
19636         * lib/full-write.c: Rework so that it may serve to define full_read,
19637         too.
19638         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
19639
19640 2003-01-07  Bruno Haible  <bruno@clisp.org>
19641
19642         * lib/strtoimax.c: Include <stdint.h> as an alternative to
19643         <inttypes.h>.
19644         * lib/xstrtol.h: Likewise.
19645         * lib/xstrtoimax.c: Likewise.
19646         * lib/xstrtoumax.c: Likewise.
19647         * lib/human.h: Likewise.
19648
19649         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
19650         on systems that have <inttypes.h> but not <stdint.h>.
19651
19652 2003-01-07  Bruno Haible  <bruno@clisp.org>
19653
19654         * MODULES.html.sh: Add copyright notice.
19655         (missed_files): Omit CVS directory entries.
19656         (func_module): Make it work with sed-3.02.
19657         * MODULES.txt: Remove file.
19658
19659 2003-01-06  Jim Meyering  <jim@meyering.net>
19660
19661         * lib/version-etc.c: Update year in translatable copyright string.
19662
19663 2003-01-03  Karl Berry  <karl@gnu.org>
19664
19665         * config/config.{guess,sub}: update from prep.
19666
19667 2003-01-02  Karl Berry  <karl@gnu.org>
19668
19669         * doc/COPYING.DOC: belatedly updated to 1.2.
19670
19671 2003-01-01  Karl Berry  <karl@gnu.org>
19672
19673         * gnulib-tool (func_verify_module): report module name $module in
19674         error message, not $1.
19675         * gnulib-tool (create-testdir): don't complain if destdir couldn't
19676         be created, only if it doesn't exist.
19677         * gnulib-tool (last_checkin_date): don't expand the $Date here.
19678
19679 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19680
19681         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
19682
19683 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19684
19685         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
19686         memcmp if strcoll doesn't work.
19687
19688 2002-12-31  Bruno Haible  <bruno@clisp.org>
19689
19690         * lib/utime.c (utime_null): No need to call ftruncate if the file was
19691         nonempty.
19692
19693 2002-12-31  Bruno Haible  <bruno@clisp.org>
19694
19695         * lib/memcoll.c (STRCOLL): New macro.
19696         (memcoll): Use it.
19697
19698 2002-12-31  Bruno Haible  <bruno@clisp.org>
19699
19700         * lib/localcharset.h: New file.
19701         * lib/localcharset.c: Include it.
19702         * lib/unicodeio.c: Likewise.
19703
19704 2002-12-31  Bruno Haible  <bruno@clisp.org>
19705
19706         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
19707         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
19708
19709 2002-12-31  Bruno Haible  <bruno@clisp.org>
19710
19711         * lib/getline.h: Include <stddef.h>, for size_t.
19712
19713         * lib/unicodeio.h: Include <stddef.h>, for size_t.
19714         * lib/unicodeio.c: Don't include <stddef.h>.
19715
19716 2002-12-31  Bruno Haible  <bruno@clisp.org>
19717
19718         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
19719         HAVE_TM_ZONE.
19720
19721 2002-12-24  Karl Berry  <karl@gnu.org>
19722
19723         * config/config.guess: update from prep.
19724
19725 2002-12-24  Bruno Haible  <bruno@clisp.org>
19726
19727         General infrasructure.
19728         * m4/README: Rewritten.
19729         * m4/onceonly.m4: New file.
19730         * m4/onceonly_2_57.m4: New file.
19731
19732         Module atexit.
19733         * m4/atexit.m4: New file.
19734
19735         Module strtod.
19736         * m4/strtod.m4: New file.
19737
19738         Module strtol.
19739         * m4/strtol.m4: New file.
19740
19741         Module strtoul.
19742         * m4/strtoul.m4: New file.
19743
19744         Module memchr.
19745         * m4/memchr.m4: New file.
19746
19747         Module memcmp.
19748         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
19749         (jm_FUNC_MEMCMP): Invoke it.
19750
19751         Module memcpy.
19752         * m4/memcpy.m4: New file.
19753
19754         Module memmove.
19755         * m4/memmove.m4: New file.
19756
19757         Module memset.
19758         * m4/memset.m4: New file.
19759
19760         Module strcspn.
19761         * m4/strcspn.m4: New file.
19762
19763         Module strpbrk.
19764         * m4/strpbrk.m4: New file.
19765
19766         Module strstr.
19767         * m4/strstr.m4: New file.
19768
19769         Module strerror.
19770         * m4/strerror.m4: New file.
19771
19772         Module mktime.
19773         * m4/mktime.m4: Renamed from jm-mktime.m4.
19774         (gl_PREREQ_MKTIME): New macro.
19775         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
19776
19777         Module malloc.
19778         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
19779         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
19780         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
19781
19782         Module realloc.
19783         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
19784         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
19785         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
19786
19787         Module strftime.
19788         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
19789         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
19790         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
19791         gl_TM_GMTOFF.
19792         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
19793
19794         Module xalloc.
19795         * m4/xalloc.m4: New file.
19796
19797         Module alloca.
19798         * m4/alloca.m4: New file.
19799
19800         Module putenv.
19801         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
19802         (jm_FUNC_PUTENV): Invoke it.
19803
19804         Module setenv.
19805         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
19806         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
19807         when invoked twice.
19808         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
19809         gt_FUNC_SETENV.
19810
19811         Module memrchr.
19812         * m4/memrchr.m4: New file.
19813
19814         Module stpcpy.
19815         * m4/stpcpy.m4: New file.
19816
19817         Module strcase.
19818         * m4/strcase.m4: New file.
19819
19820         Module strdup.
19821         * m4/strdup.m4: New file.
19822
19823         Module strnlen.
19824         * m4/strnlen.m4: New file.
19825
19826         Module strndup.
19827         * m4/strndup.m4: New file.
19828
19829         Module xstrtod.
19830         * m4/xstrtod.m4: New file.
19831
19832         Module xstrtol.
19833         * m4/xstrtol.m4: New file.
19834
19835         Module getdate.
19836         * m4/getdate.m4: New file.
19837
19838         Module unlocked-io.
19839         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
19840         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
19841         * m4/jm-glibc-io.m4n: Remove file.
19842
19843         Module long-options.
19844         * m4/long-options.m4: New file.
19845
19846         Module md5.
19847         * m4/md5.m4: New file.
19848
19849         Module sha.
19850         * m4/sha.m4: New file.
19851
19852         Module getstr.
19853         * m4/getstr.m4: New file.
19854
19855         Module getline.
19856         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
19857         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
19858         <sys/types.h>, for size_t. Use the function name gnu_getline, not
19859         simply getline. Infoke gl_PREREQ_GETLINE.
19860
19861         Module obstack.
19862         * m4/obstack.m4: New file.
19863
19864         Module hash.
19865         * m4/hash.m4: New file.
19866
19867         Module readtokens.
19868         * m4/readtokens.m4: New file.
19869
19870         Module strverscmp.
19871         * m4/strverscmp.m4: New file.
19872
19873         Module stdbool.
19874         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
19875         OSF/1.
19876
19877         Module strtoll.
19878         * m4/strtoll.m4: New file.
19879
19880         Module strtoull.
19881         * m4/strtoull.m4: New file.
19882
19883         Module strtoimax.
19884         * m4/strtoimax.m4: New file.
19885
19886         Module strtoumax.
19887         * m4/strtoumax.m4: New file.
19888
19889         Module xstrtoimax.
19890         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
19891         jm_AC_PREREQ_XSTRTOIMAX.
19892         Moved the strtol prerequisites to strtol.m4.
19893         Moved the strtoll prerequisites to strtoll.m4.
19894         Moved the strtoimax prerequisites to strtoimax.m4.
19895
19896         Module xstrtoumax.
19897         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
19898         jm_AC_PREREQ_XSTRTOUMAX.
19899         Moved the strtoul prerequisites to strtoul.m4.
19900         Moved the strtoull prerequisites to strtoull.m4.
19901         Moved the strtoumax prerequisites to strtoumax.m4.
19902
19903         Module chown.
19904         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
19905         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
19906
19907         Module dup2.
19908         * m4/dup2.m4: New file.
19909
19910         Module ftruncate.
19911         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
19912         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
19913
19914         Module getgroups.
19915         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
19916         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
19917
19918         Module gettimeofday.
19919         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
19920         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
19921         gl_PREREQ_GETTIMEOFDAY.
19922
19923         Module mkdir.
19924         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
19925         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
19926
19927         Module mkstemp.
19928         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
19929         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
19930         jm_AC_TYPE_UINTMAX_T.
19931         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
19932
19933         Module stat.
19934         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
19935         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
19936
19937         Module lstat.
19938         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
19939         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
19940
19941         Module timespec.
19942         * m4/timespec.m4 (gl_TIMESPEC): New macro.
19943         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
19944         * m4/st_mtim.m4: Indentation.
19945
19946         Module nanosleep.
19947         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
19948         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
19949         gl_PREREQ_NANOSLEEP.
19950
19951         Module regex.
19952         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
19953         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
19954         (gl_REGEX): New macro.
19955
19956         Module rename.
19957         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
19958         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
19959
19960         Module rmdir.
19961         * m4/rmdir.m4: New file.
19962
19963         Module utime.
19964         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
19965         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
19966         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
19967
19968         Module dirname.
19969         * m4/dirname.m4: New file.
19970
19971         Module getopt.
19972         * m4/getopt.m4: New file.
19973
19974         Module unistd-safer.
19975         * m4/unistd-safer.m4: New file.
19976
19977         Module fnmatch.
19978         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
19979         declaration.
19980         (gl_PREREQ_FNMATCH_EXTRA): New macro.
19981         (gl_FUNC_FNMATCH_POSIX): New macro.
19982         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
19983         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
19984         simply fnmatch.
19985
19986         Module exclude.
19987         * m4/exclude.m4: New file.
19988
19989         Module human.
19990         * m4/human.m4: New file.
19991
19992         Module acl.
19993         * m4/acl.m4: Nop.
19994
19995         Module backupfile.
19996         * m4/backupfile.m4: New file.
19997         * m4/d-ino.m4: Indentation.
19998
19999         Module fsusage.
20000         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
20001         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
20002         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
20003
20004         Module dirfd.
20005         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
20006         requirements.
20007
20008         Module euidaccess.
20009         * m4/euidaccess.m4: New file.
20010
20011         Module file-type.
20012         * m4/file-type.m4: New file.
20013
20014         Module fileblocks.
20015         * m4/fileblocks.m4: New file.
20016
20017         Module filemode.
20018         * m4/filemode.m4: New file.
20019
20020         Module isdir.
20021         * m4/isdir.m4: New file.
20022
20023         Module lchown.
20024         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
20025         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
20026
20027         Module makepath.
20028         * m4/makepath.m4: New file.
20029
20030         Module modechange.
20031         * m4/modechange.m4: New file.
20032
20033         Module mountlist.
20034         * m4/mountlist.m4: New file.
20035         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
20036         Indentation.
20037
20038         Module path-concat.
20039         * m4/path-concat.m4: New file.
20040
20041         Module pathmax.
20042         * m4/pathmax.m4: New file.
20043
20044         Module same.
20045         * m4/same.m4: New file.
20046
20047         Module save-cwd.
20048         * m4/save-cwd.m4: New file.
20049
20050         Module savedir.
20051         * m4/savedir.m4: New file.
20052
20053         Module xgetcwd.
20054         * m4/xgetcwd.m4: New file.
20055         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
20056
20057         Module xreadlink.
20058         * m4/xreadlink.m4: New file.
20059
20060         Module safe-read.
20061         * m4/safe-read.m4: New file.
20062
20063         Module safe-write.
20064         * m4/safe-write.m4: New file.
20065
20066         Module closeout.
20067         * m4/closeout.m4: New file.
20068
20069         Module stdio-safer.
20070         * m4/stdio-safer.m4: New file.
20071
20072         Module getpass.
20073         * m4/getpass.m4: New file.
20074
20075         Module getugroups.
20076         * m4/getugroups.m4: New file.
20077
20078         Module group-member.
20079         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
20080         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
20081
20082         Module idcache.
20083         * m4/idcache.m4: New file.
20084
20085         Module userspec.
20086         * m4/userspec.m4: New file.
20087
20088         Module gettime.
20089         * m4/clock_time.m4: New file.
20090         * m4/gettime.m4: New file.
20091
20092         Module settime.
20093         * m4/settime.m4: New file.
20094
20095         Module posixtm.
20096         * m4/posixtm.m4: New file.
20097
20098         Module gethostname.
20099         * m4/gethostname.m4: New file.
20100
20101         Module canon-host.
20102         * m4/canon-host.m4: New file.
20103
20104         Module gettext.
20105         * m4/codeset.m4: New file, from gettext-0.11.5.
20106         * m4/gettext.m4: New file, from gettext-0.11.5.
20107         * m4/glibc21.m4: New file, from gettext-0.11.5.
20108         * m4/iconv.m4: New file, from gettext-0.11.5.
20109         * m4/intdiv0.m4: New file, from gettext-0.11.5.
20110         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
20111         * m4/inttypes.m4: New file, from gettext-0.11.5.
20112         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
20113         * m4/isc-posix.m4: New file, from gettext-0.11.5.
20114         * m4/lcmessage.m4: New file, from gettext-0.11.5.
20115         * m4/lib-ld.m4: New file, from gettext-0.11.5.
20116         * m4/lib-link.m4: New file, from gettext-0.11.5.
20117         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
20118         * m4/progtest.m4: New file, from gettext-0.11.5.
20119         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
20120         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
20121         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
20122
20123         Module localcharset.
20124         * m4/localcharset.m4: New file.
20125
20126         Module hard-locale.
20127         * m4/hard-locale.m4: New file.
20128
20129         Module mbswidth.
20130         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
20131         onceonly macros.
20132         * m4/mbrtowc.m4: Add comment.
20133
20134         Module memcasecmp.
20135         * m4/memcasecmp.m4: New file.
20136
20137         Module memcoll.
20138         * m4/memcoll.m4: New file.
20139
20140         Module unicodeio.
20141         * m4/unicodeio.m4: New file.
20142
20143         Module rpmatch.
20144         * m4/rpmatch.m4: New file.
20145
20146         Module yesno.
20147         * m4/yesno.m4: New file.
20148
20149         Module exitfail.
20150         * m4/exitfail.m4: New file.
20151
20152         Module c-stack.
20153         * m4/c-stack.m4 (gl_C_STACK): New macro.
20154         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
20155
20156         Module error.
20157         * m4/error.m4 (gl_ERROR): New macro.
20158         (jm_PREREQ_ERROR): Use onceonly macros.
20159
20160         Module fatal.
20161         * m4/fatal.m4: New file.
20162
20163         Module getloadavg.
20164         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
20165         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
20166
20167         Module getpagesize.
20168         * m4/getpagesize.m4: New file.
20169
20170         Module getusershell.
20171         * m4/getusershell.m4: New file.
20172
20173         Module physmem.
20174         * m4/physmem.m4: New file.
20175
20176         Module posixver.
20177         * m4/posixver.m4: New file.
20178
20179         Module quotearg.
20180         * m4/quotearg.m4: New file.
20181
20182         Module quote.
20183         * m4/quote.m4: New file.
20184
20185         Module readutmp.
20186         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
20187
20188         Module sig2str.
20189         * m4/sig2str.m4: New file.
20190
20191         Other.
20192         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
20193         ulonglong.m4.
20194         * m4/intmax_t.m4: New file.
20195         * m4/d-type.m4: Indentation.
20196         * m4/jm-macros.m4: Update.
20197         * m4/prereq.m4 (jm_PREREQ): Update.
20198         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
20199         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
20200         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
20201         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
20202         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
20203         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
20204         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
20205         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
20206         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
20207         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
20208         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
20209         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
20210         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
20211         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
20212         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
20213         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
20214         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
20215         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
20216         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
20217
20218 2002-12-24  Bruno Haible  <bruno@clisp.org>
20219
20220         * MODULES.txt: Update according to m4/ changes.
20221
20222         Module gettext.
20223         * config.rpath: New file, from gettext-0.11.5.
20224
20225         * modules/*: New module descriptions.
20226         * gnulib-tool: New file.
20227         * MODULES.html.sh: New file.
20228
20229 2002-12-21  Karl Berry  <karl@gnu.org>
20230
20231         * doc/fdl.texi: update to version 1.2.
20232
20233 2002-12-19  Karl Berry  <karl@gnu.org>
20234
20235         * config/config.guess: update from prep.
20236
20237 2002-12-18  Bruno Haible  <bruno@clisp.org>
20238
20239         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
20240         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
20241
20242 2002-12-17  Bruno Haible  <bruno@clisp.org>
20243
20244         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
20245         stdlib.h, string.h.
20246
20247 2002-12-17  Bruno Haible  <bruno@clisp.org>
20248
20249         * lib/canon-host.c (strdup): Remove unused declaration.
20250
20251         * lib/fsusage.c: Include full_read.h.
20252         (get_fs_usage): Use full_read instead of safe_read.
20253
20254         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
20255
20256 2002-12-12  Karl Berry  <karl@gnu.org>
20257
20258         * config/config.guess: update from prep.
20259
20260 2002-12-11  Bruno Haible  <bruno@clisp.org>
20261
20262         * m4/setenv.m4: New file, from gettext-0.11.5.
20263
20264 2002-12-11  Bruno Haible  <bruno@clisp.org>
20265
20266         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
20267         not unsetenv().
20268         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
20269         modifications:
20270
20271         2002-12-11  Bruno Haible  <bruno@clisp.org>
20272
20273                 * setenv.c (alloca): Fall back to malloc.
20274                 (freea): New macro.
20275                 (setenv): Use freea() to free memory allocated with alloca().
20276
20277         2002-11-13  Bruno Haible  <bruno@clisp.org>
20278
20279                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
20280                 function declarations.
20281                 * unsetenv.c (unsetenv): Likewise.
20282
20283         2002-03-04  Bruno Haible  <bruno@clisp.org>
20284
20285                 Portability to AIX 4.3.3.
20286                 * unsetenv.c: New file, extracted from setenv.c.
20287                 * setenv.c: Move the unsetenv() function to unsetenv.c.
20288
20289         2001-12-20  Bruno Haible  <bruno@clisp.org>
20290
20291                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
20292                 use malloc instead. For SunOS 4.
20293
20294         2001-12-11  Bruno Haible  <bruno@clisp.org>
20295
20296                 * setenv.c: Declare alloca.
20297                 (compar_fn_t): New typedef.
20298                 (KNOWN_VALUE, STORE_VALUE): Use it.
20299
20300         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
20301         setenv.h.
20302
20303 2002-12-10  Paul Eggert  <eggert@twinsun.com>
20304
20305         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
20306         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
20307         Choose values that are less likely to collide with system fnmatch
20308         options.
20309         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
20310         defined (e.g., a pure POSIX system).
20311         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
20312         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
20313
20314 2002-12-06  Paul Eggert  <eggert@twinsun.com>
20315
20316         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
20317         a pain in practice to deal with generated m4 files.  This change
20318         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
20319
20320         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
20321         and jm-glibc-io.m4, as they are no longer a special case.
20322         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
20323         kludge and the auto-generation stuff.  Check only whether the
20324         functions are declared, not whether they exist, since older hosts
20325         that don't declare the functions can't use the optimization anyway.
20326
20327 2002-12-06  Jim Meyering  <jim@meyering.net>
20328
20329         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
20330
20331         Merge in changes from libc's misc/error.c, in preparation
20332         for the merge of gnulib's changes back into libc.
20333
20334         * lib/error.c (_): Define only if not already defined.
20335         Move definition to follow all #include directives.
20336         Include unlocked-io.h only if !_LIBC.
20337         [_LIBC]: Include <libio/libioP.h>.
20338         [USE_IN_LIBIO]: Include <libio/iolibio.h>
20339         (fflush): Tweak definition to use INTUSE.
20340         (putc): Define.
20341
20342 2002-12-05  Paul Eggert  <eggert@twinsun.com>
20343
20344         * lib/alloca.c [defined emacs]: Include "lisp.h".
20345         (xalloc_die) [defined emacs]: New macro.
20346         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
20347         [! defined emacs]: Include <xalloc.h>.
20348         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
20349         (pointer): Typedef to POINTER_TYPE *.
20350         (malloc): Remove decl; we now always use xmalloc.
20351         (alloca): Use old-style definition, since Emacs needs this.
20352         Check for arithmetic overflow when computing combined size.
20353
20354 2002-12-04  Paul Eggert  <eggert@twinsun.com>
20355
20356         Do not generate unlocked-io.h automatically, since it's easier to
20357         maintain it by hand.
20358
20359         * lib/unlocked-io.h: New file, from GNU diffutils,
20360         but with proper copyright notice and attribution.
20361         * lib/gen-uio: Remove.
20362         * lib/Makefile.am: Add copyright notice.
20363         (libfetish_a_SOURCES): Add unlocked-io.h.
20364         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
20365         (DISTCLEANFILES, io_functions): Remove macros.
20366         (EXTRA_DIST): Remove gen_uio.
20367         (unlocked-io.h): Remove rule.
20368
20369 2002-12-04  Jim Meyering  <jim@meyering.net>
20370
20371         Reflect the fact that stat.c and lstat.c are no longer generated.
20372         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
20373         (DISTCLEANFILES): Likewise.
20374         (EXTRA_DIST): Likewise.
20375         (all_local): Don't depend on stat.c or lstat.c.
20376         (stat.c, lstat.c): Remove rules.
20377         (EXTRA_DIST): Remove xstat.in.
20378
20379         * lib/xstat.in: Remove file.  Contents moved into stat.c.
20380         * lib/stat.c: New file.  Contents mostly from xstat.in.
20381         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
20382         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
20383
20384         * lib/safe-read.c: Rework so that it may serve to define safe_write,
20385         too.
20386         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
20387
20388 2002-12-03  Jim Meyering  <jim@meyering.net>
20389
20390         * lib/safe-read.c, safe-write.c: Change variable names and comments,
20391         but not semantics, to minimize the differences between these two files.
20392         (safe_read): Change comment to mention SAFE_READ_ERROR.
20393
20394         * lib/safe-read.c (IS_EINTR): Define.
20395         (safe_read): Use IS_EINTR in place of in-function cpp directives.
20396
20397 2002-12-02  Jim Meyering  <jim@meyering.net>
20398
20399         * lib/safe-read.c (EINTR): Define.
20400         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20401         (INT_MAX): Provide fallback.
20402         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
20403
20404         * lib/safe-read.h (SAFE_READ_ERROR): Define.
20405
20406 2002-12-02  Bruno Haible  <bruno@clisp.org>
20407
20408         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
20409         Define, taken from safe-read.c.
20410         (INT_MAX): Provide fallback.
20411         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
20412         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
20413
20414         * lib/safe-read.c (EINTR): Remove definition.
20415         (safe_read): Don't use EINTR if it is absent.
20416
20417 2002-12-01  Jim Meyering  <jim@meyering.net>
20418
20419         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
20420         zero.
20421         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
20422
20423 2002-11-27  Paul Eggert  <eggert@twinsun.com>
20424
20425         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
20426         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
20427         with `if (! (value < limit)) abort ();', for readability.
20428
20429 2002-11-26  Karl Berry  <karl@gnu.org>
20430
20431         * lib/strdup.c: copy from libc again, with jim's ok.
20432         * lib/.cppi-disable: re-add strdup.c
20433
20434 2002-11-25  Karl Berry  <karl@gnu.org>
20435
20436         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
20437         instead of "strtol.c".
20438
20439 2002-11-25  Karl Berry  <karl@gnu.org>
20440
20441         * config/install-sh: update from automake for variable quoting, $0 in
20442         error msgs, etc.
20443
20444         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
20445         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
20446         entry.
20447
20448 2002-11-25  Jim Meyering  <jim@meyering.net>
20449
20450         * lib/mktime.c: Sync from libc, now that it has the latest fix.
20451
20452 2002-11-24  Karl Berry  <karl@gnu.org>
20453
20454         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
20455         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
20456
20457 2002-11-24  Jim Meyering  <jim@meyering.net>
20458
20459         Update from coreutils:
20460
20461         * lib/mktime.c: Merge in changes from libc.
20462
20463         Avoid a link-time failure on some Linux systems.
20464         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
20465         (otherwise).
20466         (__mon_yday): Declare with the STATIC attribute.
20467         (__mktime_internal): Likewise.
20468         Based on a report from Greg Schafer.
20469
20470 2002-11-23  Jim Meyering  <jim@meyering.net>
20471
20472         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
20473         Use `unsigned', not `int', as type of index.
20474
20475         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
20476
20477         * lib/fsusage.c: Remove unneeded parentheses around operands of
20478         `defined'.
20479
20480 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20481
20482         * lib/quotearg.h: Allow multiple inclusion by surrounding with
20483         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
20484         so that we can be included first.
20485         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
20486         * lib/quotearg.c: Include quotearg.h immediately after config.h.
20487         No need to include stddef.h or sys/types.h any more.
20488         Surround local include files with "", not "<>".
20489         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
20490         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
20491         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
20492         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
20493         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
20494         (ISPRINT): Remove; no longer needed now that we assume C89.
20495
20496         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
20497         Preserve errno.
20498
20499         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
20500         quotearg_char): Use SIZE_MAX rather than
20501         (size_t) -1 when we are talking about "infinity".
20502
20503         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
20504
20505 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20506
20507         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
20508         hint that one should use `if (! x) abort ();' rather than `assert
20509         (x);', and anyway it's one less thing to worry about configuring.
20510         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
20511         hash_rehash, hash_insert): Use abort rather than assert.
20512
20513 2002-11-22  Bruno Haible  <bruno@clisp.org>
20514
20515         * lib/safe-read.h: Assume C89. Add comments.
20516         (safe_read): Change return type to size_t.
20517         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
20518         byte counts > SSIZE_MAX correctly.
20519         * lib/safe-write.h: New file.
20520         * lib/safe-write.c: New file.
20521         * lib/full-read.h: New file.
20522         * lib/full-read.c: New file.
20523         * lib/full-write.h: Assume C89. Add comments.
20524         * lib/full-write.c: Include safe-write.h.
20525         (full_write): Rewritten to use safe_write.
20526         Suggested by Jim Meyering and Paul Eggert.
20527
20528 2002-11-21  Jim Meyering  <jim@meyering.net>
20529
20530         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
20531
20532         Merge in changes from the coreutils.
20533
20534         2002-09-25  Paul Eggert  <eggert@twinsun.com>
20535         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
20536         <stdint.h>.
20537         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
20538         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
20539         int.  Work more efficiently if X is the same width as uintmax_t.
20540         Do not compare X to -1, to avoid bogus compiler warning.
20541         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
20542         Don't assume that f_frsize and f_bsize are the same type.
20543
20544         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
20545         warning on FreeBSD.
20546
20547         * lib/makepath.c (make_path): Restore umask *before* creating the final
20548         component.
20549         (make_path): Minor reformatting.
20550
20551         * lib/xmalloc.c: Adjust to work with new autoconf macros,
20552         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
20553         HAVE_MALLOC/HAVE_REALLOC.
20554
20555         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
20556         dummy ones.  At least on GNU/Linux systems, `auto' means something
20557         else.
20558         From Michael Stone.
20559
20560 2002-11-21  Bruno Haible  <bruno@clisp.org>
20561
20562         Remove case insensitive option matching.
20563         * lib/argmatch.h (argcasematch): Remove declaration.
20564         (ARGCASEMATCH): Remove macro.
20565         (__xargmatch_internal): Remove case_sensitive argument.
20566         (XARGMATCH): Update.
20567         (XARGCASEMATCH): Remove macro.
20568         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
20569         case_sensitive argument.
20570         (argcasematch): Remove function.
20571         (__xargmatch_internal): Remove case_sensitive argument.
20572         (main): Use XARGMATCH instead of XARGCASEMATCH.
20573
20574         * lib/xmalloc.c: Change compile-time error message. Add comment about
20575         required autoconf version.
20576
20577 2002-11-20  Paul Eggert  <eggert@twinsun.com>
20578
20579         Merge argmatch cleanups from Bison.  Assume C89.
20580
20581         * lib/argmatch.c: Include config.h here, not in argmatch.h.
20582         Include stdlib.h, for EXIT_FAILURE.
20583         Always include <string.h>, since we assume C89.
20584         (EXIT_FAILURE): Remove pre-C89 bug workaround.
20585         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
20586         Include <stddef.h> instead, since it's all we need for size_t.
20587         (PARAMS): Remove.  All uses removed.
20588         (ARRAY_CARDINALITY): Do not bother to #undef.
20589         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
20590         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20591         Remove unnecessary parentheses.
20592         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20593         Insert necessary parentheses.
20594         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
20595         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
20596
20597 2002-11-19  Bruno Haible  <bruno@clisp.org>
20598
20599         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
20600         * lib/mbswidth.h: Include <stddef.h>, for size_t.
20601
20602         * lib/mbswidth.h (PARAMS): Remove macro.
20603         (mbswidth, mbsnwidth): Use ANSI C function declarations.
20604         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
20605
20606         * lib/gcd.h (PARAMS): Remove macro.
20607         (gcd): Use ANSI C function declarations.
20608         * lib/gcd.c (gcd): Likewise.
20609
20610 2002-11-15  Bruno Haible  <bruno@clisp.org>
20611
20612         * lib/strcspn.c: Include <stddef.h>.
20613         (strcspn): Use ANSI C function declaration. Change return type to
20614         size_t. Use NULL.
20615         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
20616         (strpbrk): Use NULL.
20617         * lib/strpbrk.h (PARAMS): Remove macro.
20618         (strpbrk): Use ANSI C function declaration.
20619         * lib/strstr.c: Don't include <sys/types.h>.
20620         * lib/strstr.h (PARAMS): Remove macro.
20621         (strstr): Use ANSI C function declarations.
20622
20623 2002-11-14  Karl Berry  <karl@gnu.org>
20624
20625         * config/mkinstalldirs: `do' on separate line, instead of
20626         `for var; do'.
20627
20628 2002-11-06  Bruno Haible  <bruno@clisp.org>
20629
20630         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
20631         * lib/gcd.c (gcd): Likewise.
20632
20633 2002-11-05  Bruno Haible  <bruno@clisp.org>
20634
20635         * lib/gcd.h: New file, from gettext-0.11.5.
20636         * lib/gcd.c: New file, from gettext-0.11.5.
20637
20638 2002-11-05  Bruno Haible  <bruno@clisp.org>
20639
20640         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20641         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20642         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20643         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20644
20645         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
20646         <libintl.h>.
20647         * lib/makepath.c: Include gettext.h instead of <locale.h> and
20648         <libintl.h>.
20649
20650         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
20651         * lib/human.c: Include gettext.h instead of <libintl.h>.
20652         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
20653         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
20654         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
20655         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
20656         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
20657         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
20658         (textdomain): Remove definition.
20659         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
20660
20661         * lib/long-options.c: Remove include of <libintl.h> and definition of
20662         _.
20663         * lib/same.c: Remove include of <libintl.h> and definition of _.
20664
20665 2002-11-04  Owen Taylor  <otaylor@redhat.com>
20666
20667         * lib/config.charset: A few additions for Solaris.
20668
20669 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20670
20671         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
20672         * lib/localcharset.c (locale_charset): Declare as extern "C".
20673
20674 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20675
20676         * lib/config.charset: msdos in uk_UA uses CP1125.
20677
20678 2002-11-04  Bruno Haible  <bruno@clisp.org>
20679
20680         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
20681         * lib/strcase.h: New file, from GNU gettext-0.11.5.
20682         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
20683         * lib/strstr.h: New file, from GNU gettext-0.11.5.
20684         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
20685
20686 2002-11-04  Bruno Haible  <bruno@clisp.org>
20687
20688         * lib/localcharset.c (locale_charset): Don't return an empty string.
20689
20690 2002-11-04  Bruno Haible  <bruno@clisp.org>
20691
20692         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
20693         aliases.
20694
20695 2002-11-04  Bruno Haible  <bruno@clisp.org>
20696
20697         * lib/config.charset: Update for newest glibc. Add canonical names
20698         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
20699
20700 2002-11-04  Bruno Haible  <bruno@clisp.org>
20701
20702         * lib/config.charset: Add support for NetBSD.
20703
20704 2002-11-04  Bruno Haible  <bruno@clisp.org>
20705
20706         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
20707
20708 2002-11-01  Bruno Haible  <bruno@clisp.org>
20709
20710         * configure.in: Add AC_CONFIG_AUX_DIR call.
20711         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
20712         test/Makefile.
20713         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
20714
20715 2002-09-28  Karl Berry  <karl@gnu.org>
20716
20717         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
20718         installed automake until the next release, since changes have been
20719         made.
20720
20721 2002-09-25  Karl Berry  <karl@gnu.org>
20722
20723         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
20724         * lib/getopt*: copy from libc/posix.
20725         * lib/gettext.h: copy from gettext.
20726         * lib/.cppi-disable: add strdup.c, gettext.h.
20727
20728 2002-09-25  Karl Berry  <karl@gnu.org>
20729
20730         * config/srclist.txt: enable gettext.h check.
20731         * config/config.{guess,sub}: update from prep.
20732         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
20733                 from automake 1.6.3.
20734         See srclist*.
20735
20736 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
20737
20738         * regex.c (PATFETCH): Remove the translating fetch.
20739         (PATFETCH_RAW): Rename to PATFETCH.
20740         (set_image_of_range): New fun.
20741         (SET_RANGE_TABLE_WORK_AREA): Use it.
20742         (regex_compile): Don't translate the pattern chars so eagerly.
20743         Only do it when inserting an `exactn' bytecode or when handling
20744         a char-range.
20745         (mutually_exclusive_p): Avoid empty statement.
20746
20747 2002-07-06  Jim Meyering  <meyering@lucent.com>
20748
20749         * m4/README: Don't mention Makefile.am.in.
20750         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
20751
20752 2002-07-01  Jim Meyering  <meyering@lucent.com>
20753
20754         * lib/c-stack.c: Include sys/time.h.
20755         From Volker Borchert.
20756
20757 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20758
20759         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
20760
20761 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20762
20763         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
20764         New macro.  Use it uniformly instead of
20765         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
20766         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
20767         reported by Vin Shelton.
20768
20769 2002-06-22  Paul Eggert  <eggert@twinsun.com>
20770
20771         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
20772         Do not assume SA_SIGINFO behavior.
20773         Bug reported by Jim Meyering on NetBSD 1.5.2.
20774
20775 2002-06-22  Jim Meyering  <meyering@lucent.com>
20776
20777         * m4/c-stack.m4: New file, from diffutils-2.8.2.
20778         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
20779
20780         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
20781         now that configure.ac uses AC_GNU_SOURCE.
20782         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
20783         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
20784
20785         Update to latest tools.  Suggestions from Paul Eggert.
20786         * m4/stdbool.m4: New file, from diffutils-2.8.2.
20787         * m4/gnu-source.m4: Update from diffutils-2.8.2.
20788         * m4/fnmatch.m4: Likewise.
20789         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
20790         to AC_HEADER_STDBOOL
20791
20792 2002-06-22  Jim Meyering  <meyering@lucent.com>
20793
20794         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
20795         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
20796
20797 2002-06-22  Jim Meyering  <meyering@lucent.com>
20798
20799         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
20800
20801         * lib/exitfail.c, exitfail.h: Likewise.
20802         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
20803
20804         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
20805         of fnmatch.h.
20806         (EXTRA_DIST): Add fnmatch_loop.c.
20807         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
20808
20809         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
20810         * lib/fnmatch.c: Update from diffutils-2.8.2.
20811         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
20812         * lib/fnmatch.h: Remove file.
20813
20814 2002-06-21  Jim Meyering  <meyering@lucent.com>
20815
20816         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
20817         * m4/mbrtowc.m4: Likewise.
20818
20819         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
20820         * m4/mbswidth.m4: Reflect name change:
20821         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
20822         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
20823
20824         * m4/lib-link.m4: Update from gettext-0.11.2.
20825         * m4/gettext.m4: Likewise.
20826
20827         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
20828         From Alfred M. Szmidt.
20829
20830 2002-06-18  Paul Eggert  <eggert@twinsun.com>
20831
20832         * lib/file-type.h: Report an error if neither S_ISREG nor
20833         S_IFREG is defined, instead of using a test specific to glibc
20834         2.2.  This should be safe, since POSIX requires S_ISREG and
20835         Unix Version 7 had S_IFREG.  We don't need to check for
20836         <sys/types.h> since we don't use any symbols that it defines.
20837
20838 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
20839
20840         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
20841         $@-t, so that each temporary file name is unique and valid in the first
20842         8 characters, for operation under DOS.
20843
20844 2002-06-15  Paul Eggert  <eggert@twinsun.com>
20845
20846         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
20847
20848 2002-06-15  Jim Meyering  <meyering@lucent.com>
20849
20850         Work even with DJGPP 2.03, which lacks support for symlinks.
20851         From Richard Dawe.
20852         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
20853         is defined.
20854         * lib/lchown.c (S_ISLNK): Likewise.
20855
20856 2002-06-15  Jim Meyering  <meyering@lucent.com>
20857
20858         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
20859         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
20860         have been included before this file.
20861
20862 2002-06-14  Jim Meyering  <meyering@lucent.com>
20863
20864         * lib/file-type.h: Use the version from diffutils-2.8.2.
20865         * lib/file-type.c: Likewise.
20866
20867 2002-06-07  Jim Meyering  <meyering@lucent.com>
20868
20869         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
20870         They're needed at least for NetBSD 1.5.2.
20871         ($statxfs_includes): Include those same headers.
20872         ($statxfs_includes): Include sys/vfs.h if available.
20873         ($statxfs_includes): Likewise for sys/statvfs.h.
20874         Check for the following members in both structs statfs and statvfs:
20875         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
20876
20877 2002-06-01  Jim Meyering  <meyering@lucent.com>
20878
20879         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
20880         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
20881
20882 2002-05-28  Jim Meyering  <meyering@lucent.com>
20883
20884         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
20885         Reported by Volker Borchert.
20886
20887 2002-05-27  Jim Meyering  <meyering@lucent.com>
20888
20889         Fix a problem seen only on nonconforming systems whereby ls.c's
20890         use of localtime, and then of gettimeofday would cause trouble:
20891         the localtime call used to initialize rpl_gettimeofday's save
20892         mechanism would clobber ls's current local time information so
20893         that in any long listing the first file would always be listed
20894         with date 1970-01-01.  Analysis by Volker Borchert.
20895
20896         * lib/gettimeofday.c (localtime): Undefine.
20897         (rpl_localtime): New function.
20898
20899 2002-05-27  Jim Meyering  <meyering@lucent.com>
20900
20901         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
20902         localtime.
20903
20904         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
20905         use the replacement function; it wouldn't resolve at link time.
20906         Reported by Volker Borchert.
20907
20908 2002-05-22  Jim Meyering  <meyering@lucent.com>
20909
20910         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
20911         file-type.h.
20912         * lib/file-type.h: New file.
20913         * lib/file-type.c (file_type): New file/function.  Extracted from
20914         diffutils.
20915
20916 2002-04-30  Jim Meyering  <meyering@lucent.com>
20917
20918         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
20919
20920 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20921
20922         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
20923
20924 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20925
20926         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
20927         Do not check for alloca.h (no longer used) or stdbool.h (was never
20928         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
20929
20930 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20931
20932         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
20933
20934 2002-04-29  Jim Meyering  <meyering@lucent.com>
20935
20936         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
20937         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
20938         Use AC_FUNC_STRNLEN here instead.
20939
20940         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
20941         With autoconf-2.53a, it's part of AC_PROG_CC.
20942
20943 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20944
20945         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
20946         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
20947
20948 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20949
20950         * lib/sig2str.h, lib/sig2str.c: New files.
20951         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
20952
20953 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20954
20955         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
20956         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
20957         of 127, since 64 is the largest conceivable number for ancient
20958         nonstandard hosts.
20959         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
20960
20961 2002-04-28  Jim Meyering  <meyering@lucent.com>
20962
20963         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
20964
20965 2002-04-24  Jim Meyering  <meyering@lucent.com>
20966
20967         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
20968         (jm_PREREQ): Use it.
20969
20970         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
20971         mach/mach.h fcntl.h.
20972         Check for this function: setlocale.
20973
20974 2002-04-24  Jim Meyering  <meyering@lucent.com>
20975
20976         * lib/gettext.h: New file, from Gettext.
20977         * lib/Makefile.am (INCLUDES): Remove -I../intl.
20978         (libfetish_a_SOURCES): Add gettext.h.
20979
20980 2002-04-16  Jim Meyering  <meyering@lucent.com>
20981
20982         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
20983         ut_pid, ut_id, ut_exit.
20984
20985 2002-04-16  Jim Meyering  <meyering@lucent.com>
20986
20987         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
20988         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
20989         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
20990
20991 2002-04-12  Jim Meyering  <meyering@lucent.com>
20992
20993         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
20994         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
20995         existence of the getmntinfo function.  Needed for Darwin 5.3.
20996
20997         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
20998         This is necessary at least on Darwin 5.3.
20999
21000         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
21001         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
21002         strnlen.o in the library, and that makes some versions of ranlib
21003         object.
21004
21005 2002-04-12  Jim Meyering  <meyering@lucent.com>
21006
21007         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
21008
21009 2002-04-09  Jim Meyering  <meyering@lucent.com>
21010
21011         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
21012         to be more precise.  Rather than saying we're checking whether the
21013         function `works', say what we're testing.
21014         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
21015         Reported by Bruno Haible.
21016
21017 2002-03-10  Jim Meyering  <meyering@lucent.com>
21018
21019         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
21020         Suggestion from Santiago Vila.
21021
21022 2002-03-08  Jim Meyering  <meyering@lucent.com>
21023
21024         * lib/rename.c: Mention that this wrapper is needed also on
21025         mips-dec-ultrix4.4 systems.
21026
21027 2002-03-02  Jim Meyering  <meyering@lucent.com>
21028
21029         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
21030         not HAVE_CLOCK_SETTIME.
21031
21032 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21033
21034         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
21035         Check for clock_settime.
21036
21037 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21038
21039         * lib/nanosleep.h: Rename to....
21040         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
21041
21042         * lib/gettime.c: New file.
21043         * lib/settime.c: New file.
21044         * lib/stime.c: Remove.
21045
21046         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
21047         timespec.h.  Remove nanosleep.h.
21048
21049 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21050
21051         * m4/acl.m4: New file.
21052         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
21053         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
21054
21055 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21056
21057         * lib/acl.c, lib/acl.h: New files.
21058         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
21059
21060 2002-02-24  Jim Meyering  <meyering@lucent.com>
21061
21062         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
21063         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
21064         cause trouble.  Reported by Nelson Beebe.
21065
21066 2002-02-23  Paul Eggert  <eggert@twinsun.com>
21067
21068         * lib/path-concat.c (xpath_concat): Reorder code to pacify
21069         compilers that don't know that xalloc_die never returns.
21070
21071 2002-02-20  Jim Meyering  <meyering@lucent.com>
21072
21073         * lib/getdate.c: Regenerate using bison-1.33.
21074
21075 2002-02-17  Jim Meyering  <meyering@lucent.com>
21076
21077         * config/config.guess (main): Don't use `head -1'; it's no longer
21078         portable. Use `sed 1q' instead.
21079
21080 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
21081
21082         * m4/codeset.m4: Upgrade to gettext-0.11.
21083         * m4/gettext.m4: Upgrade to gettext-0.11.
21084         * m4/glibc21.m4: Upgrade to gettext-0.11.
21085         * m4/iconv.m4: Upgrade to gettext-0.11.
21086         * m4/isc-posix.m4: Upgrade to gettext-0.11.
21087         * m4/lcmessage.m4: Upgrade to gettext-0.11.
21088         * m4/lib-ld.m4: New file, from gettext-0.11.
21089         * m4/lib-link.m4: New file, from gettext-0.11.
21090         * m4/lib-prefix.m4: New file, from gettext-0.11.
21091         * m4/progtest.m4: Upgrade to gettext-0.11.
21092
21093 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21094
21095         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
21096         (jm_PREREQ): Use it.
21097
21098 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21099
21100         * lib/posixver.c, lib/posixver.h: New files.
21101         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21102
21103 2002-02-02  Paul Eggert  <eggert@twinsun.com>
21104             Bruno Haible  <bruno@clisp.org>
21105
21106         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
21107         (fwrite_success_callback): New declaration.
21108         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
21109         print_unicode_char. Call failure callback instead of error.
21110         (fwrite_success_callback): New function.
21111         (exit_failure_callback): New function.
21112         (fallback_failure_callback): New function.
21113         (print_unicode_char): Call unicode_to_mb.
21114
21115 2002-01-26  Jim Meyering  <meyering@lucent.com>
21116
21117         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
21118         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
21119
21120 2002-01-26  Jim Meyering  <meyering@lucent.com>
21121
21122         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
21123
21124 2002-01-22  Paul Eggert  <eggert@twinsun.com>
21125
21126         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
21127
21128 2002-01-22  Jim Meyering  <meyering@lucent.com>
21129
21130         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
21131         Otherwise, some versions of automake would omit the rule that makes
21132         Makefile from Makefile.in.
21133
21134 2002-01-21  Paul Eggert  <eggert@twinsun.com>
21135
21136         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
21137         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21138         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
21139         (memcoll): Set errno to zero if there is no error.
21140
21141         * lib/quotearg.c (quotearg_buffer_restyled):
21142         Fix bug with quoting buffers containing NUL when backslashing escapes.
21143         This bug was exposed by the other changes in this patch.
21144         (quotearg_n_options): New arg ARGSIZE.
21145         All callers changed.
21146         (quoting_options_from_style): New function.
21147         (quotearg_n_style): Use it.
21148         (quotearg_n_style_mem): New function.
21149
21150         * lib/quotearg.h (quotearg_n_style_mem): New function.
21151
21152 2002-01-19  Jim Meyering  <meyering@lucent.com>
21153
21154         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
21155         Remove useless quotes: DF_PROG="df".
21156         * m4/strnlen.m4: New file.
21157
21158 2002-01-16  Paul Eggert  <eggert@twinsun.com>
21159
21160         * lib/backupfile.c (ISDIGIT): Comment fix.
21161         * lib/getdate.y (ISDIGIT): Likewise.
21162         * lib/posixtm.c (ISDIGIT, year): Likewise.
21163         * lib/strverscmp.c (ISDIGIT): Likewise.
21164         * lib/userspec.c (ISDIGIT): Likewise.
21165
21166 2002-01-16  Jim Meyering  <meyering@lucent.com>
21167
21168         * lib/getdate.y: Add three semicolons, each just before a closing
21169         brace. Bison (as of version 1.31) no longer papers over that mistake.
21170
21171 2002-01-05  Jim Meyering  <meyering@lucent.com>
21172
21173         * lib/version-etc.c (version_etc_copyright): Update copyright year.
21174
21175 2001-12-19  Paul Eggert  <eggert@twinsun.com>
21176
21177         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
21178         not silently exit merely because the output buffer happens to
21179         have nothing pending.
21180
21181 2001-12-18  Paul Eggert  <eggert@twinsun.com>
21182
21183         See the big note in ../ChangeLog.
21184         * lib/human.c (suffixes): Prefer K to k for 1024.
21185         (generate_suffix_backwards): New function.
21186         (human_readable_inexact): Use it.
21187         * lib/xstrtol.c (__xstrtol): If there is no number but there
21188         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
21189         Accept 'K' as well as 'k'.
21190
21191 2001-12-15  Jim Meyering  <meyering@lucent.com>
21192
21193         * lib/regex.h (__restrict_arr): Update from libc.
21194
21195         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
21196         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
21197         (STREQ): Define.
21198
21199 2001-12-14  Jim Meyering  <meyering@lucent.com>
21200
21201         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
21202         Suggestion from Bruno Haible.
21203
21204 2001-12-10  Jim Meyering  <meyering@lucent.com>
21205
21206         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
21207         xrealloc, Instead, include "xalloc.h".
21208         (initbuffer): Don't cast xmalloc return value to char*.
21209         (readline): Reword comment.
21210         Don't cast xrealloc return value to char*
21211         Return NULL, not 0.
21212
21213 2001-12-09  Jim Meyering  <meyering@lucent.com>
21214
21215         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
21216         about `signed and unsigned type in conditional expression'.
21217         * lib/posixtm.c (posix_time_parse): Likewise.
21218
21219         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
21220
21221         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
21222         to avoid a pedantic warning.
21223
21224         * lib/getstr.c: Don't include assert.h.
21225         (getstr): Remove warning-evoking assertions.
21226         Return -1 if offset parameter is out of bounds.
21227         Change the type of a local from int to size_t.
21228
21229         * lib/strftime.c (my_strftime_localtime_r): Include this function
21230         definition in the `#if ! HAVE_TM_GMTOFF' block.
21231
21232         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
21233         Include xalloc.h instead.
21234
21235 2001-12-02  Jim Meyering  <meyering@lucent.com>
21236
21237         * lib/tempname.c: Don't declare getenv, thus reverting the change of
21238         2001-11-18.  It's no longer necessary, now that stdlib.h is always
21239         included.
21240
21241         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
21242         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
21243
21244 2001-11-30  Akim Demaille  <akim@epita.fr>
21245
21246         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
21247         before being defined.
21248
21249 2001-11-27  Paul Eggert  <eggert@twinsun.com>
21250
21251         * lib/quotearg.h (quotearg_n, quotearg_n_style):
21252         First arg is int, not unsigned.
21253         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
21254         (SIZE_MAX, UINT_MAX): New macros.
21255         (quotearg_n_options): Abort if N is negative.
21256         Avoid overflow check on hosts where size_t is 64 bits and int
21257         is 32 bits, as overflow is impossible there.
21258         Fix off-by-one typo that caused unnecessary reallocation.
21259
21260 2001-11-27  Jim Meyering  <meyering@lucent.com>
21261
21262         * lib/tempname.c: Merge with version from libc.
21263         * lib/regex.c: Likewise.
21264
21265         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
21266         systems for which STDC_HEADERS is 0, it was not included, resulting in
21267         a warning about an integer-to-pointer conversion problem with getenv.
21268         Reported by Volker Borchert.
21269
21270 2001-11-26  Jim Meyering  <meyering@lucent.com>
21271
21272         * lib/gtod.h: Remove file.
21273         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
21274         * lib/gettimeofday.c: Don't include gtod.h.
21275         (GTOD_init): Remove function.
21276         (rpl_gettimeofday): Do its job here instead, rather than aborting.
21277         Suggestion from Volker Borchert.
21278
21279 2001-11-23  Jim Meyering  <meyering@lucent.com>
21280
21281         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
21282         it.
21283         * lib/hash.c (struct hash_table): Define it here instead.
21284
21285 2001-11-22  Jim Meyering  <meyering@lucent.com>
21286
21287         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
21288
21289 2001-11-20  Jim Meyering  <meyering@lucent.com>
21290
21291         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
21292         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
21293
21294 2001-11-19  Jim Meyering  <meyering@lucent.com>
21295
21296         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
21297         directory.  Use "conftestXXXXXX" as the template.
21298         Suggestion from Paul Eggert.
21299
21300         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
21301         immediately, so the test doesn't mistakenly hit the max-open-files
21302         limit.
21303
21304 2001-11-18  Paul Eggert  <eggert@twinsun.com>
21305
21306         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
21307         (TEMPORARIES): New macro.
21308         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
21309         removes an artificial limitation (e.g. HP-UX 10.20, where
21310         TMP_MAX is 17576).
21311
21312 2001-11-18  Jim Meyering  <meyering@lucent.com>
21313
21314         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
21315
21316 2001-11-18  Jim Meyering  <meyering@lucent.com>
21317
21318         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
21319         on SunOS 4.
21320
21321         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
21322         files will be created before anything else.
21323
21324 2001-11-17  Paul Eggert  <eggert@twinsun.com>
21325
21326         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
21327         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
21328
21329 2001-11-17  Jim Meyering  <meyering@lucent.com>
21330
21331         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
21332         Prompted by a report from Bob Proulx.
21333
21334         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
21335         Instead, require UTILS_FUNC_MKSTEMP.
21336
21337 2001-11-17  Jim Meyering  <meyering@lucent.com>
21338
21339         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
21340         Now, that's done as part of AC_FUNC_STRTOD.
21341
21342 2001-11-17  Jim Meyering  <meyering@lucent.com>
21343
21344         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
21345         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
21346         rather than group writable.  Patch by Juan F. Codagnone.
21347
21348         * lib/readtokens.c: Remove explicit declarations of xmalloc and
21349         xrealloc, Instead, include "xalloc.h".
21350
21351         * lib/mountlist.c: Include unlocked-io.h after all system headers.
21352         Remove explicit declarations of xmalloc, xrealloc,
21353         and xstrdup.  Instead, include "xalloc.h".
21354
21355         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
21356         unlocked-io.h.
21357         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
21358         Likewise.
21359         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
21360
21361         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
21362         Reported by Padraig Brady.
21363
21364         * lib/mkstemp.c: #undef mkstemp.
21365         Include config.h.
21366         (rpl_mkstemp): Rename from mkstemp.
21367         Protoize.
21368
21369 2001-11-16  Jim Meyering  <meyering@lucent.com>
21370
21371         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
21372         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
21373         determine the amount of total physical memory, use pstat_getstatic.
21374         HPUX-11 doesn't define _SC_PHYS_PAGES.
21375         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
21376         If sysconf couldn't be used to determine the amount of available
21377         physical memory, use both pstat_getstatic and pstat_getdynamic.
21378         Based on a patch from Bob Proulx.
21379
21380 2001-11-10  Jim Meyering  <meyering@lucent.com>
21381
21382         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
21383         (jm_PREREQ): Use it.
21384
21385 2001-11-09  Jim Meyering  <meyering@lucent.com>
21386
21387         * m4/jm-macros.m4: Require autoconf-2.52f.
21388         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
21389         Use these AC_-prefixed names, not the AM_-prefixed ones.
21390
21391         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
21392
21393 2001-11-05  Jim Meyering  <meyering@lucent.com>
21394
21395         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
21396
21397 2001-11-04  Jim Meyering  <meyering@lucent.com>
21398
21399         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
21400         $DEFS.
21401
21402 2001-11-03  Jim Meyering  <meyering@lucent.com>
21403
21404         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
21405         of AC_DEFUN.
21406
21407         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
21408         know the name of the variable in the macro definition.
21409
21410 2001-11-03  Jim Meyering  <meyering@lucent.com>
21411
21412         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
21413         in argmatch_to_argument call.
21414
21415         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
21416         argument.
21417
21418         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
21419         e.g., a fault due to an attempt to free a NULL pointer.
21420
21421 2001-11-01  Jim Meyering  <meyering@lucent.com>
21422
21423         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
21424         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
21425
21426 2001-11-01  Jim Meyering  <meyering@lucent.com>
21427
21428         * lib/dirfd.c, lib/dirfd.h: New files.
21429         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
21430
21431         * lib/hash.c (hash_print) [TESTING]: Clean up.
21432
21433 2001-10-22  Paul Eggert  <eggert@twinsun.com>
21434
21435         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
21436         to avoid a warning if -Wall.
21437
21438 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
21439
21440         * README: New file
21441         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
21442         (per RMS's instructions, this is now the canonical source)
21443         * lgpl/, gpl/: New directories.
21444
21445 2001-10-21  Paul Eggert  <eggert@twinsun.com>
21446
21447         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
21448
21449 2001-10-21  Jim Meyering  <meyering@lucent.com>
21450
21451         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
21452         this code would end up calling gettext even in packages built
21453         with --disable-nls.
21454         * lib/getopt.c (_): Likewise.
21455         * lib/regex.c (_): Likewise.
21456
21457 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21458
21459         * m4/error.m4 (jm_PREREQ_ERROR):
21460         Do not invoke AC_CHECK_FUNCS with strerror_r, as
21461         AC_FUNC_STRERROR_R does that.
21462         Check for strerror declaration.
21463
21464         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
21465         are supposed to have them these days.
21466         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
21467         Merge changes from latest Autoconf CVS.
21468         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
21469         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
21470         POSIX decided to standardize on the int flavor of strerror_r.
21471
21472 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21473
21474         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
21475         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
21476         Use strerror_r that is only a macro, even if it is not a function.
21477         (strerror): Check for HAVE_DECL_STRERROR before declaring.
21478         (private_strerror): Use prototypes, not old-style function definition.
21479         (print_errno_message): New function.
21480         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
21481         char*-flavored one.
21482         (error_tail, error, error_at_line): Use it.
21483
21484 2001-10-11  Jim Meyering  <meyering@lucent.com>
21485
21486         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
21487         and quote_n (1, ... to avoid clobbering a buffer.
21488
21489 2001-10-05  Jim Meyering  <meyering@lucent.com>
21490
21491         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
21492         hash-pjw.h.
21493         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
21494         * lib/hash-pjw.h: New file.
21495
21496 2001-09-30  Jim Meyering  <meyering@lucent.com>
21497
21498         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
21499         `struct fsstat' has the `f_fstypename' member.
21500         Use that to define FS_TYPE, which is now used to make
21501         the getfsstat link test tighter.
21502
21503 2001-09-30  Jim Meyering  <meyering@lucent.com>
21504
21505         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
21506         Include <sys/ucred.h>, for Apple Darwin.
21507         Include sys/mount.h and sys/fs_types.h only if available.
21508         (FS_TYPE): Define.
21509         (read_filesystem_list): Use FS_TYPE.
21510
21511 2001-09-29  Paul Eggert  <eggert@twinsun.com>
21512
21513         * lib/exclude.c (excluded_filename): 0 -> false, since it's
21514         a boolean context.
21515
21516 2001-09-29  Jim Meyering  <meyering@lucent.com>
21517
21518         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21519         [one-argument getmntent function]): Include stdio.h before mntent.h.
21520         SunOS 4.1.x needs it for the declaration of `FILE'.
21521         Patch by Volker Borchert.
21522
21523         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21524         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
21525         sys/fs_types.h, and make the link-test for getfsstat guard #include
21526         directives with appropriate #if HAVE_*_H tests so that we can
21527         detect getfsstat on Apple Darwin1.3.7 systems.
21528         Reported by Nelson Beebe.
21529         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
21530
21531 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21532
21533         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21534         #defines strtoimax.  Also treat the other strto* functions
21535         like strtoimax.
21536
21537         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21538         Check for strtoul and strtoumax,
21539         as those declarations are made even in the signed case.
21540         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
21541         Likewise, for strtol and strtoimax.
21542
21543 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21544
21545         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21546         #defines strtoimax.  Also treat the other strto* functions
21547         like strtoimax.
21548
21549         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
21550         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
21551         (strtoimax, strtoumax): Do not declare if already defined as a macro.
21552
21553 2001-09-26  Jim Meyering  <meyering@lucent.com>
21554
21555         Most macros in unlocked-io.h had the wrong number of arguments.
21556         * lib/gen-uio: New script.
21557         (USE_UNLOCKED_IO): Define to 1 if not already defined.
21558         * lib/unlocked-io.hin: Remove file.
21559         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
21560         rather than trying to embed it here.
21561         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
21562         Reported by Padraig Brady.
21563
21564 2001-09-25  Volker Borchert  <bt@teknon.de>
21565
21566         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
21567         `result'.
21568
21569 2001-09-24  Jim Meyering  <meyering@lucent.com>
21570
21571         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
21572
21573 2001-09-23  Jim Meyering  <meyering@lucent.com>
21574
21575         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
21576         instead of the mere test for existence of mntent.h.  The latter
21577         would get a false-positive on AIX 3.4 systems.
21578         In the outer getmntent if-block, don't die if neither of the getmntent
21579         tests succeeds.  Instead, just fall through and continue with the
21580         remaining tests.
21581
21582 2001-09-23  Jim Meyering  <meyering@lucent.com>
21583
21584         * lib/mountlist.c: Remove useless parentheses in #if directives.
21585         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
21586         the deprecated MOUNTED symbol is no longer defined in mntent.h.
21587
21588 2001-09-22  Jim Meyering  <meyering@lucent.com>
21589
21590         * m4/gettext.m4: New file.  From gettext.
21591         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
21592         * m4/progtest.m4: Likewise
21593         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
21594         * m4/glibc21.m4: Likewise.
21595
21596         * m4/libintl.m4: Remove.  No longer used.
21597
21598 2001-09-22  Jim Meyering  <meyering@lucent.com>
21599
21600         * lib/localcharset.c: Update from latest gettext.
21601         * lib/config.charset: Likewise.
21602
21603 2001-09-20  Jim Meyering  <meyering@lucent.com>
21604
21605         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
21606         strtoimax.
21607         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
21608         strtoumax.
21609
21610 2001-09-20  Jim Meyering  <meyering@lucent.com>
21611
21612         * lib/xstrtol.c (strtoimax): Guard declaration with
21613         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
21614         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
21615         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
21616         (strtoumax): Likewise, for completeness (it wasn't necessary).
21617
21618 2001-09-17  Paul Eggert  <eggert@twinsun.com>
21619
21620         * lib/strtoimax.c (HAVE_LONG_LONG):
21621         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
21622         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
21623         to work around bug in IBM C compiler.
21624
21625 2001-09-17  Jim Meyering  <meyering@lucent.com>
21626
21627         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
21628         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
21629         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
21630         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
21631         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
21632         whenever the right hand side need not be expanded by the shell.
21633
21634 2001-09-16  Paul Eggert  <eggert@twinsun.com>
21635
21636         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
21637         library.  It's not correct, as some older glibcs are buggy.
21638         fnmatch wasn't fixed until glibc 2.2.
21639
21640         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
21641         special shell magic here.
21642
21643 2001-09-16  Jim Meyering  <meyering@lucent.com>
21644
21645         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
21646         * m4/jm-macros.m4: Require it.
21647
21648 2001-09-16  Jim Meyering  <meyering@lucent.com>
21649
21650         * lib/mkdir.c: New file.
21651
21652 2001-09-15  Jim Meyering  <meyering@lucent.com>
21653
21654         * m4/jm-macros.m4: Check for help2man.
21655
21656 2001-09-11  Jim Meyering  <meyering@lucent.com>
21657
21658         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
21659         The body, by Paul Eggert, was moved here from configure.in.
21660         * m4/jm-macros.m4: Require UTILS_HOST_OS.
21661
21662 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21663
21664         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
21665         (jm_PREREQ): Use it.
21666
21667 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21668
21669         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
21670         Use ssize_t, not int, to store result of readlink.
21671         Check for ssize_t overflow as well as size_t overflow,
21672         as POSIX says the result of readlink is implementation-defined
21673         when ssize_t overflows.
21674         Remove unnecessary cast to char*.
21675         Use free+malloc instead of realloc, as the storage doesn't need
21676         to be preserved and it's clearer and can be more efficient that way.
21677         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
21678         * lib/xreadlink.h (xreadlink): Update prototype.
21679
21680 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21681
21682         * lib/xgetcwd.c: Revert some of the previous change; intead,
21683         fix the HAVE_GETCWD_NULL code to behave more like the
21684         !HAVE_GETCWD_NULL code used to.
21685
21686         Include "xalloc.h".
21687         (xgetcwd): Do not return NULL when memory is exhausted; instead,
21688         invoke xalloc_die.
21689
21690 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21691
21692         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
21693         sys/param.h, as pathmax.h includes them.
21694
21695 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21696
21697         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
21698         (jm_PREREQ_XGETCWD): New macro.
21699
21700         * m4/getcwd.m4: New file.
21701
21702 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21703
21704         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
21705         like the HAVE_GETCWD_NULL code.
21706         Include pathmax.h if not HAVE_GETCWD.
21707         Do not include xalloc.h.
21708         (INITIAL_BUFFER_SIZE): New symbol.
21709         Do not use xmalloc / xrealloc, since the caller is responsible for
21710         handling errors.  Preserve errno around `free' during failure.
21711         Do not overrun buffer when using getwd.
21712
21713 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21714
21715         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
21716         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
21717         getcwd (NULL, 0).
21718
21719 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21720
21721         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
21722         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
21723         spotted by Jim Meyering.
21724
21725 2001-09-03  Jim Meyering  <meyering@lucent.com>
21726
21727         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
21728         failure.
21729
21730 2001-09-02  Jim Meyering  <meyering@lucent.com>
21731
21732         * lib/error.c: Update from GNU libc.
21733
21734 2001-09-01  Jim Meyering  <meyering@lucent.com>
21735
21736         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
21737         Used by df.
21738
21739 2001-09-01  Jim Meyering  <meyering@lucent.com>
21740
21741         * lib/xreadlink.c: New file.
21742         * lib/xreadlink.h: New file.
21743         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
21744         xreadlink.h.
21745
21746         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
21747         doesn't conflict with sparc Solaris 7's definition in
21748         /usr/include/sys/int_types.h.
21749
21750         * lib/exclude.c: Use `""', not `<>' to #include non-system header
21751         files.
21752         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
21753         and strncasecmp as r-values.  Unixware didn't have declarations.
21754
21755 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21756
21757         * lib/xstrtol.h: Add copyright notice.
21758         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
21759         LONGINT_INVALID_SUFFIX_CHAR.
21760
21761 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21762
21763         * lib/xstrtol.c (strtoimax): New decl.
21764
21765 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21766
21767         * lib/xgetcwd.c: Don't include pathmax.h.
21768         Include stdlib.h and unistd.h if available.
21769         Include xalloc.h.
21770         (xmalloc, xstrdup, free): Remove decls.
21771         (xgetcwd): Don't assume sizes fit in unsigned.
21772         Check for overflow when computing sizes.
21773         Simplify reallocation code.
21774
21775 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21776
21777         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
21778         a directory's st_size can have an arbitrary value, so the old
21779         usage could waste an arbitrary amount of memory.  All uses
21780         changed.
21781         * lib/savedir.h: Update prototype.
21782
21783 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21784
21785         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
21786
21787         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
21788         old strtoimax.c.
21789
21790         Also, make the following further changes to make this file's
21791         configuration more similar to that of strtol.c:
21792         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
21793         (strtoumax, uintmax_t, strtoull, strtol): Remove.
21794         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
21795         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
21796         changed to signed values.
21797
21798         And make the following changes as well:
21799         Fix copyright notice, as 1999 was missing.
21800         (verify): New macro.
21801         (strtoimax): Check sizes at compile-time, not run-time.
21802         Prefer strtol to strtoll if both work.
21803         (main): Remove; it was not that useful and was a pain to maintain.
21804
21805         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
21806
21807 2001-08-31  Jim Meyering  <meyering@lucent.com>
21808
21809         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
21810         Use an initial, malloc'd, buffer of length 128 rather than
21811         a statically allocated one of length 1024.
21812
21813 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21814
21815         Simplify code, partly by assuming autoconf 2.52 semantics.
21816
21817         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
21818
21819         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
21820         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
21821         All uses removed.
21822         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
21823         Move AC_REQUIRE to next-to-top level, to avoid confusion.
21824         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
21825         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
21826         jm_AC_HEADER_INTTYPES_H.
21827         * m4/jm-macros.m4 (jm_MACROS): Likewise.
21828
21829         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
21830
21831         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21832         Quote first arg of AC_DEFUN.
21833         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
21834         since they are needed to parse the include file even if we need
21835         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
21836         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
21837         but with opposite signedness.
21838
21839 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21840
21841         Merge 'exclude' changes from tar 1.13.22.
21842         This fixes one or two unlikely storage allocation overflow bugs,
21843         but doesn't change user-visible behavior otherwise.
21844
21845 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21846
21847         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
21848         (jm_PREREQ_EXCLUDE): New macro.
21849
21850 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21851
21852         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
21853         tm to be declared.
21854
21855 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21856
21857         * lib/hash.c: Remove '2001' from copyright notice.
21858
21859 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21860
21861         * lib/full-write.h: New file.
21862         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
21863         * lib/full-write.c: Correct credits, as cccp.c no longer
21864         exists and anyway it was so heavily changed from the old cccp
21865         code as to be unrecognizable.  Include full-write.h.
21866         (full_write) Return size_t, with short writes meaning failure.
21867         All callers changed.  This fixes a bug with large buffers
21868         on 64-bit hosts.
21869         * lib/utime.c: Include full-write.h.
21870
21871 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21872
21873         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
21874         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
21875         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
21876         Include if available.
21877         (<xalloc.h>): Include
21878         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
21879         (verify): New macro.  Use it to verify that EXCLUDE macros do not
21880         collide with FNM macros.
21881         (struct patopts): New struct.
21882         (struct exclude): Use it, as exclude patterns now come with options.
21883         (new_exclude): Support above changes.
21884         (new_exclude, add_exclude_file):
21885         Initial size must now be a power of two to simplify overflow checking.
21886         (free_exclude, fnmatch_no_wildcards): New function.
21887         (excluded_filename): No longer requires options arg, as the options
21888         are determined by add_exclude.  Now returns bool, not int.
21889         (excluded_filename, add_exclude):
21890         Add support for the fancy new exclusion options.
21891         (add_exclude, add_exclude_file): Now takes int options arg.
21892         Check for arithmetic overflow when computing sizes.
21893         (add_exclude_file): xrealloc might modify errno, so don't
21894         realloc until after errno might be used.
21895
21896         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
21897         New macros.
21898         (free_exclude): New decl.
21899         (add_exclude, add_exclude_file): Now takes int options arg.
21900         (excluded_filename): No longer requires options arg, as the options
21901         are determined by add_exclude.  Now returns bool, not int.
21902
21903 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21904
21905         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
21906
21907 2001-08-27  Jim Meyering  <meyering@lucent.com>
21908
21909         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
21910
21911         * lib/version-etc.c (N_): Remove definition.
21912         Revert most of last change.
21913         Instead, simply don't mark the `Copyright...' string for translation.
21914         Based on advice from Paul Eggert.
21915
21916         * lib/strtoxmax.c: Tweak comment.
21917
21918 2001-08-26  Jim Meyering  <meyering@lucent.com>
21919
21920         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
21921
21922         * m4/xstrtoimax.m4: New file.
21923         * m4/xstrtoumax.m4: Add comments explaining why we
21924         AC_REPLACE_FUNCS(strtol).
21925
21926 2001-08-26  Jim Meyering  <meyering@lucent.com>
21927
21928         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
21929         of copyright with `%s' so translators don't get an untranslated
21930         message in 2002.
21931         (COPYRIGHT_YEAR): Define.
21932         (version_etc): Use fprintf rather than fputs.
21933         Suggestion from Ulrich Drepper.
21934
21935         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
21936
21937         * lib/strtoll.c: New file, from GNU libc.
21938         * lib/xstrtoimax.c: New file.
21939
21940         * lib/xstrtol.h: Add xstrtoimax.
21941         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
21942         * lib/strtoimax.c: New file.  Likewise, but first define
21943         STRTOUXMAX_SIGNED.
21944
21945         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
21946         ...
21947         * lib/strtoxmax.c: ... then renamed to this.
21948
21949 2001-08-18  Paul Eggert  <eggert@twinsun.com>
21950
21951         * m4/inttypes.m4: Add AC_PREREQ(2.13).
21952         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
21953         (jm_AC_TYPE_INTMAX_T): New macro.
21954         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
21955
21956         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
21957
21958         * m4/longlong.m4: Renamed from ulonglong.m4.
21959         * m4/inttypes.m4: Renamed from inttypes_h.m4.
21960         * m4/uintmax_t.m4: Removed.
21961
21962 2001-08-13  Paul Eggert  <eggert@twinsun.com>
21963
21964         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
21965         Port to Solaris 8, where 'sed' requires a space after the 'r'
21966         command, and where sh dislikes "$/".  Clean up the spacing a bit.
21967         Redirect output to $tmp just once.
21968
21969 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
21970
21971         * lib/addext.c (<errno.h>): Include.
21972         (errno): Declare if not defined.
21973         (addext): Work correctly when pathconf returns -1 and leaves
21974         errno alone because there is no limit.  Also, work even if
21975         pathconf returns a value greater than SIZE_MAX.
21976
21977 2001-08-12  Jim Meyering  <meyering@lucent.com>
21978
21979         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
21980         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
21981         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
21982         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
21983         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
21984         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
21985         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
21986         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
21987         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
21988         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
21989         utime.m4, utimes.m4, xstrtoumax.m4:
21990         Quote the first argument in each use of AC_DEFUN.
21991
21992 2001-08-12  Jim Meyering  <meyering@lucent.com>
21993
21994         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
21995         Simply `return getcwd (NULL, 0);'.
21996         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
21997         Use 1300 as initial value for length, not PATH_MAX.
21998
21999         * lib/pathmax.h: Clean up cpp syntax.
22000
22001 2001-08-12  Jim Meyering  <meyering@lucent.com>
22002
22003         * lib/gettimeofday.c: New file.
22004         * lib/gtod.h: New file.
22005         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
22006
22007 2001-08-05  Jim Meyering  <meyering@lucent.com>
22008
22009         * m4/jm-macros.m4: Require autoconf-2.52.
22010
22011 2001-08-04  Jim Meyering  <meyering@lucent.com>
22012
22013         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
22014         stmt, to get in sync with glibc.
22015
22016 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22017
22018         The following changes are from gettext 0.10.39 as maintained by
22019         Bruno Haible.
22020
22021         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
22022         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
22023         with inverted sense.  All uses changed.
22024
22025         * lib/mbswidth.c: Don't include <limits.h>.
22026         Include <stdlib.h> and <string.h> unconditionally.
22027         (iswcntrl, mbsinit, ISCNTRL): New macros.
22028         (mbsnwidth): Use K&R style function declarations.
22029         Don't bother checking for MB_LEN_MAX == 1, since the compiler
22030         can optimize it when MB_CUR_MAX == 1.
22031         The width of control characters is zero, not 1.
22032
22033 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22034
22035         The following changes are from gettext 0.10.39 as maintained by
22036         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
22037
22038         * m4/codeset.m4: Upgrade to serial AM1.
22039         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
22040         all uses changed.  Quote first arg of AC_DEFUN.
22041         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
22042
22043         * m4/iconv.m4: Upgrade to serial AM2.
22044         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
22045         Add --with-libconv-prefix.
22046         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
22047         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
22048         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
22049         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
22050         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
22051
22052         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
22053         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
22054         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
22055         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
22056         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
22057         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
22058         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
22059         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
22060         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
22061
22062         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
22063         string.h any more.
22064
22065         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
22066         not the default value.
22067
22068         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
22069         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
22070         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
22071         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
22072         Also check for iswcntrl, used for wcwidth fallback.
22073         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
22074         to Autoconf 2.13.
22075
22076 2001-08-03  Jim Meyering  <meyering@lucent.com>
22077
22078         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
22079         as it was in the original.  Reported by Paul Eggert.
22080
22081 2001-07-16  Jim Meyering  <meyering@lucent.com>
22082
22083         * m4/gettimeofday.m4: New file.
22084         Prompted by a report from Bernhard Baehr.
22085
22086 2001-07-15  Jim Meyering  <meyering@lucent.com>
22087
22088         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
22089         stuff. Now it's in ../Makefile.cfg.
22090
22091 2001-07-15  Jim Meyering  <meyering@lucent.com>
22092
22093         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
22094         (BUILT_SOURCES): Add unlocked-io.h.
22095         (io_functions): Define.
22096         (unlocked-io.h): New rule.
22097         (DISTCLEANFILES): Add unlocked-io.h.
22098         (all-local): Depend on unlocked-io.h, to ensure it is created.
22099
22100         * lib/unlocked-io.hin: New file
22101
22102         * lib/regex.c: Update from glibc.
22103
22104 2001-07-05  Jim Meyering  <meyering@lucent.com>
22105
22106         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
22107         recommendation.
22108         (libfetish_a_SOURCES): Put all .h files here instead.
22109         Remove a thus-exposed (better checks in automake) duplicate and
22110         two unnecessary .h files.
22111
22112 2001-07-04  Jim Meyering  <meyering@lucent.com>
22113
22114         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
22115         that generates jm-glibc-io.m4 so that it doesn't trigger any make
22116         distcheck failure.
22117
22118 2001-07-02  Jim Meyering  <meyering@lucent.com>
22119
22120         The following changes were prompted by suggestions from Bruno Haible.
22121
22122         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
22123         is now generated.
22124         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
22125         definition of EXTRA_DIST.
22126         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
22127         ensure that the generated file is created/updated whenever the list
22128         of $(unlocked_functions) is changed.
22129         (jm-glibc-io.m4): New rule.
22130         (unlocked-io.h): New rule -- currently unused.
22131
22132 2001-06-24  Jim Meyering  <meyering@lucent.com>
22133
22134         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
22135         unmatched right bracket, rather than kludging it with an extra,
22136         falsely-matching quote in a comment.  Patch by Akim Demaille.
22137
22138 2001-06-11  Jim Meyering  <meyering@lucent.com>
22139
22140         * lib/regex.c: Update from GNU libc.
22141
22142 2001-05-27  Jim Meyering  <meyering@lucent.com>
22143
22144         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
22145         Check for ut_type in struct utmp.
22146
22147 2001-05-27  Jim Meyering  <meyering@lucent.com>
22148
22149         * lib/readutmp.h (UT_TYPE): Define.
22150
22151 2001-05-24  Jim Meyering  <meyering@lucent.com>
22152
22153         * lib/argmatch.c: Include "quote.h".
22154         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
22155         quote function.  Reported by Göran Uddeborg.
22156
22157 2001-05-22  Jim Meyering  <meyering@lucent.com>
22158
22159         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
22160         now that we use the package-supplied version unconditionally.
22161         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
22162
22163 2001-05-21  Jim Meyering  <meyering@lucent.com>
22164
22165         * m4/regex.m4: Change a couple backticks to single quotes to avoid
22166         shell syntax errors.
22167
22168 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22169
22170         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
22171
22172 2001-05-20  Paul Eggert  <eggert@twinsun.com>
22173
22174         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
22175         Don't bother to check library strftime, since
22176         we'll be using our own my_strftime function anyway.
22177         Define my_strftime instead of strftime.
22178
22179 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
22180
22181         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
22182         which is not yet declared.
22183
22184 2001-05-15  Jim Meyering  <meyering@lucent.com>
22185
22186         * m4/regex.m4: Use proper quoting so brackets appear in the test
22187         program.
22188         Reported by, and with help from, Bruno Haible.
22189
22190 2001-05-13  Jim Meyering  <meyering@lucent.com>
22191
22192         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
22193         undefined.
22194
22195 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22196
22197         dirname code cleanup.  base_name now behaves more compatibly
22198         with POSIX basename when given file names that have trailing
22199         slashes, and similarly for dir_name.  Add new primitives
22200         base_len and dir_len.  Put the directory-name-related decls
22201         into dirname.h.
22202
22203         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
22204         * lib/backupfile.c (base_name): Likewise.
22205         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
22206         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
22207         * lib/makepath.c (strip_trailing_slashes): Likewise.
22208         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
22209         ISSLASH): Likewise.
22210         * lib/rename.c (strip_trailing_slashes): Likewise.
22211         * lib/same.c (base_name): Likewise.
22212         * lib/stripslash.c (ISSLASH): Likewise.
22213
22214         * lib/addext.c: Include <dirname.h> after size_t is defined.
22215         * lib/backupfile.c: Likewise.
22216
22217         * lib/addext.c (addext): Use base_len to trim redundant
22218         trailing slashes instead of doing it ourselves.
22219         But do not trim the last slash if it is not redundant.
22220
22221         * lib/backupfile.c (find_backup_file_name,
22222         max_backup_version): Use base_len instead of rolling it ourselves.
22223         Handle the case of "" and (on DOS) "C:" correctly.
22224
22225         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
22226         needed. Include <string.h>, <dirname.h>.
22227         (base_name): Allow file names ending in slashes, other than names
22228         that are all slashes.  In this case, return the basename followed
22229         by the slashes.  This is more general, and can be used in places
22230         where the original base_name purposely had an assertion failure.
22231         (base_len): New function.
22232
22233         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
22234         Do not include <assert.h>; no longer needed.
22235         Include xalloc.h.
22236         (memrchr): Remove decl.
22237         (dir_name_r): Remove.
22238         (dir_len): Renamed from dirlen.  All callers changed.
22239         Rewrite in terms of base_name, for simplicity and consistency.
22240         (dir_name): Never return NULL.  All callers changed.
22241         Do not include <stdlib.h> in test program; no longer needed.
22242         return 0; is fine for test program.
22243
22244         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
22245         New macros.
22246         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
22247
22248         * lib/path-concat.c (path_concat): Use base_len to compute
22249         base length, not strlen; this means we cannot rely on memcpy
22250         to null-terminate.
22251
22252         * lib/same.c (STREQ): Remove.
22253         (same_name): Handle the case where the basename ends in trailing '/'.
22254
22255         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
22256         a slash was stripped.  Do not strip the last slash after a
22257         file system prefix.
22258
22259 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22260
22261         * lib/Makefile.am (libfetish_a_SOURCES):
22262         Add strftime.c, since we now compile it on all hosts.
22263
22264         * lib/strftime.c (my_strftime):
22265         Define to nstrftime if emacs, but only if my_strftime is not defined.
22266         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
22267         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
22268         Add one more extra argument: a nanoseconds value.
22269         All uses changed.
22270         (ns): New macro.
22271         (my_strftime function): Add %N format.
22272         (emacs_strftimeu): Renamed from emacs_strftime,
22273         with extra ut argument.
22274
22275 2001-05-09  Paul Eggert  <eggert@twinsun.com>
22276
22277         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
22278
22279 2001-04-21  Jim Meyering  <meyering@lucent.com>
22280
22281         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
22282         doesn't interfere.
22283
22284 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22285
22286         * m4/ftruncate.m4: Check for chsize.
22287         Link with ftruncate.o unconditionally if ftruncate is missing.
22288         This was required when cross-compiling to i586-mingw32msvc.
22289
22290 2001-04-08  Jim Meyering  <meyering@lucent.com>
22291
22292         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
22293         recomputed; that's necessary when the offset spans a DST transition.
22294         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
22295
22296 2001-04-02  Jim Meyering  <meyering@lucent.com>
22297
22298         * lib/regex.h, regex.c: Update from GNU libc.
22299
22300 2001-03-24  Jim Meyering  <meyering@lucent.com>
22301
22302         * m4/jm-macros.m4: Require autoconf-2.49d.
22303
22304 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
22305
22306         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
22307
22308 2001-03-19  Paul Eggert  <eggert@twinsun.com>
22309
22310         * lib/version-etc.c (version_etc_copyright): Update to 2001.
22311
22312 2001-03-17  Jim Meyering  <meyering@lucent.com>
22313
22314         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
22315         now that the version in autoconf is equivalent.
22316         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
22317
22318         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
22319         Suggestion from Akim Demaille.
22320
22321         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
22322         (jm_PREREQ_TEMPNAME): New function.
22323
22324 2001-03-16  Paul Eggert  <eggert@twinsun.com>
22325
22326         * lib/tempname.c (uint64_t): Define to uintmax_t if
22327         not defined, and if UINT64_MAX is not defined.
22328         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
22329         Reported by John David Anglin.
22330
22331 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
22332
22333         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
22334         resolve alias if codeset is empty.
22335         * lib/config.charset (BeOS): Use wildcard syntax.
22336
22337 2001-03-13  Jim Meyering  <meyering@lucent.com>
22338
22339         * lib/path-concat.c (path_concat)
22340         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
22341         concatenating e.g., `C:' and `foo'.
22342         From Bruno Haible.
22343
22344 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22345
22346         * lib/localcharset.c (locale_charset): Don't use
22347         setlocale(LC_CTYPE,NULL). Don't return NULL.
22348         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
22349
22350 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22351
22352         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
22353         support for DOS/DJGPP.
22354
22355 2001-03-01  Paul Eggert  <eggert@twinsun.com>
22356
22357         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
22358         lacks mkstemp.  Compile our own tempname.c if we compile our own
22359         mkstemp.c, as mkstemp relies on tempname.
22360
22361 2001-03-01  Jim Meyering  <meyering@lucent.com>
22362
22363         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
22364         AH_VERBATIM really does output its argument verbatim.
22365
22366 2001-02-28  Paul Eggert  <eggert@twinsun.com>
22367
22368         * lib/Makefile.am (libfetish_a_SOURCES):
22369         Add dup-safer.c, fopen-safer.c.
22370         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
22371
22372         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
22373         * lib/unistd-safer.h: New files.
22374
22375 2001-02-25  Paul Eggert  <eggert@twinsun.com>
22376
22377         The mkstemp replacement is taken from glibc 2.2.2, with some
22378         portability fixes for use outside glibc, as follows:
22379
22380         * lib/tempname.c (struct_stat64): New macro.
22381         (direxists, __gen_tempname): Use it.
22382         This avoids a portability problem with Solaris 8.
22383
22384         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
22385         (<stddef.h>, <stdint.h>, <string.h>):
22386         Include only if STDC_HEADERS || _LIBC.
22387         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
22388         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
22389         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
22390         (__set_errno): Define this macro if <errno.h> doesn't.
22391         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
22392         Define these macros if <stdio.h> doesn't.
22393         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
22394         Define these macros if <sys/stat.h>
22395         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
22396         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
22397         __xstat64): Define if not _LIBC.
22398         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
22399         (__gen_tempname): Invoke gettimeofday only if
22400         HAVE_GETTIMEOFDAY || _LIBC;
22401         otherwise, fall back on plain "time".
22402         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
22403
22404         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
22405
22406         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
22407
22408 2001-02-18  Paul Eggert  <eggert@twinsun.com>
22409
22410         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
22411
22412 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22413
22414         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
22415         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
22416         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
22417         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22418
22419 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22420
22421         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
22422         Remove workaround macros for hosts that have mbrtowc but not
22423         mbstate_t, as we now insist on proper declarations for both
22424         before using mbrtowc.
22425
22426 2001-02-17  Jim Meyering  <meyering@lucent.com>
22427
22428         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
22429         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
22430         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
22431         UnixWare 7.1.1.
22432
22433         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
22434         rather than AC_CACHE_VAL.
22435
22436 2001-02-17  Jim Meyering  <meyering@lucent.com>
22437
22438         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
22439         around included file name.
22440
22441         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
22442
22443         * lib/strftime.c: Update from GNU libc (the only changes were to
22444         comments).
22445
22446 2001-02-17  Jim Meyering  <meyering@lucent.com>
22447
22448         * lib/regex.c: Update from libc.
22449
22450 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
22451
22452         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
22453         clash.
22454
22455 2001-02-16  Paul Eggert  <eggert@twinsun.com>
22456
22457         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
22458         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
22459         Reported by Mark Hounschell via Paul Eggert.
22460
22461 2001-02-07  Jim Meyering  <meyering@lucent.com>
22462
22463         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
22464
22465 2001-02-05  Jim Meyering  <meyering@lucent.com>
22466
22467         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
22468         it includes the patch required for `large file' support with at least
22469         HP-UX's 10.20 /bin/cc.
22470
22471 2001-02-03  Jim Meyering  <meyering@lucent.com>
22472
22473         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
22474         AS_IF, now that it works once again (mysteriously).
22475         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22476
22477 2001-01-30  Jim Meyering  <meyering@lucent.com>
22478
22479         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
22480         * m4/chown.m4: Rename conftestchown to conftest.chown.
22481         * m4/rename.m4: s/conftestdir/conftest.d1/ and
22482         s/conftestdir2/conftest.d2/.
22483         * m4/utimes.m4: s/conftestdata/conftest.data/
22484         Inspired by Pavel Roskin's change in autoconf.
22485
22486 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
22487
22488         * lib/config.charset: Update for FreeBSD 4.2.
22489
22490 2001-01-27  Jim Meyering  <meyering@lucent.com>
22491
22492         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
22493         a use of AS_IF.
22494         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22495
22496 2001-01-26  Jim Meyering  <meyering@lucent.com>
22497
22498         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
22499         quotearg.c includes it.
22500
22501 2001-01-26  Jim Meyering  <meyering@lucent.com>
22502
22503         * lib/quotearg.c: Include stddef.h.
22504         * lib/quote.c: Include stddef.h.
22505         Reported by Axel Kittenberger.
22506
22507         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
22508         line in double quotes so that it evokes a better diagnostic.
22509         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
22510         Reported by Axel Kittenberger.
22511
22512 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
22513
22514         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
22515         as if it was a `charset'.
22516
22517 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22518
22519         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
22520         has const.
22521
22522 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22523
22524         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
22525         to avoid a warning.  Add back 'const' to inptr.
22526
22527 2001-01-20  Jim Meyering  <meyering@lucent.com>
22528
22529         Be sure that headers are checked before used in code compiled
22530         for the type checks.
22531         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
22532         In place of that, invoke jm_CHECK_ALL_TYPES.
22533         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
22534         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
22535         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
22536         The check for ssize_t was mistakenly run before the test for unistd.h.
22537
22538         The configure-time check for stdbool.h was missing.
22539         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
22540         (jm_PREREQ_HASH): New function.
22541
22542 2001-01-17  Jim Meyering  <meyering@lucent.com>
22543
22544         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
22545         for autoconf-2.49c.
22546         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
22547
22548 2001-01-16  Jim Meyering  <meyering@lucent.com>
22549
22550         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
22551         From Bruno Haible.
22552
22553 2001-01-14  Jim Meyering  <meyering@lucent.com>
22554
22555         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
22556         foo and bar.  Create conftestdir/ in the script, not in the C code.
22557         Remove directories in the script, not in the C code.
22558         Remove conftestdir{,2} before trying to create the directory.
22559         Make the entire configure script fail if the mkdir fails.
22560
22561 2001-01-14  Jim Meyering  <meyering@lucent.com>
22562
22563         * lib/rename.c: New file.  From Volker Borchert.
22564         Include stdlib.h, string.h or strings.h, and xalloc.h.
22565         Use strip_trailing_slashes rather than open-coding it.
22566
22567 2001-01-03  Paul Eggert  <eggert@twinsun.com>
22568
22569         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
22570
22571 2001-01-03  Jim Meyering  <meyering@lucent.com>
22572
22573         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
22574         of local `inptr' to avoid warning with some system declarations of
22575         iconv.
22576
22577 2001-01-02  Volker Borchert  <bt@teknon.de>
22578
22579         * m4/rename.m4: New file.
22580         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
22581
22582 2001-01-01  Jim Meyering  <meyering@lucent.com>
22583
22584         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
22585         even on systems with utmpx.h.  It's necessary for the declaration of
22586         utmp's ut_user member.  Reported by Andreas Jaeger.
22587
22588         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
22589         available. They are required for the declarations of getgrgid and
22590         getpwuid resp.
22591         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
22592         Reported by Andreas Jaeger.
22593
22594 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
22595
22596         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
22597         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
22598         so `make install' also works in VPATH builds.
22599
22600 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
22601
22602         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
22603         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
22604         can be used in subdirectories.
22605
22606 2000-12-29  Paul Eggert  <eggert@twinsun.com>
22607
22608         * lib/modechange.c: Do not assume that mode_t uses the
22609         traditional octal encoding.  E.g. "chmod 1 FOO" should set
22610         the other-execute bit of FOO even if S_IXOTH != 1.
22611
22612         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
22613         WOTH, XOTH, ALLM): New macros.
22614         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
22615          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
22616         Use them.
22617         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
22618         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
22619         (mode_compile):
22620         No need to use uintmax_t; unsigned long is long enough.
22621         Don't bother to get suffix since we don't use it.
22622
22623 2000-12-26  Jim Meyering  <meyering@lucent.com>
22624
22625         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
22626         better with autoheader.
22627
22628 2000-12-24  Jim Meyering  <meyering@lucent.com>
22629
22630         * lib/hash.c (is_prime): Return explicit boolean values.
22631         (hash_get_first): Return NULL to appease Irix5.6's 89.
22632         Reported by Nelson Beebe.
22633
22634 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
22635
22636         * lib/localcharset.c (locale_charset): Add support for Win32.
22637
22638 2000-12-18  Paul Eggert  <eggert@twinsun.com>
22639
22640         * lib/physmem.h, lib/physmem.c: New files.
22641
22642         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
22643         (noinst_HEADERS): Add physmem.h.
22644
22645         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
22646         't' for compatibility with Solaris 8 sort.
22647
22648 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
22649
22650         * lib/config.charset: Add support for BeOS.
22651
22652 2000-12-17  Jim Meyering  <meyering@lucent.com>
22653
22654         * m4/dos.m4 (jm_AC_DOS): New file and macro.
22655         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
22656
22657 2000-12-16  Jim Meyering  <meyering@lucent.com>
22658
22659         This bug had a serious impact on chown: `chown N:M FILE' (for integer
22660         N and M) would have treated it like `chown N:N FILE'.
22661
22662         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
22663
22664 2000-12-16  Jim Meyering  <meyering@lucent.com>
22665
22666         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
22667         SHELLS_FILE to a file name that's useful on djgpp systems.
22668         Include stdlib.h.
22669         (ADDITIONAL_DEFAULT_SHELLS): Define.
22670         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
22671         Based mostly on a patch from Prashant TR.
22672
22673 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
22674
22675         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
22676         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
22677         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
22678
22679 2000-12-08  Andreas Schwab  <schwab@suse.de>
22680
22681         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
22682         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
22683
22684 2000-12-07  Jim Meyering  <meyering@lucent.com>
22685
22686         * lib/stripslash.c (ISSLASH): Define.
22687         (strip_trailing_slashes): Use ISSLASH rather than comparing against
22688         `/'.
22689         From Prashant TR.
22690
22691         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
22692         (dir_name_r): Declare this function as static.
22693         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
22694         manifest itself on a name containing a mix of slashes and
22695         backslashes.
22696         Make this function work with names starting with a DOS-style
22697         drive letter and colon prefix.
22698         (dir_name): Append `.' if necessary.
22699         Based mostly on patches from Prashant TR and Eli Zaretskii.
22700
22701         * lib/dirname.h (dir_name_r): Remove prototype.
22702
22703 2000-12-06  Paul Eggert  <eggert@twinsun.com>
22704
22705         * m4/off_t-format.m4: Remove this file.
22706         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
22707
22708 2000-12-06  Jim Meyering  <meyering@lucent.com>
22709
22710         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
22711         replacement strtoull, we may well need the replacement strtoul, too.
22712         Check for declarations of strtoul and strtoull.
22713         Check for strtol.  Mainly as a cue to cause automake to include
22714         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
22715         Check for limits.h -- strtol.c needs it.
22716
22717 2000-12-05  Jim Meyering  <meyering@lucent.com>
22718
22719         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
22720
22721 2000-12-04  Jim Meyering  <meyering@lucent.com>
22722
22723         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
22724         Also include memory.h, stdlib.h, unistd.h if appropriate.
22725         Reported by Andreas Jaeger (conflicting declaration of malloc).
22726
22727 2000-12-02  Jim Meyering  <meyering@lucent.com>
22728
22729         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
22730         * m4/jm-macros.m4 (jm_MACROS): require it.
22731
22732 2000-12-02  Jim Meyering  <meyering@lucent.com>
22733
22734         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
22735
22736 2000-12-01  Paul Eggert  <eggert@twinsun.com>
22737
22738         * lib/memrchr.c: Include <config.h> before any system include file.
22739
22740 2000-11-30  Jim Meyering  <meyering@lucent.com>
22741
22742         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
22743
22744 2000-11-30  Jim Meyering  <meyering@lucent.com>
22745
22746         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
22747
22748 2000-11-29  Paul Eggert  <eggert@twinsun.com>
22749
22750         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
22751
22752 2000-11-26  Jim Meyering  <meyering@lucent.com>
22753
22754         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
22755
22756 2000-11-22  Paul Eggert  <eggert@twinsun.com>
22757
22758         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
22759         size of (size_t) -1; it's not portable.
22760
22761 2000-11-17  Jim Meyering  <meyering@lucent.com>
22762
22763         * lib/strstr.c: Update from GNU libc.
22764
22765 2000-11-17  Akim Demaille  <akim@epita.fr>
22766
22767         * lib/obstack.h: Formatting changes.
22768         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
22769         prevent type checking.
22770         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
22771         cast the value to (void *): assigning a `foo *' to a `void *'
22772         variable is valid.
22773         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
22774
22775 2000-11-16  Jim Meyering  <meyering@lucent.com>
22776
22777         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
22778
22779 2000-11-11  Jim Meyering  <meyering@lucent.com>
22780
22781         * lib/error.c: Add a couple #includes, merging from GNU libc version.
22782
22783 2000-11-10  Jim Meyering  <meyering@lucent.com>
22784
22785         * lib/obstack.h: Update from GNU libc.
22786         * lib/obstack.c: Likewise.
22787
22788 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
22789
22790         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
22791
22792 2000-11-06  Paul Eggert  <eggert@twinsun.com>
22793
22794         * lib/getusershell.c (setusershell): Use rewind rather than
22795         fseek/fseeko, to avoid configuration hassles with fseeko.
22796         Don't bother opening SHELLS_FILE if shellstream is NULL;
22797         it's not necessary.
22798
22799 2000-11-05  Jim Meyering  <meyering@lucent.com>
22800
22801         * lib/makepath.h (make_dir): Declare.
22802         * lib/makepath.c (make_dir): Remove `static' attribute.
22803         Tweak a comment.
22804
22805 2000-11-04  Jim Meyering  <meyering@lucent.com>
22806
22807         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
22808
22809 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
22810
22811         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
22812         last one in a bucket, advance to the next bucket.
22813
22814 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
22815
22816         * lib/fnmatch.c: Do not comment out all the code if we are using
22817         the GNU C library, because in some cases we are replacing buggy
22818         code in the GNU C library itself.
22819
22820 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
22821
22822         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
22823         (regex_compile): Catch bogus \(\1\).
22824
22825 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22826
22827         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
22828         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
22829         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
22830
22831 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22832
22833         * lib/error.h, getline.h, modechange.h:
22834         Remove "2000" from Copyright line, as the file hasn't been
22835         changed this year other than in the copyright notice.
22836
22837         * lib/xalloc.h: Add "2000" to Copyright line, as this file
22838         was changed this year.
22839
22840 2000-10-29  Jim Meyering  <meyering@lucent.com>
22841
22842         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
22843         renaming.
22844         * m4/ls-mntd-fs.m4: Likewise
22845
22846 2000-10-29  Jim Meyering  <meyering@lucent.com>
22847
22848         * lib/xstat.in: Fix grammar in comment.
22849
22850 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
22851
22852         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
22853         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
22854         doesn't define __restrict_arr.
22855
22856 2000-10-28  Jim Meyering  <meyering@lucent.com>
22857
22858         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
22859         (jm_PREREQ_MEMCHR): New function.
22860
22861 2000-10-28  Jim Meyering  <meyering@lucent.com>
22862
22863         * lib/memchr.c: Update from libc.
22864         Adjust for portability:
22865         [HAVE_STDLIB_H]: Include stdlib.h.
22866         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
22867         Undef __memchr, too.
22868         [!weak_alias]: Define __memchr to memchr.
22869
22870         * lib/regex.c: Update from libc.
22871         * lib/regex.h: Likewise.
22872         * lib/getopt1.c: Likewise.
22873         * lib/memcmp.c: Likewise.
22874
22875         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
22876         Avoid using fseek, when possible -- it's broken by design.
22877         Patch by Ulrich Drepper.
22878
22879 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
22880
22881         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
22882         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
22883         Giving in to popular pressure to shut up the compiler with casts.
22884
22885 2000-10-26  Jim Meyering  <meyering@lucent.com>
22886
22887         * lib/strftime.c: Update from libc.
22888
22889 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
22890
22891         * regex.c: More `unsigned char' -> `re_char' changes.
22892         Also change several `int' into `re_wchar_t'.
22893         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
22894         (PUSH_FAILURE_POINTER): Don't cast any more.
22895         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
22896         We want GCC to complain, since this piece of code makes
22897         re_match non-reentrant, which *should* be fixed.
22898         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
22899         (EXTEND_BUFFER): Use RETALLOC.
22900         (SET_LIST_BIT): Don't cast.
22901         (re_wchar_t): New type.
22902         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
22903         that those two functions will always properly return.
22904         (IMMEDIATE_QUIT_CHECK): Cast to void.
22905         (analyse_first): Use recursion rather than an explicit stack.
22906         (re_compile_fastmap): Can't fail anymore.
22907         (re_search_2): Don't check re_compile_fastmap for failure.
22908         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
22909         Now also sets the new value (passed in a new argument).
22910         (re_match_2_internal): Use it.
22911         Also, use a new var `reg' of type size_t when looping through regs
22912         rather than reuse the inappropriate `mcnt'.
22913
22914 2000-10-25  Jim Meyering  <meyering@lucent.com>
22915
22916         * lib/obstack.c: Update from libc.
22917
22918 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
22919
22920         * regex.c (regex_compile): Change the way of handling a range from
22921         a char less than 256 to a char not less than 256.
22922
22923 2000-10-24  Andrew Innes  <andrewi@gnu.org>
22924
22925         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
22926         NT-Emacs only.
22927         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
22928         so that re_search functions only quit when callers expect them to.
22929
22930 2000-10-23  Jim Meyering  <meyering@lucent.com>
22931
22932         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
22933         wrong.  That set_locale call must not have any side effects.
22934         From Paul Eggert.
22935
22936 2000-10-22  Jim Meyering  <meyering@lucent.com>
22937
22938         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
22939         [CYCLIC]: Remove now-unused definition.
22940
22941         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
22942         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
22943         Suggestion from Ulrich Drepper.
22944
22945 2000-10-21  Jim Meyering  <meyering@lucent.com>
22946
22947         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
22948         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
22949         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
22950
22951 2000-10-21  Jim Meyering  <meyering@lucent.com>
22952
22953         * lib/dirname.c (memrchr): Declare if necessary.
22954         (dir_name): Remove the restriction that there be no
22955         trailing slashes.  Now, this code skips past them, effectively
22956         ignoring them.
22957         [TEST_DIRNAME] (main): New unit tests.
22958
22959         * lib/memrchr.c: New file from GNU libc.
22960         Undef __memrchr, too.
22961         [!weak_alias]: Define __memrchr to memrchr.
22962         Guard weak_alias use with `#ifdef weak_alias'.
22963
22964 2000-10-21  Jim Meyering  <meyering@lucent.com>
22965
22966         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
22967         (dir_name): Use dir_name_r.
22968         * lib/dirname.h (dir_name_r): Declare it.
22969
22970 2000-10-17  Jim Meyering  <meyering@lucent.com>
22971
22972         * lib/quote.h (PARAMS): Define and use.
22973         Reported by Akim Demaille.
22974
22975         * lib/getopt.c: Update from libc.
22976
22977 2000-10-16  Jim Meyering  <meyering@lucent.com>
22978
22979         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
22980         setlocale.
22981         From Jan Fedak.
22982
22983 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
22984
22985         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
22986
22987 2000-09-25  Jim Meyering  <meyering@lucent.com>
22988
22989         * lib/md5.h (rol): Define (from GnuPG).
22990
22991         * lib/sha.c: Give credit (GnuPG) where due.
22992         (M): Use rol rather than open-coding it.
22993         Add a FIXME comment.
22994
22995 2000-09-21  Jim Meyering  <meyering@lucent.com>
22996
22997         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
22998         Reported by Michael Stone.
22999
23000 2000-09-20  Jim Meyering  <meyering@lucent.com>
23001
23002         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
23003         (noinst_HEADERS): Add sha.h.
23004         Based on code from Scott G. Miller and from GnuPG.
23005
23006 2000-09-18  Jim Meyering  <meyering@lucent.com>
23007
23008         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
23009         LIBS. Otherwise, everyone ends up linking with -lelf for some
23010         configurations.
23011         Reported by Mike Stone.
23012
23013 2000-09-15  Jim Meyering  <meyering@lucent.com>
23014
23015         * lib/regex.c: Update from libc.
23016
23017 2000-09-10  Jim Meyering  <meyering@lucent.com>
23018
23019         * lib/getopt.c (_getopt_internal): Update from glibc.
23020
23021 2000-09-09  Jim Meyering  <meyering@lucent.com>
23022
23023         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
23024         think it should be used as a general replacement for isascii.
23025         * lib/fnmatch.c: Likewise.
23026         * lib/mbswidth.c: Likewise
23027         * lib/regex.c: Likewise.
23028
23029         Don't use atoi.
23030         * lib/userspec.c: Include sys/param.h and limits.h.
23031         Include xstrtol.h.
23032         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23033         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
23034         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
23035         UID, GID.  Check range.
23036
23037 2000-09-06  Jim Meyering  <meyering@lucent.com>
23038
23039         * lib/getopt.c (_getopt_internal): Update from glibc.
23040
23041 2000-08-30  Jim Meyering  <meyering@lucent.com>
23042
23043         * lib/strftime.c: Merge in changes from GNU libc.
23044
23045 2000-08-26  Jim Meyering  <meyering@lucent.com>
23046
23047         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
23048         * m4/fpending.m4: New file.
23049
23050 2000-08-26  Jim Meyering  <meyering@lucent.com>
23051
23052         * lib/closeout.c: Include "__fpending.h".
23053         (close_stdout_status): Return right away if there's nothing to flush.
23054
23055         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
23056         * lib/__fpending.c: New file.
23057         * lib/__fpending.h: New file.
23058
23059 2000-08-20  Jim Meyering  <meyering@lucent.com>
23060
23061         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
23062         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
23063         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
23064
23065 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
23066
23067         Improve fileutils installation on systems where running
23068         programs (like install) can't be unlinked.
23069         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
23070         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
23071
23072 2000-08-07  Paul Eggert  <eggert@twinsun.com>
23073
23074         Standardize on "memory exhausted" instead of "Memory exhausted"
23075         or "virtual memory exhausted".
23076         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
23077         "virtual memory exhausted".
23078         * lib/same.c (same_name): Invoke xalloc_die instead of printing
23079         our own message.
23080         * lib/userspec.c (parse_user_spec): Likewise.
23081         * lib/bumpalloc.h: comment fix
23082         * lib/same.c, userspec.c: Include xalloc.h.
23083
23084         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
23085         not char *const and pointing to a constant array.
23086         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
23087         (xrealloc): Comment fix.
23088
23089         * lib/userspec.c (parse_user_spec):
23090         Don't translate a message until just before returning,
23091         to avoid unnecessary translation.
23092
23093 2000-08-07  Jim Meyering  <meyering@lucent.com>
23094
23095         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
23096         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
23097         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
23098         getgroups.c, gethostname.c, getopt.h, group-member.c,
23099         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
23100         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
23101         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
23102         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
23103         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
23104         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
23105         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
23106         yesno.c: Back out Copyright date changes for each file with no change
23107         this year.  This eases coordination with other programs using the same
23108         source code modules.  From Paul Eggert.
23109
23110 2000-08-06  Paul Eggert  <eggert@twinsun.com>
23111
23112         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
23113         not char, for compatibility with glibc 2.1.3 strftime.c.
23114
23115 2000-08-03  Greg McGary  <greg@mcgary.org>
23116
23117         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
23118         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
23119         (EXTEND_BUFFER): Use them.
23120
23121 2000-08-01  Jim Meyering  <meyering@lucent.com>
23122
23123         * lib/dirname.c (ISSLASH): Define.
23124         (BACKSLASH_IS_PATH_SEPARATOR): Define.
23125         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
23126         both `\' and `/' may be use as path separators.
23127         Based on a patch from Prashant TR.
23128
23129 2000-07-31  Paul Eggert  <eggert@twinsun.com>
23130
23131         * lib/quotearg.c (quotearg_n_options): Don't make the initial
23132         slot vector a constant, since it might get modified.
23133
23134 2000-07-31  Jim Meyering  <meyering@lucent.com>
23135
23136         * lib/xmalloc.c: Use `virtual memory exhausted', not
23137         `Memory exhausted'.
23138         * lib/obstack.c (print_and_abort): Likewise.
23139
23140 2000-07-30  Paul Eggert  <eggert@twinsun.com>
23141
23142         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
23143         buffer, so that the caller can always quote one small
23144         component of a "memory exhausted" message in slot 0.
23145         From a suggestion by Jim Meyering.
23146
23147 2000-07-30  Jim Meyering  <meyering@lucent.com>
23148
23149         * lib/makepath.c (make_path): Quote the other instance, too.
23150
23151         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
23152         (STATIC_BUF_SIZE): Define.
23153         (quotearg_n_options): Use only statically allocated storage when
23154         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
23155         than STATIC_BUF_SIZE.
23156
23157 2000-07-29  Jim Meyering  <meyering@lucent.com>
23158
23159         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
23160         * lib/dirname.c (dir_name): Likewise.
23161
23162         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
23163         `/'.
23164
23165         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
23166         (dir_name): Assert that there are no trailing slashes.
23167
23168 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
23169
23170         * lib/mbswidth.h (mbswidth): Add a flags argument.
23171         (mbswidth): New declaration.
23172         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
23173         * lib/mbswidth.c (mbswidth): Add a flags argument.
23174         (mbsnwidth): New function.
23175
23176 2000-07-24  Jim Meyering  <meyering@lucent.com>
23177
23178         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
23179
23180 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23181
23182         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
23183
23184 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23185
23186         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
23187         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
23188         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
23189         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
23190         invoke multibyte primitives.
23191
23192 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23193
23194         * lib/quotearg.c:
23195         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
23196         so that mbstate_t is always defined.
23197
23198         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
23199         be 1 in at least one GCC installation, and this configuration
23200         error is likely to be common.  Ignoring MB_LEN_MAX hurts
23201         performance on hosts that have mbrtowc but have only unibyte
23202         locales, but I assume these hosts are rare.
23203
23204 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23205
23206         * lib/mbswidth.c (_XOPEN_SOURCE):
23207         Don't define; this causes problems on Solaris 7.
23208         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
23209
23210 2000-07-23  Jim Meyering  <meyering@lucent.com>
23211
23212         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
23213         too: getgrgid, getpwuid, getuid.
23214
23215 2000-07-23  Jim Meyering  <meyering@lucent.com>
23216
23217         * lib/basename.c (base_name): Add an assertion.
23218
23219 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
23220
23221         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
23222         shadow its mbsinit function.
23223
23224 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23225
23226         * lib/mbswidth.h: New file.
23227         * lib/mbswidth.c: New file.
23228         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
23229         (noinst_HEADERS): Add mbswidth.h.
23230
23231 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23232
23233         * lib/config.charset: Add support for FreeBSD. Improve support for
23234         HP-UX and IRIX 6.
23235
23236 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
23237
23238         * m4/mbswidth.m4: New file.
23239         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
23240
23241 2000-07-15  Jim Meyering  <meyering@lucent.com>
23242
23243         * lib/makepath.c: Include quote.h.
23244         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
23245         corresponding argument in a `quote (...)' call.
23246         Give better diagnostics.
23247
23248         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
23249         (noinst_HEADERS): Add quote.h.
23250
23251         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
23252         from tar's src/misc.c.
23253         * lib/quote.h: New file.  Prototypes for same.
23254
23255 2000-07-14  Paul Eggert  <eggert@twinsun.com>
23256
23257         From a suggestion by Bruno Haible.
23258         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
23259         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
23260         to decide whether to define the BeOS workaround macro;
23261         this adjusts to the change to AC_MBSTATE_T.
23262
23263 2000-07-14  Jim Meyering  <meyering@lucent.com>
23264
23265         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
23266         jm_AC_TYPE_UINTMAX_T.
23267
23268 2000-07-13  Paul Eggert  <eggert@twinsun.com>
23269
23270         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
23271
23272         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
23273         quotearg_buffer_restyled): Add support for
23274         clocale_quoting_style.  Undo previous change to
23275         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
23276         and "{RIGHT QUOTATION MARK}" msgids.
23277
23278 2000-07-10  Paul Eggert  <eggert@twinsun.com>
23279
23280         From a suggestion by Bruno Haible.
23281         * m4/mbstate_t.m4 (AC_MBSTATE_T):
23282         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
23283         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
23284         and mbstate_t, to a single-part test that simply defines mbstate_t.
23285         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
23286         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
23287
23288 2000-07-10  Jim Meyering  <meyering@lucent.com>
23289
23290         * m4/strerror_r.m4: Mirror the correction made in autoconf.
23291
23292         * m4/gnu-source.m4: Output to confdefs.h directly.
23293         Suggestion from Akim Demaille.
23294
23295 2000-07-09  Paul Eggert  <eggert@twinsun.com>
23296
23297         The old behavior of quoting `like this' doesn't look good with
23298         newer, ISO-style fonts.  See:
23299         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
23300
23301         Instead, quote "like this" by default.  Let the translator
23302         tailor the locale-specific quoting behavior by providing
23303         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
23304
23305         * lib/quotearg.c (N_): New macro.
23306         (gettext_default): New function.
23307         (quotearg_buffer_restyled): Use
23308         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
23309         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
23310
23311 2000-07-09  Jim Meyering  <meyering@lucent.com>
23312
23313         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
23314         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
23315
23316         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
23317         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
23318
23319 2000-07-09  Jim Meyering  <meyering@lucent.com>
23320
23321         * lib/Most files: Update copyright dates to include 2000.
23322
23323 2000-07-08  Jim Meyering  <meyering@lucent.com>
23324
23325         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
23326         if not defined.
23327         (xgethostname): Remove now-unnecessary #ifdef.
23328         Move declaration of `err' into loop where it's used.
23329
23330 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23331         and Bruno Haible  <haible@clisp.cons.org>
23332
23333         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
23334         only if the test for an object-type mbstate_t fails.  This
23335         prevents us from mistakenly reporting that mbstate_t is a
23336         system object type after we "#define mbstate_t int" to work
23337         around its lack.
23338
23339 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23340         and Bruno Haible  <haible@clisp.cons.org>
23341
23342         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
23343
23344 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23345
23346         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
23347         to strerror_r.
23348         Include <ctype.h> for use of isalpha.
23349
23350 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23351
23352         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
23353         by allocating a larger buffer. Test the gethostname return value for
23354         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
23355         returns an error and ENAMETOOLONG isn't defined.
23356
23357 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23358
23359         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
23360         dimension.
23361
23362 2000-07-04  Jim Meyering  <meyering@lucent.com>
23363
23364         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
23365         of the deprecated AC_CHECKING.
23366
23367 2000-07-04  Jim Meyering  <meyering@lucent.com>
23368
23369         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
23370         Reported by Bruno Haible.
23371
23372 2000-07-04  Jim Meyering  <meyering@lucent.com>
23373
23374         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
23375         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
23376         lacks mbrtowc.
23377
23378 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23379
23380         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
23381         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
23382
23383 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23384         and Bruno Haible  <haible@clisp.cons.org>
23385
23386         * lib/quotearg.c (mbrtowc):
23387         Assign to *pwc, and return 1 only if result is nonzero.
23388         (iswprint): Use ISPRINT when substituting our own mbrtowc.
23389
23390 2000-07-03  Jim Meyering  <meyering@lucent.com>
23391
23392         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
23393
23394 2000-07-03  Jim Meyering  <meyering@lucent.com>
23395
23396         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
23397         This is necessary to get a definition of e.g., UTMP_FILE on
23398         HP-UX 10.20.
23399         From Bob Proulx.
23400
23401 2000-07-02  Jim Meyering  <meyering@lucent.com>
23402
23403         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
23404
23405         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
23406         AC_LIBOBJ(function_name).
23407         * m4/chown.m4: Likewise.
23408         * m4/fnmatch.m4: Likewise.
23409         * m4/ftruncate.m4: Likewise.
23410         * m4/getgroups.m4: Likewise.
23411         * m4/getline.m4: Likewise.
23412         * m4/group-member.m4: Likewise.
23413         * m4/jm-macros.m4: Likewise.
23414         * m4/lstat.m4: Likewise.
23415         * m4/malloc.m4: Likewise.
23416         * m4/memcmp.m4: Likewise.
23417         * m4/nanosleep.m4: Likewise.
23418         * m4/putenv.m4: Likewise.
23419         * m4/realloc.m4: Likewise.
23420         * m4/regex.m4: Likewise.
23421         * m4/stat.m4: Likewise.
23422         * m4/strftime.m4: Likewise.
23423
23424 2000-07-02  Jim Meyering  <meyering@lucent.com>
23425
23426         * lib/quotearg.c (mbstate_t): Don't define here.
23427
23428 2000-07-02  Jim Meyering  <meyering@lucent.com>
23429
23430         * lib/nanosleep.c (SIGCONT): Define if not already defined.
23431
23432 2000-07-01  Jim Meyering  <meyering@lucent.com>
23433
23434         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
23435
23436 2000-07-01  Jim Meyering  <meyering@lucent.com>
23437
23438         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
23439         problem.
23440
23441 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23442
23443         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
23444         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
23445
23446 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23447
23448         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
23449         per change in ../m4/ls-mntd-fs.m4.
23450         (read_filesystem_list): Ignore symbolic links.
23451
23452 2000-06-29  Jim Meyering  <meyering@lucent.com>
23453
23454         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
23455         for declaration of strcmp.
23456
23457         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
23458
23459         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
23460         Avoid warning by casting result to `char *' to remove `const'.
23461
23462 2000-06-28  Jim Meyering  <meyering@lucent.com>
23463
23464         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
23465         included by quotearg.c, for which we perform this test.  From
23466         Bruno Haible.
23467
23468 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23469
23470         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
23471         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
23472         <utmpx.h> exists, put readutmp.o into LIBOBJS.
23473
23474 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23475
23476         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
23477
23478 2000-06-26  Paul Eggert  <eggert@twinsun.com>
23479
23480         savedir now sets errno on failure and invokes xmalloc to get memory.
23481         Fix a couple of other minor bugs while we're at it.
23482
23483         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
23484         (NAMLEN): Remove macro.
23485         (malloc, realloc): Remove decls.
23486         (stpcpy): Likewise.
23487         ("xalloc.h"): Include.
23488         (NAME_SIZE_DEFAULT): New macro.
23489         (savedir): Use xmalloc / xrealloc to allocate memory.
23490         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
23491         Skip "" directory entries.
23492         Use strlen to calculate directory entry length, since the old method
23493         is rarely used these days and isn't worth supporting.
23494         Don't use a pointer after freeing it.
23495         Check for integer overflow when calculating allocation size.
23496         Use memcpy to copy entries, instead of stpcpy.
23497         Set errno properly when returning NULL.
23498         Check for readdir error.
23499
23500 2000-06-26  Jim Meyering  <meyering@lucent.com>
23501
23502         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
23503
23504 2000-06-25  Jim Meyering  <meyering@lucent.com>
23505
23506         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
23507         Linux header bug when _XOPEN_SOURCE is defined to 500.
23508
23509 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23510
23511         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
23512         deficiency.
23513
23514 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23515
23516         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
23517         Include xalloc.h.
23518         Don't include <stdlib.h>.  Don't declare malloc, realloc.
23519
23520 2000-06-24  Jim Meyering  <meyering@lucent.com>
23521
23522         * m4/strerror_r.m4: Revive this file -- to try out an experimental
23523         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
23524         for which strerror does return char*, but which lacks a conveniently
23525         accessible declaration of the function.  If the compile-test says
23526         strerror_r doesn't work, then resort to a `run'-test that works on
23527         BeOS and segfaults on DEC Unix.
23528
23529 2000-06-24  Jim Meyering  <meyering@lucent.com>
23530
23531         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
23532
23533 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23534
23535         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
23536         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
23537
23538 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23539
23540         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
23541         (mbrtowc, mbstate_t): Define substitutes if
23542         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
23543         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
23544         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
23545
23546 2000-06-23  Jim Meyering  <meyering@lucent.com>
23547
23548         * m4/afs.m4: Add missing AC_MSG_RESULT.
23549         Reported by Bruno Haible.
23550
23551         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
23552         Suggestion from Bruno Haible.
23553
23554 2000-06-23  Jim Meyering  <meyering@lucent.com>
23555
23556         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
23557
23558 2000-06-21  Jim Meyering  <meyering@lucent.com>
23559
23560         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
23561
23562 2000-06-21  Jim Meyering  <meyering@lucent.com>
23563
23564         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
23565         (noinst_HEADERS): Add getstr.h.
23566
23567         * lib/getline.c (getstr): Move into a separate file.
23568         * lib/getstr.c (getstr): New file, extracted from getline.c, with
23569         the following changes: new parameter, delim2; both delim[12]
23570         parameters have type `int', not `char'.  The latter would lose
23571         with 8-bit delimiters.
23572         * lib/getstr.h: New file.
23573
23574 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23575
23576         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
23577         than 1024, return a memory chunk of least possible size, instead
23578         of size PATH_MAX + 2. In the loop, increment the size proportionally.
23579         Use free/xmalloc instead of xrealloc to avoid copying for very long
23580         paths.
23581
23582 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23583
23584         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
23585         the empty string.
23586
23587 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23588
23589         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
23590         address, not strdup.  Include <stdlib.h> and don't declare free().
23591
23592 2000-06-19  Jim Meyering  <meyering@lucent.com>
23593
23594         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
23595
23596 2000-06-18  Jim Meyering  <meyering@lucent.com>
23597
23598         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
23599
23600         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
23601         `checking whether...' message to be consistent with that of the
23602         lstat test.
23603
23604 2000-06-18  Jim Meyering  <meyering@lucent.com>
23605
23606         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
23607         Besides, these days every porting target provides a mkdir function.
23608
23609         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
23610         needed. (this snippet comes from src/system.h).
23611
23612 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
23613
23614         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
23615
23616 2000-06-15  Paul Eggert  <eggert@twinsun.com>
23617
23618         * lib/human.c (adjust_value): New function.
23619         (human_readable_inexact): Apply rounding style even when
23620         printing approximate values.
23621
23622 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23623
23624         * lib/human.c (human_readable_inexact): Allow an input block
23625         size that is not a multiple of the output block size, and vice versa.
23626         Reported by Piergiorgio Sartor.
23627
23628 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23629
23630         * lib/getdate.y (get_date): Apply relative times after time
23631         zone indicator, not before.  Reported by Todd A. Jacobs.
23632
23633 2000-06-13  Jim Meyering  <meyering@lucent.com>
23634
23635         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
23636
23637         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
23638
23639 2000-06-12  Paul Eggert  <eggert@twinsun.com>
23640
23641         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
23642
23643 2000-06-12  Jim Meyering  <meyering@lucent.com>
23644
23645         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
23646         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
23647         optional argument.
23648         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
23649         the optional argument, `lib'.
23650
23651 2000-06-08  Jim Meyering  <meyering@lucent.com>
23652
23653         * m4/largefile.m4: Remove file (now that it's part of autoconf).
23654
23655 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23656
23657         Rewrite largefile configuration so that we don't need to run
23658         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
23659         AC_CANONICAL_HOST in configure.in -- jmm]
23660
23661         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
23662         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
23663         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
23664         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
23665         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
23666         All uses changed.
23667         Instead of inspecting the output of getconf, try to compile the
23668         test program without and with the macro definition.
23669         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
23670         for getconf.  Instead, check for the needed flags by compiling
23671         test programs.
23672
23673 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23674
23675         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
23676
23677 2000-06-04  Jim Meyering  <meyering@lucent.com>
23678
23679         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
23680         SunOS 4.1.4 for which gid_t is an unsigned type.
23681
23682 2000-06-03  Jim Meyering  <meyering@lucent.com>
23683
23684         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
23685         now that autoconf requires that.
23686
23687         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
23688         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
23689         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
23690
23691 2000-06-03  Jim Meyering  <meyering@lucent.com>
23692
23693         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
23694
23695 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23696
23697         * m4/glibc21.m4: New file.
23698         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
23699
23700 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23701
23702         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
23703         newer, don't install charset.alias.
23704         * lib/config.charset: Change the Linux/glibc rules so they become empty
23705         on glibc-2.1 or newer.
23706
23707 2000-06-02  Jim Meyering  <meyering@lucent.com>
23708
23709         * lib/mountlist.c: Back out last change.  Instead, do this...
23710         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
23711         me_dummy member using the same `ignore'-testing code.
23712         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
23713         fs_type strings.
23714         From Mark D. Roth.
23715
23716 2000-05-29  Jim Meyering  <meyering@lucent.com>
23717
23718         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
23719         mounts with the `ignore' attribute.  Based on a patch from
23720         Mark D. Roth.
23721
23722 2000-05-28  Jim Meyering  <meyering@lucent.com>
23723
23724         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
23725         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23726         * m4/stat.m4: Likewise.
23727         * m4/lstat.m4: Likewise.
23728         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
23729
23730         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
23731         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
23732
23733 2000-05-26  Jim Meyering  <meyering@lucent.com>
23734
23735         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
23736
23737 2000-05-24  Jim Meyering  <meyering@lucent.com>
23738
23739         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
23740         autoconf requires that.
23741         * m4/lib-check.m4: Likewise.
23742         * m4/jm-macros.m4: Likewise.
23743         * m4/strftime.m4: Likewise.
23744
23745         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
23746         AC_CHECK_DECLS, now that autoconf requires that.
23747
23748 2000-05-22  Jim Meyering  <meyering@lucent.com>
23749
23750         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23751         * m4/lstat.m4: Likewise.
23752
23753 2000-05-22  Jim Meyering  <meyering@lucent.com>
23754
23755         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
23756
23757 2000-05-20  Jim Meyering  <meyering@lucent.com>
23758
23759         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
23760         (jm_PREREQ): Use it.
23761
23762 2000-05-18  Jim Meyering  <meyering@lucent.com>
23763
23764         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
23765         back, too, since it may have been modified by allocate_entry.
23766         (hash_delete): Rewrite to use neither the assignment operator
23767         nor the comma operator in an if-expression.
23768
23769 2000-05-15  Paul Eggert  <eggert@twinsun.com>
23770
23771         * lib/closeout.c:
23772         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
23773         Remove; no longer needed.
23774         "quotearg.h": Add include.
23775         (file_name): Do not bother to explicitly initialize to NULL; it's less
23776         efficient on some hosts.
23777         (close_stdout_status): Remove test as to whether stdout was already
23778         closed; it breaks for the case "echo x | sort >&-".
23779         Quote file name colons.
23780         Do not assume that _("write error") lacks format strings.
23781
23782 2000-05-15  Jim Meyering  <meyering@lucent.com>
23783
23784         * lib/version-etc.c (version_etc_copyright): Update the copyright
23785         string used in all --version output.
23786
23787 2000-05-14  Jim Meyering  <meyering@lucent.com>
23788
23789         * lib/closeout.c (close_stdout_set_file_name): New function.
23790         (close_stdout_status): Use new file-scoped global.
23791         Return right away if fstat says the stdout file descriptor is invalid.
23792         * lib/closeout.h (close_stdout_set_file_name): Declare.
23793
23794 2000-05-10  Jim Meyering  <meyering@lucent.com>
23795
23796         * lib/closeout.c [default_exit_status]: New file-scoped variable.
23797         (close_stdout_set_status): New function.
23798         * lib/closeout.h (close_stdout_set_status): Declare.
23799
23800 2000-05-09  Jim Meyering  <meyering@lucent.com>
23801
23802         * m4/gettext.m4: Rename this...
23803         * m4/libintl.m4: ...to this.
23804
23805 2000-05-08  Jim Meyering  <meyering@lucent.com>
23806
23807         * lib/long-options.c: Don't include closeout.h.
23808         (parse_long_options): Don't call close_stdout for --version.
23809
23810 2000-05-06  Paul Eggert  <eggert@twinsun.com>
23811
23812         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
23813         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
23814         2.1.3 bug.  This avoids a clash when files like regex.c define
23815         _GNU_SOURCE.
23816
23817 2000-05-06  Jim Meyering  <meyering@lucent.com>
23818
23819         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
23820         (AC_REPLACE_FUNCS): Add strnlen.
23821
23822         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
23823         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
23824
23825         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
23826         AC_SEARCH_LIBS call for nanosleep.
23827         (LIB_NANOSLEEP): Set and AC_SUBST.
23828
23829 2000-05-06  Jim Meyering  <meyering@lucent.com>
23830
23831         * lib/strnlen.c: Undefine __strnlen and strnlen.
23832         [!weak_alias]: Define __strnlen to strnlen.
23833
23834         * lib/atexit.c: New file, from libiberty.
23835
23836 2000-05-06  Jim Meyering  <meyering@lucent.com>
23837
23838         * lib/closeout.c (close_stdout_status): Also check for errors on the
23839         stderr stream.
23840
23841 2000-05-05  Jim Meyering  <meyering@lucent.com>
23842
23843         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
23844         AC_SEARCH_LIBS call for clock_gettime.
23845         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
23846
23847         * m4/search-libs.m4: Update from autoconf.
23848
23849         su doesn't work on Solaris 2.6.
23850         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
23851         <shadow.h>.  Reported by Dragos Harabor.
23852
23853 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
23854
23855         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
23856         memcpy instead of xmalloc, xrealloc, path_concat.
23857         (locale_charset): Treat empty environment variables as absent.
23858         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
23859
23860 2000-05-04  Jim Meyering  <meyering@lucent.com>
23861
23862         * lib/getopt.c: Update from glibc.
23863         * lib/obstack.c: Likewise.
23864         * lib/obstack.h: Likewise.
23865         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
23866         file
23867
23868         * lib/regex.h: Likewise.
23869         * lib/strndup.c: Likewise.
23870         * lib/strnlen.c: New file, from glibc.
23871
23872 2000-05-03  Jim Meyering  <meyering@lucent.com>
23873
23874         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
23875
23876 2000-05-02  Paul Eggert  <eggert@twinsun.com>
23877
23878         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
23879         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
23880         compile-time test, rather than inspecting host and OS, to
23881         decide whether to define _LARGEFILE_SOURCE.
23882
23883 2000-05-01  Jim Meyering  <meyering@lucent.com>
23884
23885         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
23886
23887         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
23888         Based on a patch from Bruno Haible.
23889
23890 2000-05-01  Jim Meyering  <meyering@lucent.com>
23891
23892         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
23893
23894 2000-04-29  Jim Meyering  <meyering@lucent.com>
23895
23896         * lib/path-concat.c: Declare strdup only if it's not defined.
23897         * lib/canon-host.c: Likewise.
23898
23899 2000-04-28  Jim Meyering  <meyering@lucent.com>
23900
23901         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
23902         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
23903         is included first, then limits.h is included by locale.h by libintl.h.
23904         From John David Anglin.
23905
23906 2000-04-25  Jim Meyering  <meyering@lucent.com>
23907
23908         * lib/makepath.c (S_IRWXUGO): Define.
23909         (make_path): Always perform explicit chmod if MODE specifies any
23910         of the `special' permission bits.  Prompted by a bug report against
23911         install from Mate Wierdl and Joost van Baal.
23912
23913 2000-04-18  Jim Meyering  <meyering@lucent.com>
23914
23915         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
23916         (jm_PREREQ): Use it.
23917
23918 2000-04-18  Jim Meyering  <meyering@lucent.com>
23919
23920         * lib/README: New file.
23921
23922         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
23923         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
23924
23925 2000-04-17  Jim Meyering  <meyering@lucent.com>
23926
23927         Get it right :-)
23928         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
23929         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
23930         Suggestion from Akim Demaille.
23931
23932 2000-04-17  Jim Meyering  <meyering@lucent.com>
23933
23934         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
23935         the definition of it to rpl_strftime also defined-away the system's
23936         declaration.
23937
23938 2000-04-15  Jim Meyering  <meyering@lucent.com>
23939
23940         Use `C' to denote so-called `contiguous' files, the same way
23941         that tar does.
23942         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
23943         (ftypelet): Use S_ISCTG.
23944         From Michael Deutschmann.
23945
23946 2000-04-14  Jim Meyering  <meyering@lucent.com>
23947
23948         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
23949         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
23950         clobbered.
23951
23952 2000-04-14  Jim Meyering  <meyering@lucent.com>
23953
23954         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
23955
23956 2000-04-13  Jim Meyering  <meyering@lucent.com>
23957
23958         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
23959         AH_VERBATIM to insert required #ifndef into config.h.in.
23960         Suggestion from Akim Demaille.
23961
23962 2000-04-12  Jim Meyering  <meyering@lucent.com>
23963
23964         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
23965         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
23966         Christian Krackowizer.
23967
23968         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
23969         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
23970         (AC_SYS_LARGEFILE): Require.
23971         (AM_C_PROTOTYPES): Require.
23972
23973 2000-04-08  Jim Meyering  <meyering@lucent.com>
23974
23975         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
23976         names don't conflict.  Reported by Eli Zaretskii.
23977
23978 2000-04-07  Jim Meyering  <meyering@lucent.com>
23979
23980         * lib/putenv.c: Move inclusion of errno.h so it follows that of
23981         sys/types.h, to work around system header problems on AIX 3.2.5.
23982         From Bruno Haible.
23983
23984 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
23985
23986         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
23987         bug.  Deal with the different error behavior of Irix iconv.
23988
23989 2000-04-05  Paul Eggert  <eggert@twinsun.com>
23990
23991         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
23992         IRIX if the installer said otherwise.
23993
23994 2000-04-05  Jim Meyering  <meyering@lucent.com>
23995
23996         Portability tweaks required for ultrix4.3.
23997         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
23998         (jm_CHECK_DECLS): Add getutent to the list of functions.
23999         (_jm_DECL_HEADERS): Add utmpx.h.
24000         From John David Anglin.
24001
24002         * m4/strftime.m4: Back out the 2000-04-02 change.
24003         Instead of that change, simply undefine putenv in the test program.
24004
24005 2000-04-05  Jim Meyering  <meyering@lucent.com>
24006
24007         Portability tweaks required for ultrix4.3.
24008         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
24009         getutent.
24010         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
24011         * lib/canon-host.c: Declare strdup.
24012         * lib/path-concat.c: Likewise.
24013         From John David Anglin.
24014
24015 2000-04-04  Jim Meyering  <meyering@lucent.com>
24016
24017         Be more DOS 8.3-friendly.
24018         * lib/ref-add.sin: Renamed from ref-add.sed.in.
24019         * lib/ref-del.sin: Renamed from ref-del.sed.in.
24020         * lib/Makefile.am: Reflect renaming.
24021         Reported by Eli Zaretskii.
24022
24023         Use a temporary file name that won't clash with `charset.alias'
24024         in the DOS 8.3 name space.
24025         * lib/Makefile.am (charset_tmp): Define.
24026         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
24027         (uninstall-local): Likewise.
24028         Reported by Eli Zaretskii.
24029
24030 2000-04-03  Jim Meyering  <meyering@lucent.com>
24031
24032         * m4/gettext.m4: Fix typo in comment.
24033
24034         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
24035         textutils/configure.in).  Suggestion from Paul Eggert.
24036         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
24037
24038 2000-04-02  Paul Eggert  <eggert@twinsun.com>
24039
24040         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
24041         variable in the shell rather than using putenv, which isn't
24042         portable.  This avoids the configure-time inter-test dependency
24043         on the potentially-renamed putenv function.
24044
24045 2000-03-30  Paul Eggert  <eggert@twinsun.com>
24046
24047         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
24048         before checking struct stat.st_blksize, so that
24049         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
24050
24051 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24052
24053         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
24054         since strftime.c uses HAVE_STRFTIME to decide whether to use
24055         the underlying strftime.
24056
24057 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24058
24059         * lib/time/strftime.c (my_strftime): Make sure we call the system
24060         strftime, not ourselves, when invoking the underlying strftime.
24061
24062 2000-03-24  Jim Meyering  <meyering@lucent.com>
24063
24064         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
24065         (charset_alias): Define.
24066         (install-exec-local): Factor out common code.
24067         (uninstall-local): Split lines longer than 80.
24068         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
24069         (SUFFIXES): Define.
24070         (.sed.in.sed): New rule.  Don't redirect directly to $@.
24071         (CLEANFILES): Add ref-add.sed and ref-del.sed.
24072
24073 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
24074
24075         * lib/config.charset: Output a line containing "Packages using this
24076         file".
24077         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
24078         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
24079         ref-del.sed): New rules.
24080
24081 2000-03-17  Jim Meyering  <meyering@lucent.com>
24082
24083         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
24084         Otherwise, include <strings.h>
24085
24086 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
24087
24088         * lib/unicodeio.c (utf8_wctomb): New function.
24089         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
24090         format instead of in UCS-4 with platform dependent endianness.
24091
24092 2000-03-10  Jim Meyering  <meyering@lucent.com>
24093
24094         * m4/lib-check.m4: Look for getspnam in -lgen, too.
24095         From Marco Franzen.
24096
24097 2000-03-07  Paul Eggert  <eggert@twinsun.com>
24098
24099         * lib/savedir.c (savedir): Work even if directory size is
24100         negative; this can happen with some screwy NFS configurations.
24101
24102 2000-03-06  Jim Meyering  <meyering@lucent.com>
24103
24104         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
24105         if it's NULL (because we ran out of memory).  From Bruno Haible.
24106
24107 2000-03-05  Jim Meyering  <meyering@lucent.com>
24108
24109         * lib/localcharset.c ("path-concat.h"): Include.
24110         (get_charset_aliases): Use path_concat instead of ANSI string
24111         concatenation.
24112
24113         * lib/unicodeio.h (PARAMS): Define.
24114         Use it to guard prototype.
24115
24116 2000-03-04  Jim Meyering  <meyering@lucent.com>
24117
24118         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
24119         for lib/localcharset.c.
24120
24121 2000-03-04  Jim Meyering  <meyering@lucent.com>
24122
24123         * lib/Makefile.am (install-exec-local): Create $(libdir) before
24124         installing into it.
24125         (uninstall-local): Uncomment this rule so `make distcheck' works
24126         once again.
24127
24128         * lib/unicodeio.c (<errno.h>): Include it.
24129         (errno): Declare if not defined.
24130
24131         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
24132
24133         * lib/config.charset: New version, incorporating remarks from a linux
24134         i18n mailing list.  From Bruno Haible.
24135
24136 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
24137
24138         * m4/codeset.m4: New file.
24139         * m4/iconv.m4: New file.
24140         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
24141
24142 2000-03-03  Jim Meyering  <meyering@lucent.com>
24143
24144         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
24145
24146 2000-03-02  Jim Meyering  <meyering@lucent.com>
24147
24148         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
24149         the messages come out on separate lines.
24150
24151         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
24152         rather than jm_CHECK_DECLARATIONS.
24153         * m4/decl.m4: Remove now-unused file.
24154
24155         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
24156         geteuid.
24157
24158 2000-03-02  Jim Meyering  <meyering@lucent.com>
24159
24160         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
24161
24162 2000-03-01  Jim Meyering  <meyering@lucent.com>
24163
24164         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
24165         * lib/unicodeio.c: Likewise.
24166
24167 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
24168
24169         * lib/config.charset: New file.
24170         * lib/localcharset.c: New file.
24171         * lib/unicodeio.h, lib/unicodeio.c: New files.
24172         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
24173         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
24174         (noinst_HEADERS): Add unicodeio.h.
24175         (all-local, install-exec-local, charset.alias): New targets.
24176
24177 2000-02-28  Paul Eggert  <eggert@twinsun.com>
24178
24179         * lib/quotearg.c (ALERT_CHAR): New macro.
24180         (quotearg_buffer_restyled): Use it.
24181
24182 2000-02-27  Jim Meyering  <meyering@lucent.com>
24183
24184         * m4/check-decl.m4: Add getenv to the list.
24185
24186 2000-02-27  Jim Meyering  <meyering@lucent.com>
24187
24188         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
24189         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
24190
24191         * lib/backupfile.c: Guard inclusion of stdlib.h with
24192         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
24193         Declare malloc if needed.
24194
24195         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
24196         `#ifndef HAVE_DECL..'
24197         now that autoconf always defines the HAVE_DECL_ symbols.
24198         * lib/human.c: Likewise.
24199         * lib/same.c: Likewise.
24200         * lib/strtoumax.c: Likewise.
24201
24202         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
24203         declaration check was not run.
24204         * lib/hash.c: Likewise.
24205         * lib/human.c: Likewise.
24206         * lib/same.c: Likewise.
24207         * lib/strtoumax.c: Likewise.
24208
24209         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
24210         `.', then first look up the entire `.'-containing string as a login
24211         name.
24212
24213 2000-02-23  Jim Meyering  <meyering@lucent.com>
24214
24215         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
24216         in place of my hack.
24217
24218 2000-02-18  Paul Eggert  <eggert@twinsun.com>
24219
24220         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
24221         (textint): New typedef.
24222         (parser_control): Member year changed from int to textint.
24223         All uses changed.
24224         (YYSTYPE): Removed; replaced by %union with int and textint members.
24225         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
24226         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
24227         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
24228         (tSNUMBER, tUNUMBER): Now of type <textintval>.
24229         (date, number, to_year): Use width of number in digits, not its value,
24230         to determine whether it's a 2-digit year, or a 2-digit time.
24231         (yylex): Store number of digits of numeric tokens.
24232         Reported by John Kendall.
24233
24234         (parser_control): Changed from struct parser_control to typedef (for
24235         consistency).  All uses changed.
24236
24237         (tID): Removed; not used.
24238         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
24239
24240 2000-02-14  Paul Eggert  <eggert@twinsun.com>
24241
24242         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
24243         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
24244
24245 2000-02-12  Jim Meyering  <meyering@lucent.com>
24246
24247         * lib/userspec.c (ISDIGIT): Define it.
24248         (isdigit): Remove definition.
24249         (is_number): Use ISDIGIT, not isdigit.
24250         <libintl.h>: Include.
24251         (_ and N_): Define.
24252         (parse_user_spec): Mark translatable strings.
24253
24254 2000-02-10  Jim Meyering  <meyering@lucent.com>
24255
24256         With these changes, nanosleep.[ch] are finally enough like the other
24257         lib/* replacement files to compile on a few more losing systems.
24258
24259         * lib/nanosleep.h: Don't include config.h.
24260         Remove prototype from declaration of nanosleep.
24261         (PARAMS): Remove now-unneeded definition.
24262         * lib/nanosleep.c: #undef nanosleep.
24263         (rpl_nanosleep): Rename from nanosleep.
24264
24265 2000-02-10  Jim Meyering  <meyering@lucent.com>
24266
24267         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
24268         gnu_nanosleep to rpl_nanosleep.
24269
24270 2000-02-09  Jim Meyering  <meyering@lucent.com>
24271
24272         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
24273         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
24274
24275 2000-02-08  Akim Demaille  <akim@epita.fr>
24276
24277         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
24278         `[' and `]' and remove uses of `changequote'.
24279         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
24280         (AC_SYS_LARGEFILE): Likewise.
24281         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
24282         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
24283         of changequote.
24284         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
24285         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
24286         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
24287         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
24288
24289 2000-02-05  Jim Meyering  <meyering@lucent.com>
24290
24291         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
24292         Remove explicit use of AC_HEADER_TIME.  It is required by
24293         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
24294         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
24295         in autoconf whereby the expansion of the latter ended up preceding
24296         the expansion of its prerequisite, AC_HEADER_TIME.
24297         Reported by Volker Borchert.
24298
24299 2000-02-03  Jim Meyering  <meyering@lucent.com>
24300
24301         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
24302
24303 2000-02-03  Jim Meyering  <meyering@lucent.com>
24304
24305         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
24306         rather than with `#if HAVE_UTMPNAME'.
24307
24308 2000-02-02  Jim Meyering  <meyering@lucent.com>
24309
24310         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
24311         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
24312         Reported by Eli Zaretskii.
24313
24314 2000-02-01  Jim Meyering  <meyering@lucent.com>
24315
24316         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
24317
24318 2000-01-31  Jim Meyering  <meyering@lucent.com>
24319
24320         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
24321         functions.  Add the time.h and sys/time.h headers along with the
24322         AC_REQUIRE'ment of AC_HEADER_TIME.
24323
24324 2000-01-31  Jim Meyering  <meyering@lucent.com>
24325
24326         * lib/nanosleep.h (nanosleep): Guard declaration with
24327         `#if ! HAVE_DECL_NANOSLEEP'.
24328         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
24329         the declaration in that vendor's sys/timers.h.
24330         Reported by Christian Krackowizer.
24331
24332         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
24333         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
24334         (ISPRINT): Likewise.
24335         Reported by Tom Tromey.
24336
24337 2000-01-30  Jim Meyering  <meyering@lucent.com>
24338
24339         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
24340
24341         * m4/prereq.m4 (utmp_includes): Define.
24342         Check for ut_user and ut_name members in both struct utmpx
24343         and struct utmp.
24344
24345 2000-01-30  Jim Meyering  <meyering@lucent.com>
24346
24347         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
24348         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
24349         header files where only utmpx.ut_user is declared.
24350
24351         * lib/readutmp.h (UT_USER): Define.
24352
24353 2000-01-29  Jim Meyering  <meyering@lucent.com>
24354
24355         * m4/lib-check.m4: New file containing library-related checks from
24356         fileutils and sh-utils (textutils had none).
24357
24358 2000-01-28  Jim Meyering  <meyering@lucent.com>
24359
24360         * m4/perl.m4: Change format of warning message to look more like that
24361         from the missing script.  Suggestion from François Pinard.
24362
24363 2000-01-25  Jim Meyering  <meyering@lucent.com>
24364
24365         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
24366         well as time.h in the compile check.
24367         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
24368         Fix typo in cross-compiling case: s/yes/no/.
24369
24370 2000-01-23  Jim Meyering  <meyering@lucent.com>
24371
24372         * m4/jm-macros.m4: Move df-related tests here from
24373         fileutils/configure.in
24374
24375         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
24376         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
24377
24378         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
24379         s/space/ac_fsusage_space/.
24380         (jm_FILE_SYSTEM_USAGE): Take two parameters.
24381
24382         * m4/ftruncate.m4: New file (derived from part of
24383         fileutils/configure.in).
24384         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
24385         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
24386
24387         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
24388         AC_SUBST these here, rather than just in sh-util/configure.in, so
24389         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
24390         all the same.
24391         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
24392         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
24393         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
24394         (AC_SUBST(POW_LIBM)): Likewise.
24395         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
24396
24397 2000-01-23  Jim Meyering  <meyering@lucent.com>
24398
24399         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
24400         obstack.c.
24401
24402 2000-01-22  Jim Meyering  <meyering@lucent.com>
24403
24404         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
24405
24406         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
24407
24408         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
24409         configure.in
24410         (AC_CHECK_HEADERS): Likewise for sh-utils.
24411         (AC_CHECK_HEADERS): Likewise for textutils.
24412         Merge the three lists of headers.
24413
24414         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
24415         from fileutils' configure.in.
24416
24417         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
24418         code. Moved tests into their own function (_jm_DECL_HEADERS) in
24419         check-decl.m4.
24420
24421         * m4/check-decl.m4: Use #if rather than #ifdef.
24422         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
24423         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
24424         (_jm_DECL_HEADERS): Define new function.
24425         (jm_CHECK_DECLARATIONS): Require it.
24426
24427 2000-01-22  Jim Meyering  <meyering@lucent.com>
24428
24429         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
24430         [! HAVE_DECL_STRTOULL]: Declare strtoull.
24431         Required for some AIX systems.  Reported by Christian Krackowizer.
24432         [TESTING] (main): New function.
24433
24434         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
24435         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
24436         letters.
24437
24438         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
24439         iswprint.
24440
24441         * lib/strverscmp.c (ISDIGIT): Define.
24442         (strverscmp): Use ISDIGIT, not isdigit.
24443
24444 2000-01-19  Jim Meyering  <meyering@lucent.com>
24445
24446         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
24447         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
24448         defines `struct timespec' in <sys/time.h>
24449
24450         * m4/c-bs-a.m4: Remove uses of changequote altogether.
24451         Thanks to Akim for explaining.
24452
24453 2000-01-17  Paul Eggert  <eggert@twinsun.com>
24454
24455         * lib/nanosleep.c (nanosleep):
24456         Don't use SA_INTERRUPT to decide whether to call sigaction, as
24457         POSIX.1 doesn't require SA_INTERRUPT and some systems
24458         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
24459         it's been part of POSIX.1 since day 1 (in 1988).
24460
24461 2000-01-17  Jim Meyering  <meyering@lucent.com>
24462
24463         * lib/interlock: Remove unused file.  Reported by François Pinard.
24464
24465 2000-01-16  Paul Eggert  <eggert@twinsun.com>
24466
24467         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
24468         alert, backslash, formfeed, and vertical tab unnecessarily in
24469         shell quoting style.
24470
24471 2000-01-16  Jim Meyering  <meyering@lucent.com>
24472
24473         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
24474         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
24475         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
24476         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
24477
24478 2000-01-16  Jim Meyering  <meyering@lucent.com>
24479
24480         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
24481         because the latter didn't work.
24482
24483 2000-01-15  Jim Meyering  <meyering@lucent.com>
24484
24485         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
24486         (AC_REPLACE_FUNCS): Add memcpy and memset.
24487         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
24488         Add strpbrk.
24489         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
24490
24491 2000-01-12  Jim Meyering  <meyering@lucent.com>
24492
24493         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
24494         (jm_PREREQ): Use it.
24495         (jm_PREREQ_READUTMP): New macro.
24496         (jm_PREREQ): Use it.
24497
24498 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24499
24500         Quote multibyte characters correctly.
24501         * m4/c-bs-a.m4: New file.
24502         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
24503         (jm_PREREQ): Use it.
24504
24505 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24506
24507         * m4/uintmax_t.m4: Port to autoconf 2.13.
24508
24509 2000-01-08  Jim Meyering  <meyering@ascend.com>
24510
24511         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
24512         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
24513
24514 2000-01-04  Jim Meyering  <meyering@ascend.com>
24515
24516         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
24517         jm_STRUCT_DIRENT_D_TYPE.
24518         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
24519         jm_STRUCT_DIRENT_D_INO.
24520         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
24521         jm_STRUCT_UTIMBUF.
24522         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
24523         renamings.
24524         * m4/utime.m4: Likewise.
24525
24526         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
24527         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
24528
24529 2000-01-03  Paul Eggert  <eggert@twinsun.com>
24530
24531         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
24532         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
24533
24534 2000-01-02  Jim Meyering  <meyering@ascend.com>
24535
24536         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
24537         remember if this is necessary.
24538
24539 1999-12-26  Jim Meyering  <meyering@ascend.com>
24540
24541         * m4/jm-macros.m4: Use it here.
24542         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
24543
24544 1999-12-23  Jim Meyering  <meyering@ascend.com>
24545
24546         * m4/jm-macros.m4: Check for clock_gettime (moved from
24547         fileutils/configure.in)
24548         Check for gettimeofday.
24549
24550 1999-12-20  Jim Meyering  <meyering@ascend.com>
24551
24552         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
24553         autoconf-2.14a-1999-12-20.
24554
24555 1999-12-19  Jim Meyering  <meyering@ascend.com>
24556
24557         * m4/lstat-slash.m4: New file.
24558         * m4/jm-macros.m4: Use the new macro:
24559         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24560
24561 1999-12-07  Jim Meyering  <meyering@ascend.com>
24562
24563         * m4/perl.m4: Require that File::Compare be available, too.
24564         Too many systems seem to lack it.
24565
24566         * m4/strftime.m4: Add checks for most of the cpp macros tested in
24567         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
24568
24569 1999-11-18  Paul Eggert  <eggert@twinsun.com>
24570
24571         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
24572         problem with the QNX 4.25 shell, which doesn't propagate exit
24573         status of failed commands inside shell assignments.
24574
24575 1999-11-17  Jim Meyering  <meyering@ascend.com>
24576
24577         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
24578
24579 1999-11-07  Jim Meyering  <meyering@ascend.com>
24580
24581         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
24582
24583 1999-11-06  Jim Meyering  <meyering@ascend.com>
24584
24585         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
24586         * m4/jm-macros.m4 (jm_MACROS): Use it here.
24587
24588 1999-11-05  Jim Meyering  <meyering@ascend.com>
24589
24590         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
24591         configure.in of textutils, fileutils, and sh-utils into this one
24592         (shared between those packages) file.
24593         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
24594         AC_STRUCT_ST_BLKSIZE.
24595
24596 1999-11-03  Jim Meyering  <meyering@ascend.com>
24597
24598         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
24599         of AC_CHECK_TYPE checks includes unistd.h.
24600         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
24601         Suggestion from Akim Demaille.
24602
24603 1999-10-30  Jim Meyering  <meyering@ascend.com>
24604
24605         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
24606         m4-quoted string.
24607         * m4/ls-mntd-fs.m4: Likewise.
24608         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
24609         * m4/jm-winsz1.m4: Likewise.
24610
24611         * m4/const.m4: Remove file, since the fix made it into the experimental
24612         version of autoconf.
24613         * m4/mktime.m4: Likewise.
24614
24615         * m4/check-type.m4: Remove file, now that the latest version of
24616         AC_CHECK_TYPE takes a third arg to specify additional #includes.
24617
24618         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
24619         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
24620         AC_CHECK_TYPE.
24621
24622 1999-10-04  Jim Meyering  <meyering@ascend.com>
24623
24624         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
24625
24626 1999-09-22  Paul Eggert  <eggert@twinsun.com>
24627
24628         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
24629         2.95.1 bug with HP-UX 10.20.
24630
24631 1999-09-17  Jim Meyering  <meyering@ascend.com>
24632
24633         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
24634         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
24635         due to missing strdup (against sh-utils-2.0).
24636
24637 1999-08-29  Jim Meyering  <meyering@ascend.com>
24638
24639         * m4/jm-macros.m4: Require jm_BISON.
24640         * m4/bison.m4: New file.
24641
24642 1999-08-17  Paul Eggert  <eggert@twinsun.com>
24643
24644         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
24645         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
24646
24647 1999-08-05  Jim Meyering  <meyering@ascend.com>
24648
24649         * m4/getline.m4: Rename test file from conftestdata to conftest.data
24650         to avoid conflicts with `conftest' on 8+3 filesystems.
24651         Suggestion from Eli Zaretskii.
24652
24653 1999-08-04  Jim Meyering  <meyering@ascend.com>
24654
24655         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
24656         fileutils and sh-utils (textutils's getline test was inadequate).
24657         (AM_FUNC_GETLINE): Run this test.
24658         (AC_CHECK_FUNCS): Check for getdelim.
24659         Reported by Bob Proulx.
24660
24661 1999-08-02  Jim Meyering  <meyering@ascend.com>
24662
24663         * m4/jm-macros.m4: Add a comment.
24664
24665 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24666
24667         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
24668         <inttypes.h> defines strtoumax as a macro (and not as a
24669         function).
24670
24671 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24672
24673         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
24674         that we can shift, multiply and divide unsigned long long
24675         values; Ultrix cc can't do it.
24676
24677 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24678
24679         * m4/mktime.m4: New file, which is a preview of what should appear
24680         in the next public autoconf release.
24681
24682 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24683
24684         * m4/lfs.m4: Remove this file.
24685         * m4/largefile.m4: New file.  It contains the old contents of
24686         lfs.m4, except that all names with prefix AC_LFS have been
24687         changed to use the prefix AC_SYS_LARGEFILE instead, to be
24688         compatible with future autoconf versions.  Also, some minor m4
24689         quoting problems have been fixed.
24690
24691 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24692
24693         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
24694         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
24695         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
24696         and simplify the shell code.
24697
24698 1999-08-01  Jim Meyering  <meyering@ascend.com>
24699
24700         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
24701         m4.
24702
24703 1999-07-20  Jim Meyering  <meyering@ascend.com>
24704
24705         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
24706
24707 1999-07-15  Jim Meyering  <meyering@ascend.com>
24708
24709         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
24710
24711 1999-05-22  Jim Meyering  <meyering@ascend.com>
24712
24713         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
24714
24715 1999-05-20  Jim Meyering  <meyering@ascend.com>
24716
24717         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
24718         Add a colon after each `then' in case $4 is empty.
24719
24720 1999-05-16  Jim Meyering  <meyering@ascend.com>
24721
24722         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
24723
24724 1999-05-10  Jim Meyering  <meyering@ascend.com>
24725
24726         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
24727
24728         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
24729         AC_FUNC_MKTIME.
24730
24731 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
24732
24733         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
24734
24735 1999-05-04  Paul Eggert  <eggert@twinsun.com>
24736
24737         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
24738         not CPPFLAGS, so that linking works correctly in IRIX.
24739
24740 1999-04-30  Paul Eggert  <eggert@twinsun.com>
24741
24742         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
24743
24744 1999-04-20  Paul Eggert  <eggert@twinsun.com>
24745
24746         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
24747         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
24748         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
24749         jm_AC_TYPE_UNSIGNED_LONG_LONG.
24750         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
24751
24752         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
24753
24754 1999-04-20  Jim Meyering  <meyering@ascend.com>
24755
24756         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
24757         AC_REPLACE xstroull if necessary.  From Paul Eggert.
24758         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
24759
24760 1999-04-18  Jim Meyering  <meyering@ascend.com>
24761
24762         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
24763         * m4/jm-macros.m4: Use it.
24764
24765 1999-04-06  Jim Meyering  <meyering@ascend.com>
24766
24767         * m4/strftime.m4: Remove test for %f.
24768
24769 1999-03-29  Jim Meyering  <meyering@ascend.com>
24770
24771         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
24772         superset of the AC_TYPE_* checks in the textutils, fileutils,
24773         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
24774         AC_TYPE_PID_T.
24775
24776 1999-03-28  Jim Meyering  <meyering@ascend.com>
24777
24778         * m4/jm-macros.m4: Define GNU_PACKAGE here.
24779         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
24780         replaced e.g., in the *.sh files of the sh-utils.
24781
24782 1999-03-20  Jim Meyering  <meyering@ascend.com>
24783
24784         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
24785         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
24786         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
24787
24788 1999-03-19  Jim Meyering  <meyering@ascend.com>
24789
24790         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
24791
24792 1999-03-12  Jim Meyering  <meyering@ascend.com>
24793
24794         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
24795
24796 1999-03-07  Jim Meyering  <meyering@ascend.com>
24797
24798         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
24799         declared.
24800
24801 1999-02-17  Jim Meyering  <meyering@ascend.com>
24802
24803         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
24804         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
24805
24806 1999-02-07  Jim Meyering  <meyering@ascend.com>
24807
24808         * m4/group-member.m4: New file -- extracted from sh-utils'
24809         configure.in.
24810
24811         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
24812         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
24813
24814 1999-02-06  Jim Meyering  <meyering@ascend.com>
24815
24816         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
24817         * m4/fnmatch.m4: Likewise.
24818         * m4/getgroups.m4: Likewise.
24819         * m4/lstat.m4: Likewise.
24820         * m4/malloc.m4: Likewise.
24821         * m4/putenv.m4: Likewise.
24822         * m4/realloc.m4: Likewise.
24823         * m4/regex.m4: Likewise.
24824         * m4/stat.m4: Likewise.
24825         * m4/strftime.m4: Likewise.
24826         Suggestion from Alain Magloire.
24827
24828         * m4/chown.m4: Use `.$ac_objext', not `.o'.
24829         * m4/fnmatch.m4: Likewise.
24830         * m4/getgroups.m4: Likewise.
24831         * m4/getline.m4: Likewise.
24832         * m4/lstat.m4: Likewise.
24833         * m4/malloc.m4: Likewise.
24834         * m4/memcmp.m4: Likewise.
24835         * m4/putenv.m4: Likewise.
24836         * m4/realloc.m4: Likewise.
24837         * m4/regex.m4: Likewise.
24838         * m4/stat.m4: Likewise.
24839         * m4/strftime.m4: Likewise.
24840         Suggestion from Alain Magloire.
24841
24842         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
24843         an argument.
24844
24845         * m4/regex.m4: Add a run-time Test for proper operation of
24846         re_compile_pattern.
24847
24848 1999-01-31  Jim Meyering  <meyering@ascend.com>
24849
24850         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
24851
24852 1999-01-30  Jim Meyering  <meyering@ascend.com>
24853
24854         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
24855
24856         * m4/jm-mktime.m4: Make this a wrapper around the official
24857         AM_FUNC_MKTIME rather than my private copy, now that the official one
24858         is up to date.
24859         * m4/mktime.m4: Remove file.
24860
24861         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
24862         * m4/uptime.m4: Likewise.
24863         * m4/uintmax_t.m4: Likewise.
24864
24865 1999-01-28  Jim Meyering  <meyering@ascend.com>
24866
24867         * m4/jm-macros.m4: Use jm_AFS.
24868         * m4/afs.m4: New file (from fileutils' configure.in).
24869
24870         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
24871         * m4/chown.m4: Likewise.
24872         * m4/d-ino.m4: Likewise.
24873         * m4/d-type.m4: Likewise.
24874         * m4/fnmatch.m4: Likewise.
24875         * m4/getgroups.m4: Likewise.
24876         * m4/gettext.m4: Likewise.
24877         * m4/jm-mktime.m4: Likewise.
24878         * m4/jm-winsz2.m4: Likewise.
24879         * m4/lcmessage.m4: Likewise.
24880         * m4/ls-mntd-fs.m4: Likewise.
24881         * m4/malloc.m4: Likewise.
24882         * m4/memcmp.m4: Likewise.
24883         * m4/putenv.m4: Likewise.
24884         * m4/realloc.m4: Likewise.
24885         * m4/st_mtim.m4: Likewise.
24886         * m4/strftime.m4: Likewise.
24887
24888 1999-01-16  Jim Meyering  <meyering@ascend.com>
24889
24890         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
24891         (ARGMATCH_DIE_DECL): Define.
24892
24893 1999-01-12  Jim Meyering  <meyering@ascend.com>
24894
24895         * m4/Makefile.am.in: Rewrite to avoid using fmt.
24896         Reported by Lars Hecking.
24897
24898 1999-01-10  Jim Meyering  <meyering@ascend.com>
24899
24900         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
24901         gross kludge.
24902         * m4/inttypes_h.m4: Likewise.
24903         * m4/lstat.m4: Likewise.
24904         * m4/malloc.m4: Likewise.
24905         * m4/readdir.m4: Likewise.
24906         * m4/realloc.m4: Likewise.
24907         * m4/st_dm_mode.m4: Likewise.
24908         * m4/stat.m4: Likewise.
24909         * m4/utimbuf.m4: Likewise.
24910         * m4/utimes.m4: Likewise.
24911
24912         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
24913         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
24914         comments in config.h.in are meaningful.
24915
24916         * m4/jm-macros.m4: Require autoconf-2.13 here.
24917
24918         * m4/regex.m4: By default, don't use the included regex.c on systems
24919         with glibc 2.  Suggestion from Uli Drepper.
24920
24921 1999-01-02  Jim Meyering  <meyering@ascend.com>
24922
24923         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
24924
24925 1998-12-18  Jim Meyering  <meyering@ascend.com>
24926
24927         * m4/Makefile.am.in (Makefile.am): Simplify rule.
24928         Based on a suggestion from Lars Hecking.
24929
24930 1998-11-16  Paul Eggert  <eggert@twinsun.com>
24931
24932         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
24933
24934 1998-11-16  Jim Meyering  <meyering@ascend.com>
24935
24936         * m4/lfs.m4: Double-quote the `uname...` expression.
24937
24938 1998-11-14  Jim Meyering  <meyering@ascend.com>
24939
24940         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
24941         * m4/stat.m4: Likewise.
24942
24943 1998-11-03  Jim Meyering  <meyering@ascend.com>
24944
24945         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
24946         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
24947
24948 1998-10-18  Jim Meyering  <meyering@ascend.com>
24949
24950         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
24951
24952 1998-10-17  Jim Meyering  <meyering@ascend.com>
24953
24954         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
24955         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
24956         calls for those previously hard-coded headers.  Instead, take a new
24957         parameter.
24958         (jm_CHECK_DECLARATIONS): Reflect interface change.
24959         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
24960         (jm_CHECK_DECL_LOCALTIME_R): New macro.
24961
24962         * m4/mktime.m4: Test for spring-forward gap before long-running test.
24963
24964 1998-10-14  Jim Meyering  <meyering@ascend.com>
24965
24966         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
24967         instead of "TZ=America/Vancouver".  From Paul Eggert.
24968
24969 1998-10-11  Jim Meyering  <meyering@ascend.com>
24970
24971         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
24972         This adds a test for a recently added compatibility fix for mktime.c.
24973         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
24974
24975 1998-09-27  Jim Meyering  <meyering@ascend.com>
24976
24977         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
24978
24979         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
24980         ../configure.in, including a change from Gordon Matzigkeit to allow
24981         cross-compiling for the Hurd.
24982
24983         * m4/glibc.m4: New file/macro to test for the GNU C Library
24984         versions 1 and 2.  From Gordon Matzigkeit.
24985         Indent.
24986
24987 1998-09-21  Jim Meyering  <meyering@ascend.com>
24988
24989         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
24990
24991 1998-08-18  Paul Eggert  <eggert@twinsun.com>
24992
24993         Port nanosecond-resolution times to UnixWare 2.1.2 and
24994         pedantic Solaris 2.6.
24995
24996         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
24997         AC_STRUCT_ST_MTIM.
24998         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
24999         Generate name of ns member, instead of just 1 or undef.
25000         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
25001
25002 1998-08-15  Jim Meyering  <meyering@ascend.com>
25003
25004         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
25005         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
25006         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
25007         instead of jm_TYPE_SSIZE_T.
25008
25009 1998-08-12  Jim Meyering  <meyering@ascend.com>
25010
25011         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
25012
25013 1998-08-02  Jim Meyering  <meyering@ascend.com>
25014
25015         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
25016         in acconfig.h manually.
25017
25018 1998-07-31  Paul Eggert  <eggert@twinsun.com>
25019
25020         * m4/st_mtim.m4: New file.
25021
25022 1998-07-28  Jim Meyering  <meyering@ascend.com>
25023
25024         * m4/utimes.m4: Undef stat.
25025
25026 1998-07-25  Jim Meyering  <meyering@ascend.com>
25027
25028         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
25029         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
25030
25031 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
25032
25033         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
25034         uid and gid actually remain unchanged.
25035
25036 1998-07-07  Jim Meyering  <meyering@ascend.com>
25037
25038         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
25039
25040 1998-07-04  Jim Meyering  <meyering@ascend.com>
25041
25042         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
25043         to prove that this macro can be used in packages without regex.c.
25044
25045 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
25046
25047         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
25048         is to be used.
25049
25050 1998-07-03  Jim Meyering  <meyering@ascend.com>
25051
25052         * m4/gettext.m4: Add -lintl if it's found to be necessary.
25053
25054         * m4/gettext.m4: New file -- from gettext-0.10.35.
25055         * m4/lcmessage.m4: Likewise.
25056         * m4/progtest.m4: Likewise.
25057
25058         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
25059         * m4/jm-macros.m4: Require the new macro.
25060
25061 1998-06-29  Jim Meyering  <meyering@ascend.com>
25062
25063         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
25064         for the definition of NGROUPS (used in a system header included
25065         by sys/mount.h).
25066
25067 1998-06-28  Jim Meyering  <meyering@ascend.com>
25068
25069         * m4/ls-mntd-fs.m4: New file.
25070         * m4/fstypename.m4: New file.
25071
25072         * m4/jm-macros.m4: Require the new macro.
25073         * m4/jm-glibc-io.m4: New file.
25074
25075 1998-05-19  Jim Meyering  <meyering@ascend.com>
25076
25077         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
25078         * m4/lchown.m4: New file.
25079
25080         * m4/Makefile.am.in: New file.
25081         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
25082
25083 1998-05-14  Jim Meyering  <meyering@ascend.com>
25084
25085         * m4/Makefile.am (EXTRA_DIST): Add them.
25086         * m4/jm-macros.m4: New file.
25087         * m4/utimbuf.m4: New file.
25088
25089 1998-05-12  Jim Meyering  <meyering@ascend.com>
25090
25091         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
25092
25093 1998-05-11  Jim Meyering  <meyering@ascend.com>
25094
25095         * m4/isc-posix.m4: New file.
25096
25097 1998-05-10  Jim Meyering  <meyering@ascend.com>
25098
25099         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
25100
25101 1998-05-09  Jim Meyering  <meyering@ascend.com>
25102
25103         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
25104         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
25105         with automake.
25106
25107         * m4/ssize_t.m4: New file.
25108         * m4/mktime.m4: Remove file -- the new automake has this now.
25109
25110 1998-04-26  Jim Meyering  <meyering@ascend.com>
25111
25112         * m4/assert.m4: New file.
25113         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
25114
25115 1998-04-05  Jim Meyering  <meyering@ascend.com>
25116
25117         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
25118         (jm_PREREQ): Use it here.
25119
25120 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
25121
25122         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
25123         in acconfig.h.
25124
25125 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
25126
25127         * m4/prereq.m4: New file.
25128         * m4/error.m4: New file.
25129         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
25130
25131 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
25132
25133         * m4/getline.m4: Don't set am_cv_func_working_getline before the
25134         cache-check for the same variable -- that defeated the purpose of
25135         the test; the test program was never run.  This was a problem only
25136         on systems with losing getline functions -- HP-UX 10.20 is one.
25137         Reported by Bjorn Helgaas.
25138
25139 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
25140
25141         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
25142
25143 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
25144
25145         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
25146
25147         * m4/const.m4: New file.  Use an initializer in this declaration
25148         typedef int charset[2]; const charset x;
25149         Reported by Bob Glickstein.
25150
25151 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
25152
25153         * m4/chown.m4: Fix reversed types on -1 args to chown.
25154         From Kaveh Ghazi.
25155
25156 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
25157
25158         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
25159         Add lseek and memchr.
25160
25161         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
25162         T.E.Dickey <dickey@clark.net> said that some older preprocessors
25163         have a 20-character limit on names.
25164
25165 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
25166
25167         * m4/inttypes_h.m4: New file.
25168         * m4/uintmax_t.m4: New file.
25169         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
25170
25171 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
25172   Free Software Foundation, Inc.
25173 Copying and distribution of this file, with or without modification,
25174 are permitted provided the copyright notice and this notice are preserved.