e93b10c16a8ecbcc9e0bb6b4adc1ef82428f869d
[gnulib.git] / ChangeLog
1 2007-01-10  Eric Blake  <ebb9@byu.net>
2
3         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
4         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
5         * modules/wctype (Makefile.am): Likewise.
6         Reported by Chris McGuire.
7
8 2007-01-10  Jim Meyering  <jim@meyering.net>
9
10         fts.c: a small readability/maintainability improvement
11         * lib/fts.c (fts_read): Make this code slightly more readable and
12         maintainable by hoisting the "sp->fts_cur = p" assignments to
13         immediately follow the statements that set P.  Derived from
14         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
15
16 2007-01-10  Eric Blake  <ebb9@byu.net>
17
18         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
19         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
20         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
21         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
22         Reported by Chris McGuire.
23
24 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25
26         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
27         in sed script.
28
29 2007-01-09  Bruno Haible  <bruno@clisp.org>
30
31         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
32         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
33         variables.
34         (func_module): Use them.
35
36 2007-01-09  Bruno Haible  <bruno@clisp.org>
37
38         * modules/unistr/base: New file.
39         * lib/unistr.h: New file.
40
41         * modules/unistr/u8-to-u16: New file.
42         * lib/unistr/u8-to-u16.c: New file.
43
44         * modules/unistr/u8-to-u32: New file.
45         * lib/unistr/u8-to-u32.c: New file.
46
47         * modules/unistr/u16-to-u8: New file.
48         * lib/unistr/u16-to-u8.c: New file.
49
50         * modules/unistr/u16-to-u32: New file.
51         * lib/unistr/u16-to-u32.c: New file.
52
53         * modules/unistr/u32-to-u8: New file.
54         * lib/unistr/u32-to-u8.c: New file.
55
56         * modules/unistr/u32-to-u16: New file.
57         * lib/unistr/u32-to-u16.c: New file.
58
59         * modules/unistr/u8-check: New file.
60         * modules/unistr/u16-check: New file.
61         * modules/unistr/u32-check: New file.
62         * lib/unistr/u8-check.c: New file.
63         * lib/unistr/u16-check.c: New file.
64         * lib/unistr/u32-check.c: New file.
65
66         * modules/unistr/u8-chr: New file.
67         * modules/unistr/u16-chr: New file.
68         * modules/unistr/u32-chr: New file.
69         * lib/unistr/u8-chr.c: New file.
70         * lib/unistr/u16-chr.c: New file.
71         * lib/unistr/u32-chr.c: New file.
72
73         * modules/unistr/u8-cmp: New file.
74         * modules/unistr/u16-cmp: New file.
75         * modules/unistr/u32-cmp: New file.
76         * lib/unistr/u8-cmp.c: New file.
77         * lib/unistr/u16-cmp.c: New file.
78         * lib/unistr/u32-cmp.c: New file.
79
80         * modules/unistr/u8-cpy: New file.
81         * modules/unistr/u16-cpy: New file.
82         * modules/unistr/u32-cpy: New file.
83         * lib/unistr/u8-cpy.c: New file.
84         * lib/unistr/u16-cpy.c: New file.
85         * lib/unistr/u32-cpy.c: New file.
86         * lib/unistr/u-cpy.h: New file.
87
88         * modules/unistr/u8-cpy-alloc: New file.
89         * modules/unistr/u16-cpy-alloc: New file.
90         * modules/unistr/u32-cpy-alloc: New file.
91         * lib/unistr/u8-cpy-alloc.c: New file.
92         * lib/unistr/u16-cpy-alloc.c: New file.
93         * lib/unistr/u32-cpy-alloc.c: New file.
94         * lib/unistr/u-cpy-alloc.h: New file.
95
96         * modules/unistr/u8-endswith: New file.
97         * modules/unistr/u16-endswith: New file.
98         * modules/unistr/u32-endswith: New file.
99         * lib/unistr/u8-endswith.c: New file.
100         * lib/unistr/u16-endswith.c: New file.
101         * lib/unistr/u32-endswith.c: New file.
102         * lib/unistr/u-endswith.h: New file.
103
104         * modules/unistr/u8-mblen: New file.
105         * modules/unistr/u16-mblen: New file.
106         * modules/unistr/u32-mblen: New file.
107         * lib/unistr/u8-mblen.c: New file.
108         * lib/unistr/u16-mblen.c: New file.
109         * lib/unistr/u32-mblen.c: New file.
110
111         * modules/unistr/u8-mbtouc: New file.
112         * modules/unistr/u16-mbtouc: New file.
113         * modules/unistr/u32-mbtouc: New file.
114         * lib/unistr/u8-mbtouc.c: New file.
115         * lib/unistr/u16-mbtouc.c: New file.
116         * lib/unistr/u32-mbtouc.c: New file.
117
118         * modules/unistr/u8-mbtouc-safe: New file.
119         * modules/unistr/u16-mbtouc-safe: New file.
120         * modules/unistr/u32-mbtouc-safe: New file.
121         * lib/unistr/u8-mbtouc-safe.c: New file.
122         * lib/unistr/u16-mbtouc-safe.c: New file.
123         * lib/unistr/u32-mbtouc-safe.c: New file.
124
125         * modules/unistr/u8-move: New file.
126         * modules/unistr/u16-move: New file.
127         * modules/unistr/u32-move: New file.
128         * lib/unistr/u8-move.c: New file.
129         * lib/unistr/u16-move.c: New file.
130         * lib/unistr/u32-move.c: New file.
131         * lib/unistr/u-move.h: New file.
132
133         * modules/unistr/u8-next: New file.
134         * modules/unistr/u16-next: New file.
135         * modules/unistr/u32-next: New file.
136         * lib/unistr/u8-next.c: New file.
137         * lib/unistr/u16-next.c: New file.
138         * lib/unistr/u32-next.c: New file.
139
140         * modules/unistr/u8-prev: New file.
141         * modules/unistr/u16-prev: New file.
142         * modules/unistr/u32-prev: New file.
143         * lib/unistr/u8-prev.c: New file.
144         * lib/unistr/u16-prev.c: New file.
145         * lib/unistr/u32-prev.c: New file.
146
147         * modules/unistr/u8-set: New file.
148         * modules/unistr/u16-set: New file.
149         * modules/unistr/u32-set: New file.
150         * lib/unistr/u8-set.c: New file.
151         * lib/unistr/u16-set.c: New file.
152         * lib/unistr/u32-set.c: New file.
153         * lib/unistr/u-set.h: New file.
154
155         * modules/unistr/u8-startswith: New file.
156         * modules/unistr/u16-startswith: New file.
157         * modules/unistr/u32-startswith: New file.
158         * lib/unistr/u8-startswith.c: New file.
159         * lib/unistr/u16-startswith.c: New file.
160         * lib/unistr/u32-startswith.c: New file.
161         * lib/unistr/u-startswith.h: New file.
162
163         * modules/unistr/u8-stpcpy: New file.
164         * modules/unistr/u16-stpcpy: New file.
165         * modules/unistr/u32-stpcpy: New file.
166         * lib/unistr/u8-stpcpy.c: New file.
167         * lib/unistr/u16-stpcpy.c: New file.
168         * lib/unistr/u32-stpcpy.c: New file.
169         * lib/unistr/u-stpcpy.h: New file.
170
171         * modules/unistr/u8-stpncpy: New file.
172         * modules/unistr/u16-stpncpy: New file.
173         * modules/unistr/u32-stpncpy: New file.
174         * lib/unistr/u8-stpncpy.c: New file.
175         * lib/unistr/u16-stpncpy.c: New file.
176         * lib/unistr/u32-stpncpy.c: New file.
177         * lib/unistr/u-stpncpy.h: New file.
178
179         * modules/unistr/u8-strcat: New file.
180         * modules/unistr/u16-strcat: New file.
181         * modules/unistr/u32-strcat: New file.
182         * lib/unistr/u8-strcat.c: New file.
183         * lib/unistr/u16-strcat.c: New file.
184         * lib/unistr/u32-strcat.c: New file.
185         * lib/unistr/u-strcat.h: New file.
186
187         * modules/unistr/u8-strchr: New file.
188         * modules/unistr/u16-strchr: New file.
189         * modules/unistr/u32-strchr: New file.
190         * lib/unistr/u8-strchr.c: New file.
191         * lib/unistr/u16-strchr.c: New file.
192         * lib/unistr/u32-strchr.c: New file.
193
194         * modules/unistr/u8-strcmp: New file.
195         * modules/unistr/u16-strcmp: New file.
196         * modules/unistr/u32-strcmp: New file.
197         * lib/unistr/u8-strcmp.c: New file.
198         * lib/unistr/u16-strcmp.c: New file.
199         * lib/unistr/u32-strcmp.c: New file.
200
201         * modules/unistr/u8-strcpy: New file.
202         * modules/unistr/u16-strcpy: New file.
203         * modules/unistr/u32-strcpy: New file.
204         * lib/unistr/u8-strcpy.c: New file.
205         * lib/unistr/u16-strcpy.c: New file.
206         * lib/unistr/u32-strcpy.c: New file.
207         * lib/unistr/u-strcpy.h: New file.
208
209         * modules/unistr/u8-strcspn: New file.
210         * modules/unistr/u16-strcspn: New file.
211         * modules/unistr/u32-strcspn: New file.
212         * lib/unistr/u8-strcspn.c: New file.
213         * lib/unistr/u16-strcspn.c: New file.
214         * lib/unistr/u32-strcspn.c: New file.
215         * lib/unistr/u-strcspn.h: New file.
216
217         * modules/unistr/u8-strdup: New file.
218         * modules/unistr/u16-strdup: New file.
219         * modules/unistr/u32-strdup: New file.
220         * lib/unistr/u8-strdup.c: New file.
221         * lib/unistr/u16-strdup.c: New file.
222         * lib/unistr/u32-strdup.c: New file.
223         * lib/unistr/u-strdup.h: New file.
224
225         * modules/unistr/u8-strlen: New file.
226         * modules/unistr/u16-strlen: New file.
227         * modules/unistr/u32-strlen: New file.
228         * lib/unistr/u8-strlen.c: New file.
229         * lib/unistr/u16-strlen.c: New file.
230         * lib/unistr/u32-strlen.c: New file.
231         * lib/unistr/u-strlen.h: New file.
232
233         * modules/unistr/u8-strmblen: New file.
234         * modules/unistr/u16-strmblen: New file.
235         * modules/unistr/u32-strmblen: New file.
236         * lib/unistr/u8-strmblen.c: New file.
237         * lib/unistr/u16-strmblen.c: New file.
238         * lib/unistr/u32-strmblen.c: New file.
239
240         * modules/unistr/u8-strmbtouc: New file.
241         * modules/unistr/u16-strmbtouc: New file.
242         * modules/unistr/u32-strmbtouc: New file.
243         * lib/unistr/u8-strmbtouc.c: New file.
244         * lib/unistr/u16-strmbtouc.c: New file.
245         * lib/unistr/u32-strmbtouc.c: New file.
246
247         * modules/unistr/u8-strncat: New file.
248         * modules/unistr/u16-strncat: New file.
249         * modules/unistr/u32-strncat: New file.
250         * lib/unistr/u8-strncat.c: New file.
251         * lib/unistr/u16-strncat.c: New file.
252         * lib/unistr/u32-strncat.c: New file.
253         * lib/unistr/u-strncat.h: New file.
254
255         * modules/unistr/u8-strncmp: New file.
256         * modules/unistr/u16-strncmp: New file.
257         * modules/unistr/u32-strncmp: New file.
258         * lib/unistr/u8-strncmp.c: New file.
259         * lib/unistr/u16-strncmp.c: New file.
260         * lib/unistr/u32-strncmp.c: New file.
261
262         * modules/unistr/u8-strncpy: New file.
263         * modules/unistr/u16-strncpy: New file.
264         * modules/unistr/u32-strncpy: New file.
265         * lib/unistr/u8-strncpy.c: New file.
266         * lib/unistr/u16-strncpy.c: New file.
267         * lib/unistr/u32-strncpy.c: New file.
268         * lib/unistr/u-strncpy.h: New file.
269
270         * modules/unistr/u8-strnlen: New file.
271         * modules/unistr/u16-strnlen: New file.
272         * modules/unistr/u32-strnlen: New file.
273         * lib/unistr/u8-strnlen.c: New file.
274         * lib/unistr/u16-strnlen.c: New file.
275         * lib/unistr/u32-strnlen.c: New file.
276         * lib/unistr/u-strnlen.h: New file.
277
278         * modules/unistr/u8-strpbrk: New file.
279         * modules/unistr/u16-strpbrk: New file.
280         * modules/unistr/u32-strpbrk: New file.
281         * lib/unistr/u8-strpbrk.c: New file.
282         * lib/unistr/u16-strpbrk.c: New file.
283         * lib/unistr/u32-strpbrk.c: New file.
284         * lib/unistr/u-strpbrk.h: New file.
285
286         * modules/unistr/u8-strrchr: New file.
287         * modules/unistr/u16-strrchr: New file.
288         * modules/unistr/u32-strrchr: New file.
289         * lib/unistr/u8-strrchr.c: New file.
290         * lib/unistr/u16-strrchr.c: New file.
291         * lib/unistr/u32-strrchr.c: New file.
292
293         * modules/unistr/u8-strspn: New file.
294         * modules/unistr/u16-strspn: New file.
295         * modules/unistr/u32-strspn: New file.
296         * lib/unistr/u8-strspn.c: New file.
297         * lib/unistr/u16-strspn.c: New file.
298         * lib/unistr/u32-strspn.c: New file.
299         * lib/unistr/u-strspn.h: New file.
300
301         * modules/unistr/u8-strstr: New file.
302         * modules/unistr/u16-strstr: New file.
303         * modules/unistr/u32-strstr: New file.
304         * lib/unistr/u8-strstr.c: New file.
305         * lib/unistr/u16-strstr.c: New file.
306         * lib/unistr/u32-strstr.c: New file.
307         * lib/unistr/u-strstr.h: New file.
308
309         * modules/unistr/u8-strtok: New file.
310         * modules/unistr/u16-strtok: New file.
311         * modules/unistr/u32-strtok: New file.
312         * lib/unistr/u8-strtok.c: New file.
313         * lib/unistr/u16-strtok.c: New file.
314         * lib/unistr/u32-strtok.c: New file.
315         * lib/unistr/u-strtok.h: New file.
316
317         * modules/unistr/u8-uctomb: New file.
318         * modules/unistr/u16-uctomb: New file.
319         * modules/unistr/u32-uctomb: New file.
320         * lib/unistr/u8-uctomb.c: New file.
321         * lib/unistr/u16-uctomb.c: New file.
322         * lib/unistr/u32-uctomb.c: New file.
323
324         * MODULES.html.sh (Unicode string functions): Add the new modules.
325
326 2007-01-08  Bruno Haible  <bruno@clisp.org>
327
328         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
329         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
330         subdirectories.
331
332 2007-01-08  Karl Berry  <karl@gnu.org>
333
334         * doc/error.texi: mention that main() fns must set program_name
335         when progname is used.
336
337 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
338
339         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
340         WCTYPE_H is empty, for the benefit of builds from non-distclean
341         directories.  Problem reported by Eric Blake in
342         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
343
344 2007-01-08  Bruno Haible  <bruno@clisp.org>
345
346         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
347         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
348         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
349         PROVIDE_CANONICALIZE_FILENAME_MODE.
350         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
351
352 2007-01-08  Bruno Haible  <bruno@clisp.org>
353
354         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
355         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
356         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
357         * lib/fts.c: Likewise.
358         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
359
360 2006-12-25  Bruno Haible  <bruno@clisp.org>
361
362         * modules/utf8-ucs4-safe: New file.
363         * lib/utf8-ucs4-safe.h: New file.
364         * lib/unistr/utf8-ucs4-safe.c: New file.
365
366         * modules/utf16-ucs4-safe: New file.
367         * lib/utf16-ucs4-safe.h: New file.
368         * lib/unistr/utf16-ucs4-safe.c: New file.
369
370         * MODULES.html.sh (Unicode string functions): Add the new modules.
371
372 2007-01-08  Bruno Haible  <bruno@clisp.org>
373
374         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
375         (Depends-on): Add unitypes.
376         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
377         (u8_mbtouc_aux): Move out to separate file.
378         (u8_mbtouc): Use ucs4_t, uint8_t types.
379         * lib/unistr/utf8-ucs4.c: New file.
380
381         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
382         (Depends-on): Add unitypes.
383         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
384         (u16_mbtouc_aux): Move out to separate file.
385         (u16_mbtouc): Use ucs4_t, uint16_t types.
386         * lib/unistr/utf16-ucs4.c: New file.
387
388         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
389         (Depends-on): Add unitypes.
390         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
391         (u8_uctomb_aux): Move out to separate file.
392         (u8_uctomb): Use ucs4_t, uint8_t types.
393         * lib/unistr/ucs4-utf8.c: New file.
394
395         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
396         (Depends-on): Add unitypes.
397         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
398         (u16_uctomb_aux): Move out to separate file.
399         (u16_uctomb): Use ucs4_t, uint16_t types.
400         * lib/unistr/ucs4-utf16.c: New file.
401
402 2006-12-25  Bruno Haible  <bruno@clisp.org>
403
404         * modules/unitypes: New file.
405         * lib/unitypes.h: New file.
406         * MODULES.html.sh (func_all_modules): New section "Unicode string
407         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
408         this section. Add unitypes.
409
410 2007-01-08  Bruno Haible  <bruno@clisp.org>
411
412         Avoid variable names that conflict with those from libtool.
413         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
414         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
415         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
416         library_names_spec to acl_library_names_spec, hardcode_* to
417         acl_hardcode_*.
418         Reported by Ralf Wildenhues.
419
420 2007-01-08  Bruno Haible  <bruno@clisp.org>
421
422         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
423         definition.
424         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
425         definition.
426         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
427         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
428         definition.
429         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
430         definition.
431         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
432         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
433         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
434         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
435         definition.
436         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
437         definition.
438         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
439         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
440         GC_USE_<algorithm>.
441         * lib/gc-libgcrypt.c: Likewise.
442         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
443         * modules/gc-arctwo (configure.ac): Likewise.
444         * modules/gc-des (configure.ac): Likewise.
445         * modules/gc-hmac-md5 (configure.ac): Likewise.
446         * modules/gc-hmac-sha1 (configure.ac): Likewise.
447         * modules/gc-md2 (configure.ac): Likewise.
448         * modules/gc-md4 (configure.ac): Likewise.
449         * modules/gc-md5 (configure.ac): Likewise.
450         * modules/gc-random (configure.ac): Likewise.
451         * modules/gc-rijndael (configure.ac): Likewise.
452         * modules/gc-sha1 (configure.ac): Likewise.
453
454 2007-01-08  Bruno Haible  <bruno@clisp.org>
455
456         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
457         macro definition.
458         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
459         definition.
460         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
461         definition.
462         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
463         * modules/fcntl-safer (configure.ac): Likewise.
464         * modules/fopen-safer (configure.ac): Likewise.
465         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
466         GNULIB_FWRITEERROR macro definition.
467
468 2007-01-08  Bruno Haible  <bruno@clisp.org>
469
470         * m4/gnulib-common.m4: New file.
471         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
472         (func_get_filelist): Add m4/gnulib-common.m4.
473
474 2007-01-08  Bruno Haible  <bruno@clisp.org>
475
476         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
477         command.
478
479 2007-01-08  Jim Meyering  <jim@meyering.net>
480
481         Use a more robust test for a "can't happen" condition.
482         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
483         narrowed the st_size value.  Presuming the "can't happen" condition
484         is true, that narrowing could conceivably convert an invalid st_size
485         value into a valid one.  Instead, use a change based on Matthew
486         Woehlke's original patch.
487
488         Slight readability improvement: use an assert-like macro
489         in place of literal "abort ()" uses.
490         * lib/fts.c (fts_assert): Define.
491         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
492         Use this macro instead of a bare 'abort'.
493
494 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
495
496         Don't worry about using IRIX 5.3's wctype.h broken definitions;
497         simply work around them.
498         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
499         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
500         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
501         Don't bother to define as macros, since the standard doesn't require it.
502         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
503         longer worry about IRIX 5.3.
504         (HAVE_WCTYPE_CTMP_BUG): Remove.
505
506 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
507
508         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
509         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
510         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
511         Problems reported by Georg Schwarz for IRIX 5.3.
512
513         * gnulib-tool (autoconf_minversion): Take the maximum version number
514         found, not the minimum.  Problem reported by James Youngman.
515
516 2007-01-03  Karl Berry  <karl@gnu.org>
517
518         * doc/error.texi: new file, explaining interaction with progname.
519         * doc/gnulib.texi: include it.  Update copyright.
520
521 2007-01-03  Simon Josefsson  <simon@josefsson.org>
522
523         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
524         AC_CANONICAL_HOST, to improve autobuild outputs.
525
526 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
527             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
528
529         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
530         sockets, server sockets, and other file descriptors.  Count errors
531         to compute the return value.  Reorder the code a bit to be easier
532         to follow.  Don't set event bits that were not requested (except
533         POLLERR and POLLHUP).
534
535 2007-01-01  Bruno Haible  <bruno@clisp.org>
536
537         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
538
539 2007-01-03  Jim Meyering  <jim@meyering.net>
540
541         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
542
543 2007-01-02  Bruno Haible  <bruno@clisp.org>
544
545         * modules/settime (Include): Require timespec.h.
546         * modules/nanosleep (Include): Likewise.
547
548 2007-01-01  Bruno Haible  <bruno@clisp.org>
549
550         * gnulib-tool (func_emit_copyright_notice): Bump year.
551         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
552
553 2007-01-01  Bruno Haible  <bruno@clisp.org>
554
555         Improve support for OpenBSD.
556         * build-aux/config.rpath (libname_spec): Export.
557         (library_names_spec): New variable. Export.
558         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
559         library_names_spec from the config.rpath output. Locate shared library
560         through the name pattern in library_names_spec.
561
562 2007-01-01  Eric Blake  <ebb9@byu.net>
563
564         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
565
566 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
567
568         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
569         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
570         assume the C locale, and avoid an "eval" that could cause trouble.
571         Problem with SORT reported by Bob Proulx.
572
573         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
574         Define.  Trivial patch from Henning Nielsen Lund, originally
575         sent to bug-grep@gnu.org today.
576
577 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
578
579         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
580         struct stat.  Problem reported by Henning Nielsen Lund.
581         * lib/acl.c: Include acl.h first, to check interface.  Don't
582         bother to include sys/types.h and sys/stat.h again.
583
584 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
585
586         Import the following change from libc; problem reported by
587         Sven Verdoolaege.
588
589         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
590
591         [BZ #1373]
592         * lib/argp.h: Remove __NTH for __argp_usage inline function.
593
594 2006-12-28  Jim Meyering  <jim@meyering.net>
595
596         * build-aux/announce-gen: Do not assume that the package
597         builds any of tar.gz, tar.bz2, and .xdelta files.
598         Suggestion from Simon Josefsson.
599
600 2006-12-28  Simon Josefsson  <simon@josefsson.org>
601
602         * modules/announce-gen: New file.
603
604 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
605
606         * lib/mbchar.h: Just include <wctype.h>; the wctype module
607         handles its gotchas now.
608         * lib/mbswidth.c: Likewise.
609         * lib/wcwidth.h: Likewise.
610         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
611         and iswcntrl; the wctype module does this stuff now.
612         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
613         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
614         * modules/mbchar (Depends-on): Add wctype.
615         * modules/mbswidth (Depends-on): Likewise.
616         * modules/wcwidth (Depends-on): Likewise.
617
618 2006-12-27  Eric Blake  <ebb9@byu.net>
619
620         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
621         module uses more than what <wctype.h> is required to provide.
622
623 2006-12-26  Eric Blake  <ebb9@byu.net>
624
625         * gnulib-tool (sed_extract_prog): Avoid space-tab.
626
627 2006-12-26  Eric Blake  <ebb9@byu.net>
628
629         * modules/absolute-header: New module.
630         * modules/fcntl (Depends-on): Depend on it.
631         * modules/inttypes (Depends-on): Likewise.
632         * modules/stdint (Depends-on): Likewise.
633         * modules/sys_stat (Depends-on): Likewise.
634         * modules/wctype (Depends-on): Likewise.
635         * MODULES.html.sh (Support for building libraries and
636         executables): Document it.
637
638 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
639
640         * gnulib-tool (SED): Remove, undoing previous change.
641         The problem was that it broke coreutils on Solaris, because
642         "sed --posix" leaked into a makefile.
643         (sed): New alias, if 'alias' and GNU sed.
644
645 2006-12-24  Jim Meyering  <jim@meyering.net>
646
647         Work around an fchownat bug in glibc-2.4:
648         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
649         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
650         in spite of the -P option.
651         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
652         New macros.
653         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
654         * modules/openat (Files): Add lib/fchownat.c.
655         * lib/openat.c (fchownat): Don't define here.  Move to...
656         * lib/fchownat.c: ...this new file.
657
658 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
659
660         Fix bug reported by Bruno Haible in
661         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
662         where quotearg.c didn't compile on Mac OS X 10.2 because it
663         lacks <wchar.h> and wint_t.
664         * lib/wctype_.h (__wctype_wint_t): New type.
665         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
666         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
667         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
668         Arg is now of type __wctype_wint_t, not wint_t.
669         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
670         substitute HAVE_WINT_T.
671         * modules/wctype (Files): Add m4/wint_t.m4.
672         (wctype.h): Substitute HAVE_WINT_T.
673
674 2006-12-23  Bruno Haible  <bruno@clisp.org>
675
676         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
677
678 2006-12-23  Bruno Haible  <bruno@clisp.org>
679
680         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
681         S_ISLNK.
682         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
683         mingw.
684
685 2006-12-22  Bruno Haible  <bruno@clisp.org>
686
687         * lib/copy-file.c: Include acl.h.
688         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
689         Close the file descriptors only after being done with copy_acl.
690         * modules/copy-file (Depends-on): Add acl.
691
692 2006-12-22  Bruno Haible  <bruno@clisp.org>
693
694         * gnulib-tool (SED): New variable.
695         Use $SED instead of sed everywhere.
696
697 2006-12-22  Bruno Haible  <bruno@clisp.org>
698
699         * modules/no-c++: New file.
700         * m4/no-c++.m4: New file.
701         * MODULES.html.sh (Support for building libraries and executables):
702         Add no-c++.
703
704 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
705
706         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
707         Include <limits.h>, and use its INT_MAX to rewrite the
708         j loop so that it does not overflow 'int'.  Problem reported by
709         Ralf Wildenhues in
710         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
711         Play it safe by shifting left by 1 rather than multiplying by 2,
712         as GCC is less likely to optimize this away when the value
713         is signed (when it assumes overflow leads to undefined behavior).
714         Also, don't assume time_t uses two's complement.
715
716 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
717
718         * MODULES.html.sh: New module wctype.
719         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
720         * lib/fnmatch.c: Don't bother to include <wchar.h> before
721         <wctype.h>, since the new wctype module should fix this.
722         * lib/quotearg.c: Include <wctype.h> unconditionally, since
723         the wctype module should arrange for it.
724         * lib/regex_internal.h: Likewise.
725         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
726         since the wctype module should handle this now.
727         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
728         * modules/fnmatch (Depends-on): Add wctype.
729         * modules/quotearg (Depends-on): Likewise.
730         * modules/regex (Depends-on): Likewise.
731
732 2006-12-19  Bruno Haible  <bruno@clisp.org>
733
734         * lib/strdup.h [C++]: Wrap definitions in extern "C".
735         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
736
737 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
738
739         * modules/savewd (Depends-on): Fix dependency on fcntl.
740
741 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
742
743         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
744         conforms to C99, rather than relying on the user's environment
745         setting of STDINT_H.
746
747 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
748         and Eric Blake  <ebb9@byu.net>
749
750         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
751         This is more consistent with the other defines here.
752         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
753         Port to z/OS.  Problem reported by Paul Gilmartin.
754         Change local vars to use gl_ prefix rather than ac_.
755         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
756         with other defines.
757         * modules/double-slash-root: New module.
758         * modules/dirname (Files): Remove m4/double-slash-root.m4.
759         (Depends-on): Add double-slash-root.
760         * MODULES.html.sh (File system functions): Mention new module.
761
762 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
763
764         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
765         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
766         This is for the benefit of gzip, which doesn't do i18n.
767
768 2006-12-12  Jim Meyering  <jim@meyering.net>
769
770         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
771         Reported by Andreas Schwab <schwab@suse.de>.
772
773 2006-12-12  Bruno Haible  <bruno@clisp.org>
774
775         Merge these changes.
776         2006-09-05  Bruno Haible  <bruno@clisp.org>
777         * lib/iconvme.c (iconv_string): No need to save and restore errno when
778         iconv_alloc succeeded.
779         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
780         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
781         test for " && dest " at the end - dest is always != NULL there. Call
782         iconv with 4xNULL arguments initially, to reset the state. Call iconv
783         with 2xNULL arguments, also to flush the state storage. Handle the
784         IRIX iconv behaviour. Realloc the final result, to throw away unused
785         memory.
786
787 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
788
789         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
790         and fchmodat unconditionally, since glibc 2.4 has them.
791         Problem reported by Arkadiusz Miskiewicz.
792
793 2006-12-10  Bruno Haible  <bruno@clisp.org>
794
795         * gnulib-tool (func_import): Show the include files only for those
796         modules that are copied and specified.
797         Reported by Karl Berry.
798
799 2006-12-08  Jim Meyering  <jim@meyering.net>
800
801         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
802         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
803
804         * build-aux/announce-gen: Add two new options, both optional:
805         --bootstrap-tools=TOOL_LIST
806               a comma-separated list of tools, e.g.,
807               autoconf,automake,bison,gnulib
808         --gnulib-snapshot-date=DATE
809               if gnulib is in the bootstrap tool list,
810               then report this as the snapshot date.
811               If not specified, use the current date/time.
812               If you specify a date here, be sure it's UTC.
813
814 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
815
816         * tests/test-argp-2.sh: Fix test to match actual output.
817         (func_compare): Fix sed script to be portable.
818
819 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
820
821         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
822         workaround for this case.  It is not autoconfigured now; offhand
823         it's hard to see how to autoconfigure it.
824
825 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
826
827         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
828         a directory that is about to be chowned.  Such a directory's
829         initial file permissions should permit the owner only and this
830         should not be changed until after the chown, since the group and
831         other bits would be incorrect if they granted permission before
832         the chown.
833
834         Fix porting problem for iswctype reported by Georg Schwarz in:
835         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
836         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
837         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
838         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
839         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
840
841 2006-12-03  Jim Meyering  <jim@meyering.net>
842
843         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
844         p->fts_statp may not yet be defined.
845         (fts_read): Instead, set it in the caller, once p->fts_statp is
846         sure to be defined, and corresponds to a top-level directory.
847         This bug made du -x fail.  Here's the coreutils test case:
848         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
849         Reported by Mike Frysinger.
850
851 2006-12-01  Jim Meyering  <jim@meyering.net>
852
853         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
854         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
855         Reported by Simon Josefsson.
856
857 2006-11-30  Jim Meyering  <jim@meyering.net>
858
859         * m4/warning.m4: Use the all-permissive copyright notice
860         recommended by RMS (rather than LGPL).
861         * m4/vararrays.m4: Likewise.
862         * m4/flexmember.m4: Likewise.
863
864 2006-11-29  Bruno Haible  <bruno@clisp.org>
865
866         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
867         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
868         using +=.
869         Reported by Simon Josefsson <simon@josefsson.org>.
870
871 2006-11-28  James Youngman <jay@gnu.org>
872
873         * README: Advise users that they might find the bug-gnulib@gnu.org
874         and autotools-announce@gnu.org mailing lists useful.
875
876 2006-11-28  Bruno Haible  <bruno@clisp.org>
877
878         * m4/ptrdiff_max.m4: Remove file.
879
880 2006-11-21  Bruno Haible  <bruno@clisp.org>
881
882         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
883         _AC_COMPUTE_INT.
884         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
885         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
886         _AC_COMPUTE_INT.
887         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
888         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
889         _AC_COMPUTE_INT.
890         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
891
892 2006-11-28  Jim Meyering  <jim@meyering.net>
893
894         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
895         warning from "gcc -Wshadow" about shadowing the builtin.
896
897 2006-11-27  Bruno Haible  <bruno@clisp.org>
898
899         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
900         _AC_COMPUTE_INT.
901         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
902
903 2006-11-27  Bruno Haible  <bruno@clisp.org>
904             Paul Eggert  <eggert@cs.ucla.edu>
905
906         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
907
908 2006-11-26  Bruno Haible  <bruno@clisp.org>
909
910         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
911         noinst_LTLIBRARIES.
912
913 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
914             Bruno Haible  <bruno@clisp.org>
915
916         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
917         if compiling with "gcc -ansi".
918
919 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
920
921         Fix some incompatibilities with gcc -ansi -pedantic.
922         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
923         if compiling pedantically with GCC, unless it's C99 or later.
924         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
925         it mishandles gcc -ansi -pedantic as well.
926         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
927         if gcc -pedantic.
928         * lib/regexec.c (check_node_accept_bytes): Don't use auto
929         initializers for struct if -pedantic, unless it's C99 or later.
930
931 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
932
933         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
934         Don't close an fd more than once. Identical atimes indicate
935         success, not failure.
936
937 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
938
939         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
940
941 2006-11-23  Jim Meyering  <jim@meyering.net>
942
943         * build-aux/announce-gen: New file.  From coreutils.
944
945 2006-11-22  Jim Meyering  <jim@meyering.net>
946
947         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
948         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
949         (fts_read): Use a temporary to narrow the overused st_size member
950         before using it in a switch statement.  Reported by Matthew Woehlke.
951
952         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
953         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
954
955 2006-11-20  Bruno Haible  <bruno@clisp.org>
956
957         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
958         changequote instead of pairs of brackets.
959         Reported by Andreas Schwab <schwab@suse.de>.
960
961 2006-11-21  Jim Meyering  <jim@meyering.net>
962
963         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
964         so as to remain compatible with older compilers.
965         Patch from Michael Deutschmann.
966
967 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
968
969         * MODULES.html.sh (File system functions): Add openat.
970
971         * lib/openat.h (rpl_fstatat): New macro, if
972         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
973         (fstatat): Define to rpl_fstatat under the same conditions,
974         unless COMPILING_FSTATAT.
975         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
976         seems to have the bug.
977         * lib/fstatat.c: New file.
978         * modules/openat (Files): Add it.
979
980 2006-11-20  Bruno Haible  <bruno@clisp.org>
981
982         * Makefile: New file.
983
984 2006-11-20  Jim Meyering  <jim@meyering.net>
985
986         The beginnings of syntax-related checks for gnulib.
987         * lib/Makefile: New file.
988         * lib/t-idcache: New script.  Ensure that the two halves of
989         idcache.c stay in sync.
990
991         * lib/idcache.c: Adjust comments in user- and group- portions to
992         be more accurate, and to be consistent with one another.
993
994 2006-11-20  Jim Meyering  <jim@meyering.net>
995
996         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
997         continue using the flexible array member (thus, this module performs
998         half as many malloc calls), with the addition that...
999         (getgroup, getuser): Consistently record a non-match via an empty
1000         "name" string, and map an empty string match to a NULL return value.
1001         * modules/idcache (Depends-on): Re-add flexmember.
1002
1003         * lib/idcache.c (getuser): Remove all uses of the register keyword.
1004         (getuidbyname, getgroup, getgidbyname): Likewise.
1005
1006         Use cleaner syntax: NULL rather than 0.
1007         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
1008
1009 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1010
1011         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
1012         It mishandled the case where the group was missing.
1013         Problem reported by Greg Schafer.
1014         * modules/idcache: Likewise.
1015
1016 2006-11-18  Jim Meyering  <jim@meyering.net>
1017
1018         * check-module (%exempt_header): Add exception for some
1019         conditionally-included headers.
1020
1021         * modules/i-ring (Depends-on): Add verify.
1022         (License): Change to LGPL.
1023
1024 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
1025
1026         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
1027         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
1028         and inttostr.h.  Use snprintf rather than uinttostr, so that
1029         LGPLed code doesn't depend on GPLed.
1030
1031 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
1032
1033         * modules/inline (License): Change from GPL to LGPL.
1034
1035 2006-11-17  Jim Meyering  <jim@meyering.net>
1036
1037         * modules/d-type (License): Switch to LGPL.
1038
1039 2006-11-15  Bruno Haible  <bruno@clisp.org>
1040
1041         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
1042
1043 2006-11-15  Eric Blake  <ebb9@byu.net>
1044
1045         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
1046         the module dependency.
1047
1048 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1049             Bruno Haible  <bruno@clisp.org>
1050
1051         * gnulib-tool (func_create_testdir): Add license consistency check.
1052
1053 2006-11-15  Eric Blake  <ebb9@byu.net>
1054
1055         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
1056         random "(cached)" in configure output.
1057
1058 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1059
1060         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
1061         test for conforming inttypes.h is both announced and cached.
1062
1063         * MODULES.html.sh (seen_modules, seen_files): New variables.
1064         (func_module): Rewrite to use a few less gnulib-tool and sed
1065         invocations.  Avoid a couple of quadratic algorithms for ...
1066         (missed_modules, missed_files): ... these, with ...
1067         (func_append, func_tmpdir): ... these new functions, from
1068         gnulib-tool.  Analogously, install traps for cleanup.
1069
1070         * tests/test-gc.c (main): Remove unused variables.
1071         * tests/test-read-file.c: Include stdlib.h, for 'free'.
1072
1073 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
1074
1075         * modules/inttostr (License): Change to LGPL.
1076
1077 2006-11-14  Eric Blake  <ebb9@byu.net>
1078
1079         * modules/tempname (License): Change to LGPL.
1080
1081 2006-11-14  Eric Blake  <ebb9@byu.net>
1082
1083         * doc/functions.texi (Function Portability): *printf functions on
1084         Cygwin now understand all POSIX size specifiers.
1085
1086 2006-11-14  Bruno Haible  <bruno@clisp.org>
1087
1088         * modules/c-ctype (License): Change to LGPL.
1089
1090 2006-11-12  Bruno Haible  <bruno@clisp.org>
1091
1092         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
1093         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
1094         for GNOME libraries, for which the include files are installed in
1095         subdirectories of $prefix/include.
1096
1097 2006-11-12  Bruno Haible  <bruno@clisp.org>
1098
1099         * m4/lib-link.m4: Require at least autoconf-2.54.
1100         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
1101         name to underscores for the --with option.
1102
1103 2006-11-13  Bruno Haible  <bruno@clisp.org>
1104
1105         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
1106         the tests directory.
1107         Reported by Ralf Wildenhues.
1108
1109 2006-11-13  Bruno Haible  <bruno@clisp.org>
1110
1111         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
1112         (func_emit_initmacro_end): Undo the override here.
1113         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
1114         Works around the famous automake error in coreutils.
1115
1116 2006-11-13  Eric Blake  <ebb9@byu.net>
1117
1118         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
1119         element, not its node.
1120
1121 2006-11-12  Bruno Haible  <bruno@clisp.org>
1122
1123         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
1124         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
1125
1126 2006-11-12  Bruno Haible  <bruno@clisp.org>
1127
1128         * gnulib-tool: New option --local-symlink.
1129         (func_usage): Document it.
1130         (lsymbolic): New variable.
1131         (func_import, func_create_testdir): If --symlink was not specified,
1132         test whether --local-symlink was specified and the file comes from
1133         the local_gnulib_dir.
1134
1135 2006-11-12  Bruno Haible  <bruno@clisp.org>
1136
1137         * gnulib-tool (func_ln): New function.
1138         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
1139
1140 2006-11-12  Bruno Haible  <bruno@clisp.org>
1141
1142         Finish support for source files in subdirectories.
1143         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
1144         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
1145         AUTOMAKE_OPTIONS.
1146         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
1147
1148 2006-11-12  Bruno Haible  <bruno@clisp.org>
1149
1150         * gnulib-tool (func_get_automake_snippet): Synthesize also an
1151         EXTRA_lib_SOURCES augmentation.
1152         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
1153
1154 2006-11-12  Jim Meyering  <jim@meyering.net>
1155
1156         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
1157         file descriptors.  This also averts a failure on systems with
1158         native openat support when a traversed directory lacks "x" access.
1159         * lib/fts_.h: Include "i-ring.h"
1160         (struct FTS) [fts_fd_ring]: New member.
1161         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
1162         (FCHDIR): Add parentheses.
1163         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
1164         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
1165         When descending, rather than simply closing the previous
1166         fts_cwd_fd value, push that file descriptor onto the ring.
1167         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
1168         (fts_open): Initialize the new fd_ring member.
1169         (fts_close): Clear the ring.
1170         (fts_safe_changedir): When possible, use our new fd_ring to skip
1171         the diropen and fstat and dev/ino comparison that would normally
1172         accompany a virtual `chdir ("..")'.
1173
1174         * modules/fts (Depends-on): Add i-ring.
1175         * modules/i-ring: New module.
1176         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
1177         * m4/i-ring.m4: New file.
1178
1179 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1180
1181         * gnulib-tool (func_create_testdir): Fix replacement of
1182         `build-aux' in configure.ac.  Run autotools in gltests
1183         subdirectory.
1184         (func_create_testdir, func_create_megatestdir, test): There is
1185         no need for '--force' in most autotool invocations in a new
1186         tree.  Actually fail the whole test if any of the tools, or the
1187         configure or make stages fail.
1188
1189         Sync from Automake.
1190         * build-aux/gnupload: Revert last change.  Add pointer to upload
1191         instructions of the GNU Maintenance Instructions.
1192         Suggestion by Karl Berry.
1193
1194 2006-11-10  Jim Meyering  <jim@meyering.net>
1195
1196         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
1197
1198 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1199
1200         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
1201         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
1202         (bind_textdomain_codeset) [! ENABLE_NLS]:
1203         Evaluate all the arguments.  That way, callers get compatible behavior
1204         if the arguments have side effects.  Also, it avoids some GCC
1205         diagnostics in some cases; Joel E. Denny reported problems when Bison
1206         was configured with --enable-gcc-warnigs.
1207
1208 2006-11-10  Jim Meyering  <jim@meyering.net>
1209
1210         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
1211         relevant options in CFLAGS (like -O, -fno-inline) are taken into
1212         account.
1213
1214 2006-11-10  Jim Meyering  <jim@meyering.net>
1215
1216         * modules/inline: New file/module.
1217         * modules/xalloc (Files): Remove m4/inline.m4.
1218         (Depends-on): Add inline, instead.
1219         * modules/oset: Likewise.
1220         * modules/list: Likewise.
1221
1222 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1223
1224         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
1225         Problem reported by Matthew Woehlke.
1226
1227 2006-11-09  Bruno Haible  <bruno@clisp.org>
1228
1229         * lib/tempname.c (gen_tempname): Remove variant that invokes
1230         __gen_tempname.
1231         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
1232         __gen_tempname.
1233
1234 2006-11-08  Bruno Haible  <bruno@clisp.org>
1235
1236         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
1237         to 'yes' instead of 'cross-compiling'.
1238
1239 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
1240
1241         * lib/quotearg.h (quotearg_free): New decl.
1242         * lib/quotearg.c (quotearg_free): New function.
1243         (slot0, nslots, slotvec0, slotvec):
1244         Now file-scope so that quotearg_free can get at them.
1245
1246 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1247
1248         Sync from Automake.
1249         * build-aux/gnupload: Add missing 'gnu' to example URL.
1250         Report by Karl Berry.
1251
1252 2006-11-08  Bruno Haible  <bruno@clisp.org>
1253
1254         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
1255         Suggested by Paul Eggert.
1256
1257 2006-11-08  Jim Meyering  <jim@meyering.net>
1258
1259         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
1260         It's already included if !_LIBC.
1261         (fts_safe_changedir): Add a comment.
1262
1263 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1264
1265         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
1266         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
1267         Matthew Woehlke.
1268
1269         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
1270         definitions up, to avoid colliding with change below.
1271         (static_inline) [HAVE_INLINE]: New macro.
1272         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
1273         Provide extern decls when !HAVE_INLINE.  Do not define unless
1274         static_inline is defined, either by us or by xmalloc.c.  Use
1275         static_inline rather than static inline.
1276         (XCALLOC): Optimize sizeof(T) = 1 case.
1277         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
1278
1279 2006-11-07  Bruno Haible  <bruno@clisp.org>
1280
1281         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
1282         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
1283         AC_C_INLINE.
1284         * modules/xalloc (Files): Add m4/inline.m4.
1285
1286 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1287
1288         * README: Fix typo.
1289         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
1290         (Miscellanous Notes): ...from this.
1291
1292 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1293
1294         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
1295         Mention that offsetof should be used instead of sizeof.
1296         From Bruno Haible.
1297
1298 2006-11-07  Bruno Haible  <bruno@clisp.org>
1299
1300         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
1301
1302 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1303
1304         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1305         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
1306         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1307         (gl_tree_add_before, gl_tree_add_after):
1308         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
1309         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
1310         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1311         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
1312         (gl_linked_add_after, gl_linked_add_at): Likewise.
1313         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
1314         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1315         (gl_tree_add_before, gl_tree_add_after): Likewise.
1316         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
1317         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
1318         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
1319
1320 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1321
1322         * lib/gl_oset.h: Use C comment style, not C++ comment style.
1323
1324 2006-11-06  Bruno Haible  <bruno@clisp.org>
1325
1326         * m4/inline.m4: New file.
1327         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
1328         * modules/list (Files): Add m4/inline.m4.
1329         * modules/oset (Files): Likewise.
1330
1331 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1332
1333         * lib/idcache.c: Include <stddef.h>, for offsetof.
1334         (struct userid.name): Change from char * to a flexible array member.
1335         All uses changed.
1336         * modules/idcache (Depends-on): Add flexmember.
1337
1338         * MODULES.html.sh (Core language properties): New module flexmember.
1339         * modules/flexmember, m4/flexmember.m4: New files.
1340
1341         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
1342         inline functions that are identical with the old xnmalloc_inline,
1343         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
1344         that we can avoid some unnecessary integer multiplications and
1345         divisions in the common case where the element size is known at
1346         compile time.
1347         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
1348         needed.
1349         (xnboundedmalloc): Remove.
1350         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
1351         arguments, for consistency with rest of this header.
1352         (xcharalloc): Rewrite using XNMALLOC.
1353         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
1354         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
1355         versions have been moved to lib/xalloc.h and renamed to be the
1356         non-*_inline versions.
1357         (xmalloc, xrealloc): Implement without reference to the xnmalloc
1358         and xnrealloc functions, since those functions are now inline and
1359         now call us.
1360         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
1361         renaming described above.
1362         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
1363         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
1364         captures the dependency in AC_C_INLINE.
1365
1366         New module canonicalize-lgpl, proposed by Charles Wilson in
1367         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
1368         with a few small changes afterwards.
1369         * MODULES.html.sh (File system functions): New module
1370         canonicalize-lgpl.
1371         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
1372         and canonicalize_file_name.
1373         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
1374         * modules/canonicalize-lgpl: New files.
1375
1376 2006-11-05  Bruno Haible  <bruno@clisp.org>
1377
1378         * gnulib-tool (func_import, func_create_testdir): Create directories
1379         also for files in subdirectories of lib/.
1380
1381 2006-11-05  Bruno Haible  <bruno@clisp.org>
1382
1383         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
1384         ANSI C compliant.
1385
1386 2006-11-03  Bruno Haible  <bruno@clisp.org>
1387
1388         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1389         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
1390         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
1391         (xnboundedmalloc): New inline function.
1392         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
1393         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
1394         xmalloc.
1395         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
1396         xmalloc.
1397         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
1398         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
1399         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
1400         xmalloc.
1401         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1402         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
1403         xmalloc.
1404         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
1405         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1406         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
1407         xmalloc.
1408         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1409         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
1410         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1411         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
1412         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
1413         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
1414         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
1415
1416 2006-11-03  Bruno Haible  <bruno@clisp.org>
1417
1418         * lib/c-ctype.h [C++]: Define functions without name mangling.
1419         * lib/fwriteerror.h [C++]: Likewise.
1420         * lib/gcd.h [C++]: Likewise.
1421         * lib/linebreak.h [C++]: Likewise.
1422
1423 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
1424
1425         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
1426         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
1427         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
1428         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1429         Check for functions and headers just once.
1430         Check for declaration of canonicalize_file_name.
1431         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
1432
1433 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1434
1435         * gnulib-tool (func_import): Fix typo in actioncmd.
1436
1437 2006-11-02  Bruno Haible  <bruno@clisp.org>
1438
1439         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
1440         newline sequence in the Makefile.am snippet as a space, like "make"
1441         does.
1442         Reported by Roger Persson <perrog@gmail.com>.
1443
1444 2006-11-01  Bruno Haible  <bruno@clisp.org>
1445
1446         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
1447         already declared in <string.h>.
1448         * lib/strcase.h (strncasecmp): Don't declare it if yes.
1449
1450 2006-11-01  Bruno Haible  <bruno@clisp.org>
1451
1452         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
1453         * lib/strcase.h: Include <string.h>.
1454         (strcasecmp): Define to rpl_strcasecmp here.
1455
1456 2006-11-01  Bruno Haible  <bruno@clisp.org>
1457
1458         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
1459
1460 2006-11-01  Eric Blake  <ebb9@byu.net>
1461
1462         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
1463
1464         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
1465
1466 2006-10-29  Bruno Haible  <bruno@clisp.org>
1467
1468         Make it compile in C++ mode.
1469         * lib/full-write.c (full_rw): Add a cast.
1470
1471 2006-11-01  Bruno Haible  <bruno@clisp.org>
1472
1473         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
1474         be POSIX compliant.
1475         Reported by Roger Persson <perrog@gmail.com>.
1476
1477 2006-11-01  Eric Blake  <ebb9@byu.net>
1478
1479         * lib/getopt_.h: Fix comments.
1480
1481 2006-10-31  Eric Blake  <ebb9@byu.net>
1482
1483         * modules/tmpdir (Depends-on): Add sys_stat.
1484         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
1485         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
1486         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
1487         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
1488         tempname.
1489
1490 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
1491
1492         Avoid some C++ diagnostics reported by Bruno Haible.
1493         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
1494         xmalloc.
1495         (quotearg_alloc): Use xcharalloc rather than xmalloc.
1496         (struct slotvec): Move to top level.
1497         (quotearg_n_options): Rewrite to avoid xmalloc.
1498         * lib/xalloc.h (xcharalloc): New function.
1499         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
1500         [defined __cplusplus]: Add function template that provides result
1501         type propagation.  This part of the change is from Bruno Haible.
1502
1503 2006-10-29  Bruno Haible  <bruno@clisp.org>
1504
1505         Make it compile in C++ mode.
1506         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
1507         * lib/strnlen1.c (strnlen1): Cast memchr result.
1508         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
1509         * lib/clean-temp.c (string_equals, string_hash): Add casts.
1510         (create_temp_dir): Rename local variable 'template'.
1511         (compile_csharp_using_sscli): Add cast.
1512         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
1513         * lib/findprog.c (find_in_path): Likewise.
1514         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
1515         * lib/wait-process.c (register_slave_subprocess): Likewise.
1516
1517 2006-10-22  Bruno Haible  <bruno@clisp.org>
1518
1519         * modules/tsearch: New file.
1520         * lib/tsearch.h: New file.
1521         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
1522         * m4/tsearch.m4: New file.
1523         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
1524
1525 2006-10-29  Eric Blake  <ebb9@byu.net>
1526
1527         * lib/arcfour.c: Assume config.h.
1528         * lib/arctwo.c: Likewise.
1529         * lib/base64.c: Likewise.
1530         * lib/check-version.c: Likewise.
1531         * lib/crc.c: Likewise.
1532         * lib/des.c: Likewise.
1533         * lib/gc-gnulib.c: Likewise.
1534         * lib/gc-libgcrypt.c: Likewise.
1535         * lib/gc-pbkdf2-sha1.c: Likewise.
1536         * lib/getaddrinfo.c: Likewise.
1537         * lib/getdelim.c: Likewise.
1538         * lib/getline.c: Likewise.
1539         * lib/hmac-md5.c: Likewise.
1540         * lib/hmac-sha1.c: Likewise.
1541         * lib/iconvme.c: Likewise.
1542         * lib/md2.c: Likewise.
1543         * lib/md4.c: Likewise.
1544         * lib/memxor.c: Likewise.
1545         * lib/read-file.c: Likewise.
1546         * lib/readline.c: Likewise.
1547         * lib/rijndael-alg-fst.c: Likewise.
1548         * lib/rijndael-api-fst.c: Likewise.
1549         * lib/xgetdomainname.c: Likewise.
1550
1551 2006-10-28  Eric Blake  <ebb9@byu.net>
1552
1553         * lib/xstrndup.c: Assume config.h.
1554
1555 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
1556
1557         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
1558         stat-macros.h is now for our own macros, whereas stat_h is for
1559         macros in the <sys/stat.h> name space.
1560         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
1561         (STAT_MACROS_H): Remove.
1562         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
1563         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
1564         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
1565         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
1566         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
1567         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
1568         Move these macros to ...
1569         * lib/stat_.h: here.  Don't include stat-macros.h.
1570         * lib/canonicalize.c: Don't include stat-macros.h.
1571         * lib/chown.c: Likewise.
1572         * lib/euidaccess.c: Likewise.
1573         * lib/file-type.c: Likewise.
1574         * lib/filemode.c: Likewise.
1575         * lib/glob.c: Likewise.
1576         * lib/isapipe.c: Likewise.
1577         * lib/lchown.c: Likewise.
1578         * lib/lstat.c: Likewise.
1579         * lib/mkdir-p.c: Likewise.
1580         * lib/rmdir.c: Likewise.
1581         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
1582         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
1583         unless mkdir isn't declared, to speed up 'configure'.
1584         Always create sys/stat.h, since it's unlikely any real sys/stat.h
1585         would define all the S_* symbols.
1586         * modules/canonicalize (Depends-on):
1587         Depend on sys_stat, not stat-macros.
1588         * modules/chown: Likewise.
1589         * modules/euidaccess: Likewise.
1590         * modules/filemode: Likewise.
1591         * modules/file-type: Likewise.
1592         * modules/glob: Likewise.
1593         * modules/isapipe: Likewise.
1594         * modules/lchown: Likewise.
1595         * modules/lstat: Likewise.
1596         * modules/mkancesdirs: Likewise.
1597         * modules/rmdir: Likewise.
1598         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
1599         * modules/modechange: Likewise.
1600         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
1601         (configure.ac): Remove gl_STAT_MACROS.
1602         * modules/sys_stat (Depends-on): Remove stat-macros.
1603
1604 2006-10-27  Bruno Haible  <bruno@clisp.org>
1605
1606         * m4/signed.m4: Remove file.
1607         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
1608         invocation.
1609         * modules/vasnprintf (Files): Remove m4/signed.m4.
1610
1611 2006-10-27  Bruno Haible  <bruno@clisp.org>
1612
1613         Update to GNU gettext 0.16.
1614         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
1615         m4/inttypes-h.m4, m4/signed.m4.
1616         * m4/gettext.m4: Update to GNU gettext 0.16.
1617         * m4/intl.m4: New file, from GNU gettext.
1618         * m4/intldir.m4: New file, from GNU gettext.
1619         * config/srclist.txt: Update
1620
1621 2006-10-27  Eric Blake  <ebb9@byu.net>
1622
1623         * MODULES.html.sh: Document tempname.
1624         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
1625         dependencies.
1626         (Files): Move lib/tempname.c...
1627         * modules/tempname: ...to this new module.
1628         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
1629         (gl_PREREQ_TEMPNAME): Move...
1630         * m4/tempname.m4: ...to this new file.
1631         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
1632         * modules/sys_stat (Depends-on): Add stat-macros.
1633         * lib/stat_.h (includes): Pick up stat macros.
1634         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
1635         if stat macros are broken.
1636         * lib/tempname.c (includes): No need to include "stat-macros.h".
1637         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
1638         (direxists, __path_search) [!_LIBC]: Don't compile these in
1639         gnulib; the tmpdir module covers that.
1640         * lib/tempname.h: New file.
1641
1642 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
1643
1644         * COPYING: Explain how gnulib-tool converts licence headers.
1645         Almost all wording by Eric Blake.
1646
1647 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
1648
1649         * lib/mbchar.h (is_basic_table): Make read-only.
1650         * lib/mbchar.c (is_basic_table): Likewise.
1651         Reported by John Darrington.
1652
1653 2006-10-25  Bruno Haible  <bruno@clisp.org>
1654
1655         * lib/progname.h (set_program_name): Undefine before defining.
1656
1657 2006-10-25  Bruno Haible  <bruno@clisp.org>
1658
1659         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
1660         false for non-gcc C++ compilers.
1661         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
1662
1663 2006-10-24  Bruno Haible  <bruno@clisp.org>
1664
1665         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
1666         iconv implementations like Irix iconv.
1667
1668 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1669
1670         * modules/vararrays: New file.
1671         * m4/vararrays.m4: New file, taken from diffutils.
1672         * MODULES.html.sh: New module vararrays.
1673
1674 2006-10-24  Karl Berry  <karl@gnu.org>
1675
1676         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
1677         Don't call GNU Unix.
1678
1679 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1680
1681         * users.txt: Add Libtool.
1682
1683         Sync from Libtool:
1684
1685         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1686
1687         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
1688         to gnulib's policy of including config.h unconditionally.
1689
1690 2006-10-24  Bruno Haible  <bruno@clisp.org>
1691
1692         * modules/wcwidth (Files): Add m4/wint_t.m4.
1693         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
1694         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
1695
1696 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
1697
1698         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
1699         to pacify GCC with some -W flags enabled.  Problem reported by
1700         Bruno Haible.
1701
1702 2006-10-24  Jim Meyering  <jim@meyering.net>
1703
1704         * MODULES.html.sh: Remove uinttostr.  It's not a module.
1705         Reported by Karl Berry.
1706
1707 2006-10-23  Bruno Haible  <bruno@clisp.org>
1708
1709         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
1710
1711 2006-10-24  Bruno Haible  <bruno@clisp.org>
1712
1713         * lib/gl_list.h: Use C comment style, not C++ comment style.
1714
1715 2006-10-23  Eric Blake  <ebb9@byu.net>
1716
1717         * lib/getaddrinfo.c (includes): Add missing include.
1718
1719 2006-10-23  Bruno Haible  <bruno@clisp.org>
1720             Paul Eggert  <eggert@cs.ucla.edu>
1721
1722         Ability to rename obstack_free.
1723         * lib/obstack.h (__obstack_free): New macro. Declare instead of
1724         obstack_free.
1725         (obstack_free): Invoke the __obstack_free macro.
1726         * lib/obstack.c (obstack_free): Use __obstack_free macro.
1727
1728 2006-10-23  Bruno Haible  <bruno@clisp.org>
1729             Paul Eggert  <eggert@cs.ucla.edu>
1730
1731         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
1732         __argc, __argv from the declaration. (They are defined as macros on
1733         mingw.)
1734
1735 2006-10-22  Bruno Haible  <bruno@clisp.org>
1736
1737         * doc/gnulib-intro.texi: New file.
1738         * doc/gnulib.texi: Include it.
1739
1740 2006-10-21  Bruno Haible  <bruno@clisp.org>
1741
1742         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
1743         "Introduction", "Miscellanous Notes", "Particular Modules".
1744
1745 2006-10-21  Bruno Haible  <bruno@clisp.org>
1746
1747         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1748         Change mostlyclean-local rule to avoid sh syntax error from bash
1749         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
1750
1751 2006-10-23  Jim Meyering  <jim@meyering.net>
1752
1753         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
1754         in place of snprintf.
1755
1756         * modules/inttostr (Files): Add lib/uinttostr.c.
1757         * lib/uinttostr.c (inttostr): New file/function.
1758         * lib/inttostr.h (uinttostr): Declare.
1759         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
1760         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
1761         Add uinttostr.
1762         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
1763
1764 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1765
1766         * lib/canonicalize.c (ELOOP): Define if not already defined.
1767         Problem reported by Bruno Haible in
1768         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
1769
1770 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
1771
1772         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
1773         Problem reported by Perry Smith and Ville Laurikari.
1774
1775         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
1776         uses.
1777
1778 2006-10-19  Bruno Haible  <bruno@clisp.org>
1779
1780         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
1781         for mingw.
1782
1783 2006-10-19  Bruno Haible  <bruno@clisp.org>
1784
1785         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
1786         Needed for mingw.
1787
1788 2006-10-19  Bruno Haible  <bruno@clisp.org>
1789
1790         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
1791
1792 2006-10-19  Bruno Haible  <bruno@clisp.org>
1793
1794         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
1795         it.
1796
1797 2006-10-19  Bruno Haible  <bruno@clisp.org>
1798
1799         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
1800         invocation.
1801
1802 2006-10-19  Bruno Haible  <bruno@clisp.org>
1803
1804         * gnulib-tool (func_create_testdir): Don't include ftruncate and
1805         mountlist by default.
1806
1807 2006-10-16  Bruno Haible  <bruno@clisp.org>
1808
1809         * lib/c-strstr.c: Include c-strstr.h.
1810
1811 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1812
1813         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
1814         in a slash.
1815
1816 2006-10-18  Bruno Haible  <bruno@clisp.org>
1817
1818         * lib/lock.h [C++]: Wrap definitions in extern "C".
1819
1820 2006-10-18  Bruno Haible  <bruno@clisp.org>
1821
1822         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
1823         gl_LIBOBJS list.
1824
1825 2006-10-18  Bruno Haible  <bruno@clisp.org>
1826
1827         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
1828
1829 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
1830
1831         * lib/xstrtol.h: Include gettext.h.
1832         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
1833         Problem reported by Eric Blake.
1834         * modules/xstrtol (Depends-on): Add gettext-h.
1835
1836 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
1837
1838         * lib/strftime.c (advance): New macro.
1839         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
1840         incomplete type, so you can't add 0 to it.  Problem and patch
1841         reported by Eelco Dolstra for dietlibc.
1842
1843 2006-10-18  Jim Meyering  <jim@meyering.net>
1844
1845         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
1846         type for a local, and rename it: s/up/user_proc/.
1847
1848 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
1849
1850         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
1851         READ_UTMP_USER_PROCESS.
1852         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
1853
1854 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
1855
1856         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
1857         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
1858
1859 2006-10-17  Eric Blake  <ebb9@byu.net>
1860
1861         * lib/sigprocmask.c (sigprocmask): Fix typo.
1862
1863         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
1864
1865         * modules/clean-temp (Makefile.am): Don't add to make output...
1866         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
1867         config.h.
1868
1869 2006-10-17  Bruno Haible  <bruno@clisp.org>
1870
1871         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
1872         differently if DEFAULT_TEXT_DOMAIN is set.
1873
1874 2006-10-16  Bruno Haible  <bruno@clisp.org>
1875
1876         * lib/clean-temp.c: Include fwriteerror.h.
1877
1878 2006-10-16  Bruno Haible  <bruno@clisp.org>
1879
1880         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
1881
1882 2006-10-16  Bruno Haible  <bruno@clisp.org>
1883
1884         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
1885         * lib/sigprocmask.h: Include <sys/types.h>.
1886         (sigset_t): Use the system's definition if present.
1887
1888 2006-10-17  Eric Blake  <ebb9@byu.net>
1889
1890         * lib/xvasprintf.c (includes): Assume config.h.
1891         * lib/xasprintf.c (includes): Likewise.
1892
1893 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
1894
1895         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
1896         at least as wide as intmax_t.
1897
1898 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
1899
1900         (Imported from Automake.)
1901         * build-aux/gnupload: Update to version 1.1 of directive file.
1902
1903 2006-10-16  Eric Blake  <ebb9@byu.net>
1904
1905         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
1906         match Automake 1.10a.
1907
1908 2006-10-14  Bruno Haible  <bruno@clisp.org>
1909
1910         * modules/sigprocmask: New file.
1911         * lib/sigprocmask.h: New file.
1912         * lib/sigprocmask.c: New file.
1913         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
1914         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
1915         request sigprocmask.o.
1916         (gl_PREREQ_SIGPROCMASK): New macro.
1917         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
1918         (Depends-on): Add sigprocmask.
1919         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
1920         gt_SIGNALBLOCKING. Test for 'raise' only once.
1921         * lib/fatal-signal.c: Include sigprocmask.h.
1922         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
1923         unblock_fatal_signals): Define always.
1924         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
1925         sigprocmask.
1926
1927 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
1928
1929         Sync from Automake.
1930         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
1931         which incorrectly sets the mode of an existing destination
1932         directory.  In some cases the unpatched install-sh could do the
1933         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
1934         system.  We hope this is rare in practice, but it's clearly worth
1935         fixing.  Problem reported by Alex Unleashed in
1936         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
1937         Also, don't bother to check for -m bugs unless we're using -m;
1938         suggested by Stepan Kasal.
1939
1940 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1941
1942         Sync from Automake.
1943         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
1944         `-c' flag, so they appear at the same position as in %FASTDEP%
1945         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
1946         which ignores unknown options only after the first non-option.
1947         Bug report against M4 by Nelson H. F. Beebe.
1948
1949 2006-10-13  Jim Meyering  <jim@meyering.net>
1950
1951         Fix a bug in yesterday's change.
1952         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
1953         p->fts_statp->st_dev would be used uninitialized.
1954         Ensures that we always call fts_stat on the very first entry.
1955         Miklos Szeredi reported that find -xdev stopped working.
1956
1957 2006-10-12  Bruno Haible  <bruno@clisp.org>
1958
1959         * gnulib-tool (func_get_automake_snippet): Append an automatically
1960         computed EXTRA_DIST augmentation.
1961         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
1962         * modules/alloca-opt (Makefile.am): Likewise.
1963         * modules/allocsa (Makefile.am): Likewise.
1964         * modules/arcfour (Makefile.am): Likewise.
1965         * modules/arctwo (Makefile.am): Likewise.
1966         * modules/argmatch (Makefile.am): Likewise.
1967         * modules/argz (Makefile.am): Likewise.
1968         * modules/atexit (Makefile.am): Likewise.
1969         * modules/backupfile (Makefile.am): Likewise.
1970         * modules/byteswap (Makefile.am): Likewise.
1971         * modules/c-strtod (Makefile.am): Likewise.
1972         * modules/c-strtold (Makefile.am): Likewise.
1973         * modules/calloc (Makefile.am): Likewise.
1974         * modules/canon-host (Makefile.am): Likewise.
1975         * modules/canonicalize (Makefile.am): Likewise.
1976         * modules/chdir-long (Makefile.am): Likewise.
1977         * modules/chdir-safer (Makefile.am): Likewise.
1978         * modules/check-version (Makefile.am): Likewise.
1979         * modules/chown (Makefile.am): Likewise.
1980         * modules/cloexec (Makefile.am): Likewise.
1981         * modules/close-stream (Makefile.am): Likewise.
1982         * modules/closeout (Makefile.am): Likewise.
1983         * modules/crc (Makefile.am): Likewise.
1984         * modules/csharpexec (Makefile.am): Likewise.
1985         * modules/cycle-check (Makefile.am): Likewise.
1986         * modules/des (Makefile.am): Likewise.
1987         * modules/dev-ino (Makefile.am): Likewise.
1988         * modules/dirfd (Makefile.am): Likewise.
1989         * modules/dirname (Makefile.am): Likewise.
1990         * modules/dup2 (Makefile.am): Likewise.
1991         * modules/eealloc (Makefile.am): Likewise.
1992         * modules/error (Makefile.am): Likewise.
1993         * modules/euidaccess (Makefile.am): Likewise.
1994         * modules/exclude (Makefile.am): Likewise.
1995         * modules/exitfail (Makefile.am): Likewise.
1996         * modules/fcntl-safer (Makefile.am): Likewise.
1997         * modules/fcntl (Makefile.am): Likewise.
1998         * modules/file-type (Makefile.am): Likewise.
1999         * modules/fileblocks (Makefile.am): Likewise.
2000         * modules/filemode (Makefile.am): Likewise.
2001         * modules/filenamecat (Makefile.am): Likewise.
2002         * modules/fnmatch (Makefile.am): Likewise.
2003         * modules/fopen-safer (Makefile.am): Likewise.
2004         * modules/fpending (Makefile.am): Likewise.
2005         * modules/fprintftime (Makefile.am): Likewise.
2006         * modules/free (Makefile.am): Likewise.
2007         * modules/fsusage (Makefile.am): Likewise.
2008         * modules/ftruncate (Makefile.am): Likewise.
2009         * modules/fts (Makefile.am): Likewise.
2010         * modules/gc-arcfour (Makefile.am): Likewise.
2011         * modules/gc-des (Makefile.am): Likewise.
2012         * modules/gc-hmac-md5 (Makefile.am): Likewise.
2013         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
2014         * modules/gc-md4 (Makefile.am): Likewise.
2015         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2016         * modules/gc-sha1 (Makefile.am): Likewise.
2017         * modules/gc (Makefile.am): Likewise.
2018         * modules/getaddrinfo (Makefile.am): Likewise.
2019         * modules/getcwd (Makefile.am): Likewise.
2020         * modules/getdelim (Makefile.am): Likewise.
2021         * modules/getdomainname (Makefile.am): Likewise.
2022         * modules/getgroups (Makefile.am): Likewise.
2023         * modules/gethostname (Makefile.am): Likewise.
2024         * modules/gethrxtime (Makefile.am): Likewise.
2025         * modules/getline (Makefile.am): Likewise.
2026         * modules/getloadavg (Makefile.am): Likewise.
2027         * modules/getlogin_r (Makefile.am): Likewise.
2028         * modules/getndelim2 (Makefile.am): Likewise.
2029         * modules/getopt (Makefile.am): Likewise.
2030         * modules/getpagesize (Makefile.am): Likewise.
2031         * modules/getpass-gnu (Makefile.am): Likewise.
2032         * modules/getpass (Makefile.am): Likewise.
2033         * modules/getsubopt (Makefile.am): Likewise.
2034         * modules/gettime (Makefile.am): Likewise.
2035         * modules/gettimeofday (Makefile.am): Likewise.
2036         * modules/getugroups (Makefile.am): Likewise.
2037         * modules/getusershell (Makefile.am): Likewise.
2038         * modules/glob (Makefile.am): Likewise.
2039         * modules/group-member (Makefile.am): Likewise.
2040         * modules/hard-locale (Makefile.am): Likewise.
2041         * modules/hash (Makefile.am): Likewise.
2042         * modules/hmac-md5 (Makefile.am): Likewise.
2043         * modules/hmac-sha1 (Makefile.am): Likewise.
2044         * modules/human (Makefile.am): Likewise.
2045         * modules/idcache (Makefile.am): Likewise.
2046         * modules/imaxabs (Makefile.am): Likewise.
2047         * modules/imaxdiv (Makefile.am): Likewise.
2048         * modules/inet_ntop (Makefile.am): Likewise.
2049         * modules/inet_pton (Makefile.am): Likewise.
2050         * modules/intprops (Makefile.am): Likewise.
2051         * modules/inttostr (Makefile.am): Likewise.
2052         * modules/inttypes (Makefile.am): Likewise.
2053         * modules/isapipe (Makefile.am): Likewise.
2054         * modules/javaversion (Makefile.am): Likewise.
2055         * modules/lchmod (Makefile.am): Likewise.
2056         * modules/lchown (Makefile.am): Likewise.
2057         * modules/localcharset (Makefile.am): Likewise.
2058         * modules/long-options (Makefile.am): Likewise.
2059         * modules/lstat (Makefile.am): Likewise.
2060         * modules/malloc (Makefile.am): Likewise.
2061         * modules/mathl (Makefile.am): Likewise.
2062         * modules/mbchar (Makefile.am): Likewise.
2063         * modules/md2 (Makefile.am): Likewise.
2064         * modules/md4 (Makefile.am): Likewise.
2065         * modules/md5 (Makefile.am): Likewise.
2066         * modules/memcasecmp (Makefile.am): Likewise.
2067         * modules/memchr (Makefile.am): Likewise.
2068         * modules/memcmp (Makefile.am): Likewise.
2069         * modules/memcoll (Makefile.am): Likewise.
2070         * modules/memcpy (Makefile.am): Likewise.
2071         * modules/memmem (Makefile.am): Likewise.
2072         * modules/memmove (Makefile.am): Likewise.
2073         * modules/mempcpy (Makefile.am): Likewise.
2074         * modules/memrchr (Makefile.am): Likewise.
2075         * modules/memset (Makefile.am): Likewise.
2076         * modules/memxor (Makefile.am): Likewise.
2077         * modules/mkancesdirs (Makefile.am): Likewise.
2078         * modules/mkdir-p (Makefile.am): Likewise.
2079         * modules/mkdir (Makefile.am): Likewise.
2080         * modules/mkdtemp (Makefile.am): Likewise.
2081         * modules/mkstemp (Makefile.am): Likewise.
2082         * modules/mktime (Makefile.am): Likewise.
2083         * modules/modechange (Makefile.am): Likewise.
2084         * modules/mountlist (Makefile.am): Likewise.
2085         * modules/nanosleep (Makefile.am): Likewise.
2086         * modules/obstack (Makefile.am): Likewise.
2087         * modules/openat (Makefile.am): Likewise.
2088         * modules/pagealign_alloc (Makefile.am): Likewise.
2089         * modules/pathmax (Makefile.am): Likewise.
2090         * modules/physmem (Makefile.am): Likewise.
2091         * modules/poll (Makefile.am): Likewise.
2092         * modules/posixtm (Makefile.am): Likewise.
2093         * modules/posixver (Makefile.am): Likewise.
2094         * modules/putenv (Makefile.am): Likewise.
2095         * modules/quote (Makefile.am): Likewise.
2096         * modules/quotearg (Makefile.am): Likewise.
2097         * modules/raise (Makefile.am): Likewise.
2098         * modules/read-file (Makefile.am): Likewise.
2099         * modules/readline (Makefile.am): Likewise.
2100         * modules/readlink (Makefile.am): Likewise.
2101         * modules/readtokens (Makefile.am): Likewise.
2102         * modules/readutmp (Makefile.am): Likewise.
2103         * modules/realloc (Makefile.am): Likewise.
2104         * modules/regex (Makefile.am): Likewise.
2105         * modules/rename-dest-slash (Makefile.am): Likewise.
2106         * modules/rename (Makefile.am): Likewise.
2107         * modules/rijndael (Makefile.am): Likewise.
2108         * modules/rmdir (Makefile.am): Likewise.
2109         * modules/rpmatch (Makefile.am): Likewise.
2110         * modules/safe-read (Makefile.am): Likewise.
2111         * modules/safe-write (Makefile.am): Likewise.
2112         * modules/same-inode (Makefile.am): Likewise.
2113         * modules/same (Makefile.am): Likewise.
2114         * modules/save-cwd (Makefile.am): Likewise.
2115         * modules/savedir (Makefile.am): Likewise.
2116         * modules/setenv (Makefile.am): Likewise.
2117         * modules/settime (Makefile.am): Likewise.
2118         * modules/sha1 (Makefile.am): Likewise.
2119         * modules/sig2str (Makefile.am): Likewise.
2120         * modules/snprintf (Makefile.am): Likewise.
2121         * modules/stat-macros (Makefile.am): Likewise.
2122         * modules/stat-time (Makefile.am): Likewise.
2123         * modules/stdbool (Makefile.am): Likewise.
2124         * modules/stdint (Makefile.am): Likewise.
2125         * modules/stdlib-safer (Makefile.am): Likewise.
2126         * modules/stpcpy (Makefile.am): Likewise.
2127         * modules/stpncpy (Makefile.am): Likewise.
2128         * modules/strcase (Makefile.am): Likewise.
2129         * modules/strcasestr (Makefile.am): Likewise.
2130         * modules/strchrnul (Makefile.am): Likewise.
2131         * modules/strcspn (Makefile.am): Likewise.
2132         * modules/strdup (Makefile.am): Likewise.
2133         * modules/strerror (Makefile.am): Likewise.
2134         * modules/strftime (Makefile.am): Likewise.
2135         * modules/strndup (Makefile.am): Likewise.
2136         * modules/strnlen (Makefile.am): Likewise.
2137         * modules/strpbrk (Makefile.am): Likewise.
2138         * modules/strsep (Makefile.am): Likewise.
2139         * modules/strstr (Makefile.am): Likewise.
2140         * modules/strtod (Makefile.am): Likewise.
2141         * modules/strtoimax (Makefile.am): Likewise.
2142         * modules/strtok_r (Makefile.am): Likewise.
2143         * modules/strtol (Makefile.am): Likewise.
2144         * modules/strtoll (Makefile.am): Likewise.
2145         * modules/strtoul (Makefile.am): Likewise.
2146         * modules/strtoull (Makefile.am): Likewise.
2147         * modules/strtoumax (Makefile.am): Likewise.
2148         * modules/strverscmp (Makefile.am): Likewise.
2149         * modules/sys_socket (Makefile.am): Likewise.
2150         * modules/sys_stat (Makefile.am): Likewise.
2151         * modules/sysexits (Makefile.am): Likewise.
2152         * modules/time_r (Makefile.am): Likewise.
2153         * modules/timegm (Makefile.am): Likewise.
2154         * modules/timespec (Makefile.am): Likewise.
2155         * modules/tmpfile-safer (Makefile.am): Likewise.
2156         * modules/trim (Makefile.am): Likewise.
2157         * modules/unistd-safer (Makefile.am): Likewise.
2158         * modules/unlinkdir (Makefile.am): Likewise.
2159         * modules/unlocked-io (Makefile.am): Likewise.
2160         * modules/userspec (Makefile.am): Likewise.
2161         * modules/utime (Makefile.am): Likewise.
2162         * modules/utimecmp (Makefile.am): Likewise.
2163         * modules/utimens (Makefile.am): Likewise.
2164         * modules/vasnprintf (Makefile.am): Likewise.
2165         * modules/vasprintf (Makefile.am): Likewise.
2166         * modules/vsnprintf (Makefile.am): Likewise.
2167         * modules/xalloc (Makefile.am): Likewise.
2168         * modules/xgetcwd (Makefile.am): Likewise.
2169         * modules/xnanosleep (Makefile.am): Likewise.
2170         * modules/xreadlink (Makefile.am): Likewise.
2171         * modules/xstrtod (Makefile.am): Likewise.
2172         * modules/xstrtol (Makefile.am): Likewise.
2173         * modules/xstrtold (Makefile.am): Likewise.
2174         * modules/yesno (Makefile.am): Likewise.
2175         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
2176
2177 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2178
2179         * modules/error (Makefile.am): Distribute files through
2180         EXTRA_DIST, not lib_SOURCES.
2181
2182 2006-10-12  Eric Blake  <ebb9@byu.net>
2183
2184         * modules/error (Makefile.am): Distribute files in /lib.
2185         * modules/obstack (Makefile.am): Likewise.
2186
2187 2006-10-12  Bruno Haible  <bruno@clisp.org>
2188
2189         * modules/acl (Makefile.am): Distribute all files in lib/ through
2190         EXTRA_DIST.
2191         * modules/arcfour (Makefile.am): Likewise.
2192         * modules/arctwo (Makefile.am): Likewise.
2193         * modules/argmatch (Makefile.am): Likewise.
2194         * modules/argz (Makefile.am): Likewise.
2195         * modules/atexit (Makefile.am): Likewise.
2196         * modules/backupfile (Makefile.am): Likewise.
2197         * modules/c-strtod (Makefile.am): Likewise.
2198         * modules/c-strtold (Makefile.am): Likewise.
2199         * modules/calloc (Makefile.am): Likewise.
2200         * modules/canon-host (Makefile.am): Likewise.
2201         * modules/canonicalize (Makefile.am): Likewise.
2202         * modules/chdir-long (Makefile.am): Likewise.
2203         * modules/chdir-safer (Makefile.am): Likewise.
2204         * modules/check-version (Makefile.am): Likewise.
2205         * modules/chown (Makefile.am): Likewise.
2206         * modules/cloexec (Makefile.am): Likewise.
2207         * modules/close-stream (Makefile.am): Likewise.
2208         * modules/closeout (Makefile.am): Likewise.
2209         * modules/crc (Makefile.am): Likewise.
2210         * modules/cycle-check (Makefile.am): Likewise.
2211         * modules/des (Makefile.am): Likewise.
2212         * modules/dirfd (Makefile.am): Likewise.
2213         * modules/dirname (Makefile.am): Likewise.
2214         * modules/dup2 (Makefile.am): Likewise.
2215         * modules/euidaccess (Makefile.am): Likewise.
2216         * modules/exclude (Makefile.am): Likewise.
2217         * modules/exitfail (Makefile.am): Likewise.
2218         * modules/fcntl-safer (Makefile.am): Likewise.
2219         * modules/file-type (Makefile.am): Likewise.
2220         * modules/fileblocks (Makefile.am): Likewise.
2221         * modules/filemode (Makefile.am): Likewise.
2222         * modules/filenamecat (Makefile.am): Likewise.
2223         * modules/fnmatch (Makefile.am): Likewise.
2224         * modules/fopen-safer (Makefile.am): Likewise.
2225         * modules/fpending (Makefile.am): Likewise.
2226         * modules/fprintftime (Makefile.am): Likewise.
2227         * modules/free (Makefile.am): Likewise.
2228         * modules/fsusage (Makefile.am): Likewise.
2229         * modules/ftruncate (Makefile.am): Likewise.
2230         * modules/fts (Makefile.am): Likewise.
2231         * modules/gc (Makefile.am): Likewise.
2232         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2233         * modules/getaddrinfo (Makefile.am): Likewise.
2234         * modules/getcwd (Makefile.am): Likewise.
2235         * modules/getdelim (Makefile.am): Likewise.
2236         * modules/getdomainname (Makefile.am): Likewise.
2237         * modules/getgroups (Makefile.am): Likewise.
2238         * modules/gethostname (Makefile.am): Likewise.
2239         * modules/gethrxtime (Makefile.am): Likewise.
2240         * modules/getline (Makefile.am): Likewise.
2241         * modules/getloadavg (Makefile.am): Likewise.
2242         * modules/getlogin_r (Makefile.am): Likewise.
2243         * modules/getopt (Makefile.am): Likewise.
2244         * modules/getpass (Makefile.am): Likewise.
2245         * modules/getpass-gnu (Makefile.am): Likewise.
2246         * modules/getsubopt (Makefile.am): Likewise.
2247         * modules/gettime (Makefile.am): Likewise.
2248         * modules/gettimeofday (Makefile.am): Likewise.
2249         * modules/getugroups (Makefile.am): Likewise.
2250         * modules/getusershell (Makefile.am): Likewise.
2251         * modules/glob (Makefile.am): Likewise.
2252         * modules/group-member (Makefile.am): Likewise.
2253         * modules/hard-locale (Makefile.am): Likewise.
2254         * modules/hash (Makefile.am): Likewise.
2255         * modules/hmac-md5 (Makefile.am): Likewise.
2256         * modules/hmac-sha1 (Makefile.am): Likewise.
2257         * modules/human (Makefile.am): Likewise.
2258         * modules/idcache (Makefile.am): Likewise.
2259         * modules/imaxabs (Makefile.am): Likewise.
2260         * modules/imaxdiv (Makefile.am): Likewise.
2261         * modules/inet_ntop (Makefile.am): Likewise.
2262         * modules/inet_pton (Makefile.am): Likewise.
2263         * modules/inttostr (Makefile.am): Likewise.
2264         * modules/isapipe (Makefile.am): Likewise.
2265         * modules/lchown (Makefile.am): Likewise.
2266         * modules/long-options (Makefile.am): Likewise.
2267         * modules/lstat (Makefile.am): Likewise.
2268         * modules/malloc (Makefile.am): Likewise.
2269         * modules/mathl (Makefile.am): Likewise.
2270         * modules/mbchar (Makefile.am): Likewise.
2271         * modules/md2 (Makefile.am): Likewise.
2272         * modules/md4 (Makefile.am): Likewise.
2273         * modules/md5 (Makefile.am): Likewise.
2274         * modules/memcasecmp (Makefile.am): Likewise.
2275         * modules/memchr (Makefile.am): Likewise.
2276         * modules/memcmp (Makefile.am): Likewise.
2277         * modules/memcoll (Makefile.am): Likewise.
2278         * modules/memcpy (Makefile.am): Likewise.
2279         * modules/memmem (Makefile.am): Likewise.
2280         * modules/memmove (Makefile.am): Likewise.
2281         * modules/mempcpy (Makefile.am): Likewise.
2282         * modules/memrchr (Makefile.am): Likewise.
2283         * modules/memset (Makefile.am): Likewise.
2284         * modules/memxor (Makefile.am): Likewise.
2285         * modules/mkancesdirs (Makefile.am): Likewise.
2286         * modules/mkdir (Makefile.am): Likewise.
2287         * modules/mkdir-p (Makefile.am): Likewise.
2288         * modules/mkdtemp (Makefile.am): Likewise.
2289         * modules/mkstemp (Makefile.am): Likewise.
2290         * modules/mktime (Makefile.am): Likewise.
2291         * modules/modechange (Makefile.am): Likewise.
2292         * modules/mountlist (Makefile.am): Likewise.
2293         * modules/nanosleep (Makefile.am): Likewise.
2294         * modules/openat (Makefile.am): Likewise.
2295         * modules/pagealign_alloc (Makefile.am): Likewise.
2296         * modules/physmem (Makefile.am): Likewise.
2297         * modules/poll (Makefile.am): Likewise.
2298         * modules/posixtm (Makefile.am): Likewise.
2299         * modules/posixver (Makefile.am): Likewise.
2300         * modules/putenv (Makefile.am): Likewise.
2301         * modules/quote (Makefile.am): Likewise.
2302         * modules/quotearg (Makefile.am): Likewise.
2303         * modules/raise (Makefile.am): Likewise.
2304         * modules/read-file (Makefile.am): Likewise.
2305         * modules/readline (Makefile.am): Likewise.
2306         * modules/readlink (Makefile.am): Likewise.
2307         * modules/readtokens (Makefile.am): Likewise.
2308         * modules/readutmp (Makefile.am): Likewise.
2309         * modules/realloc (Makefile.am): Likewise.
2310         * modules/regex (Makefile.am): Likewise.
2311         * modules/rename (Makefile.am): Likewise.
2312         * modules/rename-dest-slash (Makefile.am): Likewise.
2313         * modules/rijndael (Makefile.am): Likewise.
2314         * modules/rmdir (Makefile.am): Likewise.
2315         * modules/rpmatch (Makefile.am): Likewise.
2316         * modules/safe-read (Makefile.am): Likewise.
2317         * modules/safe-write (Makefile.am): Likewise.
2318         * modules/same (Makefile.am): Likewise.
2319         * modules/save-cwd (Makefile.am): Likewise.
2320         * modules/savedir (Makefile.am): Likewise.
2321         * modules/setenv (Makefile.am): Likewise.
2322         * modules/settime (Makefile.am): Likewise.
2323         * modules/sha1 (Makefile.am): Likewise.
2324         * modules/sig2str (Makefile.am): Likewise.
2325         * modules/snprintf (Makefile.am): Likewise.
2326         * modules/stdlib-safer (Makefile.am): Likewise.
2327         * modules/stpcpy (Makefile.am): Likewise.
2328         * modules/stpncpy (Makefile.am): Likewise.
2329         * modules/strcase (Makefile.am): Likewise.
2330         * modules/strcasestr (Makefile.am): Likewise.
2331         * modules/strchrnul (Makefile.am): Likewise.
2332         * modules/strcspn (Makefile.am): Likewise.
2333         * modules/strdup (Makefile.am): Likewise.
2334         * modules/strerror (Makefile.am): Likewise.
2335         * modules/strftime (Makefile.am): Likewise.
2336         * modules/strndup (Makefile.am): Likewise.
2337         * modules/strnlen (Makefile.am): Likewise.
2338         * modules/strpbrk (Makefile.am): Likewise.
2339         * modules/strsep (Makefile.am): Likewise.
2340         * modules/strstr (Makefile.am): Likewise.
2341         * modules/strtod (Makefile.am): Likewise.
2342         * modules/strtoimax (Makefile.am): Likewise.
2343         * modules/strtok_r (Makefile.am): Likewise.
2344         * modules/strtol (Makefile.am): Likewise.
2345         * modules/strtoll (Makefile.am): Likewise.
2346         * modules/strtoul (Makefile.am): Likewise.
2347         * modules/strtoull (Makefile.am): Likewise.
2348         * modules/strtoumax (Makefile.am): Likewise.
2349         * modules/strverscmp (Makefile.am): Likewise.
2350         * modules/time_r (Makefile.am): Likewise.
2351         * modules/timegm (Makefile.am): Likewise.
2352         * modules/tmpfile-safer (Makefile.am): Likewise.
2353         * modules/unistd-safer (Makefile.am): Likewise.
2354         * modules/unlinkdir (Makefile.am): Likewise.
2355         * modules/userspec (Makefile.am): Likewise.
2356         * modules/utime (Makefile.am): Likewise.
2357         * modules/utimecmp (Makefile.am): Likewise.
2358         * modules/utimens (Makefile.am): Likewise.
2359         * modules/vasnprintf (Makefile.am): Likewise.
2360         * modules/vasprintf (Makefile.am): Likewise.
2361         * modules/vsnprintf (Makefile.am): Likewise.
2362         * modules/xalloc (Makefile.am): Likewise.
2363         * modules/xgetcwd (Makefile.am): Likewise.
2364         * modules/xnanosleep (Makefile.am): Likewise.
2365         * modules/xreadlink (Makefile.am): Likewise.
2366         * modules/xstrtod (Makefile.am): Likewise.
2367         * modules/xstrtol (Makefile.am): Likewise.
2368         * modules/xstrtold (Makefile.am): Likewise.
2369         * modules/yesno (Makefile.am): Likewise.
2370
2371 2006-10-12  Jim Meyering  <jim@meyering.net>
2372
2373         * m4/getloadavg.m4: Revert the change below.
2374
2375         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
2376         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
2377         fail with a symlink, which is what coreutils' ./bootstrap now
2378         creates by default.
2379
2380 2006-10-12  Bruno Haible  <bruno@clisp.org>
2381
2382         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
2383         mingw.
2384         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
2385         MSVC and mingw explicitly.
2386
2387 2006-10-11  Simon Josefsson  <jas@extundo.com>
2388             Bruno Haible  <bruno@clisp.org>
2389
2390         Add support for multiple gnulib-tool invocations in the scope of a
2391         single configure.ac file.
2392         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
2393         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
2394         with the same contents as the _LIBADD variable.
2395         (func_emit_initmacro_start, func_emit_initmacro_end,
2396         func_emit_initmacro_done): New functions.
2397         (func_import, func_create_testdir): Invoke them. Allow the identifiers
2398         gl_LIBOBJS and gl_LTLIBOBJS.
2399
2400 2006-10-11  Bruno Haible  <bruno@clisp.org>
2401
2402         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
2403         (func_create_testdir): Don't create po/Makefile.am, don't invoke
2404         autoreconf. Instead, invoke autopoint explicitly but move back the
2405         *.m4 files from gnulib.
2406
2407 2006-10-11  Bruno Haible  <bruno@clisp.org>
2408
2409         * gnulib-tool (func_usage): Make module names after --create-testdir
2410         optional.
2411         (func_create_testdir): If no module was specified, use nearly all
2412         modules.
2413
2414 2006-10-12  Jim Meyering  <jim@meyering.net>
2415
2416         Big performance improvement for fts-based tools that use FTS_NOSTAT.
2417         Avoid spurious inode-mismatch problems on non-POSIX file systems.
2418         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
2419         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
2420         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
2421         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
2422         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
2423         (fts_set_stat_required): New function.
2424         (fts_open): Defer the calls to fts_stat, if possible or requested.
2425         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
2426         into fts_stat itself.
2427         (fts_read): Perform any required (deferred) fts_stat call.
2428         (fts_build): Likewise, for the directory we're about to open and read.
2429         In the readdir loop, carefully decide whether each entry will require
2430         an eventual call to fts_stat, using dirent.d_type info if available.
2431         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
2432         a command line argument into this function.  Update all callers.
2433         Map a return value of FTS_DOT to FTS_D for a command line argument.
2434         * modules/fts (Depends-on): Add d-type.  Alphabetize.
2435         Thanks to Miklos Szeredi for his tenacity and for the initial
2436         bug report about "find" failing on a FUSE-based file system.
2437
2438         * lib/fts.c (fts_open): Use consistent indentation.
2439
2440 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2441
2442         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
2443         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
2444         reported by Jim Meyering.  All uses of cache variables renamed
2445         to match Autoconf's.
2446         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
2447         the other one.
2448
2449         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
2450         Fix misspelling in diagnostic.
2451
2452 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2453
2454         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
2455         defined.  Problem reported by Matthew Woehlke.
2456
2457         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
2458         Add support for Tandem NonStop R series.
2459         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
2460         Use new macro.
2461
2462         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
2463         (has_trailing_slash): Omit size arg; all callers changed.
2464         Omit 'inline', since it doesn't help performance and we'd
2465         need to configure it.
2466         Don't count //, ///, etc. as having a trailing slash.
2467         As a side effect, this removes a C99ism reported by Matthew Woehlke.
2468         (rpl_rename_dest_slash): On failure, use rename's errno rather
2469         than (in some cases) an incorrect or junk errno.
2470         Simplify code by removing need to compute length; this does
2471         cause it to make two passes instead of one over the file name,
2472         but it's worth it.
2473
2474         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
2475         change, since Autoconf's version may no longer be appropriate now
2476         that we are using CVS Autoconf's version.  Add support for Tandem.
2477
2478 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2479             Bruno Haible  <bruno@clisp.org>
2480
2481         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
2482         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
2483         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
2484         gl_AC_TYPE_LONG_LONG.
2485
2486         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
2487         instead of HAVE_LONG_LONG.
2488         * lib/printf-args.c (printf_fetchargs): Likewise.
2489         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
2490         * lib/vasnprintf.c (VASNPRINTF): Likewise.
2491         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
2492         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
2493         gl_AC_TYPE_LONG_LONG.
2494
2495 2006-10-11  Bruno Haible  <bruno@clisp.org>
2496
2497         * m4/longlong.m4: Add comments.
2498         * m4/ulonglong.m4: Likewise.
2499
2500 2006-10-10  Bruno Haible  <bruno@clisp.org>
2501
2502         Make it possible to #define stpcpy, strdup to aliases.
2503         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
2504         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
2505
2506 2006-10-10  Bruno Haible  <bruno@clisp.org>
2507
2508         Make it possible to #define gcd to an alias.
2509         * lib/gcd.c: Include config.h.
2510
2511 2006-10-10  Bruno Haible  <bruno@clisp.org>
2512
2513         Make it possible to #define c_isascii to an alias.
2514         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
2515         defined. Undefine the macros before defining them, to avoid gcc
2516         warnings.
2517         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
2518         define NO_C_CTYPE_MACROS early.
2519
2520 2006-10-10  Bruno Haible  <bruno@clisp.org>
2521
2522         Make it possible to #define set_program_name to an alias.
2523         * lib/progname.c: Don't undefine set_program_name; instead, undefine
2524         ENABLE_RELOCATABLE early.
2525
2526 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
2527
2528         Port to Tandem NSK OSS, which has 64-bit signed int but at most
2529         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
2530         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
2531         More generally, don't assume that 64-bit signed int is available
2532         if unsigned int is, and vice versa.
2533         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
2534         unsigned symbols, not on their signed counterparts.
2535         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
2536         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
2537         (UINT64_C, UINTMAX_C):
2538         Likewise.
2539         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
2540         unsigned counterparts.
2541         (Have_long_long, Unsigned): New macros.
2542         (Int): Renamed from INT.
2543         (strtoimax): Use the new macros.
2544         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
2545         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
2546         * modules/inttypes (inttypes.h): Substitute
2547         HAVE_UNSIGNED_LONG_LONG_INT.
2548         * modules/stdint (stdint.h): Likewise.
2549         (Files): Add m4/ulonglong.m4.
2550
2551 2006-10-10  Bruno Haible  <bruno@clisp.org>
2552
2553         Fix a gcc -Wshadow warning.
2554         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
2555         to 'bucket'.
2556         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
2557         gl_linked_indexof_from_to): Likewise.
2558         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
2559         Likewise.
2560         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
2561         Likewise.
2562         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
2563         Reported by Eric Blake.
2564
2565 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2566
2567         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
2568         for NetBSD.  Problem reported by Bruno Haible.
2569
2570 2006-10-09  Jim Meyering  <jim@meyering.net>
2571
2572         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
2573         Patch from Bruno Haible.
2574
2575 2006-10-09  Jim Meyering  <jim@meyering.net>
2576
2577         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
2578         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
2579         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
2580
2581 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
2582
2583         Don't include <config.h> twice; this doesn't work in some cases,
2584         e.g., when config.h has "#define intmax_t long long int" and
2585         we include <config.h>, <inttypes.h>, <config.h> in that order.
2586         Problem reported by Matthew Woehlke in:
2587         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
2588         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
2589         * lib/fts-cycle.c: Don't include config.h.
2590         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
2591         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
2592         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
2593         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
2594         inttypes.h.
2595         * lib/xstrtoumax.c: Likewise.
2596         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
2597         __strtol and the like, so that this module is more like its siblings.
2598         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
2599         Remove; no longer needed now that we assume gnulib inttypes.h.
2600
2601 2006-10-08  Bruno Haible  <bruno@clisp.org>
2602
2603         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
2604         option.
2605
2606 2006-10-07  Jim Meyering  <jim@meyering.net>
2607
2608         * modules/inttypes (inttypes.h): Revert what seems to have been
2609         an inadvertent part of today's change: use "|", not "/" in the
2610         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
2611
2612 2006-10-07  Bruno Haible  <bruno@clisp.org>
2613
2614         * modules/sublist: New file.
2615
2616 2006-10-07  Bruno Haible  <bruno@clisp.org>
2617
2618         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
2619         * modules/argz (argz.h): Likewise.
2620         * modules/arpa_inet (arpa/inet.h): Likewise.
2621         * modules/byteswap (byteswap.h): Likewise.
2622         * modules/configmake (configmake.h): Likewise.
2623         * modules/fcntl (fcntl.h): Likewise.
2624         * modules/fnmatch (fnmatch.h): Likewise.
2625         * modules/getopt (getopt.h): Likewise.
2626         * modules/glob (glob.h): Likewise.
2627         * modules/inttypes (inttypes.h): Likewise.
2628         * modules/netinet_in (netinet/in.h): Likewise.
2629         * modules/poll (poll.h): Likewise.
2630         * modules/stdbool (stdbool.h): Likewise.
2631         * modules/stdint (stdint.h): Likewise.
2632         * modules/sys_select (sys/select.h): Likewise.
2633         * modules/sys_socket (sys/socket.h): Likewise.
2634         * modules/sys_stat (sys/stat.h): Likewise.
2635         * modules/sysexits (sysexits.h): Likewise.
2636         * modules/unistd (unistd.h): Likewise.
2637         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2638         Add a "DO NOT EDIT" comment to the generated file.
2639         (func_import): Likewise for gnulib-comp.m4.
2640
2641 2006-10-07  Bruno Haible  <bruno@clisp.org>
2642
2643         * lib/gl_sublist.h: New file.
2644         * lib/gl_sublist.c: New file.
2645
2646 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
2647
2648         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
2649         name (relative to the original working directory) and the file
2650         name component (relative to the temporary working directory).  All
2651         callers changed.
2652         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
2653         * lib/mkdir-p.c (make_dir_parents): Likewise.
2654         * lib/mkdir-p.h (make_dir_parents): Likewise.
2655
2656 2006-10-06  Eric Blake  <ebb9@byu.net>
2657
2658         Define several macros for use by the clean-temp module.
2659         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
2660         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
2661         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
2662
2663         * lib/clean-temp.h (close_stream_temp): New declaration.
2664         * lib/clean-temp.c (includes): Pull in headers according to what
2665         other modules are in use.
2666         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
2667
2668 2006-10-06  Bruno Haible  <bruno@clisp.org>
2669
2670         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
2671         instead of fopen, fwriteerror.
2672
2673 2006-10-06  Bruno Haible  <bruno@clisp.org>
2674
2675         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
2676         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
2677         int.
2678         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
2679         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
2680         Return an error indicator.
2681         Suggested by Eric Blake.
2682
2683 2006-10-06  Bruno Haible  <bruno@clisp.org>
2684
2685         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
2686         Reported by Eric Blake.
2687
2688 2006-10-06  Bruno Haible  <bruno@clisp.org>
2689
2690         * modules/closeout (Description): Mention stderr too.
2691
2692 2006-10-06  Bruno Haible  <bruno@clisp.org>
2693         and Paul Eggert  <eggert@cs.ucla.edu>
2694
2695         * lib/closeout.c (close_stdout): Also close stderr.
2696         * lib/closeout.h: Update comment.
2697
2698 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
2699
2700         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
2701         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
2702         * lib/dirchownmod.c: Include lchown.h.
2703         * lib/lchown.c: Don't include files that lchown.h now includes.
2704         Don't declare chown, since lchown.h now does that.
2705         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
2706         (lchown): Define to rpl_chown if lchown is declared but
2707         does not exist.  Declare using a prototype if lchown is not
2708         declared.  Add a copyright notice.
2709         * lib/mkstemp.h: Include <unistd.h>.
2710         * lib/openat.c: Include lchown.h.
2711
2712         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
2713         we now test for that separately.
2714         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
2715         rather than O_NOFOLLOW, when testing whether it's possible to
2716         avoid a race condition reliably.
2717         * lib/savewd.c (savewd_chdir): Likewise.
2718
2719         Remove macros that are no longer needed now that stdint.h is
2720         reliable.
2721         * lib/fsusage.c (UINTMAX_MAX): Remove.
2722         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
2723         * lib/utimecmp.c (SIZE_MAX): Remove.
2724
2725         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
2726
2727         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
2728         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
2729         O_NOATIME works.
2730
2731 2006-10-05  Bruno Haible  <bruno@clisp.org>
2732
2733         * lib/gl_list.h (gl_sortedlist_search_from_to,
2734         gl_sortedlist_indexof_from_to): New declarations.
2735         (gl_list_implementation): New fields sortedlist_search_from_to,
2736         sortedlist_indexof_from_to.
2737         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
2738         inline functions.
2739         * lib/gl_list.c (gl_sortedlist_search_from_to,
2740         gl_sortedlist_indexof_from_to): New functions.
2741         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
2742         function.
2743         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
2744         (gl_array_sortedlist_search_from_to): New function.
2745         (gl_array_list_implementation): Update.
2746         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
2747         function.
2748         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
2749         (gl_carray_sortedlist_search_from_to): New function.
2750         (gl_carray_list_implementation): Update.
2751         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
2752         gl_linked_sortedlist_indexof_from_to): New functions.
2753         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2754         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2755         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
2756         gl_tree_sortedlist_indexof_from_to): New functions.
2757         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2758         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2759         Update.
2760         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2761         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
2762         Update.
2763
2764 2006-10-05  Bruno Haible  <bruno@clisp.org>
2765
2766         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
2767         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
2768         (struct gl_list_implementation): Add fields search_from_to,
2769         indexof_from_to. Remove fields search, indexof.
2770         (gl_list_search): Use the search_from_to method.
2771         (gl_list_search_from, gl_list_search_from_to): New functions.
2772         (gl_list_indexof): Use the indexof_from_to method.
2773         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2774         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
2775         (gl_list_search_from, gl_list_search_from_to): New functions.
2776         (gl_list_indexof): Use the indexof_from_to method.
2777         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
2778         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
2779         gl_array_indexof. Add start_index, end_index arguments.
2780         (gl_array_search_from_to): Renamed from gl_array_search. Add
2781         start_index, end_index arguments.
2782         (gl_array_remove, gl_array_list_implementation): Update.
2783         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
2784         gl_carray_indexof. Add start_index, end_index arguments.
2785         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
2786         start_index, end_index arguments.
2787         (gl_carray_remove, gl_carray_list_implementation): Update.
2788         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
2789         gl_linked_search. Add start_index, end_index arguments.
2790         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
2791         start_index, end_index arguments.
2792         (gl_linked_remove): Update.
2793         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
2794         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
2795         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
2796         field to 'size_t'.
2797         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
2798         gl_tree_search. Add start_index, end_index arguments.
2799         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2800         start_index, end_index arguments.
2801         (gl_tree_remove): Update.
2802         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
2803         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
2804         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
2805         function.
2806         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
2807         gl_tree_search. Add start_index, end_index arguments.
2808         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
2809         start_index, end_index arguments.
2810         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
2811         Update.
2812         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
2813
2814 2006-10-05  Bruno Haible  <bruno@clisp.org>
2815
2816         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
2817
2818         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
2819         fwriteerror_temp): New declarations.
2820         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
2821         (descriptors): New variable.
2822         (cleanup): First, close the descriptors.
2823         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
2824         fclose_temp, fwriteerror_temp): New functions.
2825
2826 2006-10-04  Jim Meyering  <jim@meyering.net>
2827
2828         * lib/fts.c (fts_open): Tiny comment change.
2829
2830 2006-10-04  Bruno Haible  <bruno@clisp.org>
2831
2832         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
2833         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
2834         gl_LOCK_BODY.
2835         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
2836         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
2837         gl_LOCK_EARLY_BODY.
2838         (gl_LOCK): Require gl_LOCK_BODY.
2839
2840 2006-10-04  Bruno Haible  <bruno@clisp.org>
2841
2842         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
2843         (gl_oset_search_atleast): New declaration.
2844         (struct gl_oset_implementation): Add field 'search_atleast'.
2845         (gl_oset_search_atleast): New inline function.
2846         * lib/gl_oset.c (gl_oset_search_atleast): New function.
2847         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
2848         (gl_array_oset_implementation): Update.
2849         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
2850         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
2851         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
2852
2853 2006-10-04  Bruno Haible  <bruno@clisp.org>
2854
2855         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
2856
2857 2006-10-03  Bruno Haible  <bruno@clisp.org>
2858
2859         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
2860         from gl_avltreehash_list_implementation.
2861
2862 2006-10-03  Bruno Haible  <bruno@clisp.org>
2863
2864         * lib/gl_oset.c (gl_oset_add): Fix return type.
2865
2866 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
2867
2868         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
2869
2870 2006-10-02  Eric Blake  <ebb9@byu.net>
2871
2872         * modules/strnlen (Depends-on): Add extensions.
2873
2874 2006-10-02  Eric Blake  <ebb9@byu.net>
2875
2876         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
2877         definition in 2.60+.
2878
2879 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
2880
2881         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
2882         checks.
2883
2884 2006-10-02  Bruno Haible  <bruno@clisp.org>
2885
2886         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
2887         to the AUTOMAKE_OPTIONS.
2888         Reported by Jim Meyering.
2889
2890 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
2891
2892         Work around bug in Solaris 10 /proc file system:
2893         /proc/self/fd/NNN/.. isn't the parent directory of
2894         the directory whose file descriptor is NNN.  This needs to
2895         be worked around at run time, not compile time, since a
2896         program might be built on Solaris 8, where things work, and
2897         run on Solaris 10.
2898         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
2899         to use the following interface instead:
2900         (OPENAT_BUFFER_SIZE): New macro.
2901         (openat_proc_name): New function.
2902         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
2903         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
2904         Likewise.
2905         * lib/openat-proc.c: New file.
2906         * modules/openat (Files): Add lib/openat-proc.c.
2907         (Depends-on): Add same-inode, stdbool.
2908         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
2909
2910 2006-09-29  Bruno Haible  <bruno@clisp.org>
2911
2912         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
2913         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
2914         argument. Set stdout_closed before testing for ferror, not after.
2915         (fwriteerror, fwriteerror_no_ebadf): New functions.
2916
2917 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2918
2919         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
2920
2921 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
2922
2923         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
2924         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
2925
2926 2006-09-28  Jim Meyering  <jim@meyering.net>
2927
2928         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
2929         Include <unistd.h>.
2930
2931 2006-09-28  Bruno Haible  <bruno@clisp.org>
2932
2933         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
2934         * modules/linkedhash-list (Depends-on): Likewise.
2935         * modules/rbtreehash-list (Depends-on): Likewise.
2936
2937 2006-09-28  Bruno Haible  <bruno@clisp.org>
2938
2939         * lib/strndup.h: Simplify the redefinition of strndup.
2940         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
2941         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
2942
2943 2006-09-28  Bruno Haible  <bruno@clisp.org>
2944
2945         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
2946         * lib/gl_linkedhash_list.c: Likewise.
2947         * lib/gl_rbtreehash_list.c: Likewise.
2948
2949 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
2950
2951         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
2952         getaddrinfo.
2953
2954         * lib/__fpending.h: Don't include <stdio_ext.h> unless
2955         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
2956         it causes <stdio_ext.h> to cause a compile-time error.
2957         Problem reported by Nelson H. F. Beebe.
2958         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
2959         of HAVE_DECL___PENDING.
2960
2961         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
2962         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
2963         declaration.
2964
2965 2006-09-27  Jim Meyering  <jim@meyering.net>
2966
2967         This file could end up with a definition for a function
2968         named __strndup, rather than rpl_strndup on a system with
2969         incomplete weak_alias support.
2970         * lib/strndup.c (strndup): Rename from __strndup.
2971         Remove #defines that used to map __strndup to strndup.
2972         Don't use K&R prototypes.
2973         Remove LIBC-related code, since this file is not sync'd with glibc.
2974         * lib/strndup.h: Revamp, accordingly.
2975         * m4/strndup.m4: Modernize.
2976
2977 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
2978
2979         * modules/savewd (Depends-on): Add 'raise'.
2980         * lib/savewd.c: Include <signal.h>, for 'raise'.
2981
2982 2006-09-26  Jim Meyering  <jim@meyering.net>
2983
2984         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
2985         when we detect Darwin 8.7.0's acl_get_file bug.
2986         Rearrange to perform the new (below) run-test while $LIBS
2987         contains any acl-related library.  Set USE_ACL at the end.
2988         (gl_ACL_GET_FILE): New function.
2989
2990 2006-09-26  Eric Blake  <ebb9@byu.net>
2991
2992         * lib/verror.c: Include <config.h> unconditionally.
2993
2994 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
2995
2996         * modules/clock-time (Maintainer): Add self.
2997         * modules/getlogin_r (Depends-on): Add extensions.
2998
2999 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3000
3001         * modules/clock-time: New module.
3002         * modules/nanosleep (Depends-on): Add clock-time.
3003         * modules/gethrxtime (Depends-on): Likewise.
3004         * modules/gettime (Depends-on): Likewise.
3005         * modules/settime (Depends-on): Likewise.
3006
3007         * modules/fts-lgpl: Depend on openat.
3008         * modules/mkancesdirs: Depend on savewd.
3009         * modules/mkdir-p: Likewise.
3010
3011 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3012
3013         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
3014
3015         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
3016         `gl_have_arbitrary_file_name_length_limit' to
3017         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
3018         actually works between configure runs.
3019
3020 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3021             Bruno Haible  <bruno@clisp.org>
3022
3023         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
3024
3025 2006-09-25  Jim Meyering  <jim@meyering.net>
3026
3027         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
3028         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
3029
3030 2006-09-25  Eric Blake  <ebb9@byu.net>
3031
3032         * gnulib-tool (func_import, func_create_testdir): Fix typos in
3033         exec's in 2006-09-18 patch when shuffling fds.
3034
3035 2006-09-25  Bruno Haible  <bruno@clisp.org>
3036
3037         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
3038         Reported by Jim Meyering.
3039
3040 2006-09-24  Jim Meyering  <jim@meyering.net>
3041
3042         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
3043         compare a pointer against a literal "0".  That caused failures with
3044         at least HP-UX's hpcc.
3045
3046 2006-09-22  Simon Josefsson  <jas@extundo.com>
3047
3048         * modules/gc-sha1:
3049         * modules/gc-md4:
3050         * modules/gc-hmac-sha1:
3051         * modules/gc-hmac-md5:
3052         * modules/gc-des:
3053         * modules/gc-arcfour: Distribute more files.
3054
3055 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3056
3057         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
3058         (gl_linked_iterator_from_to): Initialize struct completely.
3059         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
3060         (gl_tree_iterator_from_to): Likewise
3061         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
3062         * lib/gl_array_list.c [lint] (gl_array_iterator)
3063         (gl_array_iterator_from_to): Likewise.
3064         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
3065         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
3066         (gl_carray_iterator_from_to): Likewise.
3067
3068         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
3069         * lib/md4.c (md4_process_block): Remove unused variable.
3070         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
3071         parentheses for clarity.
3072
3073 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3074
3075         * modules/bison-i18n (Depends-on): Add gettext.
3076
3077 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3078
3079         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
3080         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
3081         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
3082         also add missing comma that caused broken test.
3083         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
3084         stdlib.h, for `abort'.
3085         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
3086         variables.
3087         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
3088         include unistd.h if present, for `rmdir'.
3089         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
3090         variables.
3091         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
3092         in the process include standard headers for prototypes.
3093         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
3094         gets declared on GNU/Linux.
3095         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
3096         unistd.h, for `rmdir'.
3097         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
3098
3099         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
3100         always true.
3101         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
3102
3103         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
3104
3105 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3106
3107         * gnulib-tool (func_version): Create output all at once.  This
3108         may help avoid triggering unnecessary SIGPIPEs, and at any
3109         rate it doesn't hurt.
3110
3111 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3112             Bruno Haible  <bruno@clisp.org>
3113
3114         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
3115         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
3116         * m4/signed.m4 (bh_C_SIGNED): Likewise.
3117
3118         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
3119         (gl_FUNC_VASPRINTF): Invoke it.
3120
3121 2006-09-22  Bruno Haible  <bruno@clisp.org>
3122
3123         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
3124         getloadavg.c as first argument.
3125
3126 2006-09-22  Bruno Haible  <bruno@clisp.org>
3127
3128         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
3129         at the beginning of the gl_INIT macro.
3130         * modules/getloadavg (configure.ac): Pass $gl_source_base to
3131         gl_GETLOADAVG.
3132
3133 2006-09-22  Bruno Haible  <bruno@clisp.org>
3134
3135         * gnulib-tool (func_create_megatestdir): Don't include the config-h
3136         module.
3137         Suggested by Ralf Wildenhues.
3138
3139 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
3140
3141         Import this patch from libc:
3142
3143         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
3144
3145         * lib/regex_internal.c (re_string_reconstruct): Handle
3146         offset < pstr->valid_raw_len && pstr->offsets_needed case.
3147         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
3148         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
3149         re_string_context_at.
3150
3151         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
3152         now requires it.
3153         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
3154         gl_REGEX now does it for us.
3155         (gl_REGEX): Add test taken from
3156         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
3157
3158         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
3159         Check that large offsets work.  Modernize Autoconf usages.
3160         Prefer "yes" to mean a good thing rather than a bad.
3161         Don't put "#define mkstemp" in config.h, as this might interfere
3162         with standard system headers that "#define mkstemp mkstemp64".
3163
3164         * modules/mkstemp (Depends-on): Add extensions, so that
3165         mkstemp is visible on some platforms.
3166         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
3167         (Include): Change to "mkstemp.h" from <stdlib.h>.
3168         (Files): Add mkstemp.h.
3169
3170         * lib/mkstemp.h: New file, since some standard headers
3171         #define mkstemp.
3172         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
3173         Include "mkstemp.h".
3174         Make the _LIBC code resemble glibc original more,
3175         e.g., use K&R style.
3176         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
3177         (mkstemp): Remove, since mkstemp.h does this for us.
3178         * lib/stdlib--.h: Include mkstemp.h.
3179
3180         Import this patch from libc:
3181
3182         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3183
3184         * lib/tempname.c (__gen_tempname): Change attempts_min
3185         into a macro.  Use preprocessor to decide how to initialize
3186         attempts [Coverity CID 67].
3187
3188 2006-09-20  Bruno Haible  <bruno@clisp.org>
3189
3190         * lib/mkdtemp.c: Import from libc.
3191         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3192                 * sysdeps/posix/tempname.c (__gen_tempname): Change
3193                 attempts_min into a macro.  Use preprocessor to decide how to
3194                 initialize attempts [Coverity CID 67].
3195         2001-11-27  Paul Eggert  <eggert@twinsun.com>
3196                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
3197                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
3198
3199 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3200
3201         * gnulib-tool (func_exit): New function, to allow to pass the
3202         exit status portably through the trap.  Use everywhere.
3203         (--help, --version): Signal a write error.
3204         (trap): catch SIGPIPE, for write errors.
3205         Exit at the end of the trap, with the correct exit status.
3206
3207 2006-09-19  Karl Berry  <karl@gnu.org>
3208
3209         * doc/gnulib.texi: note about the license texinfo files.
3210
3211 2006-09-19  Eric Blake  <ebb9@byu.net>
3212
3213         * gnulib-tool: Avoid space-tab.
3214
3215 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3216
3217         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
3218         that prevented coreutils 6.1 from building.  Problem reported
3219         by Petter Reinholdtsen.
3220
3221 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3222
3223         * gnulib-tool (avoidlist): Fix typo that broke options like
3224         --avoid=lock that are used by coreutils bootstrap.
3225
3226 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
3227
3228         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
3229         more systematically.
3230
3231 2006-09-18  Jim Meyering  <jim@meyering.net>
3232
3233         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
3234
3235 2006-09-18  Bruno Haible  <bruno@clisp.org>
3236
3237         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
3238
3239 2006-09-18  Bruno Haible  <bruno@clisp.org>
3240
3241         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
3242         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
3243         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
3244         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
3245         * m4/gettext.m4: Require autoconf >= 2.52.
3246         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
3247         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
3248         of gl_cv_header_inttypes_h.
3249
3250 2006-09-18  Bruno Haible  <bruno@clisp.org>
3251
3252         * lib/javaversion.c: Include configmake.h.
3253
3254 2006-09-18  Bruno Haible  <bruno@clisp.org>
3255
3256         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
3257         avoid that the while loops be executed in a subshell.
3258
3259 2006-09-18  Bruno Haible  <bruno@clisp.org>
3260
3261         * MODULES.html.sh (func_module): Break long lines.
3262         Suggested by Bruce Korb <bkorb@gnu.org>.
3263
3264 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3265
3266         Speed up by a factor of 1.12.
3267         * gnulib-tool (nl): New variable.
3268         (func_import): Rewrite include directive extraction to only read each
3269         directive once.
3270
3271 2006-09-17  Bruno Haible  <bruno@clisp.org>
3272
3273         * modules/javaversion (Makefile.am): Remove DEFS setting.
3274         (Depends-on): Add configmake, for PKGDATADIR definition.
3275
3276 2006-09-17  Bruno Haible  <bruno@clisp.org>
3277
3278         * gnulib-tool (func_create_testdir): Rewrite all files at once.
3279
3280 2006-09-17  Bruno Haible  <bruno@clisp.org>
3281
3282         * gnulib-tool (func_append): New function, stolen from libtool.m4.
3283         (func_modules_transitive_closure, func_modules_add_dummy,
3284         func_modules_to_filelist, func_import, func_create_testdir,
3285         func_create_megatestdir, ...): Use it wherever possible.
3286         Suggested by Ralf Wildenhues.
3287
3288 2006-09-16  Karl Berry  <karl@gnu.org>
3289
3290         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
3291         to avoid sectioning errors.
3292         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
3293         [ifinfo]: blank line after @center-ed titles.
3294         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
3295         Spell FSF address consistently with others.
3296         (These changes approved by rms.)
3297
3298 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3299
3300         Speed up by a factor of 1.61.
3301         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
3302         already checked module names again.
3303
3304 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3305
3306         Speed up by a factor of 1.13.
3307         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
3308         for new_files, and the input to func_add_or_update.
3309
3310 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3311
3312         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
3313         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
3314
3315 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3316
3317         * modules/mkancesdirs (Depends-on): Add fcntl.
3318         * modules/savewd: New file.
3319         * MODULES.html.sh (File system functions): Add savewd.
3320
3321         * modules/configmake (Makefile.am): Add support for the
3322         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
3323
3324 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3325
3326         * m4/savewd.m4: New file.
3327
3328 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3329
3330         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
3331         (dirchownmod): New arg FD.  All callers changed.
3332         Use FD rather than opening the directory ourself, as opening is
3333         now the caller's responsibility.
3334         * lib/dirchownmod.h: Likewise.
3335         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
3336         hosts that require <sys/types.h> before <sys/stat.h>.  Include
3337         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
3338         (test_dir): Remove.
3339         (mkancesdirs): Return length of prefix of FILE that has already
3340         been made, or -2 if there is a child doing the work.  Redo
3341         algorithm so that it is O(N) rather than O(N**2).  Optimize away
3342         ".", and treat ".." specially since it might stray back into
3343         already-created areas.  Use a subprocess if necessary.  New arg
3344         WD; all users changed.  MAKE_DIR function should now return 1
3345         if it creates a directory that is not readable.  Return -2 if
3346         a child process is spun off.
3347         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
3348         Adjust signature to match code.
3349         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
3350         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
3351         all users changed.
3352         * lib/savewd.c, lib/savewd.h: New files.
3353
3354 2006-09-15  Jim Meyering  <jim@meyering.net>
3355
3356         * modules/rename-dest-slash: New module.
3357         * MODULES.html.sh (posix_compat): Add it here.
3358
3359         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
3360
3361 2006-09-15  Jim Meyering  <jim@meyering.net>
3362
3363         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
3364         file.
3365
3366         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
3367
3368 2006-09-15  Jim Meyering  <jim@meyering.net>
3369
3370         * lib/rename-dest-slash.c (has_trailing_slash): Use
3371         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
3372         (rpl_rename_dest_slash): Perform the cheaper trailing slash
3373         test before testing whether SRC is a directory.
3374         Suggestions from Bruno Haible.
3375
3376         Avoid a warning about an unused variable.
3377         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
3378         into the #ifdef block where it's used.
3379
3380         * lib/rename-dest-slash.c: New file.
3381
3382 2006-09-14  Bruno Haible  <bruno@clisp.org>
3383
3384         * lib/allocsa.c: Include <config.h> unconditionally.
3385         * lib/asnprintf.c: Likewise.
3386         * lib/asprintf.c: Likewise.
3387         * lib/c-strcasecmp.c: Likewise.
3388         * lib/c-strcasestr.c: Likewise.
3389         * lib/c-strncasecmp.c: Likewise.
3390         * lib/c-strstr.c: Likewise.
3391         * lib/classpath.c: Likewise.
3392         * lib/clean-temp.c: Likewise.
3393         * lib/concatpath.c: Likewise.
3394         * lib/copy-file.c: Likewise.
3395         * lib/csharpcomp.c: Likewise.
3396         * lib/csharpexec.c: Likewise.
3397         * lib/execute.c: Likewise.
3398         * lib/fatal-signal.c: Likewise.
3399         * lib/findprog.c: Likewise.
3400         * lib/fwriteerror.c: Likewise.
3401         * lib/gl_array_list.c: Likewise.
3402         * lib/gl_array_oset.c: Likewise.
3403         * lib/gl_avltree_list.c: Likewise.
3404         * lib/gl_avltree_oset.c: Likewise.
3405         * lib/gl_avltreehash_list.c: Likewise.
3406         * lib/gl_carray_list.c: Likewise.
3407         * lib/gl_linked_list.c: Likewise.
3408         * lib/gl_linkedhash_list.c: Likewise.
3409         * lib/gl_list.c: Likewise.
3410         * lib/gl_oset.c: Likewise.
3411         * lib/gl_rbtree_list.c: Likewise.
3412         * lib/gl_rbtree_oset.c: Likewise.
3413         * lib/gl_rbtreehash_list.c: Likewise.
3414         * lib/imaxabs.c: Likewise.
3415         * lib/imaxdiv.c: Likewise.
3416         * lib/javacomp.c: Likewise.
3417         * lib/javaexec.c: Likewise.
3418         * lib/javaversion.c: Likewise.
3419         * lib/linebreak.c: Likewise.
3420         * lib/localcharset.c: Likewise.
3421         * lib/lock.c: Likewise.
3422         * lib/mbchar.c: Likewise.
3423         * lib/mbswidth.c: Likewise.
3424         * lib/mkdtemp.c: Likewise.
3425         * lib/pipe.c: Likewise.
3426         * lib/printf-args.c: Likewise.
3427         * lib/printf-parse.c: Likewise.
3428         * lib/progname.c: Likewise.
3429         * lib/progreloc.c: Likewise.
3430         * lib/readlink.c: Likewise.
3431         * lib/sh-quote.c: Likewise.
3432         * lib/stpcpy.c: Likewise.
3433         * lib/stpncpy.c: Likewise.
3434         * lib/strcasecmp.c: Likewise.
3435         * lib/strcasestr.c: Likewise.
3436         * lib/strcspn.c: Likewise.
3437         * lib/striconv.c: Likewise.
3438         * lib/strncasecmp.c: Likewise.
3439         * lib/strnlen1.c: Likewise.
3440         * lib/strstr.c: Likewise.
3441         * lib/strtok_r.c: Likewise.
3442         * lib/tls.c: Likewise.
3443         * lib/tmpdir.c: Likewise.
3444         * lib/unicodeio.c: Likewise.
3445         * lib/unsetenv.c: Likewise.
3446         * lib/vasnprintf.c: Likewise.
3447         * lib/vasprintf.c: Likewise.
3448         * lib/wait-process.c: Likewise.
3449         * lib/xallocsa.c: Likewise.
3450         * lib/xsetenv.c: Likewise.
3451         * lib/xstriconv.c: Likewise.
3452
3453 2006-09-13  Simon Josefsson  <jas@extundo.com>
3454
3455         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
3456         that internally, suggested by Ralf Wildenhues
3457         <Ralf.Wildenhues@gmx.de>.
3458
3459 2006-09-13  Simon Josefsson  <jas@extundo.com>
3460
3461         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
3462         @LIBOBJS@.
3463         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3464
3465 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
3466
3467         * lib/_fpending.c: Include <config.h> unconditionally, since we no
3468         longer worry about uses that don't define HAVE_CONFIG_H.
3469         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
3470         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
3471         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
3472         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
3473         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
3474         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
3475         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
3476         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
3477         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
3478         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
3479         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
3480         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
3481         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
3482         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
3483         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
3484         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
3485         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
3486         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
3487         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
3488         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
3489         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
3490         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
3491         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
3492         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
3493         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
3494         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
3495         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
3496         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
3497         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
3498         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
3499         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
3500         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
3501         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
3502         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
3503         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
3504         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
3505         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
3506         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
3507         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
3508         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
3509         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
3510         Likewise.
3511
3512 2006-09-13  Eric Blake  <ebb9@byu.net>
3513
3514         * lib/getopt.c: Fix typo in last commit.
3515
3516 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
3517
3518         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
3519         dgettext.
3520
3521 2006-09-12  Jim Meyering  <jim@meyering.net>
3522
3523         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
3524         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
3525         Reported by Nelson H. F. Beebe.
3526
3527 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
3528
3529         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
3530         program_invocation_name and program_invocation_short_name are
3531         initialized.
3532         * lib/argp-namefrob.h: Move declarations of program_invocation_name
3533         and program_invocation_short_name to argp.h, so they are visible
3534         to user programs.
3535         * lib/argp.h: Likewise
3536
3537 2006-09-10  Bruno Haible  <bruno@clisp.org>
3538
3539         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
3540         m4/inttypes_h.m4, m4/uintmax_t.m4.
3541
3542 2006-09-10  Bruno Haible  <bruno@clisp.org>
3543
3544         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
3545         gl_AC_TYPE_UINTMAX_T.
3546
3547 2006-09-10  Bruno Haible  <bruno@clisp.org>
3548
3549         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
3550
3551 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
3552
3553         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
3554         convention.  Text proposed by Bruno Haible.
3555         (struct argp_option): Document the use of N_() wrappers.
3556
3557         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
3558         '\v', and translate the two parts separately, instead of feeding
3559         the whole string to gettext.  This allows to exclude
3560         '\v' from the strings visible to the translator by writing doc
3561         strings as N_("..") "\v" N_("..").
3562
3563 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
3564
3565         * config/srclist.txt: Undo latest change; the bug was fixed.
3566
3567 2006-09-09  Bruno Haible  <bruno@clisp.org>
3568
3569         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
3570         assignments if building a library without libtool.
3571         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
3572         in func_emit_lib_Makefile_am.
3573         (func_import): When building a static library libfoo.a, arrange to
3574         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
3575         (func_create_testdir): Likewise.
3576         * modules/gc (configure.ac, Makefile.am): If building statically,
3577         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
3578         * modules/iconvme (configure.ac, Makefile.am): Likewise.
3579         * modules/striconv (configure.ac, Makefile.am): Likewise.
3580         Based on a suggestion by Ralf Wildenhues.
3581
3582 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3583
3584         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
3585         Check for unistd.h too, since Autoconf doesn't assume POSIX.
3586         Also:
3587
3588         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3589         Add year_2050_test to catch glibc bug 2821
3590         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3591
3592         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
3593         Prefer #ifdef to #if.
3594
3595         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
3596         Return from 'main' instead of calling 'exit'.
3597
3598 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3599
3600         * lib/mktime.c (guess_time_tm): Fix bug where mktime
3601         returned the maximum time_t value rather than (time_t) -1.
3602         Problem originally reported by William Bardwell
3603         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3604
3605         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3606         Moved to here ...
3607         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3608         ... from here.
3609
3610 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3611
3612         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
3613         2821 is fixed.
3614
3615 2006-09-08  Jim Meyering  <jim@meyering.net>
3616
3617         Don't make generated files read-only.  That would bother too many
3618         people.  However, do retain the ability to work when targets are
3619         read-only: remove the destination and temporary files before writing
3620         them (when generated via sed or echo), or by using the -f option for
3621         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
3622         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3623         * modules/byteswap, modules/configmake, modules/fcntl:
3624         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3625         * modules/localcharset, modules/netinet_in, modules/poll:
3626         * modules/stdbool, modules/stdint, modules/sys_select:
3627         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3628
3629 2006-09-08  Jim Meyering  <jim@meyering.net>
3630
3631         Avoid new build failure on FreeBSD 6.0.
3632         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
3633         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
3634         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
3635
3636 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3637
3638         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
3639
3640 2006-09-07  Jim Meyering  <jim@meyering.net>
3641
3642         Fix global typo in last change: use chmod u-w, not chmod u-x.
3643         Spotted by Paul Eggert and Bruce Korb.
3644         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3645         * modules/byteswap, modules/configmake, modules/fcntl:
3646         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
3647         * modules/localcharset, modules/netinet_in, modules/poll:
3648         * modules/stdbool, modules/stdint, modules/sys_select:
3649         * modules/sys_socket, modules/sys_stat, modules/sysexits:
3650
3651 2006-09-06  Jim Meyering  <jim@meyering.net>
3652
3653         Make generated files be read-only.
3654         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
3655         Ensure that each generated file is now read-only.
3656         * modules/argz: Likewise.
3657         * modules/arpa_inet: Likewise.
3658         * modules/byteswap: Likewise.
3659         * modules/configmake: Likewise.
3660         * modules/fcntl: Likewise.
3661         * modules/fnmatch: Likewise.
3662         * modules/getopt: Likewise.
3663         * modules/glob: Likewise.
3664         * modules/inttypes: Likewise.
3665         * modules/netinet_in: Likewise.
3666         * modules/poll: Likewise.
3667         * modules/stdbool: Likewise.
3668         * modules/stdint: Likewise.
3669         * modules/sys_select: Likewise.
3670         * modules/sys_socket: Likewise.
3671         * modules/sys_stat: Likewise.
3672         * modules/sysexits: Likewise.
3673         * modules/localcharset: Same as above, but continue using temporary
3674         file named "t-$@" (why different?) rather than the "$@-t" used
3675         everywhere else.
3676
3677         * modules/sysexits (Makefile.am): Replace literal occurrences
3678         of "sysexit.h" more readable, and more consistent, "$@".
3679
3680 2006-09-06  Bruno Haible  <bruno@clisp.org>
3681
3682         * modules/striconv: New file.
3683         * modules/xstriconv: New file.
3684         * MODULES.html.sh (Internationalization functions): Add striconv,
3685         xstriconv.
3686
3687 2006-09-06  Bruno Haible  <bruno@clisp.org>
3688
3689         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
3690         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
3691         not using libtool correctly.
3692
3693 2006-09-06  Bruno Haible  <bruno@clisp.org>
3694
3695         * lib/striconv.h: New file.
3696         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
3697         iconvstring.c.
3698         * lib/xstriconv.h: New file.
3699         * lib/xstriconv.c: New file.
3700
3701 2006-09-06  Bruno Haible  <bruno@clisp.org>
3702
3703         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
3704         lib_..._LDFLAGS.
3705
3706 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3707
3708         * lib/argz_.h: Sync from Libtool.
3709
3710         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
3711                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3712
3713         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
3714
3715 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3716
3717         * modules/trim: New file.
3718
3719 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
3720
3721         * lib/trim.h: New file.
3722         * lib/trim.c: New file.
3723
3724 2006-09-05  Bruno Haible  <bruno@clisp.org>
3725
3726         * MODULES.html.sh (String handling): Add trim.
3727
3728 2006-09-04  Karl Berry  <karl@gnu.org>
3729
3730         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
3731         until next release.
3732
3733 2006-09-03  Bruno Haible  <bruno@clisp.org>
3734
3735         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
3736         correctly.
3737
3738 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3739
3740         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
3741         not gl_GETLOADAVG.  Omit unneeded semicolons.
3742         Problems reported by Ralf Wildenhues in
3743         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3744         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
3745         at the end, which is the usual gnulib style.
3746
3747         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
3748         of doing all the work ourselves.
3749         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
3750         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
3751
3752 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3753
3754         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
3755         Problem reported by Ralf Wildenhues in
3756         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
3757
3758         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
3759         HAVE_STRUCT_STATFS_F_FSTYPENAME.
3760
3761 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
3762
3763         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
3764         yesterday's patch by changing test -n to test -z.
3765
3766 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3767
3768         * modules/getloadavg (Files): Add m4/getloadavg.m4.
3769         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
3770         the former is now obsolescent.
3771
3772         * modules/chdir-long (Depends-on): Add fcntl.
3773
3774 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3775
3776         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
3777         obsolescent, and programs should use gnulib instead.
3778         * m4/getloadavg.m4: New file, with contents taken from Autoconf
3779         but with prefixes changed.
3780
3781 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
3782
3783         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
3784         or stdbool.h, because they might not exist while configuring.
3785
3786         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
3787         Don't include unistd.h or limits.h; not needed, since chdir-long.h
3788         does that for us.
3789         (O_DIRECTORY): Remove.
3790
3791 2006-08-31  Eric Blake  <ebb9@byu.net>
3792
3793         * gnulib-tool: Don't let emacs change spaces to TAB.
3794
3795 2006-08-31  Bruno Haible  <bruno@clisp.org>
3796
3797         * gnulib-tool: When calling func_import more than once, do it in a
3798         subshell.
3799         Reported by Eric Blake <ebb9@byu.net>.
3800
3801 2006-08-31  Bruno Haible  <bruno@clisp.org>
3802
3803         * gnulib-tool (nl): Remove variable.
3804         (sed_transform_lib_file): Use more robust test for config-h module.
3805         (func_import): Fix typo in 2006-08-25 patch.
3806
3807 2006-08-31  Bruno Haible  <bruno@clisp.org>
3808
3809         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
3810         specified, augment Makefile.am variables instead of assigning them.
3811
3812 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3813
3814         Work around a bug in both the Linux and SunOS 64-bit kernels:
3815         nanosleep mishandles sleeps for longer than 2**31 seconds.
3816         Problem reported by Frank v Waveren in
3817         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3818         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
3819         Check for nanosleep bug.
3820         (LIB_NANOSLEEP): Append clock_gettime library if needed.
3821
3822 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3823
3824         Work around a bug in both the Linux and SunOS 64-bit kernels:
3825         nanosleep mishandles sleeps for longer than 2**31 seconds.
3826         Problem reported by Frank v Waveren in
3827         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
3828         * lib/nanosleep.c (BILLION): New constant.
3829         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
3830         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
3831         implementation.
3832
3833 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3834
3835         * modules/nanosleep (Depends-on): Add gettime.
3836
3837 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
3838         and Simon Josefsson  <jas@extundo.com>
3839         and Oskar Liljeblad  <oskar@osk.mine.nu>
3840
3841         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
3842         * gnulib-tool (func_import): New license type 'unmodifiable license
3843         text'.
3844         * modules/fdl: Use it.  Longer description.
3845         * module/gpl, module/lgpl: New files.
3846
3847 2006-08-30  Jim Meyering  <jim@meyering.net>
3848
3849         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
3850         shadowing the parameter.
3851
3852 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3853
3854         Sync from Libtool:
3855
3856         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3857
3858         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
3859         sharing with gnulib.  Report by Eric Blake.
3860
3861 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3862
3863         * modules/isapipe: New file.
3864         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
3865
3866 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3867
3868         * modules/configmake (Makefile.am): Add a comment, and omit
3869         the CONFIGMAKE_ prefix from generated macro names.  Suggested
3870         by Bruno Haible.
3871
3872 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3873
3874         * m4/isapipe.m4: New file.
3875
3876 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
3877
3878         * lib/isapipe.c, lib/isapipe.h: New files.
3879
3880 2006-08-29  Jim Meyering  <jim@meyering.net>
3881
3882         * modules/configmake (Makefile.am): Make configmake.h depend on
3883         Makefile.  Otherwise, a stale configmake.h could hang around.
3884
3885 2006-08-29  Eric Blake  <ebb9@byu.net>
3886
3887         * lib/error.c (error_at_line, print_errno_message): Match libc, after
3888         resolution of upstream bug 3044.
3889
3890 2006-08-29  Bruno Haible  <bruno@clisp.org>
3891
3892         * modules/localcharset (Depends-on): Add configmake.
3893         (Makefile.am): Remove setting of LIBDIR through DEFS.
3894
3895 2006-08-29  Bruno Haible  <bruno@clisp.org>
3896
3897         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
3898         defined.
3899
3900 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3901
3902         * modules/fcntl: New file.
3903         * modules/chdir-safer (Depends-on): Add fcntl.
3904         * modules/fts: Likewise.
3905         * modules/mkdir-p: Likewise.
3906
3907         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
3908         This undoes the most recent change, since we're now addressing the
3909         problem in a different way.
3910
3911         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
3912         into output, since the output might be called Makefile.am even
3913         if $makefile_name is something different.
3914         (func_import): Use $makefile_am rather than
3915         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
3916         empty.
3917
3918         * modules/inttypes (Files): Add m4/inttypes-h.m4.
3919
3920 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3921
3922         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
3923         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
3924         recent change to stdint.m4, since we're now addressing the problem in a
3925         different way.
3926
3927 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3928
3929         * m4/fcntl_h.m4: New file.
3930
3931 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
3932
3933         * lib/fcntl_.h: New file.
3934         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
3935         the fcntl module.
3936         * lib/dirchownmod.c: Likewise.
3937         * lib/fts.c: Likewise.
3938
3939         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
3940         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
3941         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
3942         just before including <inttypes.h>, to avoid circular inclusion.
3943
3944 2006-08-28  Jim Meyering  <jim@meyering.net>
3945
3946         * doc/visibility.texi: Actually read and correct the grammar of the
3947         sentence affected by yesterday's change.
3948
3949 2006-08-28  Eric Blake  <ebb9@byu.net>
3950
3951         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
3952         needs wrapper.
3953
3954 2006-08-28  Eric Blake  <ebb9@byu.net>
3955
3956         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
3957
3958 2006-08-28  Eric Blake  <ebb9@byu.net>
3959
3960         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
3961
3962 2006-08-28  Bruno Haible  <bruno@clisp.org>
3963
3964         * modules/c-strstr: New file, from GNU gettext.
3965         * MODULES.html.sh (String handling): Add c-strstr.
3966
3967 2006-08-28  Bruno Haible  <bruno@clisp.org>
3968
3969         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
3970         macros.
3971         Reported by Eric Blake.
3972
3973 2006-08-28  Bruno Haible  <bruno@clisp.org>
3974
3975         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
3976         (VASNPRINTF): Return a string of length > INT_MAX without failing.
3977         * lib/vasprintf.c: Include errno.h, limits.h.
3978         (EOVERFLOW): New fallback definition.
3979         (vasprintf): Test here whether the string length is > INT_MAX.
3980         * lib/vsnprintf.c: Include errno.h, limits.h.
3981         (EOVERFLOW): New fallback definition.
3982         (vsnprintf): Fix bug when generated string was too long for the buffer.
3983         Test here whether the string length is > INT_MAX.
3984
3985 2006-08-28  Bruno Haible  <bruno@clisp.org>
3986
3987         * lib/inttypes_.h (SCNX*): Remove definitions.
3988         Reported by Eric Blake.
3989
3990 2006-08-28  Bruno Haible  <bruno@clisp.org>
3991
3992         * lib/c-strstr.h: New file, from GNU gettext.
3993         * lib/c-strstr.c: New file, from GNU gettext.
3994
3995 2006-08-28  Bruno Haible  <bruno@clisp.org>
3996
3997         * gnulib-tool: Reorder some statements.
3998
3999 2006-08-28  Bruno Haible  <bruno@clisp.org>
4000
4001         * gnulib-tool: New option --makefile-name.
4002         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
4003         $makefile_name.
4004         (func_import): Write $makefile_name to the cache file, and read it from
4005         there unless explicitly specified. Use $makefile_name as file name
4006         instead of Makefile.am. Adjust the recommendations accordingly.
4007
4008 2006-08-28  Bruno Haible  <bruno@clisp.org>
4009
4010         * gnulib-tool (func_verify_module): Check against misapplying patch.
4011
4012 2006-08-28  Bruno Haible  <bruno@clisp.org>
4013
4014         * gnulib-tool (func_relativize, func_relconcat): New functions.
4015         Give an error if --local-dir is given with --update.
4016         Remove trailing slashes from $local_gnulib_dir.
4017         (func_import): Store the relativized $local_gnulib_dir in
4018         gnulib-cache.m4, and read it from there if not specified explicitly.
4019
4020 2006-08-28  Bruno Haible  <bruno@clisp.org>
4021
4022         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
4023         is the current directory. Respect also $local_gnulib_dir.
4024
4025 2006-08-28  Bruno Haible  <bruno@clisp.org>
4026             Simon Josefsson  <jas@extundo.com>
4027
4028         BeOS portability.
4029         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
4030
4031 2006-08-27  Jim Meyering  <jim@meyering.net>
4032
4033         * doc/visibility.texi: Remove duplicate word: "pointer".
4034
4035 2006-08-26  Bruno Haible  <bruno@clisp.org>
4036
4037         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
4038         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
4039         (Makefile.am): Create inttypes.h from inttypes_.h.
4040         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
4041
4042         * modules/imaxabs: New file.
4043
4044         * modules/imaxdiv: New file.
4045
4046 2006-08-26  Bruno Haible  <bruno@clisp.org>
4047
4048         * m4/inttypes.m4: New file.
4049         * m4/_inttypes_h.m4: Remove file.
4050         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
4051         PRI_MACROS_BROKEN.
4052         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
4053
4054         * m4/imaxabs.m4: New file.
4055
4056         * m4/imaxdiv.m4: New file.
4057
4058 2006-08-26  Bruno Haible  <bruno@clisp.org>
4059
4060         * lib/inttypes_.h: New file.
4061         * lib/inttypes.h: Remove file.
4062         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
4063
4064         * lib/imaxabs.c: New file.
4065
4066         * lib/imaxdiv.c: New file.
4067
4068 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4069
4070         New config-h module, so that "make" output needn't be cluttered
4071         by -DHAVE_CONFIG_H.
4072         * MODULES.html.sh (Support for building libraries and executables):
4073         Add config-h.
4074         * modules/config-h: New file.
4075         * gnulib-tool (nl, sed_transform_lib_file): New vars.
4076         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
4077         the config-h module is used.
4078
4079         New configmake module, so that "make" output needn't be cluttered
4080         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
4081         * MODULES.html.sh (Support for building libraries and executables):
4082         Add configmake.
4083         * modules/configmake: New file.
4084
4085 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4086
4087         * m4/config-h.m4: New file.
4088
4089 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4090
4091         * config/srclist.txt: Add elisp-comp.
4092
4093 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4094
4095         * MODULES.html.sh (Support for building libraries and executables):
4096         Add elisp-comp.
4097         * build-aux/elisp-comp: New file.
4098         * modules/elisp-comp: New file.
4099
4100 2006-08-24  Bruno Haible  <bruno@clisp.org>
4101
4102         * gnulib-tool (func_create_testdir): Use non-default values of
4103         sourcebase and m4base.
4104
4105 2006-08-24  Bruno Haible  <bruno@clisp.org>
4106
4107         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
4108         HTML structure.
4109
4110 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
4111
4112         * modules/openat (Depends-on): Add lchown.
4113
4114 2006-08-23  Bruno Haible  <bruno@clisp.org>
4115
4116         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
4117         of gl_LOCK_EARLY instead of gl_LOCK.
4118
4119 2006-08-23  Bruno Haible  <bruno@clisp.org>
4120
4121         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
4122         on OSF/1 to no.
4123         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
4124
4125 2006-08-23  Bruno Haible  <bruno@clisp.org>
4126
4127         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
4128         as unusable.
4129
4130         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
4131         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
4132         (gl_LOCK): New macro.
4133
4134 2006-08-22  Simon Josefsson  <jas@extundo.com>
4135
4136         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
4137         to md5 module.
4138
4139 2006-08-22  Simon Josefsson  <jas@extundo.com>
4140
4141         * MODULES.html.sh: Add "Support for maintaining and release
4142         projects".
4143
4144         * build-aux/gnupload: New file, from coreutils.
4145
4146 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4147
4148         Avoid the need for AC_LIBSOURCES in m4 macros.
4149         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
4150         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
4151         * modules/check-version (EXTRA_DIST): Add check-version.h.
4152         * modules/crc (EXTRA_DIST): Add crc.h.
4153         * modules/des (EXTRA_DIST): Add des.h.
4154         * modules/gc (EXTRA_DIST): Add gc.h.
4155         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
4156         * modules/getline (EXTRA_DIST): Add getline.h.
4157         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
4158         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
4159         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
4160         * modules/md2 (EXTRA_DIST): Add md2.h.
4161         * modules/md4 (EXTRA_DIST): Add md4.h.
4162         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
4163         * modules/read-file (EXTRA_DIST): Add read-file.h.
4164         * modules/readline (EXTRA_DIST): Add readline.h.
4165         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
4166         rijndael-api-fst.h.
4167
4168 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4169
4170         * m4/rijndael.m4 (gl_ARCFOUR):
4171         * m4/arctwo.m4 (gl_ARCTWO):
4172         * m4/check-version.m4 (gl_CHECK_VERSION):
4173         * m4/crc.m4 (gl_CRC):
4174         * m4/des.m4 (gl_DES):
4175         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
4176         * m4/gc.m4 (gl_GC):
4177         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
4178         * m4/getline.m4 (gl_FUNC_GETLINE):
4179         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
4180         * m4/hmac-md5.m4 (gl_HMAC_MD5):
4181         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
4182         * m4/md2.m4 (gl_MD2):
4183         * m4/md4.m4 (gl_MD4):
4184         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
4185         * m4/read-file.m4 (gl_FUNC_READ_FILE):
4186         * m4/readline.m4 (gl_FUNC_READLINE):
4187         * m4/rijndael.m4 (gl_RIJNDAEL):
4188         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4189         to get the necessary .h files and whatnot.
4190
4191 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4192
4193         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
4194         gnulib rather than the other way around.
4195         * config/srclistvars.sh (COREUTILS): Remove.
4196
4197 2006-08-22  Jim Meyering  <jim@meyering.net>
4198
4199         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
4200
4201         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
4202
4203 2006-08-22  Eric Blake  <ebb9@byu.net>
4204
4205         * modules/regexprops-generic: New file.
4206         * MODULES.html.sh (Support for building documentation): List it.
4207
4208 2006-08-22  Eric Blake  <ebb9@byu.net>
4209
4210         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
4211         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
4212         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
4213         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
4214
4215 2006-08-22  Bruno Haible  <bruno@clisp.org>
4216
4217         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
4218         and lib_LTLIBRARIES like the other lib_* variables.
4219
4220 2006-08-22  Bruno Haible  <bruno@clisp.org>
4221
4222         * build-aux/x-to-1.in: New file, from GNU gettext.
4223
4224 2006-08-22  Bruno Haible  <bruno@clisp.org>
4225
4226         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
4227         <utmpx.h> exists.
4228
4229 2006-08-22  Bruno Haible  <bruno@clisp.org>
4230
4231         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
4232         <utmpx.h> exists.
4233
4234 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4235
4236         BeOS portability.
4237         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
4238         exist.
4239         Problem reported by Bruno Haible.
4240
4241 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4242
4243         Avoid the need for AC_LIBSOURCES in m4 macros.
4244         * modules/acl (EXTRA_DIST): Add acl.h.
4245         * modules/argmatch (Files): Add m4/argmatch.m4.
4246         (configure.ac): Add gl_ARGMATCH.
4247         (EXTRA_DIST): Renamed from lib_SOURCES, for
4248         consistency with the other modules.  Remove argmatch.c.
4249         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
4250         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
4251         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
4252         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
4253         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
4254         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
4255         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
4256         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
4257         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
4258         * modules/closeout (EXTRA_DIST): Add closeout.h.
4259         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
4260         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
4261         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
4262         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
4263         dirname.h; remove basename.c and stripslash.c.
4264         * modules/exclude (EXTRA_DIST): Add exclude.h.
4265         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
4266         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
4267         * modules/file-type (EXTRA_DIST): Add file-type.h.
4268         * modules/filemode (EXTRA_DIST): Add filemode.h.
4269         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
4270         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4271         * modules/fpending (EXTRA_DIST): Add __fpending.h.
4272         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
4273         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
4274         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
4275         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
4276         * modules/getdate (EXTRA_DIST): Add getdate.c.
4277         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
4278         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
4279         * modules/getpass (EXTRA_DIST): Add getpass.h.
4280         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
4281         * modules/group-member (EXTRA_DIST): Add group-member.h.
4282         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
4283         * modules/hash (EXTRA_DIST): Add hash.h.
4284         * modules/human (EXTRA_DIST): Add human.h.
4285         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
4286         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
4287         * modules/lchown (EXTRA_DIST): Add lchown.h.
4288         * modules/long-options (EXTRA_DIST): Add long-options.h.
4289         * modules/lstat (EXTRA_DIST): Add lstat.h.
4290         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
4291         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
4292         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
4293         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
4294         * modules/memxor (EXTRA_DIST): Add memxor.h.
4295         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
4296         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
4297         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
4298         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
4299         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
4300         * modules/physmem (EXTRA_DIST): Add physmem.h.
4301         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
4302         * modules/posixver (EXTRA_DIST): Add posixver.h.
4303         * modules/quote (EXTRA_DIST): Add quote.h.
4304         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
4305         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
4306         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
4307         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
4308         regex_internal.h regexec.c.
4309         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
4310         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
4311         * modules/same (EXTRA_DIST): Add same.h.
4312         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
4313         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
4314         * modules/savedir (EXTRA_DIST): Add savedir.h.
4315         * modules/sha1 (EXTRA_DIST): Add sha1.h.
4316         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
4317         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
4318         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
4319         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
4320         * modules/strdup (EXTRA_DIST): Add strdup.h.
4321         * modules/strftime (EXTRA_DIST): Add strftime.h.
4322         * modules/strndup (EXTRA_DIST): Add strndup.h.
4323         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
4324         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
4325         * modules/time_r (EXTRA_DIST): Add time_r.h.
4326         * modules/timespec (EXTRA_DIST): Add timespec.h.
4327         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4328         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
4329         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
4330         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
4331         * modules/userspec (EXTRA_DIST): Add userspec.h.
4332         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
4333         * modules/utimens (EXTRA_DIST): Add utimens.h.
4334         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
4335         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
4336         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
4337         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
4338         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
4339         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
4340         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
4341         * modules/yesno (EXTRA_DIST): Add yesno.h.
4342
4343 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4344
4345         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
4346
4347         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
4348         * m4/dev-ino.m4, same-inode.m4: Remove.
4349
4350         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
4351         * m4/acl.m4 (AC_FUNC_ACL):
4352         * m4/backupfile.m4 (gl_BACKUPFILE):
4353         * m4/c-strtod.m4 (gl_C99_STRTOLD):
4354         * m4/canon-host.m4 (gl_CANON_HOST):
4355         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4356         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
4357         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
4358         * m4/cloexec.m4 (gl_CLOEXEC):
4359         * m4/close-stream.m4 (gl_CLOSE_STREAM):
4360         * m4/closeout.m4 (gl_CLOSEOUT):
4361         * m4/dirfd.m4 (gl_FUNC_DIRFD):
4362         * m4/dirname.m4 (gl_DIRNAME):
4363         * m4/exclude.m4 (gl_EXCLUDE):
4364         * m4/exitfail.m4 (gl_EXITFAIL):
4365         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
4366         * m4/file-type.m4 (gl_FILE_TYPE):
4367         * m4/filemode.m4 (gl_FILEMODE):
4368         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
4369         * m4/fpending.m4 (gl_FUNC_FPENDING):
4370         * m4/fprintftime.m4 (gl_FPRINTFTIME):
4371         * m4/fts.m4 (gl_FUNC_FTS):
4372         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
4373         * m4/getdate.m4 (gl_GETDATE):
4374         * m4/gethrxtime.m4 (gl_GETHRXTIME):
4375         * m4/getpagesize.m4 (gl_GETPAGESIZE):
4376         * m4/getpass.m4 (gl_FUNC_GETPASS):
4377         * m4/gettime.m4 (gl_GETTIME):
4378         * m4/getugroups.m4 (gl_GETUGROUPS):
4379         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
4380         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
4381         * m4/hard-locale.m4 (gl_HARD_LOCALE):
4382         * m4/hash.m4 (gl_HASH):
4383         * m4/idcache.m4 (gl_IDCACHE):
4384         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
4385         * m4/lchown.m4 (gl_FUNC_LCHOWN):
4386         * m4/long-options.m4 (gl_LONG_OPTIONS):
4387         * m4/lstat.m4 (gl_FUNC_LSTAT):
4388         * m4/md5.m4 (gl_MD5):
4389         * m4/memcasecmp.m4 (gl_MEMCASECMP):
4390         * m4/memcoll.m4 (gl_MEMCOLL):
4391         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
4392         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
4393         * m4/memxor.m4 (gl_MEMXOR):
4394         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
4395         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
4396         * m4/modechange.m4 (gl_MODECHANGE):
4397         * m4/mountlist.m4 (gl_MOUNTLIST):
4398         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4399         * m4/openat.m4 (gl_FUNC_OPENAT):
4400         * m4/pathmax.m4 (gl_PATHMAX):
4401         * m4/physmem.m4 (gl_PHYSMEM):
4402         * m4/posixtm.m4 (gl_POSIXTM):
4403         * m4/posixver.m4 (gl_POSIXVER):
4404         * m4/quote.m4 (gl_QUOTE):
4405         * m4/quotearg.m4 (gl_QUOTEARG):
4406         * m4/readtokens.m4 (gl_READTOKENS):
4407         * m4/readutmp.m4 (gl_READUTMP):
4408         * m4/regex.m4 (gl_REGEX):
4409         * m4/safe-read.m4 (gl_SAFE_READ):
4410         * m4/safe-write.m4 (gl_SAFE_WRITE):
4411         * m4/same.m4 (gl_SAME):
4412         * m4/save-cwd.m4 (gl_SAVE_CWD):
4413         * m4/savedir.m4 (gl_SAVEDIR):
4414         * m4/settime.m4 (gl_SETTIME):
4415         * m4/sha1.m4 (gl_SHA1):
4416         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
4417         * m4/stat-macros.m4 (gl_STAT_MACROS):
4418         * m4/stat-time.m4 (gl_STAT_TIME):
4419         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
4420         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
4421         * m4/strdup.m4 (gl_FUNC_STRDUP):
4422         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
4423         * m4/strndup.m4 (gl_FUNC_STRNDUP):
4424         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
4425         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
4426         * m4/time_r.m4 (gl_TIME_R):
4427         * m4/timespec.m4 (gl_TIMESPEC):
4428         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
4429         * m4/unlinkdir.m4 (gl_UNLINKDIR):
4430         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
4431         * m4/userspec.m4 (gl_USERSPEC):
4432         * m4/utimecmp.m4 (gl_UTIMECMP):
4433         * m4/utimens.m4 (gl_UTIMENS):
4434         * m4/xalloc.m4 (gl_XALLOC):
4435         * m4/xgetcwd.m4 (gl_XGETCWD):
4436         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
4437         * m4/xreadlink.m4 (gl_XREADLINK):
4438         * m4/xstrtod.m4 (gl_XSTRTOD):
4439         * m4/yesno.m4 (gl_YESNO):
4440         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4441         to get the necessary .h files and whatnot.
4442
4443 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
4444             Bruno Haible  <bruno@clisp.org>
4445
4446         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
4447         /bin/sh understanding of '!' conditional negation.
4448
4449 2006-08-21  Jim Meyering  <jim@meyering.net>
4450
4451         * modules/openat (Depends-on): Really alphabetize.
4452
4453         * modules/acl (Depends-on): Add error and quote.
4454
4455         * check-module (find_included_lib_files): Add at-func.c to the
4456         ok-to-include-more-than-once white list.
4457
4458         * modules/openat (Depends-on): Add lstat.  Alphabetize.
4459
4460 2006-08-21  Bruno Haible  <bruno@clisp.org>
4461
4462         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4463         Emit a pkgdata_DATA variable only if some snippets add contents to it.
4464         Reported by Martin Lambers <marlam@marlam.de>.
4465
4466 2006-08-21  Bruno Haible  <bruno@clisp.org>
4467
4468         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
4469         specify an installation location, don't emit a noinst_LIBRARIES or
4470         noinst_LTLIBRARIES assignment.
4471
4472 2006-08-21  Bruno Haible  <bruno@clisp.org>
4473
4474         BeOS portability.
4475         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
4476         BeOS has mbrtowc() but no <wctype.h>.
4477
4478 2006-08-21  Bruno Haible  <bruno@clisp.org>
4479
4480         BeOS portability.
4481         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
4482         exist.
4483
4484 2006-08-21  Bruno Haible  <bruno@clisp.org>
4485
4486         BeOS portability.
4487         * lib/mbchar.h: Include <wctype.h> only if it exists.
4488
4489 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4490
4491         Remove files that are no longer needed by their respective modules.
4492         * m4/obstack.m4: Remove.
4493         * m4/strerror_r.m4: Remove.
4494         * m4/uint32_t.m4: Remove.
4495         * m4/uintptr_t.m4: Remove.
4496         * m4/ullong_max.m4: Remove.
4497         * m4/xstrtoimax.m4: Remove.
4498         * m4/xstrtoumax.m4: Remove.
4499
4500         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
4501         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
4502         dependencies now capture this.
4503
4504         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
4505         Do not use AC_LIBSOURCES, since gnulib modules now do this.
4506         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
4507         * m4/human.m4 (gl_HUMAN): Likewise.
4508         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
4509         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
4510
4511         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
4512
4513         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
4514         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
4515         stdint.
4516         * m4/human.m4 (gl_HUMAN): Likewise.
4517         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
4518         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
4519         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4520         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4521         * m4/xstrtol (gl_XSTRTOL): Likewise.
4522
4523         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
4524         AC_TYPE_LONG_LONG_INT.
4525         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4526         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
4527         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
4528         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4529
4530         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
4531         on stdbool.
4532
4533         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
4534         (gl_PREREQ_XSTRTOUL): Remove.
4535
4536         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
4537
4538         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
4539         mode.
4540
4541 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4542
4543         Add and change modules to make it easier for coreutils to use
4544         gnulib-tool.
4545         * modules/backupfile (Files): Remove m4/d-ino.m4.
4546         (Depends-on): Add d-ino.
4547         * modules/cycle-check (Depends-on): Add stdint.
4548         (lib_SOURCES): Add cycle-check.h.
4549         * modules/d-ino: New module.
4550         * modules/d-type: New module.
4551         * modules/error (Files): Remove m4/strerror_r.m4.
4552         * modules/filemode (Files): Add m4/st_dm_mode.m4.
4553         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4554         m4/inttypes_h.m4, m4/uintmax_t.m4.
4555         (Depends-on): Add stdint.
4556         (lib_SOURCES): Add fsusage.h.
4557         * modules/getcwd (Files): Remove d-ino.m4.
4558         (Depends-on): Add d-ino.
4559         * modules/getndelim2 (Depends-on): Add stdint.
4560         * modules/glob (Files): Remove m4/d-type.m4.
4561         (Depends-on): Add d-type.
4562         * modules/host-os: New module.
4563         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
4564         m4/inttypes_h.m4, m4/uintmax_t.m4.
4565         * Depends-on: Add stdint.
4566         (lib_SOURCES): Add human.h.
4567         * modules/inttostr (Files): Remove m4/intmax_t.m4,
4568         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
4569         m4/uintmax_t.m4, m4/ulonglong.m4.
4570         (Depends-on): Add stdint.
4571         (EXTRA_DIST): Add inttostr.h.
4572         * modules/lchmod: New module.
4573         * modules/link-follow: New module.
4574         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
4575         (Depends-on): Add lchmod.
4576         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
4577         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
4578         (Depends-on): Add stdint.
4579         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
4580         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
4581         (Depends-on): Add stdint.
4582         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
4583         * modules/perl: New module.
4584         * modules/regex (Depends-on): Add stdint.
4585         * modules/rmdir-errno: New module.
4586         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4587         m4/intmax_t.m4.
4588         (Depends-on): Add stdint.
4589         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4590         m4/uintmax_t.m4.
4591         (Depends-on): Add stdint.
4592         * modules/unlink-busy: New module.
4593         * modules/utimecmp (Depends-on): Add stdint.
4594         * modules/uptime: New module.
4595         * modules/winsz-ioctl: New module.
4596         * modules/winsz-termios: New module.
4597         * modules/xnanosleep (Depends-on): Add nanosleep.
4598         * modules/ullong_max: Remove.
4599         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
4600         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
4601         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
4602         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
4603         (Depends-on): Add inttypes.
4604         (lib_SOURCES): Add xstrtol.h.
4605         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
4606         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
4607         * MODULES.html.sh: Move 'assert' into the assert section.
4608         Move 'dummy' into the linking section.
4609         Remove ullong_max.
4610         Add section for compatibility checks for POSIX:2001 functions,
4611         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
4612         winsz-ioctl, and winsz-termios into it.
4613         Add lchmod.
4614         Add top-level Misc section and put host-os, perl, and uptime
4615         into it.
4616
4617 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4618
4619         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
4620         now assume the stdint module.  Do not include inttypes.h.
4621         * lib/fsusage.h: Likewise.
4622         * lib/getndelim2.c: Likewise.
4623         * lib/human.h: Likewise.
4624         * lib/inttostr.h: Likewise.
4625         * lib/obstack.c: Likewise.
4626         * lib/regex_internal.h: Likewise.
4627         * lib/tempname.c: Likewise.
4628         * lib/utimecmp.c: Likewise.
4629         * lib/xstrtol.h: Likewise.
4630
4631         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
4632
4633         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
4634         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
4635         * lib/xtime.h: Likewise.
4636
4637 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4638
4639         * modules/openat (Files): Add lib/fchmodat.c.
4640         Fixes problem reported by Jay Youngman.
4641
4642 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
4643
4644         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
4645         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
4646
4647 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
4648             Bruno Haible  <bruno@clisp.org>
4649
4650         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
4651         and is a script that invokes bison. Tighten the code. Add comments.
4652
4653 2006-08-18  Jim Meyering  <jim@meyering.net>
4654
4655         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
4656         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
4657         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
4658         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
4659
4660 2006-08-18  Bruno Haible  <bruno@clisp.org>
4661
4662         * modules/bison-i18n: New file.
4663         * MODULES.html.sh (Internationalization functions): Add it.
4664
4665 2006-08-18  Bruno Haible  <bruno@clisp.org>
4666
4667         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
4668         sys/statvfs.h. When getmntinfo was found, check its declaration and
4669         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
4670
4671 2006-08-18  Bruno Haible  <bruno@clisp.org>
4672
4673         * m4/bison-i18n.m4: New file, from bison.
4674
4675 2006-08-18  Bruno Haible  <bruno@clisp.org>
4676
4677         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
4678         (ME_DUMMY): Treat "kernfs" as a dummy.
4679         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
4680
4681 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4682
4683         Update from coreutils.
4684
4685         2006-08-15  Jim Meyering  <jim@meyering.net>
4686
4687         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
4688
4689         2006-01-17  Jim Meyering  <jim@meyering.net>
4690
4691         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
4692
4693         2006-01-11  Jim Meyering  <jim@meyering.net>
4694
4695         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
4696         Check for the lchmod function.
4697
4698 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
4699
4700         Update from coreutils.
4701
4702         * lib/__fpending.h: Add copyright notice.
4703         * lib/fprintftime.h: Likewise.
4704         * lib/savedir.c: Use (C) in copyright notice.
4705         * lib/savedir.h: Likewise.
4706
4707         2006-08-15  Jim Meyering  <jim@meyering.net>
4708
4709         * lib/at-func.c: New file, with the logic of all emulated at-functions.
4710         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
4711         in support of the EXPECTED_ERRNO macro.
4712         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
4713         definitions.  Instead, define the appropriate symbols and include
4714         "at-func.c".
4715         * lib/mkdirat.c (mkdirat): Likewise.
4716         * lib/fchmodat.c (fchmodat): Likewise.
4717         (ENOSYS): Remove definition.
4718         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
4719         it.  Don't include "unistd--.h" -- it wasn't ever used.
4720
4721         2006-01-17  Jim Meyering  <jim@meyering.net>
4722
4723         Rewrite fts.c not to change the current working directory,
4724         by using openat, fstatat, fdopendir, etc..
4725
4726         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
4727         (HAVE_OPENAT_SUPPORT): Define.
4728         [_LIBC] (fchdir): Don't undef or define; no longer used.
4729         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
4730         Now, this `function' always succeeds, and consumes its file descriptor
4731         parameter -- so callers must not close such FDs.  Update callers.
4732         (diropen_fd, opendirat, cwd_advance_fd): New functions.
4733         (diropen): Add parameter, SP.  Adjust all callers.
4734         Implement using diropen_fd, rather than open.
4735         (fts_open): Initialize new member, fts_cwd_fd.
4736         Remove fts_rft-setting code.
4737         (fts_close): Close fts_cwd_fd, if necessary.
4738         (__opendir2): Define in terms of opendir or opendirat,
4739         depending on whether the FST_NOCHDIR flag is set.
4740         (fts_build): Since fts_safe_changedir consumes its FD, and since
4741         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
4742         and close the dup'd file descriptor upon failure.
4743         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
4744         (fts_safe_changedir): Tweak semantics to reflect that this function
4745         now calls cwd_advance_fd and hence consumes its FD argument.
4746         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
4747         [struct FTS] (fts_rft): Remove now-unused member.
4748         [struct FTS] (fts_cycle.state): Improve comment.
4749
4750         * lib/openat.c (openat_needs_fchdir): New function.
4751         * lib/openat.h (openat_needs_fchdir): Declare it.
4752
4753 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
4754
4755         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
4756         Problem and fix reported by Pádraig Brady in
4757         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
4758
4759 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4760
4761         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
4762
4763 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4764
4765         * lib/memcoll.c (memcoll): Optimize for the common case where the
4766         arguments are bytewise equal.
4767
4768 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4769
4770         * doc/regexprops-generic.texi: Add a copyright notice.
4771
4772 2006-08-15  Bruno Haible  <bruno@clisp.org>
4773
4774         * modules/tmpdir (License): Change to LGPL.
4775
4776 2006-08-15  Bruno Haible  <bruno@clisp.org>
4777
4778         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
4779         module.
4780
4781 2006-08-14  Simon Josefsson  <jas@extundo.com>
4782
4783         * config/srclist.txt: Add gnupload.
4784
4785 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4786
4787         Change copyright notice from LGPL 2 to GPL 2, since that's the
4788         standard form used in the gnulib repository.
4789         * tests/test-lock.c: Likewise.
4790         * tests/test-stdint.c: Likewise.
4791         * tests/test-tls.c: Likewise.
4792
4793         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
4794         prelude-manager.  User shorter URLs for GNU projects, without '?'.
4795         Add copyright notice.
4796
4797         * check-module: Add copyright notice.  Output a copyright
4798         notice if "--version" is specified.
4799         * modules/COPYING: New file.
4800         * tests/test-getaddrinfo.c: Add copyright notice.
4801         * tests/test-verify.c: Likewise.
4802
4803 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4804
4805         Change copyright notice from LGPL 2 to GPL 2, since that's the
4806         standard form used in the gnulib repository.
4807         * lib/lock.c: LGPL -> GPL.
4808         * lib/lock.h: Likewise.
4809         * lib/strnlen1.c: Likewise.
4810         * lib/strnlen1.h: Likewise.
4811         * lib/tls.c: Likewise.
4812         * lib/tls.h: Likewise.
4813         * lib/tmpdir.c: Likewise.
4814
4815         * lib/TODO: Remove; this belongs only in coreutils.
4816
4817 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4818
4819         Add copyright notices to long-enough files that lack them, since
4820         otherwise the files aren't clearly free.  Use the same notice that
4821         getdate.texi already uses.
4822         * doc/alloca-opt.texi: Add copyright notice.
4823         * doc/alloca.texi: Likewise.
4824         * doc/ctime.texi: Likewise.
4825         * doc/functions.texi: Likewise.
4826         * doc/gcd.texi: Likewise.
4827         * doc/gnulib-tool.texi: Likewise.
4828         * doc/inet_ntoa.texi: Likewise.
4829         * doc/visibility.texi: Likewise.
4830
4831         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
4832         * doc/quote.texi: Add copyright notice.
4833
4834         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
4835         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
4836         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
4837         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
4838         is now obsolete, and give a pointer to the Sun list.
4839         Add copyright notice.
4840
4841 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
4842
4843         * config/srclistvars.sh: Add copyright notice.
4844
4845 2006-08-14  Eric Blake  <ebb9@byu.net>
4846
4847         Import the following change from libc:
4848
4849         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
4850
4851         Upstream bug 2997.
4852         * lib/misc/error.c: Add space between program name and message if file
4853         name is missing.
4854
4855 2006-08-12  Karl Berry  <karl@gnu.org>
4856
4857         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
4858         remove, these originate in gnulib now.
4859
4860 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4861
4862         * doc/Makefile (standards.info standards.html standards.dvi):
4863         Also depend on make-stds.texi.
4864
4865 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
4866
4867         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
4868         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
4869
4870         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
4871         in wchar_t.  Problem reported by Eric Blake.
4872
4873         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
4874         LEN is smaller than SIZE.  Suggested by Bruno Haible.
4875         Also, help the compiler to keep LEN in a register.
4876
4877 2006-08-11  Eric Blake  <ebb9@byu.net>
4878
4879         * users.txt: Sort.  Add tar.
4880
4881 2006-08-11  Bruno Haible  <bruno@clisp.org>
4882
4883         * users.txt: New file.
4884
4885 2006-08-11  Bruno Haible  <bruno@clisp.org>
4886
4887         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
4888         before <wchar.h>. Needed for OSF/1 and BSD/OS.
4889
4890 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
4891
4892         * modules/snprintf (Depends-on): Remove minmax.
4893         (Maintainer): Add self and Bruno.
4894
4895 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
4896
4897         * lib/.cppi-disable: Add snprintf.h, socket_.h.
4898         * lib/snprintf.c: Include <errno.h> and <limits.h>.
4899         (EOVERFLOW): Define if the system does not.
4900         Do not include "minmax.h"; it wasn't used.
4901         (snprintf): Don't assume size_t promotes to an unsigned type.
4902         Fix bug when generated string was too long for the buffer: the
4903         buffer's contents are supposed to be the initial prefix of the
4904         output.  Don't assume vasnprintf returns EOVERFLOW if the size
4905         exceeds INT_MAX; do the check ourselves.
4906
4907         Import the following changes from libc:
4908
4909         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
4910
4911         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
4912         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
4913         set wc to the byte which couldn't be converted.
4914         (re_string_reconstruct): Don't clear valid_raw_len before calling
4915         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
4916         tip_context using re_string_context_at.
4917
4918         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
4919
4920         * lib/posix/regex.h: g++ still cannot handled [restrict].
4921
4922         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
4923
4924         * lib/posix/regex.h: Remove special handling for VMS.
4925
4926 2006-08-10  Jim Meyering  <jim@meyering.net>
4927
4928         * modules/same-inode: New module.
4929         * modules/dev-ino: New module.
4930         * modules/cycle-check: Depend on these modules, rather than simply
4931         including their .h files.
4932         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
4933         required via m4/cycle-check.m4.
4934         * modules/same: Depend on new same-inode module, rather than
4935         including same-inode.h.
4936         * modules/chdir-safer: New file.
4937
4938         * modules/chown (Depends-on): Add stat-macros.
4939
4940 2006-08-10  Jim Meyering  <jim@meyering.net>
4941
4942         * m4/cycle-check.m4: New file.
4943         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
4944         * m4/dev-ino.m4, m4/same-inode.m4: New files.
4945
4946 2006-08-10  Eric Blake  <ebb9@byu.net>
4947
4948         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
4949         in from original proposal.
4950
4951 2006-08-10  Eric Blake  <ebb9@byu.net>
4952         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
4953
4954         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
4955         namespace.
4956
4957 2006-08-10  Bruno Haible  <bruno@clisp.org>
4958
4959         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
4960         as well.
4961
4962 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
4963
4964         Sync from coreutils.
4965
4966         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
4967
4968         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
4969         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
4970
4971 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
4972
4973         * modules/restrict: Remove; no longer needed now that we assume
4974         Autoconf 2.59 or later.
4975         * MODULES.html.sh: Remove 'restrict'.
4976         * modules/argp (Depends-on): Remove 'restrict'.
4977         * modules/base64 (Depends-on): Likewise.
4978         * modules/gc (Depends-on): Likewise.
4979         * modules/getaddrinfo (Depends-on): Likewise.
4980         * modules/glob (Depends-on): Likewise.
4981         * modules/inet_ntop (Depends-on): Likewise.
4982         * modules/inet_pton (Depends-on): Likewise.
4983         * modules/memxor (Depends-on): Likewise.
4984         * modules/regex (Depends-on): Likewise.
4985         * modules/strtok_r (Depends-on): Likewise.
4986         * modules/time_r (Depends-on): Likewise.
4987
4988 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
4989
4990         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
4991         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
4992         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
4993         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
4994         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
4995         * m4/memxor.m4 (gl_MEMXOR): Likewise.
4996         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
4997         gl_C_RESTRICT replaced by AC_C_RESTRICT.
4998
4999         Merge from coreutils.
5000         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
5001         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
5002         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
5003         * m4/time_r.m4 (gl_TIME_R): Likewise.
5004
5005 2006-08-09  Karl Berry  <karl@gnu.org>
5006
5007         * config/srclist.txt: no more gettext-tools, per Bruno.
5008
5009 2006-08-08  Eric Blake  <ebb9@byu.net>
5010
5011         * modules/verror: New module.
5012         * MODULES.html.sh: Document it.
5013
5014 2006-08-08  Eric Blake  <ebb9@byu.net>
5015
5016         * lib/verror.h, lib/verror.c: New files.
5017
5018 2006-08-08  Eric Blake  <ebb9@byu.net>
5019
5020         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
5021         verror_at_line output complies with GNU Coding Standards even when
5022         file is NULL.
5023
5024 2006-08-07  Bruno Haible  <bruno@clisp.org>
5025
5026         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
5027         versions of AIX.
5028         Reported by Ralf Wildenhues.
5029
5030 2006-08-07  Bruno Haible  <bruno@clisp.org>
5031
5032         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
5033         in an AC_DEFUN. Needed so that the autoconf snippets can use
5034         AC_REQUIRE.
5035
5036 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5037
5038         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5039         Initialize pkgdata_DATA.
5040         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
5041         overriding it.
5042
5043 2006-08-06  Eric Blake  <ebb9@byu.net>
5044
5045         * lib/error.h: Fold in some upstream changes from glibc.
5046         * lib/error.c: Likewise.
5047
5048 2006-08-04  Bruno Haible  <bruno@clisp.org>
5049
5050         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5051         Make the mostlyclean-local rule depend on mostlyclean-generic.
5052         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
5053
5054 2006-07-31  Bruno Haible  <bruno@clisp.org>
5055
5056         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
5057         <stdlib.h>, <string.h>.
5058
5059 2006-07-30  Bruno Haible  <bruno@clisp.org>
5060
5061         * modules/readlink (License): Change to LGPL.
5062
5063 2006-07-30  Bruno Haible  <bruno@clisp.org>
5064
5065         * modules/javaversion (Makefile.am): Distribute javaversion.java and
5066         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
5067         set PKGDATADIR to point to it.
5068
5069 2006-07-30  Bruno Haible  <bruno@clisp.org>
5070
5071         * modules/csharpexec (configure.ac): Comment out macro invocation.
5072         * modules/javaexec (configure.ac): Likewise.
5073         * modules/javacomp-script (configure.ac): Likewise.
5074
5075         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
5076
5077 2006-07-30  Bruno Haible  <bruno@clisp.org>
5078
5079         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
5080         linked-list.
5081
5082 2006-07-30  Bruno Haible  <bruno@clisp.org>
5083
5084         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
5085
5086 2006-07-30  Bruno Haible  <bruno@clisp.org>
5087
5088         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5089         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
5090         get removed.
5091
5092 2006-07-29  Bruno Haible  <bruno@clisp.org>
5093
5094         Make it possible for gnulib-tool to work with locally modified or
5095         augmented gnulib repositories.
5096         * gnulib-tool (func_usage): Document --local-dir option.
5097         (local_gnulib_dir): New variable.
5098         Handle --local-dir option.
5099         (func_lookup_file): New function.
5100         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
5101         (func_get_description, func_get_filelist, func_get_description,
5102         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
5103         func_get_automake_snippet, func_get_include_directive,
5104         func_get_license, func_get_maintainer): Use func_lookup_file.
5105         (func_import, func_create_testdir): Use func_lookup_file.
5106
5107 2006-07-29  Bruno Haible  <bruno@clisp.org>
5108
5109         * modules/setenv (Depends-on): Add unistd.
5110
5111 2006-07-29  Bruno Haible  <bruno@clisp.org>
5112
5113         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
5114
5115 2006-07-29  Bruno Haible  <bruno@clisp.org>
5116
5117         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
5118
5119 2006-07-29  Bruno Haible  <bruno@clisp.org>
5120
5121         * gnulib-tool (import, update): If there is no Makefile.am, look at
5122         aclocal.m4, instead of bailing out.
5123
5124 2006-07-29  Bruno Haible  <bruno@clisp.org>
5125
5126         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
5127         Categorize the options by when they are useful.
5128
5129 2006-07-29  Bruno Haible  <bruno@clisp.org>
5130
5131         * gnulib-tool (func_usage): Document option --no-libtool.
5132         Handle option --no-libtool.
5133         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
5134         for changed semantics of $libtool variable.
5135         (func_import): Likewise. If libtool is not used, show this through
5136         an option --no-libtool.
5137         (func_create_testdir): Update.
5138
5139 2006-07-29  Bruno Haible  <bruno@clisp.org>
5140
5141         * gnulib-tool (func_import): Extend error message about missing
5142         --doc-base.
5143
5144 2006-07-29  Bruno Haible  <bruno@clisp.org>
5145
5146         * gnulib-tool (func_import): Don't create the $docbase directory if
5147         there is no file to store there.
5148
5149 2006-07-29  Bruno Haible  <bruno@clisp.org>
5150
5151         * gnulib-tool (autoconf_minversion): If a --dir option is given and
5152         relevant, look for configure.ac there, not in the current directory.
5153         Also use a simple search for AC_PREREQ, not "autoconf --trace".
5154
5155 2006-07-29  Bruno Haible  <bruno@clisp.org>
5156
5157         * gnulib-tool (SORT): New variable.
5158         (func_usage): Undocument --assume-autoconf option.
5159         Remove --assume-autoconf option handling.
5160         (autoconf_minversion): Determine from the contents of configure.ac.
5161         (func_import): Remove autoconf_minversion handling.
5162         Suggested by Eric Blake.
5163
5164 2006-07-29  Bruno Haible  <bruno@clisp.org>
5165
5166         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
5167
5168 2006-07-29  Bruno Haible  <bruno@clisp.org>
5169
5170         * config/srclist.txt (*setenv.[ch]): Remove rules.
5171
5172 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5173
5174         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
5175
5176 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5177
5178         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
5179         arpa/inet.h.
5180
5181 2006-07-28  Simon Josefsson  <jas@extundo.com>
5182
5183         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
5184         * modules/inet_pton (Depends-on): Likewise.
5185
5186 2006-07-28  Simon Josefsson  <jas@extundo.com>
5187
5188         * m4/netinet_in_h.m4: New file.
5189
5190 2006-07-28  Simon Josefsson  <jas@extundo.com>
5191
5192         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
5193         #include's.
5194
5195 2006-07-28  Simon Josefsson  <jas@extundo.com>
5196
5197         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
5198         #include's.
5199
5200 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
5201
5202         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
5203         setgid on directories only if they set these bits.
5204         * lib/modechange.h: Remove obsolete comment about masks.
5205
5206 2006-07-28  Eric Blake  <ebb9@byu.net>
5207
5208         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
5209         macro expansion.
5210
5211 2006-07-28  Bruno Haible  <bruno@clisp.org>
5212
5213         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
5214
5215 2006-07-28  Bruno Haible  <bruno@clisp.org>
5216
5217         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
5218
5219 2006-07-28  Bruno Haible  <bruno@clisp.org>
5220
5221         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
5222         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
5223         Define fallbacks.
5224         Avoids link error on FreeBSD 4.x.
5225         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
5226
5227         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
5228         encoding.
5229         * lib/mbswidth.c (iswcntrl): Likewise.
5230
5231 2006-07-27  Bruno Haible  <bruno@clisp.org>
5232
5233         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
5234         test.
5235
5236 2006-07-27  Bruno Haible  <bruno@clisp.org>
5237
5238         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
5239         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
5240         defined.
5241
5242 2006-07-26  Eric Blake  <ebb9@byu.net>
5243
5244         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
5245
5246 2006-07-26  Eric Blake  <ebb9@byu.net>
5247
5248         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
5249         like mingw that lack mkstemp.
5250         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
5251         avoid compilation warning on mingw.
5252
5253 2006-07-26  Bruno Haible  <bruno@clisp.org>
5254
5255         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
5256         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
5257         INT_FAST*_MIN, INTPTR_MIN.
5258
5259 2006-07-25  Bruno Haible  <bruno@clisp.org>
5260
5261         * modules/version-etc (Depends-on): Add stdarg.
5262
5263 2006-07-25  Bruno Haible  <bruno@clisp.org>
5264
5265         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
5266         complex commands.
5267
5268 2006-07-25  Bruno Haible  <bruno@clisp.org>
5269
5270         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
5271         defined in <stdarg.h> or config.h.
5272
5273 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5274
5275         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
5276         (gl_STDIO_SAFER): Remove.
5277
5278 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5279
5280         * MODULES.html.sh (File stream based Input/Output):
5281         Add fopen-safer, tmpfile-safer; remove stdio-safer.
5282         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
5283         * modules/fopen-safer, modules/tmpfile-safer: New files.
5284         * modules/stdio-safer: Remove.
5285
5286 2006-07-24  Bruno Haible  <bruno@clisp.org>
5287
5288         * modules/tmpdir: New file.
5289         * MODULES.html.sh (File system functions): Add it.
5290
5291 2006-07-24  Bruno Haible  <bruno@clisp.org>
5292
5293         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
5294         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
5295
5296 2006-07-24  Bruno Haible  <bruno@clisp.org>
5297
5298         * modules/clean-temp: New file.
5299
5300 2006-07-24  Bruno Haible  <bruno@clisp.org>
5301
5302         * m4/tmpdir.m4: New file, from GNU gettext.
5303
5304 2006-07-24  Bruno Haible  <bruno@clisp.org>
5305
5306         * lib/tmpdir.h: New file, from GNU gettext.
5307         * lib/tmpdir.c: New file, from GNU gettext.
5308
5309 2006-07-24  Bruno Haible  <bruno@clisp.org>
5310
5311         * lib/clean-temp.h: New file, from GNU gettext.
5312         * lib/clean-temp.c: New file, from GNU gettext.
5313
5314 2006-07-23  Eric Blake  <ebb9@byu.net>
5315
5316         * modules/stdio-safer (Files): Add tmpfile-safer.c.
5317         (Depends-on): Add binary-io.
5318
5319 2006-07-23  Eric Blake  <ebb9@byu.net>
5320
5321         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
5322
5323 2006-07-23  Eric Blake  <ebb9@byu.net>
5324
5325         * lib/tmpfile-safer.c: New file.
5326         * lib/stdio-safer.h (fopen_safer): Add prototype.
5327         * lib/stdio--.h (tmpfile): Make safer.
5328
5329 2006-07-23  Bruno Haible  <bruno@clisp.org>
5330
5331         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
5332         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
5333         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
5334         gl_linked_remove_at): Use it.
5335
5336 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5337         and Simon Josefsson <jas@extundo.com>
5338
5339         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
5340
5341         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
5342
5343 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5344
5345         * modules/close-stream: New file.
5346         * modules/closeout (Description): Make it clear that it exits
5347         with a diagnostic on error.
5348         (Depends-on): Add close-stream.  Remove fpending, stdbool.
5349         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
5350
5351 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5352
5353         * m4/close-stream.m4: New file.
5354
5355 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5356
5357         * lib/close-stream.c, lib/close-stream.h: New files.
5358
5359 2006-07-22  Bruno Haible  <bruno@clisp.org>
5360
5361         Merge from GNU gettext 0.15.
5362
5363         2006-05-01  Bruno Haible  <bruno@clisp.org>
5364
5365                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
5366
5367         2006-07-22  Bruno Haible  <bruno@clisp.org>
5368
5369                 * modules/javaversion: New file.
5370                 * MODULES.html.sh (Java): Add javaversion.
5371
5372         2006-03-12  Bruno Haible  <bruno@clisp.org>
5373
5374                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
5375
5376         2005-12-04  Bruno Haible  <bruno@clisp.org>
5377
5378                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
5379                 (untested).
5380
5381         2006-06-21  Bruno Haible  <bruno@clisp.org>
5382
5383                 Avoid warnings from recent versions of mcs.
5384                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
5385                 -o, -L, -r any more. Use options documented since mcs-1.0
5386                 instead. Similarly for -g.
5387
5388         2005-12-04  Bruno Haible  <bruno@clisp.org>
5389
5390                 * build-aux/csharpcomp.sh.in: Suffix for resources is
5391                 .resources, not .resource.
5392
5393         2005-07-09  Bruno Haible  <bruno@clisp.org>
5394
5395                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
5396                 add a .dll suffix.
5397                 Reported by Mark Junker <mjscod@gmx.de>.
5398
5399         2006-07-22  Bruno Haible  <bruno@clisp.org>
5400
5401                 * modules/gettext: Upgrade to gettext-0.15.
5402                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
5403                 m4/visibility.m4.
5404                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
5405
5406 2006-07-22  Bruno Haible  <bruno@clisp.org>
5407
5408         Merge from GNU gettext 0.15.
5409
5410         2006-03-25  Bruno Haible  <bruno@clisp.org>
5411
5412                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
5413
5414         2006-07-21  Bruno Haible  <bruno@clisp.org>
5415
5416                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
5417                 "1.1".
5418
5419         2006-05-09  Bruno Haible  <bruno@clisp.org>
5420
5421                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
5422                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
5423                 for the conftestver execution.
5424
5425         2006-05-01  Bruno Haible  <bruno@clisp.org>
5426
5427                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
5428                 optional target-version argument. Verify that the compiler
5429                 groks source of the specified source-version, or add -source
5430                 option as necessary. Verify that the compiler produces
5431                 bytecode in the specified target-version, or add -target and
5432                 -source options as necessary. Make the result of the test
5433                 available as variable CONF_JAVAC. Also log error output in
5434                 config.log.
5435
5436         2006-03-11  Bruno Haible  <bruno@clisp.org>
5437
5438                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
5439
5440         2006-05-09  Bruno Haible  <bruno@clisp.org>
5441
5442                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
5443                 CLASSPATH_SEPARATOR to a semicolon.
5444
5445         2006-03-12  Bruno Haible  <bruno@clisp.org>
5446
5447                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
5448                 available as variable CONF_JAVA, for subsequent autoconf
5449                 tests. Also log error output in config.log.
5450
5451         2006-07-19  Bruno Haible  <bruno@clisp.org>
5452
5453                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
5454                 that getline works on glibc2 systems. Needed to avoid trouble
5455                 in relocatable.c.
5456                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
5457
5458         2005-12-04  Bruno Haible  <bruno@clisp.org>
5459
5460                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
5461                 launcher (untested).
5462
5463         2005-12-04  Bruno Haible  <bruno@clisp.org>
5464
5465                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
5466
5467         2006-07-22  Bruno Haible  <bruno@clisp.org>
5468
5469                 * gettext.m4: Update from GNU gettext-0.15.
5470                 * nls.m4: Likewise.
5471                 * po.m4: Likewise.
5472                 * inttypes-pri.m4: Likewise.
5473                 * inttypes-h.m4: Renamed from inttypes.m4.
5474                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
5475
5476 2006-07-22  Bruno Haible  <bruno@clisp.org>
5477
5478         Merge from GNU gettext 0.15.
5479
5480         2005-07-05  Bruno Haible  <bruno@clisp.org>
5481
5482                 * printf-args.c (printf_fetchargs): Work around broken
5483                 definition of wint_t on mingw.
5484
5485         2005-02-12  Bruno Haible  <bruno@clisp.org>
5486
5487                 * xallocsa.h: Add extern "C" for C++.
5488
5489         2006-05-17  Bruno Haible  <bruno@clisp.org>
5490
5491                 Cygwin portability.
5492                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
5493
5494         2006-04-30  Bruno Haible  <bruno@clisp.org>
5495
5496                 * progreloc.c: Include <mach-o/dyld.h> if available.
5497                 (find_executable): Use _NSGetExecutablePath when possible.
5498
5499         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5500
5501                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
5502                 function.
5503
5504         2005-12-29  Bruno Haible  <bruno@clisp.org>
5505
5506                 * progreloc.c (set_program_name_and_installdir): Fix
5507                 compilation error.
5508
5509         2005-12-04  Bruno Haible  <bruno@clisp.org>
5510
5511                 Cygwin portability.
5512                 * progreloc.c: Include <windows.h> also on Cygwin.
5513                 (find_executable): Add support for Cygwin.
5514                 (set_program_name_and_installdir): Handle also platforms with
5515                 nonempty EXEEXT.
5516
5517         2006-07-11  Bruno Haible  <bruno@clisp.org>
5518
5519                 * javacomp.c: Fix a comment.
5520                 Reported by Jim Meyering.
5521
5522         2006-04-30  Bruno Haible  <bruno@clisp.org>
5523
5524                 * javacomp.h (compile_java_class): Add source_version,
5525                 target_version arguments.
5526                 * javacomp.c: Rewritten to choose only a compiler that
5527                 respects the specified source_version and target_version.
5528
5529         2006-06-27  Bruno Haible  <bruno@clisp.org>
5530
5531                 Assume correct S_ISDIR macro.
5532                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
5533
5534         2006-07-22  Bruno Haible  <bruno@clisp.org>
5535
5536                 * javaversion.h: New file, from GNU gettext.
5537                 * javaversion.c: New file, from GNU gettext.
5538                 * javaversion.java: New file, from GNU gettext.
5539                 * javaversion.class: New file, from GNU gettext.
5540
5541         2006-05-17  Bruno Haible  <bruno@clisp.org>
5542
5543                 Cygwin portability.
5544                 * javaexec.c (execute_java_class): Test for jview program
5545                 also on Cygwin.
5546
5547         2006-04-09  Bruno Haible  <bruno@clisp.org>
5548
5549                 * fatal-signal.c: Don't include string.h.
5550                 (at_fatal_signal): Use a copying loop instead of memcpy.
5551
5552         2005-12-04  Bruno Haible  <bruno@clisp.org>
5553
5554                 * csharpexec.c: Add support for 'clix' launcher (untested).
5555                 (execute_csharp_using_sscli): New function.
5556                 (execute_csharp_program): Call it.
5557
5558         2006-06-21  Bruno Haible  <bruno@clisp.org>
5559
5560                 Avoid warnings from recent versions of mcs.
5561                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
5562                 -o, -L, -r any more. Use options documented since mcs-1.0
5563                 instead. Similarly for -g.
5564
5565         2005-07-09  Bruno Haible  <bruno@clisp.org>
5566
5567                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
5568                 add a .dll suffix.
5569                 Reported by Mark Junker <mjscod@gmx.de>.
5570
5571         2006-06-17  Bruno Haible  <bruno@clisp.org>
5572
5573                 * config.charset: Update for NetBSD 3.0.
5574
5575         2006-05-17  Bruno Haible  <bruno@clisp.org>
5576
5577                 Cygwin portability.
5578                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
5579
5580         2006-05-16  Bruno Haible  <bruno@clisp.org>
5581
5582                 * localcharset.c [CYGWIN]: Include <windows.h>.
5583                 (get_charset_aliases): For Cygwin, return the same CPxxx
5584                 aliases list as under WIN32.
5585                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
5586                 the environment variables. Fall back to GetACP().
5587
5588         2006-04-05  Bruno Haible  <bruno@clisp.org>
5589
5590                 * config.charset: Update Juan Manuel Guerrero's address.
5591
5592         2005-02-12  Bruno Haible  <bruno@clisp.org>
5593
5594                 * allocsa.h: Add extern "C" for C++.
5595
5596         2005-02-10  Bruno Haible  <bruno@clisp.org>
5597
5598                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
5599                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
5600
5601         2006-07-22  Bruno Haible  <bruno@clisp.org>
5602
5603                 * gettext.h: Update to GNU gettext-0.15.
5604
5605 2006-07-22  Bruno Haible  <bruno@clisp.org>
5606
5607         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
5608         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
5609         lib-prefix.m4, longdouble.m4, ssize_t.m4.
5610
5611 2006-07-21  Eric Blake  <ebb9@byu.net>
5612
5613         * modules/stdlib-safer: New file.
5614         * MODULES.html.sh (File stream based Input/Output): Add
5615         stdlib-safer.
5616
5617 2006-07-21  Eric Blake  <ebb9@byu.net>
5618
5619         * lib/stdlib-safer.h: New file from coreutils, required by
5620         stdlib--.h.
5621
5622 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
5623
5624         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
5625
5626 2006-07-20  Bruno Haible  <bruno@clisp.org>
5627
5628         * gnulib-tool: Recognize new option --assume-autoconf.
5629         (autoconf_minversion): New variable.
5630         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
5631
5632 2006-07-20  Bruno Haible  <bruno@clisp.org>
5633
5634         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
5635
5636 2006-07-19  Derek R. Price  <derek@ximbiot.com>
5637
5638         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
5639         Reindent and repaginate.
5640
5641 2006-07-19  Derek Price  <derek@ximbiot.com>
5642
5643         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
5644         Correct grammar.
5645
5646 2006-07-17  Bruno Haible  <bruno@clisp.org>
5647
5648         * modules/list: New file.
5649         * modules/array-list: New file.
5650         * modules/carray-list, modules/carray-list-tests: New files.
5651         * modules/linked-list, modules/linked-list-tests: New files.
5652         * modules/avltree-list, modules/avltree-list-tests: New files.
5653         * modules/rbtree-list, modules/rbtree-list-tests: New files.
5654         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
5655         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
5656         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
5657         * modules/oset: New file.
5658         * modules/array-oset: New file.
5659         * modules/avltree-oset, modules/avltree-oset-tests: New files.
5660         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
5661         * tests/test-carray_list.c: New file.
5662         * tests/test-linked_list.c: New file.
5663         * tests/test-avltree_list.c: New file.
5664         * tests/test-rbtree_list.c: New file.
5665         * tests/test-linkedhash_list.c: New file.
5666         * tests/test-avltreehash_list.c: New file.
5667         * tests/test-rbtreehash_list.c: New file.
5668         * tests/test-avltree_oset.c: New file.
5669         * tests/test-rbtree_oset.c: New file.
5670         * MODULES.html.sh (Container data structures): New section.
5671
5672 2006-07-17  Bruno Haible  <bruno@clisp.org>
5673
5674         * m4/gl_list.m4: New file.
5675
5676 2006-07-17  Bruno Haible  <bruno@clisp.org>
5677
5678         * lib/gl_list.h: New file.
5679         * lib/gl_list.c: New file.
5680         * lib/gl_array_list.h: New file.
5681         * lib/gl_array_list.c: New file.
5682         * lib/gl_carray_list.h: New file.
5683         * lib/gl_carray_list.c: New file.
5684         * lib/gl_linked_list.h: New file.
5685         * lib/gl_linked_list.c: New file.
5686         * lib/gl_anylinked_list1.h: New file.
5687         * lib/gl_anylinked_list2.h: New file.
5688         * lib/gl_avltree_list.h: New file.
5689         * lib/gl_avltree_list.c: New file.
5690         * lib/gl_anyavltree_list1.h: New file.
5691         * lib/gl_anyavltree_list2.h: New file.
5692         * lib/gl_rbtree_list.h: New file.
5693         * lib/gl_rbtree_list.c: New file.
5694         * lib/gl_anyrbtree_list1.h: New file.
5695         * lib/gl_anyrbtree_list2.h: New file.
5696         * lib/gl_anytree_list1.h: New file.
5697         * lib/gl_anytree_list2.h: New file.
5698         * lib/gl_linkedhash_list.h: New file.
5699         * lib/gl_linkedhash_list.c: New file.
5700         * lib/gl_anyhash_list1.h: New file.
5701         * lib/gl_anyhash_list2.h: New file.
5702         * lib/gl_avltreehash_list.h: New file.
5703         * lib/gl_avltreehash_list.c: New file.
5704         * lib/gl_rbtreehash_list.h: New file.
5705         * lib/gl_rbtreehash_list.c: New file.
5706         * lib/gl_anytreehash_list1.h: New file.
5707         * lib/gl_anytreehash_list2.h: New file.
5708
5709         * lib/gl_oset.h: New file.
5710         * lib/gl_oset.c: New file.
5711         * lib/gl_array_oset.h: New file.
5712         * lib/gl_array_oset.c: New file.
5713         * lib/gl_avltree_oset.h: New file.
5714         * lib/gl_avltree_oset.c: New file.
5715         * lib/gl_rbtree_oset.h: New file.
5716         * lib/gl_rbtree_oset.c: New file.
5717         * lib/gl_anytree_oset.h: New file.
5718
5719 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5720
5721         * m4/mkancesdirs.m4: New file.
5722         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
5723         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
5724         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
5725         it.
5726
5727 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5728
5729         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
5730         * lib/mkancesdirs.h: New files.
5731         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
5732         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
5733         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
5734         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
5735         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
5736         callers changed.  Revamp internals significantly, by not
5737         attempting to create directories that are temporarily more
5738         permissive than the final results.  Do not attempt to use
5739         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
5740         This removes some race conditions, fixes some bugs, and simplifies
5741         things.  Use new dirchownmod function to do owner and mode changes.
5742         * lib/mkdir-p.h: Likewise.
5743         * lib/modechange.c (octal_to_mode): New function.
5744         (struct mode_change): New member mentioned.
5745         (make_node_op_equals): New arg mentioned.  All callers changed.
5746         (mode_compile): Keep track of which mode bits the user has explicitly
5747         mentioned.
5748         (mode_adjust): New arg DIR, so that we implement the X op correctly.
5749         New arg PMODE_BITS, to keep track of which mode bits the user
5750         mentioned; it treats S_ISUID and S_ISGID speciall.
5751         All callers changed.
5752         * lib/modechange.h: Likewise.
5753
5754 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
5755
5756         * MODULES.html.sh: Add mkancestors.
5757         * modules/mkancesdirs: New module.
5758         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
5759         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
5760         The chdir-safer and afs files are now orphans; I'll remove them
5761         unless someone speaks up.
5762         Add lib/dirchownmod.c, lib/dirchownmod.h.
5763         (Depends-on): Remove alloca, chown, save-cwd, dirname.
5764         Add lchown, mkancesdirs.
5765         (Maintainer): Add self.
5766
5767 2006-07-15  Karl Berry  <karl@gnu.org>
5768
5769         * gnulib-tool: help message wording/arrangement.
5770
5771 2006-07-14  Simon Josefsson  <jas@extundo.com>
5772
5773         * doc/gnulib.texi (Libtool and Windows): New section.
5774
5775 2006-07-12  Simon Josefsson  <jas@extundo.com>
5776
5777         * modules/gendocs (License): Fix license, approved by Karl.
5778
5779 2006-07-12  Eric Blake  <ebb9@byu.net>
5780
5781         * MODULES.html.sh: Add gendocs.
5782
5783 2006-07-11  Eric Blake  <ebb9@byu.net>
5784
5785         * modules/fdl: New module, to install doc/fdl.texi.
5786         * MODULES.html.sh: Add new section for documentation modules.
5787         * gnulib-tool: Avoid space-tab.
5788         (--doc-base): New option, to manage files from doc.
5789
5790 2006-07-11  Eric Blake  <ebb9@byu.net>
5791
5792         * m4/absolute-header.m4: Fix comments to match recent change.
5793
5794 2006-07-11  Eric Blake  <ebb9@byu.net>
5795
5796         * gnulib-tool: List --doc-base before --tests-base.
5797
5798 2006-07-11  Derek R. Price  <derek@ximbiot.com>
5799
5800         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
5801
5802 2006-07-11  Bruno Haible  <bruno@clisp.org>
5803
5804         * README: Mention where to put documentation.
5805
5806 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5807
5808         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
5809
5810 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5811
5812         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
5813         to stdint.m4.
5814
5815 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
5816
5817         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
5818         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
5819         "no/such/file/stdint.h" when there is no such file, so that
5820         the resulting C code can be parsed by dodgy compilers.
5821         Problems reported by Bob Proulx.
5822
5823 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5824
5825         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
5826         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5827         macros into the GNU _D_EXACT_NAMLEN.
5828         * lib/savedir.c:  Likewise.
5829         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
5830
5831 2006-07-10  Derek R. Price  <derek@ximbiot.com>
5832         and Paul Eggert  <eggert@cs.ucla.edu>
5833
5834         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
5835         * m4/savedir.m4:
5836         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
5837         macros into the GNU _D_EXACT_NAMLEN.
5838
5839 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5840
5841         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
5842         around the absolute name, to work around a problem with the HP-UX
5843         11.23 native C compiler, reported by Bob Proulx.
5844
5845 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5846
5847         * doc/maintain.texi, make-stds.texi: Sync from
5848         <http://savannah.gnu.org/projects/gnustandards>.
5849
5850 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
5851
5852         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
5853
5854 2006-07-09  Jim Meyering  <jim@meyering.net>
5855
5856         * m4/glob.m4: Remove a doubled word in a comment.
5857
5858 2006-07-09  Jim Meyering  <jim@meyering.net>
5859
5860         * lib/argp-pv.c: Remove a doubled word in a comment.
5861         * lib/check-version.c (check_version): Likewise.
5862         * lib/javacomp.c (compile_java_class): Likewise.
5863
5864 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
5865
5866         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
5867         for the benefit of people using Autoconf 2.60.  If you want to
5868         support older Autoconf versions you can copy m4/onceonly_2_57.m4
5869         (or m4/onceonly.m4, if pre-2.57) manually.
5870
5871 2006-07-08  Jim Meyering  <jim@meyering.net>
5872
5873         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
5874         comment.
5875         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
5876         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
5877         comment.
5878
5879 2006-07-08  Jim Meyering  <jim@meyering.net>
5880
5881         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
5882
5883 2006-07-07  Simon Josefsson  <jas@extundo.com>
5884
5885         * tests/test-crc.c: Change expected crc value, the test vector
5886         were probably computed using the old broken crc.c?
5887
5888 2006-07-06  Simon Josefsson  <jas@extundo.com>
5889
5890         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
5891         now the canonical place for the M4 file).
5892
5893         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
5894         from the sys_socket dependency now.
5895
5896         * modules/inet_pton (Files): Ditto.
5897
5898         * modules/inet_ntop (Files): Ditto.
5899
5900 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
5901
5902         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
5903         not gl_PREREQ_GETUSERSHELL.
5904
5905 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5906
5907         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
5908         with only one argument, for Autoconf 2.60.
5909         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
5910         expand to nothing, so add a shell command to avoid syntax error.
5911         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
5912
5913 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5914
5915         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
5916
5917 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5918
5919         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
5920         no longer needed.  Check for isblank decl.
5921         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
5922         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
5923         of existence.
5924
5925 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5926
5927         * lib/getloadavg.c: Use __VMS, not VMS.
5928         * lib/getopt.c: Likewise.
5929         * lib/getpagesize.h: Likewise.
5930         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
5931         and probably does not work.
5932
5933 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
5934
5935         * lib/.cppi-disable: Add wcwidth.
5936         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
5937         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
5938         (ISGRAPH): Remove.  All uses changed to isgraph.
5939         (FOLD) [!defined _LIBC]: Remove special case.
5940         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
5941         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
5942         HAVE_ISBLANK.
5943         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
5944         case.
5945
5946 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
5947
5948         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
5949         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
5950         brackets.  Other minor changes to suppress some compiler
5951         warnings.
5952
5953 2006-07-06  Derek R. Price  <derek@ximbiot.com>
5954         and Paul Eggert  <eggert@cs.ucla.edu>
5955
5956         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
5957         of invoking obsolescent AC_HEADER_DIRENT macro.
5958         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
5959         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
5960         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
5961         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
5962         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
5963         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5964         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
5965         * m4/readdir.m4: Remove; no longer needed.
5966
5967 2006-07-06  Derek R. Price  <derek@ximbiot.com>
5968         and Paul Eggert  <eggert@cs.ucla.edu>
5969
5970         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
5971         Don't worry about this obsolete case any more.
5972         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
5973         directories.
5974         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
5975         worry about this obsolete case any more.
5976         * lib/fts.c: Likewise.
5977         * lib/getcwd.c: Likewise.
5978         * lib/glob.h: Likewise.
5979         * lib/savedir.c: Likewise.
5980
5981 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
5982
5983         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
5984         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
5985         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
5986         needed.
5987         All uses removed.
5988         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
5989         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
5990         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
5991         needed.
5992         * m4/getdate.m4 (gl_GETDATE): Likewise.
5993         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
5994         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
5995         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
5996         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
5997         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
5998         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
5999         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
6000         needed.
6001
6002 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6003
6004         * lib/memcasecmp.c: Include <limits.h>.
6005         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
6006         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
6007         Don't assume isdigit succeeds only on '0' through '9'.
6008
6009 2006-07-05  Eric Blake  <ebb9@byu.net>
6010
6011         * modules/getaddrinfo (Depends-on): Add snprintf.
6012
6013 2006-07-05  Eric Blake  <ebb9@byu.net>
6014
6015         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
6016         to avoid 'header present but could not be compiled' on cygwin.
6017
6018 2006-07-05  Eric Blake  <ebb9@byu.net>
6019
6020         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
6021         missing from netdb.h.
6022         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
6023
6024 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6025
6026         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
6027         no longer needed.
6028         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
6029         * m4/getdate.m4 (gl_GETDATE): Likewise.
6030         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6031         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6032         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6033         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6034         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6035
6036 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6037
6038         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
6039         All uses of is_space replaced by isspace.
6040         * lib/exit.h: Don't talk about STDC_HEADERS.
6041         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
6042         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
6043         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
6044         replaced by isprint etc.
6045         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
6046         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6047         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
6048         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
6049         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
6050         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6051
6052 2006-07-05  Bruno Haible  <bruno@clisp.org>
6053
6054         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
6055         the function exists, before testing against AIX.
6056         Reported by Martin Lambers <marlam@marlam.de>.
6057
6058 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6059
6060         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
6061         From Mark D. Baushke.
6062
6063 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6064
6065         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
6066         to the absolute name, not just one, to bypass Sun C 5.8's
6067         "warning: #include of /usr/include/... may be non-portable".
6068
6069 2006-07-04  Eric Blake  <ebb9@byu.net>
6070
6071         * modules/dirname-tests: New test module.
6072         * tests/test-dirname.c: New file, replacing dirname.c
6073         TEST_DIRNAME section that was recently deleted.
6074
6075 2006-07-04  Bruno Haible  <bruno@clisp.org>
6076
6077         Assume ANSI C header files and <ctype.h> functions.
6078         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
6079         (mbsnwidth): Use isprint, iscntrl instead.
6080
6081 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6082
6083         Merge from coreutils.
6084         * MODULES.html.sh: Add xstrtold.
6085         * modules/xstrtold: New file.
6086         * modules/cycle-check (Files): Add lib/same-inode.h.
6087         * modules/dirname (Files): Add m4/double-slash-root.m4.
6088         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
6089         * modules/mkdir-p (Files): Add lib/same-inode.h.
6090         * modules/same (Files): Add lib/same-inode.h.
6091
6092 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6093
6094         * m4/absolute-header.m4: Renamed from full-header-path.m4.
6095         This is to keep the terminology clean; POSIX talks about
6096         "absolute pathnames", not "full pathnames", but the GNU
6097         Coding Standards say to use "path" for something else;
6098         so use "absolute" to keep both sides happy.
6099         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
6100         Set gl_absolute_header, not gl_full_header_path.
6101         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
6102         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
6103         All uses changed.
6104
6105         Merge from coreutils.
6106
6107         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6108
6109         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
6110         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
6111         want to require the building of c-strtod.o.
6112         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
6113         needs -lm directly.
6114         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
6115
6116         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6117
6118         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
6119         --as-needed option if available.  Problem reported by Albert Chin in
6120         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
6121         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
6122         cc merely issues a bunch of annoying warnings for --as-needed
6123         (this problem was reported by Bob Proulx).  Also, try linking with
6124         -lm to detect a bug in binutils 2.16 (this problem was reported
6125         by Ralf Wildenhues).
6126
6127         2006-06-18  Jim Meyering  <jim@meyering.net>
6128
6129         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
6130         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
6131         macro.
6132         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
6133         also check for glibc-2.4's abort-inducing bug.
6134
6135         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
6136         Low-probability clean-up should be to use rmdir to get rid of
6137         the just-created directory, not unlink.
6138
6139         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
6140         configure fail, and request a bug report to inform us about it.
6141         Add a comment that, barring reports to the contrary, in 2007 we'll
6142         assume ftruncate is universally available.
6143
6144         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6145
6146         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
6147
6148         2006-03-12  Jim Meyering  <jim@meyering.net>
6149
6150         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
6151         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
6152         * m4/same.m4 (gl_SAME): Likewise.
6153         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
6154
6155         2006-03-11  Eric Blake  <ebb9@byu.net>
6156
6157         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
6158         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
6159         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
6160         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
6161
6162 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6163
6164         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
6165         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
6166         reported by Mark D. Baushke, one in
6167         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
6168
6169         Merge from coreutils.
6170
6171         * lib/.cppi-disable: Add stdint_.h.
6172         * lib/.cvsignore: Add stdint.h.
6173
6174         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6175
6176         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
6177         both double and long double versions.
6178         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
6179         * lib/xstrtold.c: New file.
6180         * lib/xstrtod.h (xstrtold): New decl.
6181
6182         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
6183
6184         * lib/filemode.c (setst): Remove.
6185         (strmode): Rewrite to avoid setst.  This makes the code shorter,
6186         (arguably) clearer, and the generated code is a bit smaller on my
6187         Debian GNU/Linux stable x86 host.
6188
6189         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6190
6191         * lib/filemode.c: Include "filemode.h" first, to test the interface.
6192         Assume that filemode.h includes sys/types.h and sys/stat.h.
6193         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
6194         (ftypelet): Reorder to put common cases first, for efficiency.
6195         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
6196         to do 'M'.
6197         (strmode): Renamed from mode_string, and now stores 12 bytes instead
6198         of 10, for compatibility with FreeBSD.  All callers changed.
6199         (filemodestring): Now stores 12 bytes instead of 10, and sets file
6200         types that can't be deduced solely from st_mode.  First arg is now a
6201         const pointer.
6202         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
6203         (strmode): Renamed from mode_string.
6204         (filemodestring): New decl.
6205         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
6206         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
6207         needed.
6208         (S_ISPORT, S_ISWHT): New macros, if not already defined.
6209
6210         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
6211
6212         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
6213         fsusage.h now does that.  Include fsusage.h first, to test interface.
6214         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
6215         at most one method (the old code could have generated decls that
6216         didn't conform to C89, not that this was ever exercised).
6217         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
6218
6219         2006-03-19  Jim Meyering  <jim@meyering.net>
6220
6221         Work even in a chroot where d_ino values for entries in "/"
6222         don't match the stat.st_ino values for the same names.
6223         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
6224         number, iterate through all entries again, using lstat instead.
6225         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
6226         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
6227
6228         * lib/getcwd.c (__getcwd): Clarify a comment.
6229         Use memcpy in place of a call to strcpy.
6230
6231         2006-03-12  Jim Meyering  <jim@meyering.net>
6232
6233         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
6234         matches that of the current directory (which we're about to chdir ".."
6235         out of), then save the dev-ino of the parent, instead.
6236
6237         * lib/same-inode.h (SAME_INODE): New file/macro.
6238         * lib/chdir-safer.c (SAME_INODE): Remove definition.
6239         Include "same-inode.h", instead.
6240         * lib/same.c: Likewise.
6241         * lib/cycle-check.h: Include "same-inode.h".
6242         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
6243         * lib/cycle-check.c (SAME_INODE): Remove definition.
6244         * lib/root-dev-ino.h: Include "same-inode.h".
6245
6246         2006-03-11  Eric Blake  <ebb9@byu.net>
6247
6248         * lib/same.c (same_name): s/base_name/last_component/
6249         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
6250         * lib/filenamecat.c (file_name_concat): Likewise.
6251
6252         2006-03-11  Eric Blake  <ebb9@byu.net>,
6253                     Paul Eggert  <eggert@cs.ucla.edu>
6254
6255         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
6256         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
6257         drive prefix.
6258         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
6259         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
6260         (last_component): New method.
6261         * lib/dirname.c (dir_len): Determine when drive letters need a
6262         subsequent slash.  Preserve // when it is special.
6263         (dir_name): Don't append dot when drive letter is absolute.
6264         [TEST_DIRNAME]: Move into a full-blown gnulib test.
6265         * lib/basename.c (base_name): New semantics - malloc the result.
6266         Preserve // when it is special.  Preserve relative files that look
6267         like drive letters.
6268         (base_len): Preserve // when it is special.
6269         (last_component): New method, similar to old base_name semantics.
6270         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
6271         base_name.  Strip redundant slashes from ///.
6272
6273 2006-07-03  Jim Meyering  <jim@meyering.net>
6274
6275         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
6276         macro is used before the first cycle_check call.
6277
6278 2006-07-03  Eric Blake  <ebb9@byu.net>
6279
6280         * modules/dirname (Depends-on): Add xstrndup.
6281
6282 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6283
6284         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
6285         test cases, so that config.log is a bit easier to follow.
6286
6287 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6288
6289         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
6290         both are 64 bits, since this seems to be the tradition, and this
6291         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
6292         we ever run into a host that prefers long long to long in this
6293         case, we'll need another configure-time test.  Problem reported by
6294         Jim Meyering.
6295
6296 2006-07-02  Eric Blake  <ebb9@byu.net>
6297
6298         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
6299
6300 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6301
6302         * modules/inttypes (Depends-on): No longer depends on stdint.
6303         * modules/stdint (Description): Say more about assumptions.
6304         Say that the fast types might differ.  Say macros are used.
6305         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
6306         (Makefile.am): Revise list of substituted symbols to match
6307         new stdint.m4.
6308         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
6309         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
6310         * tests/test-stdint.c (verify_same_types)
6311         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
6312         the code conforms to C99/C89.
6313         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
6314         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
6315
6316 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6317
6318         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
6319         but fix a bug, by requiring at least 64 bits.
6320         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
6321         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
6322         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
6323         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
6324
6325         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
6326         changes.  Make 2.59 a prerequisite.  Check and substitute for
6327         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
6328         inttypes.h.  Do not use special include files; just use the
6329         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
6330         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
6331         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
6332         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
6333         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
6334         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
6335         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
6336         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
6337         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
6338         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
6339         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
6340         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
6341         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
6342         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
6343         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
6344         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
6345         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
6346         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
6347         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
6348         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
6349         WINT_MAX.  Check for C99 conformance more strictly, by detecting
6350         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
6351         not check for things that C99 does not require, e.g., int8_t.  If
6352         a test isn't needed unless <stdint.h> isn't working, and is
6353         unlikely to be needed for any other reason, then don't do it
6354         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
6355         size_t, since we assume C89 freestanding at least.  Do not check
6356         for sig_atomic_t, wchar_t, or wint_t, since the code now does
6357         the right thing even if the types are not defined.  Instead use:
6358         (gl_STDINT_TYPE_PROPERTIES): New macro.
6359         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
6360         testing whether <sys/types.h> clashes, as Autoconf does this for
6361         us now.  All uses removed.
6362         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
6363         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
6364         (gl_CHECK_TYPE_SAME):
6365         Remove; no longer needed.
6366         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
6367         exists, since we'll return 0 anyway in that case.
6368         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
6369
6370 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6371
6372         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
6373         possible collision with system files.
6374         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
6375         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
6376         WCHAR_MIN and WCHAR_MAX in this case.
6377         (<stddef.h>): Do not include; no longer needed.
6378         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
6379         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
6380         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
6381         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
6382         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
6383         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
6384         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
6385         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
6386         !defined(__c99))]: Include in this case too, since it's harmless
6387         now.
6388         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
6389         dangerous to do so.
6390         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
6391         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
6392         (_STDINT_MIN, _STDINT_MAX): New macros.
6393         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
6394         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
6395         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
6396         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
6397         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
6398         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
6399         macros, not typedefs; this simplifies things quite a bit.
6400         Use long int for all types narrower than int64_t.
6401         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
6402         Define in terms of long long int or int64_t or long int,
6403         not int64_t or int32_t.  This saves some compile-time testing.
6404         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
6405         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
6406         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
6407         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
6408         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
6409         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
6410         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
6411         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
6412         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
6413         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
6414         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6415         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6416         undef any previous version and define our own version, for
6417         simplicity and consistency with the new macros for types.
6418         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6419         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6420         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
6421         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
6422         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
6423         @WINT_T_SUFFIX@ to keep things simple here.
6424         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
6425         Simplify by assuming typical 8/16/32/64 host, since we're
6426         already doing that elsewhere anyway.
6427         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
6428         and assume long long int is 64 bits if available.  This
6429         speeds up 'configure'.
6430
6431 2006-07-01  Eric Blake  <ebb9@byu.net>
6432
6433         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
6434         Reported by Andreas Buening.
6435
6436 2006-07-01  Eric Blake  <ebb9@byu.net>
6437
6438         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
6439
6440 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6441
6442         * lib/getaddrinfo.c: fixed typo
6443
6444 2006-06-29  Jim Meyering  <jim@meyering.net>
6445
6446         * modules/strftime (Maintainer): Add my name, since with the
6447         FPRINTFTIME changes strftime.c has forked from glibc.
6448
6449 2006-06-29  Eric Blake  <ebb9@byu.net>
6450
6451         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
6452
6453 2006-06-29  Eric Blake  <ebb9@byu.net>
6454
6455         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
6456
6457 2006-06-29  Eric Blake  <ebb9@byu.net>
6458
6459         * lib/stat_.h: New file.
6460
6461 2006-06-29  Eric Blake  <ebb9@byu.net>
6462
6463         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
6464         unused static function.
6465
6466 2006-06-29  Eric Blake  <ebb9@byu.net>
6467
6468         * doc/functions.texi (Function Portability): Document missing lstat
6469         on mingw.
6470
6471 2006-06-29  Eric Blake  <ebb9@byu.net>
6472
6473         * MODULES.html.sh: Add sys_stat.
6474         * modules/sys_stat: New module.
6475         * modules/mkstemp (Depends-on): Add sys_stat.
6476
6477 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6478
6479         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
6480
6481 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6482
6483         * m4/c-bs-a.m4: Removed.
6484
6485 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6486
6487         * lib/strftime.c: Assume strftime() exists.
6488
6489 2006-06-29  Derek Price  <derek@ximbiot.com>
6490
6491         * modules/c-bs-a: Removed - \a is C89.
6492         * MODULES.html.sh: Remove c-bs-a.
6493
6494 2006-06-29  Bruno Haible  <bruno@clisp.org>
6495
6496         * modules/wcwidth (License): Change to LGPL.
6497
6498 2006-06-28  Simon Josefsson  <jas@extundo.com>
6499
6500         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
6501         on _WIN32.
6502
6503         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
6504         getnameinfo.
6505
6506 2006-06-28  Simon Josefsson  <jas@extundo.com>
6507
6508         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
6509
6510 2006-06-28  Simon Josefsson  <jas@extundo.com>
6511
6512         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
6513         functions there.  It will succeed on Windows XP, but on Windows
6514         2000 and (presumably) earlier, it will fail, and use the internal
6515         re-implementation.
6516         (use_win32_p): New function.
6517         (getaddrinfo): Use strtoul on servname, to support numeric ports.
6518         Support AI_NUMERICSERV to disable getservbyname.
6519         (getnameinfo): New function, only supports
6520         NI_NUMERICHOST|NI_NUMERICSERV for now.
6521
6522         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
6523         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
6524         getnameinfo.
6525
6526 2006-06-28  Eric Blake  <ebb9@byu.net>
6527
6528         * modules/wcwidth: New file.
6529         * modules/mbchar (Depends-on): Add wcwidth.
6530         * modules/mbswidth (Depends-on): Add wcwidth.
6531         * MODULES.html.sh: Add wcwidth.
6532
6533 2006-06-28  Eric Blake  <ebb9@byu.net>
6534
6535         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
6536         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
6537
6538 2006-06-28  Eric Blake  <ebb9@byu.net>
6539
6540         * lib/xvasprintf.h: Fix comments.
6541
6542 2006-06-28  Eric Blake  <ebb9@byu.net>
6543
6544         * lib/mbchar.h (wcwidth): Include wcwidth.h.
6545         * lib/mbswidth.c (wcwidth): Move from here...
6546         * lib/wcwidth.h: ...to this new file.
6547
6548 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6549
6550         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
6551
6552         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
6553         it's obsolete.
6554         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
6555
6556 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6557
6558         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
6559         Autoconf 2.60 says this stuff was obsolete.
6560
6561 2006-06-28  Bruno Haible  <bruno@clisp.org>
6562
6563         * modules/wcwidth (Files): Add m4/wchar_t.m4.
6564
6565 2006-06-28  Bruno Haible  <bruno@clisp.org>
6566
6567         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
6568         gt_TYPE_WCHAR_T.
6569
6570 2006-06-28  Bruno Haible  <bruno@clisp.org>
6571
6572         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
6573         declaration for wcwidth.
6574         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
6575
6576 2006-06-28  Bruno Haible  <bruno@clisp.org>
6577
6578         * lib/mkdtemp.c [MINGW]: Include <io.h>.
6579         (mkdir): Define using _mkdir.
6580
6581 2006-06-28  Bruno Haible  <bruno@clisp.org>
6582
6583         * lib/getaddrinfo.h: Fix POSIX URL.
6584         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
6585         _WIN32.
6586         (use_win32_p): Make static.
6587         (getaddrinfo): Reject service name if it is empty or does not consist
6588         solely of decimal digits, or if its value is > 65535.
6589         (getnameinfo): Remove useless casts.
6590
6591 2006-06-27  Simon Josefsson  <jas@extundo.com>
6592
6593         * modules/sys_select: New file, suggested by Bruno Haible, Paul
6594         Eggert and Martin Lambers.
6595
6596 2006-06-27  Simon Josefsson  <jas@extundo.com>
6597
6598         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
6599         Eggert and Martin Lambers.
6600
6601 2006-06-27  Bruno Haible  <bruno@clisp.org>
6602
6603         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
6604         result to 0, not to empty.
6605         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
6606
6607 2006-06-27  Bruno Haible  <bruno@clisp.org>
6608
6609         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
6610
6611 2006-06-26  Simon Josefsson  <jas@extundo.com>
6612
6613         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
6614         present.
6615
6616 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
6617
6618         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
6619         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
6620         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
6621
6622 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
6623
6624         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
6625
6626 2006-06-26  Bruno Haible  <bruno@clisp.org>
6627
6628         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
6629
6630 2006-06-26  Bruno Haible  <bruno@clisp.org>
6631
6632         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
6633
6634 2006-06-26  Bruno Haible  <bruno@clisp.org>
6635
6636         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
6637         SGI C compiler in pre-C99 mode.
6638         Suggested by Mark D. Baushke and Larry Jones.
6639
6640 2006-06-26  Bruno Haible  <bruno@clisp.org>
6641
6642         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
6643         WCHAR_MAX.
6644         Reported by Mark D. Baushke and Larry Jones.
6645
6646 2006-06-26  Bruno Haible  <bruno@clisp.org>
6647
6648         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
6649         in pre-C99 mode.
6650         Suggested by Mark D. Baushke and Larry Jones.
6651
6652 2006-06-23  Simon Josefsson  <jas@extundo.com>
6653             Bruno Haible  <bruno@clisp.org>
6654
6655         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
6656         Emit mostlyclean-local rule.
6657         (func_emit_tests_Makefile_am): Likewise.
6658         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
6659
6660 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
6661
6662         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
6663
6664 2006-06-23  Bruno Haible  <bruno@clisp.org>
6665
6666         * tests/test-stdint.c: Update to match ISO C 99 Technical
6667         Corrigendum 1.
6668
6669 2006-06-23  Bruno Haible  <bruno@clisp.org>
6670
6671         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
6672
6673 2006-06-23  Bruno Haible  <bruno@clisp.org>
6674
6675         * lib/stdint_.h: Treat IRIX like OpenBSD.
6676
6677 2006-06-23  Bruno Haible  <bruno@clisp.org>
6678
6679         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
6680         ISO C 99 Technical Corrigendum 1.
6681
6682 2006-06-22  Simon Josefsson  <jas@extundo.com>
6683
6684         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
6685         MinGW.
6686
6687 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
6688
6689         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
6690         needed.  Some compiler complained about some of them.  Problem reported
6691         by Larry Jones in
6692         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
6693
6694 2006-06-21  Simon Josefsson  <jas@extundo.com>
6695
6696         * tests/test-getaddrinfo.c: New file.
6697
6698         * modules/getaddrinfo-tests: New file.
6699
6700         * MODULES.html.sh: Add inet_pton.
6701
6702         * modules/inet_pton: New file.
6703
6704 2006-06-21  Simon Josefsson  <jas@extundo.com>
6705
6706         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
6707         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
6708         of using the (limited) gnulib implementation on Windows XP.
6709
6710         * m4/inet_pton.m4: New file.
6711
6712 2006-06-21  Simon Josefsson  <jas@extundo.com>
6713
6714         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
6715         variable.
6716
6717         * lib/socket_.h: Don't define WINVER.
6718
6719         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
6720         slightly modified to work in gnulib.
6721
6722 2006-06-21  Simon Josefsson  <jas@extundo.com>
6723
6724         * doc/gnulib.texi (Windows sockets): Add.
6725
6726 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
6727
6728         * lib/read-file.c (fread_file): Start with buffer allocation of
6729         0 bytes rather than 1 byte; this simplifies the code.
6730         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
6731         code to free buffer and save/restore errno.
6732         (internal_read_file): Remove unused local.
6733
6734 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
6735
6736         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
6737         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
6738         Problem reported by Denis Excoffier in
6739         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
6740
6741 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6742
6743         * modules/sys_socket, modules/socklen: Include sys/types since
6744         FreeBSD 4.x's sys/socket.h needs it.
6745
6746 2006-06-19  Simon Josefsson  <jas@extundo.com>
6747
6748         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
6749
6750 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6751
6752         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
6753
6754 2006-06-19  Bruno Haible  <bruno@clisp.org>
6755
6756         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
6757         and FULL_PATH_INTTYPES_H in angle brackets.
6758         Reported by Mark D. Baushke <mdb@gnu.org>.
6759
6760 2006-06-17  Eric Blake  <ebb9@byu.net>
6761
6762         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
6763         errno.
6764
6765 2006-06-17  Bruno Haible  <bruno@clisp.org>
6766
6767         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
6768         <sys/inttypes.h>.
6769
6770 2006-06-17  Bruno Haible  <bruno@clisp.org>
6771
6772         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
6773         whether errno is declared. Assume <errno.h> declares errno.
6774
6775 2006-06-17  Bruno Haible  <bruno@clisp.org>
6776
6777         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
6778
6779 2006-06-17  Bruno Haible  <bruno@clisp.org>
6780
6781         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
6782         problem on Solaris 2.5.1.
6783
6784 2006-06-16  Eric Blake  <ebb9@byu.net>
6785
6786         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
6787         * lib/unicodeio.c [!defined errno]: Likewise.
6788         * lib/strtol.c [!defined errno]: Likewise.
6789         * lib/strtod.c [!defined errno]: Likewise.
6790
6791 2006-06-15  Eric Blake  <ebb9@byu.net>
6792
6793         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
6794
6795 2006-06-15  Eric Blake  <ebb9@byu.net>
6796
6797         * config/srclist.txt (ssize_t.m4): Lose sync.
6798
6799 2006-06-15  Bruno Haible  <bruno@clisp.org>
6800
6801         * modules/stdint (Files): Include m4/full-header-path.m4,
6802         m4/size_max.m4, m4/wchar_t.m4.
6803         (Makefile.am): Many more substitutions.
6804         * modules/stdint-tests: New file.
6805         * tests/test-stdint.c: New file.
6806
6807 2006-06-15  Bruno Haible  <bruno@clisp.org>
6808
6809         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
6810         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
6811         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
6812         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
6813         gl_CHECK_TYPE_SAME): New macros.
6814
6815 2006-06-15  Bruno Haible  <bruno@clisp.org>
6816
6817         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
6818
6819 2006-06-15  Bruno Haible  <bruno@clisp.org>
6820
6821         * lib/stdint_.h: Rewritten to be fully auto-configured.
6822         Fixes bug on HP-UX/IA64.
6823
6824 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
6825
6826         * lib/getdate.y (__attribute__): Don't define if already defined.
6827         Problem reported by Larry Jones.
6828         * lib/utimens.c (__attribute__): Likewise.
6829
6830 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
6831
6832         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
6833         reported by Andreas Schwab.
6834
6835 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6836             Bruno Haible  <bruno@clisp.org>
6837
6838         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
6839         check for the declaration of strnlen and a run test that exposes the
6840         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
6841         rpl_strndup.
6842
6843 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6844             Bruno Haible  <bruno@clisp.org>
6845
6846         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
6847
6848 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6849
6850         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
6851         compile test, for Tru64 4.0D.
6852
6853 2006-05-28  Karl Berry  <karl@gnu.org>
6854
6855         * config/srclist.txt (printf-args.c): lose sync.
6856
6857 2006-05-26  Martin Lambers  <marlam@marlam.de>
6858
6859         * lib/getpass.c: Updates the test for the native W32 API, and adds
6860         missing includes, thus fixing compilation warnings.
6861
6862 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
6863
6864         * lib/exclude.c (exclude_fnmatch): New function.
6865         (excluded_file_name): Call exclude_fnmatch.
6866         * lib/exclude.h (excluded_file_name): New prototype
6867
6868 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
6869
6870         * lib/tempname.c (small_open, large_open): New macros.
6871         (__open, __open64) [!_LIBC]: Remove.
6872         (__gen_tempname): Use small_open and large_open instead of __open
6873         and __open64.  This fixes a portability bug on HP-UX 11.11i
6874         reported by Simon Wing-Tang in
6875         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
6876
6877 2006-05-24  Bruno Haible  <bruno@clisp.org>
6878
6879         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
6880         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
6881         Reported by Thorsten Maerz <torte@netztorte.de> via
6882         Aaron Stone <aaron@serendipity.cx>.
6883
6884 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6885
6886         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
6887         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
6888         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
6889         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
6890         not really conditional on the cache.
6891         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
6892
6893 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
6894
6895         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
6896         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
6897         (my_usleep): Don't mishandle maximum value.
6898
6899 2006-05-19  Jim Meyering  <jim@meyering.net>
6900
6901         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
6902
6903 2006-05-17  Bruno Haible  <bruno@clisp.org>
6904
6905         Cygwin portability.
6906         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
6907
6908 2006-05-17  Bruno Haible  <bruno@clisp.org>
6909
6910         * lib/stdint_.h: Fix recognition of Cygwin.
6911
6912 2006-05-15  Bruno Haible  <bruno@clisp.org>
6913
6914         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
6915         on libtool patch by Ralf Wildenhues.
6916
6917 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
6918
6919         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
6920         test for C99 conformance; (bool) 0.5 is an integer constant
6921         expression, but (bool) -0.5 is not.  Problem reported by Fedor
6922         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
6923
6924 2006-05-11  Simon Josefsson  <jas@extundo.com>
6925
6926         * m4/xvasprintf.m4: Fix obvious typo.
6927
6928 2006-05-11  Jim Meyering  <jim@meyering.net>
6929
6930         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
6931         James Lemley.
6932
6933 2006-05-10  Simon Josefsson  <jas@extundo.com>
6934
6935         * lib/md4.c: Typo fix, update copyright years.
6936         (K1, K2): Don't use L because it turn computations into 64-bit on
6937         64-bit platforms.
6938
6939 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
6940
6941         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
6942         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
6943         unwanted sign propagation, e.g., on hosts with 64-bit int.
6944         There still are some problems with reeelly weird theoretical hosts
6945         (e.g., 33-bit int) but it's not worth worrying about now.
6946         * lib/sha1.c (rol): Likewise.
6947         (K1, K2, K3, K4): Remove unnecessary L suffix.
6948
6949 2006-05-10  Bruno Haible  <bruno@clisp.org>
6950
6951         * lib/des.c: Cast to avoid warnings.
6952
6953 2006-05-09  Bruno Haible  <bruno@clisp.org>
6954
6955         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
6956         (Depends-on): Depend also on xsize, stdarg.
6957         (configure.ac): Add gl_XVASPRINTF.
6958
6959 2006-05-09  Bruno Haible  <bruno@clisp.org>
6960
6961         * m4/xvasprintf.m4: New file.
6962
6963 2006-05-09  Bruno Haible  <bruno@clisp.org>
6964
6965         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
6966         (EOVERFLOW): Define fallback value.
6967         (xstrcat): New function.
6968         (xvasprintf): Recognize the special case of a string concatenation.
6969
6970 2006-05-08  Eric Blake  <ebb9@byu.net>
6971
6972         * gnulib-tool (func_version): Base copyright year on CVS date.
6973         (func_emit_copyright_notice): New function.
6974         (func_emit_lib_Makefile_am): Use it.
6975         (func_emit_tests_Makefile_am): Likewise.
6976         (func_import): Likewise.
6977
6978 2006-05-08  Bruno Haible  <bruno@clisp.org>
6979
6980         * modules/stdarg: New file.
6981         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
6982
6983 2006-05-08  Bruno Haible  <bruno@clisp.org>
6984
6985         * m4/stdarg.m4: New file, from GNU gettext.
6986
6987 2006-05-08  Bruno Haible  <bruno@clisp.org>
6988
6989         * config/srclist.txt (build-aux/config.rpath): different from latest
6990         release.
6991
6992 2006-05-08  Bruno Haible  <bruno@clisp.org>
6993
6994         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
6995
6996 2006-05-05  Jim Meyering  <jim@meyering.net>
6997
6998         * m4/warning.m4: New file, derived from bison's file by the same name.
6999
7000 2006-05-03  Bruno Haible  <bruno@clisp.org>
7001
7002         * lib/stdint_.h: Shorter URL.
7003         * lib/inttypes.h: Likewise.
7004
7005 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7006
7007         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
7008
7009 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7010
7011         * lib/verify.h: Document the internals better.  Most of this change
7012         was written by Bruno Haible.
7013
7014 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7015
7016         * doc/verify.texi: New file, partly based on a proposal by
7017         Bruno Haible.
7018
7019 2006-05-02  Bruno Haible  <bruno@clisp.org>
7020
7021         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
7022         test from here...
7023         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
7024
7025 2006-04-29  Bruno Haible  <bruno@clisp.org>
7026
7027         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
7028         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
7029
7030 2006-04-29  Bruno Haible  <bruno@clisp.org>
7031
7032         * gnulib-tool: Make --update option actually work.
7033
7034 2006-04-29  Bruno Haible  <bruno@clisp.org>
7035
7036         * doc/gcd.texi: New file.
7037         * doc/gnulib.texi: Include it.
7038
7039 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
7040
7041         * lib/getdate.y (get_date): When adding relative date, start with the
7042         initial time, not with the result of the first mktime call.
7043
7044 2006-04-25  Bruno Haible  <bruno@clisp.org>
7045
7046         * gnulib-tool (func_import): Output the include directives in three
7047         blocks, sorted separately.
7048         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7049
7050 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7051
7052         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
7053         to define main with arguments, for C++.  Reported by Eric Blake.
7054         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
7055         Prefer 'int main ()' to 'int main (void)', for C++.
7056         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
7057         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
7058         for 'main', for C99 and C++.
7059
7060 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7061
7062         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
7063         Don't assume that exit status -1 is valid.
7064         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7065         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
7066         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7067         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
7068         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
7069         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
7070         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
7071         functions can be used without declaring them, or that you can
7072         exit with status -1.
7073         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7074
7075 2006-04-24  Karl Berry  <karl@gnu.org>
7076
7077         * config/srclist.txt (longdouble.m4): sync lost.
7078
7079 2006-04-24  Eric Blake  <ebb9@byu.net>
7080
7081         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
7082
7083 2006-04-24  Bruno Haible  <bruno@clisp.org>
7084
7085         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
7086         poll() implementation in AIX.
7087         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7088
7089 2006-04-24  Bruno Haible  <bruno@clisp.org>
7090
7091         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
7092         assigned exactly once.
7093
7094 2006-04-23  Claudio Fontana  <claudio@gnu.org>
7095             Bruno Haible  <bruno@clisp.org>
7096
7097         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
7098         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
7099         for AM_CPPFLAGS.
7100
7101 2006-04-23  Bruno Haible  <bruno@clisp.org>
7102
7103         * modules/copy-file: Depend on unistd.
7104         * modules/execute: Likewise.
7105         * modules/fatal-signal: Likewise.
7106         * modules/findprog: Likewise.
7107         * modules/mkdtemp : Likewise.
7108         * modules/pipe: Likewise.
7109         * modules/wait-process: Likewise.
7110
7111 2006-04-23  Bruno Haible  <bruno@clisp.org>
7112
7113         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
7114         condition was already detected.
7115         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7116
7117 2006-04-23  Bruno Haible  <bruno@clisp.org>
7118
7119         * lib/copy-file.c: Include <unistd.h> unconditionally.
7120         * lib/execute.c: Likewise.
7121         * lib/fatal-signal.c: Likewise.
7122         * lib/findprog.c: Likewise.
7123         * lib/mkdtemp.c: Likewise.
7124         * lib/pipe.h: Likewise.
7125         * lib/pipe.c: Likewise.
7126         * lib/wait-process.h: Likewise.
7127
7128 2006-04-23  Bruno Haible  <bruno@clisp.org>
7129
7130         * gnulib-tool (func_usage): Fix --import description. Document
7131         --update.
7132         (func_import): Create temporary file in a temporary directory, if
7133         --dry-run is specified. Silence errors from 'grep' when there are no
7134         m4 files in $m4dir.
7135         (func_create_testdir): Silence errors from 'grep' when there are no
7136         m4 files in $m4dir.
7137         Reported by Karl Berry <karl@freefriends.org>.
7138
7139 2006-04-20  Bruno Haible  <bruno@clisp.org>
7140
7141         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
7142         one argument, so that the code will be portable to Autoconf 2.60.
7143         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
7144         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7145         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
7146
7147 2006-04-19  Derek Price  <derek@ximbiot.com>
7148             Eric Blake  <ebb9@byu.net>
7149
7150         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
7151         rather than "/full/path.h".  Update comment to match.  Shorten &
7152         generalize m4_translit call via AS_TR_CPP.
7153
7154 2006-04-19  Derek Price  <derek@ximbiot.com>
7155             Eric Blake  <ebb9@byu.net>
7156
7157         * lib/inttypes.h: Correct grammar in comment.
7158
7159 2006-04-18  Derek Price  <derek@ximbiot.com>
7160             Paul Eggert  <eggert@cs.ucla.edu>
7161
7162         * modules/inttypes: New file.
7163         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
7164
7165 2006-04-18  Derek Price  <derek@ximbiot.com>
7166             Paul Eggert  <eggert@cs.ucla.edu>
7167
7168         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
7169         New files.
7170
7171 2006-04-18  Derek Price  <derek@ximbiot.com>
7172             Paul Eggert  <eggert@cs.ucla.edu>
7173
7174         * lib/inttypes.h: New file.
7175         * lib/strtoimax.c: Assume <inttypes.h>.
7176
7177 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
7178
7179         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
7180         isn't mounted.  Problem reported by Kir Kolyshkin.
7181
7182 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
7183
7184         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
7185         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
7186         Derek R. Price.
7187         * lib/regex.h (RE_DUP_MAX): Update comment to match current
7188         implementation.
7189
7190 2006-04-12  Eric Blake  <ebb9@byu.net>
7191
7192         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
7193         is now done automatically by the corresponding Autoconf macro.
7194
7195 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
7196
7197         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
7198         time_r.h.
7199
7200 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7201
7202         Merge regex changes from libc, removing some of our
7203         POSIX-conformance changes that were rejected and redoing them in a
7204         less-intrusive way.
7205
7206         * lib/regcomp.c (re_compile_internal, init_dfa):
7207         Length arg is now size_t, not Idx.  All uses changed.
7208         (peek_token): Forward decl now says internal_function.
7209         (__re_error_msgid, __re_error_msgid_idx):
7210         Now static rather than extern with attribute_hidden.
7211         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
7212         For some reason libc prefers K&R style defns for external functions.
7213         (regerror) [!defined _LIBC]: Likewise.
7214         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
7215         (seek_collating_symbol_entry, lookup_collation_sequence_value):
7216         (build_range_exp, build_collating_symbol):
7217         Use K&R-style defn.
7218         (re_compile_fastmap): Use '\0' to memset, not 0.
7219         (utf8_sb_map): Make the calculations more obvious.
7220         (init_dfa, parse_bracket_exp, build_charclass_op):
7221         Call calloc and cast result, as glibc does.
7222         (init_word_char, fetch_token, peek_token, peek_token_bracket):
7223         (build_range_exp, build_collating_symbol):
7224         Now internal functions.
7225
7226         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
7227
7228         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
7229         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
7230         Don't depend on VMS; depend on __VMS instead, for POSIX
7231         namespace cleanness.
7232         (regoff_t): Define to ssize_t, not long int.
7233
7234         Remove the REG_ macros named below.  Instead, make the old names
7235         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
7236         __USE_GNU_REGEX.
7237         (REG_BACKSLASH_ESCAPE_IN_LISTS):
7238         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
7239         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
7240         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
7241         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
7242         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
7243         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
7244         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
7245         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
7246         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
7247         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
7248         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
7249         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
7250         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
7251         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
7252         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
7253         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
7254         (REG_NREGS):
7255         Remove.  All uses replaced by the old RE_* names.
7256         (RE_BACKSLASH_ESCAPE_IN_LISTS):
7257         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
7258         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
7259         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
7260         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
7261         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
7262         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
7263         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
7264         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
7265         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
7266         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
7267         Don't bother having these macros be independent of each others'
7268         values, since they no longer exist in the POSIX name space.
7269
7270         Rename the following member names back to their old names,
7271         unless !__USE_GNU_REGEX.  All uses changed back.
7272         (buffer): Renamed from re_buffer.
7273         (allocated): Renamed from re_allocated.
7274         (used): Renamed from re_used.
7275         (syntax): Renamed from re_syntax.
7276         (fastmap): Renamed from re_fastmap.
7277         (translate): Renamed from re_translate.
7278         (can_be_null): Renamed from re_can_be_null.
7279         (regs_allocated): Renamed from re_regs_allocated.
7280         (fastmap_accurate): Renamed from re_fastmap_accurate.
7281         (no_sub): Renamed from re_no_sub.
7282         (not_bol): Renamed from re_not_bol.
7283         (not_eol): Renamed from re_not_eol.
7284         (newline_anchor): Renamed from re_newline_anchor.
7285         (num_regs): Renamed from rm_num_regs.
7286         (start): Renamed from rm_start.
7287         (end): Renamed from rm_end.
7288
7289         (free_state): Move up a bit.
7290
7291         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
7292         #define to be empty.
7293         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
7294         when that is what is intended.
7295         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
7296         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
7297         (MAX): New macro.
7298         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
7299         All uses changed back to re_malloc, etc.  It's now the caller's
7300         responsibility to check for overflow; all callers changed.
7301         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
7302         (re_x2nrealloc): Remove.
7303         (free_state): Remove decl.
7304
7305         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
7306         (re_set_registers, re_exec):
7307         Use K&R-style defn.
7308
7309         2006-01-31  Roland McGrath  <roland@redhat.com>
7310
7311         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
7312         Reported by Mike Frysinger <vapier@gentoo.org>.
7313
7314         2006-01-15  Andreas Jaeger  <aj@suse.de>
7315
7316         [BZ #1950]
7317         * lib/regex_internal.c (re_string_reconstruct): Adjust for
7318         build_wcs_upper_buffer change.
7319         (build_wcs_upper_buffer): Change return type.
7320
7321         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
7322
7323         * lib/regex_internal.h: Include <stdint.h> if available.
7324
7325         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
7326
7327         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
7328
7329         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7330
7331         * lib/regcomp.c: Adjust for changed secondary hash function.
7332
7333         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
7334
7335         * lib/regex.h: Pretty printing.
7336         Clean up namespace a bit.
7337
7338         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
7339
7340         * lib/regexec.c (update_cur_sifted_state, check_arrival,
7341         check_arrival_add_next_nodes): Avoid using uninitialized variable.
7342
7343         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7344                     Ulrich Drepper  <drepper@redhat.com>
7345
7346         [BZ #1302]
7347         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
7348         changed.
7349         (bitset_word_t): Renamed from bitset_word.  All uses changed.
7350
7351         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
7352
7353         [BZ #281]
7354         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
7355         * lib/regcomp.c: Remove unnecessary uses of
7356         unsigned RE_TRANSLATE_TYPE.
7357         * lib/regex_internal.h: Likewise.
7358         * lib/regex_internal.c: Likewise.
7359         * lib/regexec.c: Likewise.
7360         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
7361
7362         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
7363
7364         * lib/regexec.c (find_recover_state): Remove unnecessary
7365         initialization.
7366         (transit_state_bkref): Make DFA a const pointer.
7367         (get_subexp): Likewise.
7368         (check_arrival): Likewise.
7369         (update_cur_sifted_state): Likewise.
7370         (re_search_internal): Likewise.
7371         (prune_impossible_nodes): Likewise.
7372         (acquire_init_state_context): Likewise.
7373         (proceed_next_node): Likewise.
7374         (set_regs): Likewise.
7375         (free_fail_stack_return): Likewise.
7376         (check_arrival_expand_ecl): Mark DFA parameter as const.
7377         (check_arrival_expand_ecl_sub): Likewise.
7378         (check_subexp_limits): Likewise.
7379         (sub_epsilon_src_nodes):  Likewise.
7380         (add_epsilon_src_nodes):  Likewise.
7381         (merge_state_array): Likewise.
7382         (update_regs): Likewise.
7383         (build_trtable): Likewise.
7384         (sift_states_backward): Mark MCTX parameter as const.
7385         (build_sifted_states): Likewise.
7386         (update_cur_sifted_state): Likewise.
7387         (sift_states_mkref): Likewise.
7388         (check_arrival_expand_ecl): Mark eclosure as const.
7389         (check_dst_limits_calc_pos_1): Likewise.
7390         * lib/regex_internal.h (re_match_context_t): Make dfa a const
7391         pointer.
7392
7393         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
7394
7395         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
7396         (transit_state_sb): Likewise.
7397         (transit_state_mb): Likewise.
7398         (sift_states_iter_mb): Likewise.
7399         (check_arrival_add_next_nodes): Likewise.
7400         (check_node_accept_bytes): Change first parameter to pointer-to-const.
7401         [_LIBC] (re_search_2_stub): Use mempcpy.
7402
7403         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
7404         mbrtowc for very simple UTF-8 case.
7405
7406         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
7407         a pointer-to-const.
7408         (re_acquire_state_context): Likewise.
7409         * lib/regex_internal.h: Adjust prototypes.
7410
7411         * lib/regex.c: Prevent using C++ compilers.
7412
7413         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
7414         (re_acquire_state_context): Likewise.
7415
7416 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7417
7418         * modules/regex (Depends-on): Add ssize_t.
7419
7420 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7421
7422         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
7423         translation table.
7424
7425 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7426
7427         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
7428
7429 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
7430             Bruno Haible  <bruno@clisp.org>
7431
7432         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
7433         <sys/types.h> and <inttypes.h>.
7434
7435 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7436
7437         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
7438         `__error_t_defined', so argp.h will not typedef the former.
7439
7440 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
7441
7442         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
7443         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
7444         glibc names.  Even if glibc is changed to conform to POSIX, the
7445         traditional names will be available anyway, since regex depends on
7446         the extensions module.  Also, fix a longstanding typo in the
7447         implementation of Spencer ERE test #75 from grep 2.3.  Problems
7448         reported by Emanuele Giaquinta.  Also, change sense of cached
7449         variable, so that the message makes sense.
7450
7451 2006-03-24  Simon Josefsson  <jas@extundo.com>
7452
7453         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
7454         including some doc fixes.
7455         (base64_encode_alloc): Fix +1 bug on allocation failures.
7456
7457 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7458
7459         * lib/base64.c (base64_encode): Do not read past end of array with
7460         unsanitized input on systems with CHAR_BIT > 8.
7461
7462 2006-03-24  Eric Blake  <ebb9@byu.net>
7463
7464         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
7465
7466 2006-03-22  Karl Berry  <karl@gnu.org>
7467
7468         * config/srclist.txt (*setenv.[ch]): get from coreutils.
7469         * config/srclistvars.sh (COREUTILS): new var.
7470
7471 2006-03-17  Jim Meyering  <jim@meyering.net>
7472
7473         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
7474         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
7475
7476 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7477
7478         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
7479         no longer needs it.  Instead, check that regoff_t is as least
7480         as wide as ptrdiff_t.
7481
7482         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
7483         so that our regex.h stays compatible with the installed regex.
7484         This is helpful for installers who configure --without-included-regex.
7485         Problem reported by Emanuele Giaquinta.
7486
7487 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7488
7489         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
7490         Typedef to long int, not to off_, as POSIX will likely change
7491         in that direction.
7492
7493 2006-03-15  Eric Blake  <ebb9@byu.net>
7494
7495         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
7496
7497 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7498
7499         * lib/argp-help.c (validate_uparams): Fix typo
7500         * lib/argp-parse.c (argp_default_options): Consistently begin help
7501         messages with a lowercase letter.
7502
7503 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
7504
7505         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
7506         overrun buffers and shouldn't be used (much as gets shouldn't be
7507         used).
7508         * lib/time_r.c (asctime_r, ctime_r): Likewise.
7509
7510 2006-03-08  Simon Josefsson  <jas@extundo.com>
7511
7512         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
7513         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7514
7515 2006-03-08  Simon Josefsson  <jas@extundo.com>
7516
7517         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
7518         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7519
7520 2006-03-08  Simon Josefsson  <jas@extundo.com>
7521
7522         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
7523         signal that configure disabled the device.
7524
7525 2006-03-08  Simon Josefsson  <jas@extundo.com>
7526
7527         * build-aux/maint.mk: Fix refresh-po, to handle no translated
7528         languages.
7529
7530 2006-03-07  Simon Josefsson  <jas@extundo.com>
7531
7532         * modules/getopt (Depends-on): Add unistd.
7533
7534         * modules/unistd: New file.
7535
7536 2006-03-07  Simon Josefsson  <jas@extundo.com>
7537
7538         * modules/gc-random: New file.
7539
7540 2006-03-07  Simon Josefsson  <jas@extundo.com>
7541
7542         * m4/unistd_h.m4: New file.
7543
7544 2006-03-07  Simon Josefsson  <jas@extundo.com>
7545
7546         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
7547         test to be side-effect free by storing the result in the cache
7548         variable gl_cv_lib_readline, and moving the assignment of
7549         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
7550         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7551
7552 2006-03-07  Simon Josefsson  <jas@extundo.com>
7553
7554         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
7555         error on missing devices (the functions will return an error).
7556
7557         * m4/gc.m4: Move random stuff to gc-random.m4
7558
7559 2006-03-07  Simon Josefsson  <jas@extundo.com>
7560
7561         * lib/unistd_.h: New file.
7562
7563 2006-03-07  Simon Josefsson  <jas@extundo.com>
7564
7565         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
7566
7567 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7568
7569         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
7570         Problem reported by Juan Manuel Guerrero.
7571
7572 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7573
7574         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
7575         the unistd module.
7576         * lib/getlogin_r.c: Likewise.
7577         * lib/getlogin_r.h: Likewise.
7578         * lib/glob.c: Likewise.
7579         * lib/pagealign_alloc.c: Likewise.
7580         * lib/unistd_.h: Remove; no longer needed.
7581
7582 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7583
7584         * MODULES.html.sh (Support for systems lacking POSIX:2001):
7585         Add unistd.
7586         * modules/c-stack (Depends-on): Add unistd.
7587         * modules/getlogin_r: Likewise.
7588         * modules/glob: Likewise.
7589         * modules/pagealign_alloc: Likewise.
7590         * modules/unistd (Files): Remove lib/unistd_.h.
7591         (EXTRA_DIST): Remove.
7592         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
7593         need unistd_.h.
7594         (MOSTLYCLEANFILES): Remove unistd.h-t.
7595
7596 2006-03-03  Simon Josefsson  <jas@extundo.com>
7597
7598         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
7599
7600 2006-03-03  Simon Josefsson  <jas@extundo.com>
7601
7602         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
7603         libidn and bison.
7604
7605 2006-03-03  Simon Josefsson  <jas@extundo.com>
7606
7607         * build-aux/maint.mk: Add indent target.
7608
7609 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
7610
7611         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
7612         our replacement poll.h in any case, to avoid a differing
7613         declaration from a system header.  Seen on AIX.
7614
7615 2006-03-01  Simon Josefsson  <jas@extundo.com>
7616
7617         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
7618         <kasal@ucw.cz>.
7619
7620 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7621
7622         * modules/gettime (Depends-on): Add extensions module.
7623         * modules/nanosleep (Depends-on): Likewise.
7624         * modules/settime (Depends-on): Likewise.
7625
7626 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7627
7628         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
7629         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
7630         pedantically.
7631         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7632         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
7633
7634         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
7635         not "==".  Reported by Ralf Wildenhues.
7636
7637 2006-03-01  Karl Berry  <karl@gnu.org>
7638
7639         * doc/Copyright/request-*: new files, synced from gnuorg.
7640
7641 2006-03-01  Karl Berry  <karl@gnu.org>
7642
7643         * config/srclist.txt (Copyright/*): new entries.
7644
7645 2006-02-28  Simon Josefsson  <jas@extundo.com>
7646
7647         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
7648
7649 2006-02-27  Simon Josefsson  <jas@extundo.com>
7650
7651         * lib/base64.h: Indent #define's.  From Jim Meyering
7652         <jim@meyering.net>.
7653
7654 2006-02-27  Jim Meyering  <jim@meyering.net>
7655
7656         Revert the change of 2006-02-24, so these files can continue
7657         to be sync'd from gettext.
7658         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
7659         of `config.h'.
7660
7661 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
7662
7663         * modules/intprops: New file.
7664         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7665         Add intprops.
7666         * modules/getloadavg (Files): Remove lib/intprops.h.
7667         (Depends-on): Add intprops.
7668         * modules/human: Likewise.
7669         * modules/inttostr: Likewise.
7670         * modules/openat: Likewise.
7671         * modules/sig2str: Likewise.
7672         * modules/userspec: Likewise.
7673         * modules/utimecmp: Likewise.
7674         * modules/xnanosleep: Likewise.
7675         * modules/xstrtol: Likewise.
7676
7677 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
7678
7679         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
7680         * modules/lock-tests (TESTS): Use $(EXEEXT).
7681         * modules/tls-tests: Likewise.
7682         * modules/argp-tests: Likewise.
7683         (check_PROGRAMS): New var, replacing...
7684         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
7685
7686 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7687
7688         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
7689         `config.h'.
7690
7691 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
7692
7693         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
7694
7695 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7696
7697         Sync from coreutils.
7698         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
7699         gl_CHDIR_SAFER.
7700
7701 2006-02-22  Jim Meyering  <jim@meyering.net>
7702
7703         Sync from coreutils.
7704         * m4/chdir-safer.m4: New file.
7705
7706 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
7707
7708         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
7709         AT_FDCWD exceeds INT_MAX.
7710         * lib/openat.h (AT_FDCWD): Likewise.
7711
7712 2006-02-17  Eric Blake  <address@hidden>
7713
7714         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
7715
7716 2006-02-16  Simon Josefsson  <jas@extundo.com>
7717
7718         * modules/getaddrinfo (Depends-on): Add sys_socket.
7719
7720 2006-02-15  Simon Josefsson  <jas@extundo.com>
7721
7722         * build-aux/maint.mk: Add dsyntax-check rule.
7723
7724 2006-02-15  Eric Blake  <ebb9@byu.net>
7725
7726         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
7727         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
7728         'present but cannot compile' warnings on cygwin.
7729         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
7730         use ws2tcpip.h if sys/socket.h works.
7731         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
7732         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
7733
7734 2006-02-14  Simon Josefsson  <jas@extundo.com>
7735
7736         * modules/maintainer-makefile (Files): Rename.
7737
7738         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
7739         and (the local) Makefile.cfg to maint-cfg.mk.
7740
7741         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
7742         to the latter.
7743
7744         * modules/maintainer-makefile: New module.
7745
7746         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
7747         severaly stripped to make it possible to build it up from scratch
7748         with reliable tests.
7749
7750         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
7751         fixes to permit overriding the default actions when configure and
7752         makefile are not available.
7753
7754 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
7755
7756         Sync from coreutils.
7757         * modules/lstat (Depends-on): Don't depend on xalloc.
7758         (License): Change from GPL to LGPL, since this is now simply a
7759         replacement for a libc function.
7760
7761 2006-02-14  Jim Meyering  <jim@meyering.net>
7762
7763         Sync from coreutils.
7764
7765         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
7766         failure on deficient systems, and simplify gnulib lgpl dependencies.
7767         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
7768         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
7769
7770         * lib/xalloc-die.c: Remove unused definition of N_.
7771
7772 2006-02-14  Jim Meyering  <jim@meyering.net>
7773
7774         Sync from coreutils.
7775         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
7776         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
7777         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
7778         double-quote uses of that variable, to accommodate the rare case in
7779         which getmntent is available in none of the libraries checked.  This
7780         happens at least on FreeBSD 5.0.
7781
7782 2006-02-13  Simon Josefsson  <jas@extundo.com>
7783
7784         * gnulib-tool (Usage): Fix --import, from
7785         karl@freefriends.org (Karl Berry).
7786
7787 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7788
7789         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
7790
7791 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
7792
7793         * lib/argp-namefrob.h: Restore changes accidentally lost during the
7794         "autoupdate" on 2005-12-12.
7795
7796 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7797
7798         * modules/closeout (Depends-on): Remove atexit.
7799
7800 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
7801
7802         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
7803         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
7804
7805 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
7806
7807         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
7808         __EXTENSIONS__ if this causes compilation to fail.  Problem
7809         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
7810         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
7811
7812 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
7813
7814         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
7815         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
7816         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
7817         All uses changed.
7818
7819 2006-01-26  Simon Josefsson  <jas@extundo.com>
7820
7821         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
7822         prototype is visible on mingw32.
7823
7824         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
7825         for mingw32.
7826
7827         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
7828         mingw32).
7829
7830 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7831
7832         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
7833         attempt to open for write; this always fails, at least on POSIX
7834         hosts.  This reinstates the 2006-01-09 change, which was
7835         inadvertently removed.
7836
7837 2006-01-26  Bruno Haible  <bruno@clisp.org>
7838
7839         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
7840         Reported by Paul Eggert.
7841
7842 2006-01-26  Bruno Haible  <bruno@clisp.org>
7843             Paul Eggert  <eggert@cs.ucla.edu>
7844
7845         * lib/stdbool_.h (_Bool)
7846         [(! (defined __cplusplus || defined __BEOS__)
7847           && !defined __GNUC__
7848           && !(defined __HP_cc || defined __xlc__
7849                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
7850                || defined __sgi))]:
7851         #define to signed char in these cases too; this simplifies
7852         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
7853         etc., separately) and makes it more conservative.
7854
7855 2006-01-25  Simon Josefsson  <jas@extundo.com>
7856
7857         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
7858         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
7859         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
7860
7861 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7862
7863         * lib/argp-namefrob.h: Bugfix. Remove stray #
7864
7865 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
7866
7867         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
7868         so that we test the test.
7869         Check for yet another HP-UX cc bug involving *bool |= bool.
7870
7871 2006-01-25  Karl Berry  <karl@gnu.org>
7872
7873         * config/srclist.txt (vasnprintf.c): sync lost.
7874
7875 2006-01-25  Jim Meyering  <jim@meyering.net>
7876
7877         Sync from the stable (b5) branch of coreutils:
7878
7879         * lib/fts.c (fts_children): Don't let close() clobber errno from
7880         failed fchdir().
7881
7882         * lib/fts.c (fts_stat): When following a symlink-to-directory,
7883         don't necessarily interpret stat-fails+lstat-succeeds as indicating
7884         a dangling symlink.  That can also happen at least for ELOOP.
7885         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
7886         FYI, this bug predates the inclusion of fts.c in coreutils.
7887
7888         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
7889         in their own block, so pre-c99 compilers don't object.
7890
7891         Avoid the double-free (first in fts_read, second in fts_close) that
7892         would occur when an `active' directory is made inaccessible (e.g.,
7893         via chmod a-x) during a traversal.
7894         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
7895         before returning.  Reproduce this failure by
7896         mkdir -p a/b; cd a; chmod a-x . b
7897         Reported by Stavros Passas.
7898
7899 2006-01-25  Jim Meyering  <jim@meyering.net>
7900
7901         * lib/fileblocks.c: Remove more useless parentheses.
7902         * lib/readutmp.h: Likewise.
7903
7904 2006-01-25  Bruno Haible  <bruno@clisp.org>
7905
7906         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
7907         warnings.
7908         Reported by Paul Eggert.
7909
7910 2006-01-25  Bruno Haible  <bruno@clisp.org>
7911
7912         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
7913         rid of a trap command. For Solaris sh.
7914         Reported by Mark D. Baushke <mdb@gnu.org>.
7915
7916 2006-01-24  Simon Josefsson  <jas@extundo.com>
7917
7918         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
7919         Bruno.
7920
7921 2006-01-24  Karl Berry  <karl@gnu.org>
7922
7923         * config/srclist.txt (argp-namefrob.h): sync lost.
7924
7925 2006-01-24  Jim Meyering  <jim@meyering.net>
7926
7927         * modules/openat (Files): Add lib/intprops.h.
7928         From Mark D. Baushke.
7929
7930 2006-01-24  Jim Meyering  <jim@meyering.net>
7931
7932         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
7933         Reported by Mark D. Baushke.
7934
7935 2006-01-24  Jim Meyering  <jim@meyering.net>
7936
7937         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
7938
7939 2006-01-24  Bruno Haible  <bruno@clisp.org>
7940
7941         * modules/strnlen (Maintainer): Change from glibc to all.
7942
7943 2006-01-24  Bruno Haible  <bruno@clisp.org>
7944
7945         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
7946         Patch by Paul Eggert.
7947
7948 2006-01-24  Bruno Haible  <bruno@clisp.org>
7949
7950         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
7951         already has it.
7952         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
7953         2005-11-26.
7954
7955         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
7956         'signed char' to avoid problems with the built-in _Bool type.
7957         Reported by Paul Eggert on 2005-11-26.
7958
7959 2006-01-24  Bruno Haible  <bruno@clisp.org>
7960
7961         * gnulib-tool (func_import): Avoid constructing complicated sed
7962         expressions inside backquote.
7963         Report and solution by Mark D. Baushke <mdb@gnu.org>.
7964
7965 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
7966
7967         These changes imported from libc.
7968         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
7969         test and two separate function calls.
7970         * lib/strndup.c (__strndup): Add libc_hidden_def.
7971
7972 2006-01-23  Simon Josefsson  <jas@extundo.com>
7973
7974         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
7975         Remove the test_*_SOURCES variable: automake infers it by default.
7976         * modules/tls-tests: Likewise.
7977
7978 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7979
7980         Work around porting bugs reported by Dieter in
7981         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
7982         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
7983         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
7984         Include "getopt.h" first, to check interface.
7985         (getenv): Declare only if defined HAVE_DECL_GETENV &&
7986         !HAVE_DECL_GETENV.
7987         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
7988         (__strndup): Revert to K&R-style function dfns, the glibc style.
7989         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
7990         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
7991         Include strnlen.h first, to get prototype properly.
7992         (strnlen): Renamed from __strnlen.
7993         Remove weak alias.
7994
7995 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7996
7997         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
7998
7999 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8000
8001         * config/srclist.txt: Adjust to reflect glibc reorganization.
8002         This affects only comments.
8003
8004 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
8005
8006          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
8007          Reported by Bruce Korb <bkorb@gnu.org>.
8008
8009 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
8010
8011         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
8012         to pacify gcc -Wswitch-default.
8013
8014 2006-01-22  Bruno Haible  <bruno@clisp.org>
8015
8016         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
8017         temporary buffer for sprintf, take into account the precision also
8018         for 'd', 'i', 'u', 'o', 'x', 'X'.
8019
8020 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8021
8022         * modules/argp-tests: New module
8023         * tests/test-argp.c: New file
8024         * tests/test-argp-2.sh: New file
8025
8026 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8027
8028         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
8029         (__argp_base_name): Removed
8030         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
8031         typo.
8032         (__argp_base_name): Provide macro definition or extern declaration
8033         depending on the configuration
8034
8035 2006-01-20  Simon Josefsson  <jas@extundo.com>
8036
8037         * modules/inet_ntop (Depends-on): Depend on sys_socket.
8038
8039 2006-01-20  Simon Josefsson  <jas@extundo.com>
8040
8041         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
8042
8043 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
8044
8045         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
8046         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
8047         Suggested by Bruno Haible.
8048
8049 2006-01-20  Karl Berry  <karl@gnu.org>
8050
8051         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
8052         until changes propagate, I guess.
8053
8054 2006-01-19  Simon Josefsson  <jas@extundo.com>
8055
8056         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
8057
8058 2006-01-19  Simon Josefsson  <jas@extundo.com>
8059
8060         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
8061
8062 2006-01-19  Simon Josefsson  <jas@extundo.com>
8063
8064         * gnulib-tool: Set check_PROGRAMS.
8065
8066         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8067         modules/des-tests, modules/gc-arcfour-tests,
8068         modules/gc-arctwo-tests, modules/gc-des-tests,
8069         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8070         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8071         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8072         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8073         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8074         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
8075         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
8076         test_*_SOURCES.
8077
8078 2006-01-18  Simon Josefsson  <jas@extundo.com>
8079
8080         * modules/socklen (Depends-on): Depend on sys_socket.
8081
8082 2006-01-18  Simon Josefsson  <jas@extundo.com>
8083
8084         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8085         modules/des-tests, modules/gc-arcfour-tests,
8086         modules/gc-arctwo-tests, modules/gc-des-tests,
8087         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8088         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8089         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8090         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8091         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8092         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
8093         $(EXEEXT) to automake TESTS variable, for mingw32.
8094
8095 2006-01-17  Simon Josefsson  <jas@extundo.com>
8096
8097         * modules/socklen (Include): Need sys/socket.h.
8098
8099 2006-01-17  Bruno Haible  <bruno@clisp.org>
8100
8101         * modules/ssize_t (Include): Add <sys/types.h>.
8102
8103 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
8104
8105         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
8106         it's not portable and it doesn't work with cross-compiles.
8107         Problem reported by Bruno Haible.  Fix missing-$ typo in
8108         'test "gl_cv_ignore_unused_libraries" ...' that prevented
8109         -zignore from being used with Sun's C compiler.
8110
8111 2006-01-12  Simon Josefsson  <jas@extundo.com>
8112
8113         * lib/base64.c: Fix warning, reported by Bruno Haible
8114         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
8115
8116 2006-01-12  Bruno Haible  <bruno@clisp.org>
8117
8118         * modules/ldd: New file.
8119         * build-aux/ldd.sh.in: New file.
8120         * MODULES.html.sh (Support for building libraries and executables): Add
8121         ldd.
8122
8123 2006-01-12  Bruno Haible  <bruno@clisp.org>
8124
8125         * m4/ldd.m4: New file.
8126
8127 2006-01-12  Bruno Haible  <bruno@clisp.org>
8128
8129         * gnulib-tool (func_import, func_create_testdir): Don't go into an
8130         endless loop while replacing $auxdir with build-aux.
8131
8132 2006-01-11  Simon Josefsson  <jas@extundo.com>
8133
8134         * lib/stdint_.h (SIZE_MAX): Add missing (.
8135
8136 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
8137
8138         Sync from coreutils.
8139         * lib/md5.c: Fix commentary typos.
8140         (alignof, UNALIGNED_P): No need for a GCC-specific version.
8141         * lib/md5.h (__attribute__): Remove; unused.
8142         * lib/sha1.c: Fix commentary to match md5 better.
8143         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
8144         so that we don't need to worry about alignment.  All uses changed.
8145         This merges the 2005-10-28 md5 change into sha1.
8146
8147 2006-01-11  Jim Meyering  <jim@meyering.net>
8148
8149         Sync from coreutils.
8150         * lib/md5.c (OP): Fix spacing.
8151
8152 2006-01-11  Bruno Haible  <bruno@clisp.org>
8153
8154         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8155         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
8156         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
8157
8158 2006-01-11  Bruno Haible  <bruno@clisp.org>
8159
8160         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8161         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
8162         the "early" section as well.
8163
8164 2006-01-11  Bruno Haible  <bruno@clisp.org>
8165
8166         Avoid "ar: no archive members specified" error on MacOS X.
8167         * gnulib-tool (func_modules_add_dummy): New function.
8168         (func_import, func_create_testdir): Invoke it.
8169
8170 2006-01-11  Bruno Haible  <bruno@clisp.org>
8171
8172         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
8173         with $auxdir in AC_CONFIG_FILES statements.
8174
8175 2006-01-11  Bruno Haible  <bruno@clisp.org>
8176
8177         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8178         Initialize also noinst_HEADERS to empty.
8179
8180 2006-01-11  Bruno Haible  <bruno@clisp.org>
8181
8182         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
8183         variables.
8184         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
8185         autoreconf.
8186
8187 2006-01-11  Bruno Haible  <bruno@clisp.org>
8188
8189         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
8190         overridable by the user.
8191         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8192
8193 2006-01-10  Simon Josefsson  <jas@extundo.com>
8194
8195         * modules/sys_socket: New file.
8196
8197 2006-01-10  Simon Josefsson  <jas@extundo.com>
8198
8199         * m4/sys_socket_h.m4: New file.
8200
8201 2006-01-10  Simon Josefsson  <jas@extundo.com>
8202
8203         * lib/socket_.h: New file.
8204
8205 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8206
8207         * modules/readutmp (Maintainer): Add myself.
8208
8209 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8210
8211         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
8212         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
8213         People who are still concerned with buggy memcmp implementations
8214         can invoke gl_FUNC_MEMCMP themselves.
8215
8216 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8217
8218         * lib/regex_internal.h (BITSET_WORD_BITS):
8219         Work around a bug in 64-bit PGC (before version 6.1-2), where the
8220         preprocessor mishandles large unsigned values as if they were signed.
8221         Problem reported by Claudio Fontana in
8222         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
8223
8224 2006-01-10  Jim Meyering  <jim@meyering.net>
8225
8226         Avoid the double-free (first in fts_read, second in fts_close) that
8227         would occur when an `active' directory is made inaccessible (e.g.,
8228         via chmod a-x) during a traversal.
8229         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8230         before returning.  Reproduce this failure by
8231         mkdir -p a/b; cd a; chmod a-x . b
8232         Reported by Stavros Passas.
8233
8234         Sync from coreutils.
8235         * lib/sha1.c: Tweak grammar in a comment.
8236
8237 2006-01-10  Jim Meyering  <jim@meyering.net>
8238
8239         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
8240         Patch by Joerg Sonnenberger.
8241
8242 2006-01-10  Bruno Haible  <bruno@clisp.org>
8243
8244         * modules/readutmp: Depend on module free.
8245         * modules/strtok_r: Depend on module restrict.
8246
8247 2006-01-10  Bruno Haible  <bruno@clisp.org>
8248
8249         * modules/gettext (configure.ac): Add an invocation of
8250         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
8251
8252 2006-01-10  Bruno Haible  <bruno@clisp.org>
8253
8254         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
8255         Reported by Werner Lemberg <wl@gnu.org>.
8256
8257 2006-01-10  Bruno Haible  <bruno@clisp.org>
8258
8259         * lib/localcharset.c: Update from GNU gettext.
8260
8261 2006-01-10  Bruno Haible  <bruno@clisp.org>
8262
8263         * lib/argp.h (__const): Remove macro. Use const instead.
8264         * lib/argp-fmtstream.h (__const): Likewise.
8265         * lib/glob_.h (__const): Remove macro.
8266         * lib/glob-libc.h: Use const instead of __const.
8267
8268 2006-01-10  Bruno Haible  <bruno@clisp.org>
8269
8270         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
8271         variable.
8272         Needed to avoid an automake error regarding the 'gettext' module.
8273
8274 2006-01-09  Simon Josefsson  <jas@extundo.com>
8275
8276         * modules/inet_ntop (Depends-on): Add restrict.
8277
8278 2006-01-09  Simon Josefsson  <jas@extundo.com>
8279
8280         * modules/gc-rijndael-tests (License): Put under LGPL.
8281
8282         * modules/gc-des-tests (License): Likewise.
8283
8284         * modules/gc-arcfour-tests (License): Likewise.
8285
8286         * modules/gc-arctwo-tests (License): Likewise.
8287
8288         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
8289
8290         * modules/gc-hmac-sha1-tests (Files): Likewise.
8291
8292         * modules/gc-hmac-md5-tests (License): Likewise.
8293
8294         * modules/gc-sha1-tests (License): Likewise.
8295
8296         * modules/gc-md5-tests (License): Likewise.
8297
8298         * modules/gc-md4-tests (License): Likewise.
8299
8300         * modules/gc-md2-tests (License): Likewise.
8301
8302         * modules/gc-tests (License): Likewise.
8303
8304         * modules/des-tests (License): Likewise.
8305
8306         * modules/md4-tests (License): Likewise.
8307
8308         * modules/md2-tests (License): Likewise.
8309
8310 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8311
8312         Sync from coreutils:
8313
8314         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
8315         * modules/lib-ignore: New file.
8316         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
8317         chdir-safer.m4, lchmod.m4.
8318         * modules/openat: Add mkdirat.c, openat-priv.h.
8319
8320 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8321
8322         Sync from coreutils.
8323         * m4/lib-ignore.m4: New file.
8324         * m4/lchmod.m4: New file.
8325
8326 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8327
8328         Sync from coreutils.
8329         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
8330         for write access: POSIX says that must fail.
8331         * lib/fts.c (diropen): Likewise.
8332         * lib/save-cwd.c (save_cwd): Likewise.
8333         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
8334         well, for minor improvements on hosts that lack O_DIRECTORY.
8335         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
8336         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
8337         Fall back on chown if open failed with EACCES.
8338
8339         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
8340         Report an error at compile-time if only a 1-second nominal clock
8341         resolution is found.
8342
8343         * lib/lchmod.h: New file.
8344         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
8345         (make_dir_parents): Use lchown rather than chown, and
8346         lchmod rather than chmod.
8347
8348         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
8349         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
8350         "proc" reported by n0dalus.
8351
8352         * lib/mountlist.c: Include <limits.h>.
8353         (dev_from_mount_options)
8354         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
8355         New function.  It no longer assumes "dev=" has the System V meaning
8356         on Linux (since it doesn't).  It also parses "dev=" more carefully.
8357         (read_file_system_list)
8358         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
8359         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
8360         dev= in that case.
8361
8362         * lib/posixtm.h (PDS_PRE_2000): New macro.
8363         * lib/posixtm.c (year): Arg is now syntax_bits rather than
8364         allow_century.  All usages changed.  Reject dates outside the range
8365         1969-1999 if PDS_PRE_2000 is used.
8366
8367 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8368
8369         Sync from coreutils.
8370         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
8371         (Time of day items): Mention the possibility of leap seconds.
8372         Problem reported by Dr. David Alan Gilbert.
8373
8374 2006-01-09  Jim Meyering  <jim@meyering.net>
8375
8376         Sync from coreutils.
8377
8378         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
8379
8380         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
8381
8382         * lib/modechange.c (mode_compile): Reject an invalid mode string
8383         that starts with an octal digit.  From Andreas Gruenbacher.
8384
8385         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
8386         and dup to open_safer and dup_safer, respectively.
8387         (openat_permissive): Fix typo in comment.
8388
8389         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
8390         "gettext.h"; either no longer needed or are guaranteed by openat.h.
8391         (_): Remove; no longer needed.
8392         (openat): Renamed from rpl_openat; no need for rpl_openat
8393         since openat.h renames openat for us.
8394         Replace most of the body with a call to openat_permissive,
8395         to avoid duplicate code.
8396         Port to (probably hypothetical) environments were mode_t is
8397         wider than int.
8398         (openat_permissive): Require mode arg, so that we can check
8399         types better.  Put it just after flags.  Change cwd failure
8400         indicator from pointer-to-bool to pointer-to-errno-value.
8401         All callers changed.
8402         Invoke openat_save_fail and/or openat_restore_fail if
8403         cwd_errno is null, so that openat can call us.
8404         (openat_permissive, fdopendir, fstatat, unlinkat):
8405         Simplify errno handling to avoid some duplicate code,
8406         as it's OK to set errno on success.
8407         * lib/openat.h: Revamp code so that function macros depend on
8408         __OPENAT_PREFIX only, not also on AT_FDCWD.
8409         (openat_ro): Remove.  Caller changed to use openat_permissive.
8410         (openat_permissive): Now a macro, if not a function.
8411         (openat_restore_fail, openat_save_fail): Now always functions,
8412         since mkdirat needs them even if __OPENAT_PREFIX is defined.
8413
8414         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
8415         and openat.c.
8416         * lib/mkdirat.c: Include openat-priv.h.
8417         Remove definitions of macros defined therein.
8418         * lib/openat.c: Likewise.
8419
8420         * lib/mkdirat.c (mkdirat): New file and function.
8421         * lib/openat.h (mkdirat): Declare.
8422
8423         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
8424
8425         * lib/openat.h (openat_permissive): Declare.
8426         (openat_ro): Define.
8427
8428         * lib/openat.c (EXPECTED_ERRNO): New macro.
8429         (openat_permissive): New function -- used in remove.c rewrite.
8430         (all functions): Set errno just before returning, only if there
8431         was an actual failure.
8432         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
8433
8434         Emulate openat-family functions using Linux's procfs, if possible.
8435         Idea and some code based on Ulrich Drepper's glibc changes.
8436
8437         * lib/openat.c: (BUILD_PROC_NAME): New macro.
8438         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
8439         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
8440         before falling back on save_cwd and restore_cwd.
8441         (fdopendir, fstatat, unlinkat): Likewise.
8442
8443         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
8444         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
8445
8446         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
8447         as second argument to va_arg.  Otherwise, some versions of gcc
8448         warn that `if this code is reached, the program will abort'.
8449
8450 2006-01-09  Jim Meyering  <jim@meyering.net>
8451
8452         Sync from coreutils.
8453         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
8454         Require openat-priv.h.
8455
8456 2006-01-09  Bruno Haible  <bruno@clisp.org>
8457
8458         * modules/strnlen (Include): Use strnlen.h.
8459
8460 2006-01-09  Bruno Haible  <bruno@clisp.org>
8461
8462         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
8463
8464 2006-01-09  Bruno Haible  <bruno@clisp.org>
8465
8466         * lib/sysexit_.h (EX_OK): New macro.
8467         Suggested by Martin Lambers <marlam@marlam.de>.
8468
8469 2006-01-09  Bruno Haible  <bruno@clisp.org>
8470
8471         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
8472         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
8473
8474 2006-01-09  Bruno Haible  <bruno@clisp.org>
8475
8476         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
8477         numbers.
8478
8479 2006-01-09  Bruno Haible  <bruno@clisp.org>
8480
8481         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
8482         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
8483         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
8484         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
8485
8486 2006-01-09  Bruno Haible  <bruno@clisp.org>
8487
8488         * build-aux/javacomp.sh.in: New file, moved from lib/.
8489         * modules/javacomp-script (Files): Update.
8490         (configure.ac): Add AC_CONFIG_FILES invocation.
8491         (EXTRA_DIST): Remove variable.
8492
8493         * build-aux/javaexec.sh.in: New file, moved from lib/.
8494         * modules/javaexec (Files): Update.
8495         (configure.ac): Add AC_CONFIG_FILES invocation.
8496         (EXTRA_DIST): Remove javaexec.sh.in.
8497
8498         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
8499         * modules/csharpcomp-script (Files): Update.
8500         (configure.ac): Add AC_CONFIG_FILES invocation.
8501         (EXTRA_DIST): Remove variable.
8502
8503         * build-aux/csharpexec.sh.in: New file, moved from lib/.
8504         * modules/csharpexec (Files): Update.
8505         (configure.ac): Add AC_CONFIG_FILES invocation.
8506         (EXTRA_DIST): Remove csharpexec.sh.in.
8507
8508 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8509
8510         Sync from coreutils.
8511
8512         Add POSIX ACL support
8513         * lib/acl.h (copy_acl, set_acl): Add declarations.
8514         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
8515         systems other than Linux.
8516         (chmod_or_fchmod): New function: use fchmod when possible,
8517         and chmod otherwise.
8518         (file_has_acl): Add a POSIX ACL implementation, with a
8519         Linux-specific subcase.
8520         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
8521         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
8522         acls are unsupported.
8523         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
8524         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
8525         are unsupported.
8526
8527 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8528
8529         Sync from coreutils.
8530         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
8531
8532 2006-01-07  Bruno Haible  <bruno@clisp.org>
8533
8534         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
8535         gl_EARLY.
8536
8537 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8538
8539         * lib/strftime.c (tzname): Don't declare if it is already #defined.
8540         Problem reported for Mingw by Mark Junker.
8541
8542 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8543
8544         * README: Gnulib normally doesn't generate a tarball.
8545
8546 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
8547
8548         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
8549         long int, not int, for nanosecond counts, so that people who are
8550         used to POSIX struct timespec won't be surprised.  Reported by Jim
8551         Meyering.
8552
8553 2005-12-28  Bruno Haible  <bruno@clisp.org>
8554
8555         * build-aux/config.rpath: Update from GNU gettext.
8556
8557 2005-12-16  Jim Meyering  <jim@meyering.net>
8558
8559         * modules/fprintftime: New module.
8560         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
8561
8562 2005-12-16  Jim Meyering  <jim@meyering.net>
8563
8564         * m4/fprintftime.m4: New file.
8565
8566 2005-12-16  Jim Meyering  <jim@meyering.net>
8567
8568         * lib/fprintftime.c, lib/fprintftime.h: New files.
8569
8570 2005-12-15  Simon Josefsson  <jas@extundo.com>
8571
8572         * modules/socklen (configure.ac): Fix M4 macro name, to align with
8573         new m4/socklen.m4.
8574
8575 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8576
8577         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
8578         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
8579
8580 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8581
8582         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
8583         * lib/argp-help.c (fill_in_uparams): Check if the constructed
8584         struct uparams is valid. Fall back to the default values if it is
8585         not.
8586
8587 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8588
8589         * modules/argp (Files): Add argp-pin.c
8590         (Depends-on): dirname
8591         (lib_SOURCES): Add argp-pin.c
8592
8593 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8594
8595         * m4/argp.m4:  Check if program_invocation_name and
8596         program_invocation_short_name are declared and define appropriate
8597         macros if they are not.
8598
8599 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8600
8601         * lib/argp-help.c (__argp_base_name): New function
8602         (__argp_short_program_name): Rewrite using __argp_base_name
8603         * lib/argp-namefrob.h: Define program_invocation_name and
8604         program_invocation_short_name if requested
8605         (__argp_base_name): Add prototype
8606         * lib/argp-parse.c (argp_def): Use gettext wrappers
8607         (argp_default_parser): Use __argp_base_name
8608         * lib/argp-pin.c: New file. Defines program_invocation_name and
8609         program_invocation_short_name on systems that lack them.
8610
8611 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8612
8613         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
8614         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8615         porting problem reported by Georg Schwarz in
8616         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8617
8618 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8619
8620         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
8621         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8622         porting problem reported by Georg Schwarz in
8623         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8624
8625 2005-12-05  Bruno Haible  <bruno@clisp.org>
8626
8627         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
8628         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
8629         Reported by Mark Junker <mjscod@gmx.de>.
8630
8631 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
8632
8633         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
8634         Use implementation from Albert Chin, with some
8635         comments/corrections by Stepan Kasal and myself.
8636
8637 2005-12-02  Bruno Haible  <bruno@clisp.org>
8638
8639         * gnulib-tool (func_import): Accept GPLed build tool modules when
8640         --lgpl is given.
8641         * modules/csharpcomp-script: New file.
8642         * modules/csharpcomp: Depend on it.
8643         * modules/javacomp-script: New file.
8644         * modules/javacomp: Depend on it.
8645         Suggested by Simon Josefsson.
8646
8647 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
8648
8649         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
8650         statement, to work around an HP-UX 10.20 compiler bug reported by
8651         Peter O'Gorman.
8652
8653 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8654
8655         * modules/savedir (Depends-on): Add openat.
8656
8657 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
8658
8659         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
8660         (uintmax_t) [defined uintmax_t]: Do not declare.
8661         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
8662         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
8663         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
8664         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
8665         sake of portability to weird hosts that C allows (though we don't
8666         know of any practical examples).
8667
8668         * lib/savedir.h (fdsavedir): New decl.
8669         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
8670         contains most of the former guts of savedir.
8671         (savedir): Use savedirstream.
8672         Include "openat.h".
8673
8674 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
8675
8676         * modules/obstack (Files): Add m4/ulonglong.m4.
8677         Problem reported by Davide Angelocola.
8678
8679 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
8680
8681         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
8682         coreutils no longer futzes with rounding modes.
8683
8684 2005-11-14  Jim Meyering  <jim@meyering.net>
8685
8686         * lib/mkstemp-safer.c: Include <config.h>, required for possible
8687         replacement of mkstemp.
8688
8689 2005-11-10  Simon Josefsson  <jas@extundo.com>
8690
8691         * lib/readline.c: Remove EOL.
8692
8693 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8694
8695         * modules/gethrxtime (Depends-on): Add gettime.
8696
8697 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8698
8699         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
8700         or gettimeofday; no longer needed.
8701
8702 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
8703
8704         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
8705         time business.
8706         (gethrxtime) [! (HAVE_NANOUPTIME
8707         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
8708         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
8709         our own approximation.
8710
8711 2005-11-08  Eric Blake  <ebb9@byu.net>
8712
8713         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8714
8715 2005-11-08  Eric Blake  <ebb9@byu.net>
8716
8717         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
8718
8719 2005-11-04  Bruno Haible  <bruno@clisp.org>
8720
8721         * gnulib-tool: Implement --update mode.
8722
8723 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8724
8725         Fix porting problem reported by Theodoros V. Kalamatianos.
8726         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
8727         Don't assume that futimes failing means we must fail.
8728
8729 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
8730
8731         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
8732         variables to suggest the intended function of the PATH_MAX check.
8733
8734 2005-10-30  Kean Johnston  <jkj@sco.com>
8735
8736         Trivial changes to support SCO systems.
8737         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
8738         as PATH_MAX.
8739         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
8740         where __ptr is null when no I/O is pending.
8741
8742 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
8743
8744         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
8745         leave errno alone.  Problem reported by Dmitry V. Levin.
8746
8747 2005-10-28  Simon Josefsson  <jas@extundo.com>
8748
8749         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
8750         Test more.
8751
8752         * tests/test-gc-md2.c, tests/test-md2.c: New files.
8753
8754         * modules/md2, modules/md2-tests: New files.
8755
8756 2005-10-28  Simon Josefsson  <jas@extundo.com>
8757
8758         * m4/inet_ntop.m4: More tests.
8759
8760         * m4/gc-md2.m4, md2.m4: New file.
8761
8762 2005-10-28  Simon Josefsson  <jas@extundo.com>
8763
8764         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
8765         "restrict" keywords, as per POSIX.  Protect the function
8766         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
8767         Don't use K&R prototypes.  Check the sprintf return values.
8768         Re-define EAFNOSUPPORT if not present.  Indent.
8769
8770         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
8771         suggested by Bruno Haible <bruno@clisp.org>.
8772
8773         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
8774
8775         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
8776
8777         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
8778         libgcrypt).
8779
8780         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
8781
8782         * lib/md2.h, lib/md2.c: New files.
8783
8784 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
8785
8786         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
8787         errno alone.  Problem reported by Frederic Jolliton.
8788
8789 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8790
8791         * modules/verify (License): Change from GPL to LGPL.  This is a
8792         tiny module and there are apparently near-equivalents that are
8793         under the BSD license.
8794
8795 2005-10-24  Simon Josefsson  <jas@extundo.com>
8796
8797         * modules/sha1: Relicense to LGPL.
8798
8799 2005-10-24  Simon Josefsson  <jas@extundo.com>
8800
8801         * lib/md4.h: Shrink buffer size, now that we changed the type.
8802
8803 2005-10-23  Simon Josefsson  <jas@extundo.com>
8804
8805         * gnulib-tool (func_import): Fix --tests-base.
8806
8807 2005-10-22  Simon Josefsson  <jas@extundo.com>
8808
8809         * modules/arcfour (Depends-on): Need stdint.
8810
8811 2005-10-22  Simon Josefsson  <jas@extundo.com>
8812
8813         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
8814         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
8815
8816 2005-10-22  Simon Josefsson  <jas@extundo.com>
8817
8818         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
8819         suggested by Bruno Haible <bruno@clisp.org>.
8820
8821 2005-10-22  Simon Josefsson  <jas@extundo.com>
8822
8823         * lib/crc.h: Include stddef.h, for size_t.
8824
8825 2005-10-22  Simon Josefsson  <jas@extundo.com>
8826
8827         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
8828         arcfour_context struct (simplify test vector testing in GNU
8829         Shishi).
8830
8831 2005-10-21  Simon Josefsson  <jas@extundo.com>
8832
8833         * modules/des, modules/des-tests: New files.
8834
8835         * modules/gc-des, modules/gc-des-tests: New files.
8836
8837         * tests/test-des.c, tests/test-gc-des.c: New file.
8838
8839 2005-10-21  Simon Josefsson  <jas@extundo.com>
8840
8841         * modules/arctwo, modules/arctwo-tests: New files.
8842
8843         * tests/test-arctwo.c: New file.
8844
8845         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
8846
8847         * tests/test-gc-arctwo.c: New file.
8848
8849 2005-10-21  Simon Josefsson  <jas@extundo.com>
8850
8851         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
8852         Bruno Haible <bruno@clisp.org>.
8853
8854         * m4/gc-des.m4: New file.
8855
8856 2005-10-21  Simon Josefsson  <jas@extundo.com>
8857
8858         * m4/arctwo.m4: New file.
8859
8860         * m4/gc-arctwo.m4: New file.
8861
8862 2005-10-21  Simon Josefsson  <jas@extundo.com>
8863
8864         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
8865         block.
8866
8867 2005-10-21  Simon Josefsson  <jas@extundo.com>
8868
8869         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
8870         <bruno@clisp.org>.
8871
8872         * lib/hmac-sha1.c (hmac_sha1): Likewise.
8873
8874         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
8875         Bruno Haible <bruno@clisp.org>.
8876
8877         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
8878         <bruno@clisp.org>.
8879
8880 2005-10-21  Simon Josefsson  <jas@extundo.com>
8881
8882         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
8883
8884 2005-10-21  Simon Josefsson  <jas@extundo.com>
8885
8886         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
8887
8888 2005-10-21  Simon Josefsson  <jas@extundo.com>
8889
8890         * lib/des.h, lib/des.c: New files.
8891
8892         * lib/gc-gnulib.c: Support DES.c
8893
8894 2005-10-21  Simon Josefsson  <jas@extundo.com>
8895
8896         * lib/arctwo.h, lib/arctwo.c: New files.
8897
8898         * lib/gc-gnulib.c: Support ARCTWO.
8899
8900 2005-10-21  Simon Josefsson  <jas@extundo.com>
8901
8902         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
8903         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8904
8905 2005-10-21  Simon Josefsson  <jas@extundo.com>
8906
8907         * gnulib-tool (func_import, func_create_testdir): Define automake
8908         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
8909         Makefile.am snippet),
8910         suggested by Bruno Haible <bruno@clisp.org>.
8911
8912         * modules/gc (Makefile.am): Use it.
8913
8914 2005-10-21  Bruno Haible  <bruno@clisp.org>
8915
8916         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
8917         patch.
8918
8919 2005-10-19  Simon Josefsson  <jas@extundo.com>
8920
8921         * tests/test-gc-rijndael.c: New file.
8922
8923         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
8924
8925 2005-10-19  Simon Josefsson  <jas@extundo.com>
8926
8927         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
8928         interface too.
8929
8930 2005-10-19  Simon Josefsson  <jas@extundo.com>
8931
8932         * tests/test-gc-arcfour.c: New file.
8933
8934         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
8935
8936 2005-10-19  Simon Josefsson  <jas@extundo.com>
8937
8938         * modules/gc-md4, modules/gc-md4-tests: New file.
8939
8940         * tests/test-gc-md4.c: New file.
8941
8942 2005-10-19  Simon Josefsson  <jas@extundo.com>
8943
8944         * m4/gc-md4.m4: New file.
8945
8946 2005-10-19  Simon Josefsson  <jas@extundo.com>
8947
8948         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
8949         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
8950         <kasal@ucw.cz>.
8951
8952 2005-10-19  Simon Josefsson  <jas@extundo.com>
8953
8954         * m4/gc-arcfour.m4: New file.
8955
8956         * m4/gc-rijndael.m4: New file.
8957
8958 2005-10-19  Simon Josefsson  <jas@extundo.com>
8959
8960         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
8961
8962 2005-10-19  Simon Josefsson  <jas@extundo.com>
8963
8964         * lib/gc-gnulib.c: Support ARCFOUR.
8965
8966 2005-10-19  Simon Josefsson  <jas@extundo.com>
8967
8968         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
8969         support.
8970
8971         * lib/gc.h: Add ECB enum type.
8972
8973         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
8974
8975 2005-10-18  Simon Josefsson  <jas@extundo.com>
8976
8977         * tests/test-md5.c: New file.
8978
8979         * modules/md5-tests: New file.
8980
8981 2005-10-18  Simon Josefsson  <jas@extundo.com>
8982
8983         * tests/test-md4.c: New file.
8984
8985         * modules/md4, modules/md4-tests: New files.
8986
8987 2005-10-18  Simon Josefsson  <jas@extundo.com>
8988
8989         * m4/md4.m4: New file.
8990
8991 2005-10-18  Simon Josefsson  <jas@extundo.com>
8992
8993         * lib/md4.h, lib/md4.c: New files, based on md5.?.
8994
8995 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
8996
8997         * gnulib-tool (func_create_testdir): Omit the second check whether
8998         BUILT_SOURCES in nonempty.
8999
9000 2005-10-17  Simon Josefsson  <jas@extundo.com>
9001
9002         * tests/test-rijndael.c: New file.
9003
9004 2005-10-17  Simon Josefsson  <jas@extundo.com>
9005
9006         * modules/sha1: Depend on stdint instead of md5.
9007
9008         * modules/md5: Depend on stdint, remove uint32_t.
9009
9010 2005-10-17  Simon Josefsson  <jas@extundo.com>
9011
9012         * modules/gc-sha1-tests: New file.
9013
9014         * tests/test-gc-sha1.c: New file.
9015
9016 2005-10-17  Simon Josefsson  <jas@extundo.com>
9017
9018         * m4/md5.m4: Remove call to uint32_t.m4.
9019
9020 2005-10-17  Simon Josefsson  <jas@extundo.com>
9021
9022         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
9023
9024         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
9025         md5.h.
9026
9027         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
9028
9029         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
9030
9031 2005-10-17  Simon Josefsson  <jas@extundo.com>
9032
9033         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
9034
9035 2005-10-17  Simon Josefsson  <jas@extundo.com>
9036
9037         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
9038
9039 2005-10-17  Simon Josefsson  <jas@extundo.com>
9040
9041         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
9042
9043         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
9044
9045 2005-10-17  Bruno Haible  <bruno@clisp.org>
9046
9047         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
9048         that it can also be used in a test.
9049
9050 2005-10-16  Bruno Haible  <bruno@clisp.org>
9051
9052         * gnulib-tool (func_emit_tests_Makefile_am): Also define
9053         TESTS_ENVIRONMENT, so that individual tests can augment it.
9054
9055         * gnulib-tool (func_create_testdir): Use an intermediate target for
9056         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
9057         macros, like $(ALLOCA_H), which cannot be passed through the command
9058         line.
9059
9060 2005-10-15  Simon Josefsson  <jas@extundo.com>
9061
9062         * modules/rijndael-tests: New file.
9063
9064         * modules/rijndael: New file.
9065
9066 2005-10-15  Simon Josefsson  <jas@extundo.com>
9067
9068         * m4/rijndael.m4: New file.
9069
9070 2005-10-15  Simon Josefsson  <jas@extundo.com>
9071
9072         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
9073
9074         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
9075
9076 2005-10-14  Simon Josefsson  <jas@extundo.com>
9077
9078         * tests/test-arcfour.c: New file.
9079
9080         * modules/arcfour, modules/arcfour-tests: New files.
9081
9082 2005-10-14  Simon Josefsson  <jas@extundo.com>
9083
9084         * m4/arcfour.m4: New file.
9085
9086 2005-10-14  Simon Josefsson  <jas@extundo.com>
9087
9088         * lib/arcfour.h, lib/arcfour.c: New files.
9089
9090 2005-10-14  Roland McGrath  <roland@redhat.com>
9091
9092         Import from libc.  [BZ #1331]
9093         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
9094         macro argument.
9095         Reported by Matej Vela <vela@debian.org>.
9096
9097 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9098
9099         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
9100         include <wchar.h>; no longer needed.
9101
9102 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9103
9104         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
9105
9106 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
9107         and  Ulrich Drepper  <drepper@redhat.com>
9108
9109         Import from libc.
9110         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
9111         instead of inline stream orientation test and two separate
9112         function calls.  Pay no attention to USE_IN_LIBIO.
9113
9114 2005-10-13  Simon Josefsson  <jas@extundo.com>
9115
9116         * modules/gc-hmac-md5-tests: New file.
9117
9118         * tests/test-gc-hmac-sha1.c: New file.
9119
9120         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
9121
9122         * modules/gc-hmac-md5-tests: New file.
9123
9124         * tests/test-gc-md5.c: New file.
9125
9126         * modules/gc-md5-tests: New file.
9127
9128 2005-10-13  Simon Josefsson  <jas@extundo.com>
9129
9130         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
9131         Move memory allocation outside of loop.
9132
9133 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
9134
9135         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
9136         intermediate directory is in a read-only file system.  Problem
9137         reported by Eric Blake.
9138
9139 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
9140
9141         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
9142
9143 2005-10-12  Simon Josefsson  <jas@extundo.com>
9144
9145         * tests/test-hmac-sha1.c: New file.
9146
9147         * modules/hmac-sha1-tests: New file.
9148
9149         * modules/hmac-sha1: New file.
9150
9151 2005-10-12  Simon Josefsson  <jas@extundo.com>
9152
9153         * modules/gc-sha1: New file.
9154
9155 2005-10-12  Simon Josefsson  <jas@extundo.com>
9156
9157         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
9158
9159         * tests/test-gc-pbkdf2-sha1.c: New file.
9160
9161 2005-10-12  Simon Josefsson  <jas@extundo.com>
9162
9163         * modules/gc-md5, modules/gc-hmac-md5: New files.
9164
9165         * modules/gc (Files): Remove md5, memxor and hmac files.
9166
9167 2005-10-12  Simon Josefsson  <jas@extundo.com>
9168
9169         * m4/gc-pbkdf2-sha1.m4: New file.
9170
9171         * m4/gc-hmac-sha1.m4: New file.
9172
9173         * m4/gc-sha1: New file.
9174
9175         * m4/hmac-sha1.m4: New file.
9176
9177 2005-10-12  Simon Josefsson  <jas@extundo.com>
9178
9179         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
9180
9181         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
9182
9183 2005-10-12  Simon Josefsson  <jas@extundo.com>
9184
9185         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
9186         suggested by Bruno Haible <bruno@clisp.org>.
9187
9188 2005-10-12  Simon Josefsson  <jas@extundo.com>
9189
9190         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
9191
9192 2005-10-12  Simon Josefsson  <jas@extundo.com>
9193
9194         * lib/gc-pbkdf2-sha1.c: New file.
9195
9196         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
9197
9198 2005-10-12  Simon Josefsson  <jas@extundo.com>
9199
9200         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
9201
9202         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
9203
9204 2005-10-12  Simon Josefsson  <jas@extundo.com>
9205
9206         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
9207         GC_USE_HMAC_MD5, respectively.
9208
9209         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
9210         (gc_md5): Fix typo.
9211
9212         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
9213
9214         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
9215
9216         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
9217
9218 2005-10-12  Bruno Haible  <bruno@clisp.org>
9219
9220         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
9221         Reported by Stepan Kasal <kasal@ucw.cz>.
9222
9223 2005-10-11  Simon Josefsson  <jas@extundo.com>
9224
9225         * tests/test-crc.c: New file.
9226
9227         * modules/crc, modules/crc-tests: New files.
9228
9229 2005-10-11  Simon Josefsson  <jas@extundo.com>
9230
9231         * m4/crc.m4: New file.
9232
9233 2005-10-11  Simon Josefsson  <jas@extundo.com>
9234
9235         * lib/gc.h: Add gc_hash and gc_hash_buffer.
9236
9237         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
9238
9239         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
9240
9241 2005-10-11  Simon Josefsson  <jas@extundo.com>
9242
9243         * lib/crc.h, lib/crc.c: New files.
9244
9245         * lib/gc.h (gc_hash_buffer): Add doc.
9246
9247 2005-10-11  Bruno Haible  <bruno@clisp.org>
9248
9249         * modules/c-strcasestr: New file.
9250         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
9251
9252 2005-10-11  Bruno Haible  <bruno@clisp.org>
9253
9254         * modules/c-strcase: New file.
9255         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
9256
9257 2005-10-11  Bruno Haible  <bruno@clisp.org>
9258
9259         * lib/strcasecmp.c: Include limits.h.
9260         (strcasecmp): Avoid integer overflow on exotic platforms.
9261         * lib/strncasecmp.c: Include limits.h.
9262         (strncasecmp): Avoid integer overflow on exotic platforms.
9263         Reported by Paul Eggert.
9264
9265 2005-10-11  Bruno Haible  <bruno@clisp.org>
9266
9267         * lib/c-strcasestr.h: New file, from GNU gettext.
9268         * lib/c-strcasestr.c: New file, from GNU gettext.
9269
9270 2005-10-11  Bruno Haible  <bruno@clisp.org>
9271
9272         * lib/c-strcase.h: New file, from GNU gettext.
9273         * lib/c-strcasecmp.c: New file, from GNU gettext.
9274         * lib/c-strncasecmp.c: New file, from GNU gettext.
9275
9276 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9277
9278         * modules/mempcpy (License): GPL -> LGPL.
9279         * modules/strchrnul (License): Likewise.
9280         * modules/sysexits (License): Likewise.
9281
9282 2005-10-08  Simon Josefsson  <jas@extundo.com>
9283
9284         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
9285
9286 2005-10-07  Simon Josefsson  <jas@extundo.com>
9287
9288         * m4/memxor.m4: Remove gl_C_RESTRICT call.
9289
9290 2005-10-06  Simon Josefsson  <jas@extundo.com>
9291
9292         * tests/test-hmac-md5.c: New file.
9293
9294         * modules/hmac-md5-tests: New file.
9295
9296         * modules/hmac-md5: New file.
9297
9298 2005-10-06  Simon Josefsson  <jas@extundo.com>
9299
9300         * m4/hmac-md5.m4: New file.
9301
9302         * m4/memxor.m4: Require gl_C_RESTRICT.
9303
9304 2005-10-06  Simon Josefsson  <jas@extundo.com>
9305
9306         * lib/memxor.c (memxor): Avoid casts and warnings.
9307
9308 2005-10-06  Simon Josefsson  <jas@extundo.com>
9309
9310         * lib/hmac-md5.c: New file.
9311
9312         * lib/hmac.h: New file.
9313
9314 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9315
9316         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
9317         promotes to int, not unsigned int, to catch the AIX 5.3
9318         compiler bug.
9319
9320 2005-10-05  Simon Josefsson  <jas@extundo.com>
9321
9322         * modules/memxor: New file.
9323
9324         * modules/iconv (Files): Move config.rpath to havelib, it is used
9325         there.
9326
9327         * modules/havelib (Files): Add config.rpath.
9328
9329 2005-10-05  Simon Josefsson  <jas@extundo.com>
9330
9331         * m4/memxor.m4: New file.
9332
9333 2005-10-05  Simon Josefsson  <jas@extundo.com>
9334
9335         * lib/memxor.c (memxor): Fix compiler error.
9336
9337         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
9338         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
9339
9340         * lib/memxor.h, lib/memxor.c: New files.
9341
9342         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
9343         we assume all systems have it, suggested by Jim Meyering
9344         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
9345         any systems lack sys/socket.h; mingw32 is known to lack it, but we
9346         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
9347         same reasons.
9348
9349 2005-10-05  Simon Josefsson  <jas@extundo.com>
9350
9351         * config/srclist.txt: Add glibc bug 1423 for md5.h.
9352
9353 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9354
9355         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
9356         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
9357         needed, since the source code now assumes these .h files.
9358
9359 2005-10-05  Derek Price  <derek@ximbiot.com>
9360
9361         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
9362
9363 2005-10-05  Bruno Haible  <bruno@clisp.org>
9364
9365         * modules/stdint (License): Change to LGPL.
9366
9367 2005-10-04  Simon Josefsson  <jas@extundo.com>
9368
9369         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
9370         D. Baushke" <mdb@gnu.org>.
9371
9372 2005-10-04  Bruno Haible  <bruno@clisp.org>
9373
9374         * lib/verify.h (verify_true): Provide alternative definition for C++.
9375
9376 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
9377
9378         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
9379         (SSIZE_MAX): New macro, if not already defined.
9380         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
9381         than 2 GiB.
9382
9383 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9384
9385         Sync from coreutils.
9386         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
9387         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
9388         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
9389         ULLONG_MAX doesn't work with 2.7.2.1.
9390
9391 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9392
9393         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
9394         From Ben Pfaff.
9395
9396         * modules/exclude (Depends-on): Depend on verify.
9397         * modules/strtoimax (Depends-on): Likewise.
9398         * modules/utimecmp (Depends-on): Likewise.
9399
9400 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9401
9402         * lib/exclude.c: Include verify.h.
9403         (verify): Remove.  All callers changed to use verify.h's version.
9404         * lib/strtoimax.c: Likewise.
9405         * lib/utimecmp.c: Likewis.e
9406
9407         Sync from coreutils.
9408         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
9409         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
9410         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
9411         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
9412         bother returning ENOSYS if settimeofday or stime fails; just let
9413         them return whatever errno they want to return.
9414         * lib/utimens.c: Include unistd.h, for dup2.
9415         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
9416         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
9417
9418 2005-10-02  Jim Meyering  <jim@meyering.net>
9419
9420         Sync from coreutils.
9421         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
9422         from glibc-2.2.5 that fails for read-only files.
9423
9424 2005-10-02  Jim Meyering  <jim@meyering.net>
9425
9426         Sync from coreutils.
9427         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
9428         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
9429         `#if HAVE_CONFIG_H'.
9430         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
9431         Remove AT_FDCWD test.
9432         Do not consume the fd unless successful.
9433         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
9434         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
9435         block, so that we don't even try to compile it if settimeofday is
9436         available.  This works around a compilation failure on OSF1 V5.1,
9437         due to stime requiring a `long int*' while tv_sec is `int'.
9438
9439 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
9440
9441         Sync from coreutils.
9442         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
9443         against `yes', rather than just testing for nonempty.
9444
9445 2005-10-01  Simon Josefsson  <jas@extundo.com>
9446
9447         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
9448         and Darwin.
9449
9450         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
9451         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
9452         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
9453         freeaddrinfo and gai_strerror are declared by the POSIX headers.
9454         Check if struct addrinfo is declared.
9455
9456 2005-10-01  Simon Josefsson  <jas@extundo.com>
9457
9458         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
9459         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
9460         AI_* and EAI_* definitions.  Protect function declarations.
9461
9462 2005-10-01  Jim Meyering  <jim@meyering.net>
9463
9464         Sync from coreutils.
9465
9466         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
9467         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
9468         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
9469         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9470         in the inet and nsl libraries.  Required on Solaris 5.7.
9471
9472 2005-10-01  Jim Meyering  <jim@meyering.net>
9473
9474         Sync from coreutils.
9475         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9476         in the inet and nsl libraries.  Required on Solaris 5.7.
9477
9478 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
9479
9480         * lib/getdelim.c (getdelim): Remove unused variables.
9481
9482 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9483
9484         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
9485         so that the code works even with ancient cpp.  Portability problem
9486         with GCC 2.7.2.1 reported by Thomas M.Ott.
9487
9488 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9489
9490         * modules/regex (Depends-on): Add strcase.
9491
9492         * modules/gethostname (Licence): Change from GPL to LGPL, since
9493         gethostname.c is a trivial implementation of a standard library
9494         function.
9495         * modules/poll (License): Change from GPL to LGPL, since it's
9496         derived from LGPL code.
9497
9498 2005-09-27  Jim Meyering  <jim@meyering.net>
9499
9500         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
9501         HAVE_CONFIG_H.
9502
9503         * lib/intprops.h (signed_type_or_expr__): Define.
9504         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
9505         for unsigned types.
9506
9507 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9508
9509         * lib/verify.h (verify_expr): Remove, replacing with:
9510         (verify_true): New macro that returns true instead of void.
9511         (verify_type__): Remove.
9512         (verify): Use verify_true rather than verify_type__.
9513
9514 2005-09-26  Bruno Haible  <bruno@clisp.org>
9515
9516         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
9517         is necessary.
9518         (lib_SOURCES): Remove mbchar.c.
9519         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
9520         (Files): Add m4/mbrtowc.m4.
9521         * modules/mbiter: Likewise.
9522         * modules/mbuiter: Likewise.
9523
9524 2005-09-26  Bruno Haible  <bruno@clisp.org>
9525
9526         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
9527         compile mbchar.c if they are not both present.
9528         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
9529         * m4/mbiter.m4 (gl_MBITER): Likewise.
9530         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
9531         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
9532         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
9533
9534 2005-09-25  Jim Meyering  <jim@meyering.net>
9535
9536         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
9537         also uses socklen_t.
9538
9539 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
9540
9541         * lib/utimens.c (ENOSYS): Define if not already defined.
9542         (futimens): Support having a null PATH if the file descriptor
9543         is nonnegative.
9544
9545         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
9546         Remove.
9547         (__attribute): Define to empty unless GCC 3.1 or later.
9548         This works around a core dump on OpenBSD 3.4, which has GCC
9549         2.95.3, which dumps core when given __attribute__(()).  It also
9550         simplifies other tests, since we really don't want to bother with
9551         worrying about which ancient version of GCC supported what.
9552         Original problem reported by Yoann Vandoorselaere, with part of
9553         the fix suggested by Derek Price.
9554
9555 2005-09-24  Jim Meyering  <jim@meyering.net>
9556
9557         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
9558         so we can once again use a positive bitfield width of 1 -- now we
9559         don't have to explain why we were using a bitfield width of 2.
9560
9561 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9562
9563         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
9564         and similarly for the other external symbols.  Problem reported
9565         by James Gallager.
9566
9567         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
9568         bug reported by Jim Meyering.
9569
9570         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
9571         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
9572         not needed, since socklen is a prerequisite module.
9573
9574 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9575
9576         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
9577         Problem reported by Eric Blake.
9578         (getaddrinfo): Initialize se so that it's not garbage.
9579         Redo internal storage allocation so that it doesn't make unportable
9580         assumptions about alignment.
9581         Fix a memory leak.
9582
9583         * lib/utimens.c (futimens): Use futimesat if available.
9584         Prefer it to futimes since it doesn't have the futimes bug.
9585
9586         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
9587         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
9588         Instead, declare a function that returns a pointer to an array,
9589         and use verify_type__ to declare the size of the array.
9590         Problem and germ of a solution reported by Bruno Haible.
9591         (verify_type__): Use 2, not 1, for bitfield size, to avoid
9592         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
9593
9594 2005-09-23  Jim Meyering  <jim@meyering.net>
9595
9596         Sync from coreutils.
9597         Correct build failure (socklen_t not defined) on at least
9598         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
9599         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
9600
9601 2005-09-23  Jim Meyering  <jim@meyering.net>
9602
9603         * modules/getaddrinfo (Depends-on): Add socklen.
9604
9605 2005-09-23  Bruno Haible  <bruno@clisp.org>
9606
9607         * tests/test-verify.c: New file.
9608
9609 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9610
9611         Sync from coreutils.
9612
9613         * modules/argmatch (Depends-on): Add verify.
9614         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
9615         unistd-safer.
9616         * modules/save-cwd (Depends-on): Likewise.
9617
9618         * modules/openat (Files): Add lib/openat-die.c.
9619         (Depends-on): Remove error, exitfail.
9620         Add dirname.
9621
9622         * modules/verify: New file.
9623         * MODULES.html.sh (Diagnostics <assert.h>): New section,
9624         with "verify" module.
9625
9626 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9627
9628         Sync from coreutils.
9629
9630         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
9631         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
9632         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
9633         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
9634         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
9635         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
9636         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
9637         Don't bother checking for string.h, stdlib.h, unistd.h.
9638         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
9639         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
9640         module's job.
9641         * m4/jm-macros.m4 (gl_MACROS): Likewise.
9642         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
9643
9644         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
9645         (gl_GETDATE): Use it.
9646
9647         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
9648
9649 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9650
9651         Sync from coreutils.
9652
9653         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
9654         stat-time.h.
9655         * lib/argmatch.h: Include verify.h
9656         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
9657         (ARGMATCH_ASSERT): Remove; unused.
9658         * lib/canonicalize.c: Assume STDC_HEADERS.
9659         * lib/exclude.c: Include "strcase.h".
9660         * lib/regex_internal.h [!defined _LIBC]: Likewise.
9661         * lib/getusershell.c: Include stdio--.h rather than stdio.h
9662         and stdio-safer.h.
9663         (getusershell): Call fopen, not fopen_safer.
9664         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
9665         Do not include unistd-safer.h.
9666         (save_cwd): Don't call fd_safer; no longer needed
9667         now that we include fcntl--.h.
9668
9669         * lib/getdate.y (relative_time): New type.
9670         (RELATIVE_TIME_0): New constant.
9671         (parser_control): Use relative_time instead of doing it ourselves.
9672         (%union): Add new relative_time rel member.
9673         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
9674         Now typeless.
9675         (relunit, relunit_snumber): Now of type rel.
9676         (zone, rel, relunit, get_date): Adjust to above changes.
9677
9678         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
9679         Do not include unistd-safer.h.
9680         (getloadavg): Don't call fd_safer; no longer needed
9681         now that we include fcntl--.h.
9682
9683         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
9684         (make_dir_parents): Treat ENOSYS like EEXIST.
9685
9686         Improve quality of diagnostics on restore_cwd failure.
9687         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
9688         (make_dir_parents): Last arg is now int * (for errno), not bool *.
9689         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
9690         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
9691         each time through the loop.  Do not diagnose restore_cwd failure;
9692         that is the caller's job (and perhaps the caller does not care).
9693
9694         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
9695         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
9696         If the file already exists but is not a directory, don't bother
9697         to try to make its parents.
9698         Close potential file descriptor leak if we can't chdir("/") (!).
9699         Don't always return true if chdir($PWD) fails; return true only
9700         if the requested action was done successfully (except for the
9701         chdir($PWD)).
9702         Don't log final directory unless we actually made it.
9703         Refactor to avoid duplicate code to fix up permissions.
9704         Don't attempt to fix up parent permissions if chdir($PWD) fails.
9705
9706         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
9707         to make it a bit faster and (I hope) clearer.
9708         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
9709         Fix bug in formats like %2N.
9710
9711         * lib/verify.h: New file.
9712
9713 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9714
9715         Sync from coreutils.
9716         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
9717
9718 2005-09-22  Jim Meyering  <jim@meyering.net>
9719
9720         Sync from coreutils.
9721
9722         * m4/lstat.m4 (gl_FUNC_LSTAT):
9723         Use AC_LIBSOURCES to require lstat.c and lstat.h.
9724         Remove obsolete comment.
9725         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
9726         * m4/xstrtod.m4: Likewise.
9727
9728         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
9729
9730 2005-09-22  Jim Meyering  <jim@meyering.net>
9731
9732         Sync from coreutils.
9733
9734         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
9735
9736         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
9737         the .tm_year member, since otherwise gcc-4.0 would now warn about
9738         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
9739
9740         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
9741         order to avoid an unsuppressible warning from gcc on 64-bit systems.
9742
9743         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
9744         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
9745         when run in a time zone for which daylight savings time is in effect
9746         for the starting date.
9747
9748         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
9749         stop us from restricting permissions of just-created absolute-named
9750         directories.
9751         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
9752         to restore initial working directory.
9753         * lib/mkdir-p.c (make_dir_parents): New parameter:
9754         different_working_dir, to tell caller if/when we change the working
9755         directory and are unable to return to the initial one.
9756         * lib/mkdir-p.h (make_dir_parents): Update prototype.
9757         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
9758         `return false'.  This fixes a bug introduced on 2004-07-30.
9759
9760         * lib/openat.c (fdopendir): Be sure to close the supplied
9761         file descriptor before returning.  This makes our replacement
9762         implementation a little closer to Solaris's, where fdopendir
9763         ties the file descriptor to the returned DIR* pointer.
9764         * lib/openat.c (unlinkat): New function.
9765         * lib/openat.h (unlinkat): Add prototype.
9766         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
9767         (openat_restore_fail): Rename from openat_restore_die.
9768         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
9769
9770         Provide an alternative to exiting immediately upon save_cwd or
9771         restore_cwd failure.  Now, an application can arrange e.g.,
9772         to perform a longjump in that case.
9773         * lib/openat.c: Include dirname.h.
9774         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
9775         (rpl_openat, fdopendir, fstatat): Call openat_save_die
9776         and openat_restore_die rather than calling error directly.
9777         Don't include "error.h" or "exitfail.h"; they're no longer needed.
9778
9779         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
9780         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
9781         define.
9782
9783         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
9784         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
9785                             int utc, int nanoseconds);
9786         Background:
9787         date should not have to allocate a megabyte of virtual memory to
9788         handle a format argument like +%1048575T.  When implemented with
9789         strftime, it must allocate such a buffer, use strftime to fill it
9790         in, print it, then free it.
9791         With fprintftime, it simply prints everything and exits.
9792         With no need for memory allocation, that's one fewer way to fail.
9793         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
9794         optional field width, not before, so we accept %9:z, not %:9z.
9795         (my_strftime): Be sure to use L_('x') for literals.
9796
9797         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
9798         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
9799         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
9800         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
9801         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
9802         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
9803         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
9804         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
9805         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
9806         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
9807         * lib/xgethostname.c, lib/xreadlink.c:
9808         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
9809
9810         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
9811         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
9812         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
9813         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
9814         and don't include <sys/file.h>).
9815
9816 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
9817
9818         Sync from coreutils.
9819
9820         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
9821         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
9822         [!LDAV_DONE]: Avoid unused variable warning.
9823
9824 2005-09-21  Bruno Haible  <bruno@clisp.org>
9825
9826         * lib/unicodeio.h (unicode_to_mb): New declaration.
9827
9828 2005-09-20  Derek Price  <derek@ximbiot.com>
9829
9830         * lib/getaddrinfo.c: Don't include <netdb.h> included from
9831         getaddrinfo.h.
9832
9833 2005-09-20  Bruno Haible  <bruno@clisp.org>
9834
9835         * gnulib-tool: Remove trailing slashes from the values specified for
9836         --source-base, --m4-base, --tests-base, --aux-dir.
9837         Suggested by Simon Josefsson <jas@extundo.com>.
9838
9839 2005-09-20  Bruno Haible  <bruno@clisp.org>
9840
9841         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
9842         func_modules_to_filelist, func_import, func_create_testdir): Make all
9843         sorting results locale-independent, so that gnulib-cache.m4 doesn't
9844         change when gnulib-tool is invoked in a different locale.
9845
9846 2005-09-19  Simon Josefsson  <jas@extundo.com>
9847
9848         * m4/socklen.m4: Fix typo.
9849
9850 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9851
9852         Use a consistent style for including <config.h>.
9853         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
9854         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
9855         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
9856         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
9857         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
9858         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
9859         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
9860         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
9861         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
9862         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
9863         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
9864         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
9865         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
9866         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
9867         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
9868         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
9869         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
9870         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
9871         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
9872         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
9873         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
9874         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
9875         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
9876         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
9877         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
9878         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
9879         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
9880         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
9881         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
9882         lib/xstrtoumax.c, lib/yesno.c:
9883         Standardize inclusion of config.h.
9884         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
9885         lib/inttostr.h:  Removed inclusion of config.h from header files.
9886         * lib/inttostr.c:  Adjusted in-tree users.
9887         * lib/timespec.h: Remove superfluous warning to include config.h.
9888         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
9889         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
9890         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
9891         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
9892         config.h with HAVE_CONFIG_H.
9893
9894 2005-09-19  Jim Meyering  <jim@meyering.net>
9895
9896         * modules/pathmax (License): Change to LGPL.
9897
9898 2005-09-19  Derek Price  <derek@ximbiot.com>
9899
9900         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
9901
9902 2005-09-19  Bruno Haible  <bruno@clisp.org>
9903
9904         * gnulib-tool (import): Provide default for --tests-base.
9905
9906 2005-09-19  Bruno Haible  <bruno@clisp.org>
9907
9908         * doc/quote.texi: New file, extracted from gnulib.texi.
9909         * doc/ctime.texi: New file, extracted from gnulib.texi.
9910         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
9911         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
9912         * doc/gnulib.texi: Include them.
9913
9914 2005-09-18  Bruno Haible  <bruno@clisp.org>
9915
9916         Portability fix.
9917         * gnulib-tool (func_readlink): New function.
9918         (func_ln_if_changed): Use it.
9919
9920 2005-09-18  Bruno Haible  <bruno@clisp.org>
9921
9922         * gnulib-tool: Support --with-tests also with --import.
9923         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
9924         (func_import): Use variables $testsbase and $inctests. Emit a
9925         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
9926         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
9927         SUBDIRS += $testsdir.
9928         (func_create_testdir): Update.
9929
9930 2005-09-18  Bruno Haible  <bruno@clisp.org>
9931
9932         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
9933         instead of $dry_run.
9934         (func_cp_if_changed, func_mv_if_changed): Remove functions.
9935         (func_ln_if_changed): Don't handle dry-run here.
9936         (func_import): In dry-run mode, detect more precisely which actions
9937         would be performed, and don't use "...ing" verbs.
9938
9939 2005-09-18  Bruno Haible  <bruno@clisp.org>
9940
9941         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
9942         (func_import): Use join on two temporary files instead of three nested
9943         loops, in order to determine which files are new or old.
9944
9945 2005-09-18  Bruno Haible  <bruno@clisp.org>
9946
9947         * gnulib-tool (func_import): Comment out code that spits out the
9948         new files with --dry-run.
9949
9950 2005-09-18  Bruno Haible  <bruno@clisp.org>
9951
9952         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
9953
9954 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9955
9956         * lib/stat-time.h: New file.
9957         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
9958         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
9959         in a different way.
9960         (timespec_cmp): New function.
9961         * lib/utimecmp.c: Include stat-time.h.
9962         (SYSCALL_RESOLUTION): Depend on whether various struct stat
9963         members exist, not on the obsolescent ST_MTIM_NSEC.
9964         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
9965
9966 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9967
9968         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
9969
9970 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
9971
9972         * MODULES.html.sh (File system functions): Add stat-time.
9973         * modules/stat-time: New file.
9974         * modules/timespec (Files): Remove m4/st_mtim.m4; this
9975         is now done in a different way, by the stat-time module.
9976         * modules/utimecmp (Depends-on): Add stat-time.
9977
9978 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
9979
9980         * m4/st_mtim.m4: Remove.  Superseded by...
9981         * m4/stat-time.m4: New file.
9982         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
9983         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
9984
9985 2005-09-15  Derek Price  <derek@ximbiot.com>
9986
9987         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
9988
9989 2005-09-15  Derek Price  <derek@ximbiot.com>
9990
9991         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
9992         * lib/regex_internal.c: Ditto, using this...
9993         (__GNUC_PREREQ): ...new macro.
9994         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
9995         using...
9996         (__GNUC_PREREQ): ...this new macro.
9997
9998         * lib/strstr.h: Include string.h. Define strstr as a macro here.
9999
10000 2005-09-15  Derek Price  <derek@ximbiot.com>
10001             Paul Eggert  <eggert@cs.ucla.edu>
10002
10003         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
10004         changes, consolidating in...
10005         * lib/regex_internal.h: ...this file.
10006
10007 2005-09-13  Jim Meyering  <jim@meyering.net>
10008
10009         * lib/canon-host.c: Filter through gnu indent and reword comments
10010         slightly.
10011         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
10012
10013 2005-09-13  Derek Price  <derek@ximbiot.com>
10014
10015         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
10016         failure.
10017         Reported by Jim Meyering  <jim@meyering.net>.
10018
10019 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10020
10021         * lib/base64.c: Typo.
10022         (base64_encode): Put b64str in initialized data section.
10023
10024 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
10025
10026         Merge glibc and coreutils changes into gnulib, plus a few
10027         extra fixes.
10028         * lib/md5.c: Use #error rather than a string.
10029         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
10030         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
10031         (__attribute__): Define to empty for non recent-GCC.
10032         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
10033         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
10034         Renamed from their non-__ counterparts, with new macros replacing
10035         them if not _LIBC.  Add __THROW attribute.
10036         (rol): Remove.
10037         (struct md5_ctx): Align buffer if using GCC.
10038         * lib/sha1.h (struct sha1_ctx): Likewise.
10039         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
10040         The old name was backwards.
10041         (NOTSWAP): Remove; not used.
10042         (rol): New macro, moved here from md5.h.
10043         (sha1_process_block): Remove a FIXME that doesn't make sense.
10044
10045 2005-09-12  Derek Price  <derek@ximbiot.com>
10046
10047         Return usable errors from canon-host.
10048         * lib/canon-host.h: New file.
10049         * lib/canon-host.c (canon_host): Wrap...
10050         (canon_host_r): ...this new function, which now relies exclusively on
10051         getaddrinfo.
10052         (ch_strerror): New function.
10053         (last_cherror): New global.
10054         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
10055         interface.
10056         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
10057         void *.
10058         (freeaddrinfo): Free ai->ai_canonname when set.
10059
10060 2005-09-12  Derek Price  <derek@ximbiot.com>
10061
10062         Make canon-host require getaddrinfo.
10063         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
10064         AC_LIBSOURCE canon-host.h.  Call...
10065         (gl_PREREQ_CANON_HOST): ...this new function, which requires
10066         gl_GETADDRINFO.
10067         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
10068
10069 2005-09-12  Derek Price  <derek@ximbiot.com>
10070
10071         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
10072         LGPL.
10073         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
10074
10075 2005-09-12  Derek Price  <derek@ximbiot.com>
10076
10077         * lib/gai_strerror.c: Include config.h when available.  Include
10078         getaddrinfo.h before other headers to test interface.
10079         Reported by Larry Jones <lawrence.jones@ugs.com>.
10080
10081 2005-09-12  Derek Price  <derek@ximbiot.com>
10082             Paul Eggert  <eggert@cs.ucla.edu>
10083
10084         * modules/glob (Files): Add glob-libc.h.
10085
10086 2005-09-12  Derek Price  <derek@ximbiot.com>
10087             Paul Eggert  <eggert@cs.ucla.edu>
10088
10089         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
10090         glob_.h, glob-libc.h.
10091         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
10092
10093 2005-09-12  Derek Price  <derek@ximbiot.com>
10094             Paul Eggert  <eggert@cs.ucla.edu>
10095
10096         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
10097         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
10098         protecting things that should be done only in gnulib contexts.
10099         * lib/glob_.h: New file, containing only the glob things needed for
10100         gnulib.
10101         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
10102         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
10103         (glob, globfree, glob_pattern_p): Now defined simply in terms of
10104         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
10105         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
10106         and to respect the namespace rules better.
10107
10108 2005-09-08  Simon Josefsson  <jas@extundo.com>
10109
10110         * modules/socklen: New file.
10111
10112 2005-09-08  Simon Josefsson  <jas@extundo.com>
10113
10114         * m4/socklen.m4: New file.
10115
10116 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10117
10118         * modules/utimens (Files): Add m4/utimbuf.m4, since
10119         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
10120         Reported by Sergey Poznyakoff.
10121
10122 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10123
10124         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
10125         definitions, since that's the preferred style in glibc.
10126         Fix a minor spacing issue, and update copyright notice to match
10127         glibc's.
10128
10129 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10130
10131         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
10132
10133 2005-09-06  Simon Josefsson  <jas@extundo.com>
10134
10135         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
10136         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
10137
10138 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10139
10140         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
10141         warning.
10142
10143 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10144
10145         * config/srclist.txt: Add glibc bug 1302.
10146
10147 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
10148
10149         Change bitset word type from unsigned int to unsigned long int,
10150         as this has better performance on typical 64-bit hosts.
10151         Port bitset code to hosts with unusual word sizes.
10152         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
10153         (build_collating_symbol):
10154         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
10155         argument is a bitset.  This is merely a style issue, but it makes
10156         it clearer that an entire array is expected.
10157         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
10158         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
10159         Port to the case where bitset_word is not the same as unsigned int.
10160         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10161         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
10162         Likewise.
10163         * lib/regexec.c (check_dst_limits_calc_pos_1,
10164         check_subexp_matching_top):
10165         (build_trtable, group_nodes_into_DFAstates):
10166         Likewise.
10167         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
10168         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
10169         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
10170         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
10171         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
10172         * lib/regcomp.c (optimize_subexps, lower_subexp):
10173         Work even if bitset_word has holes in its bitwise representation.
10174         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
10175         * lib/regexec.c (check_dst_limits_calc_pos_1,
10176         check_subexp_matching_top):
10177         Likewise.
10178         * lib/regex_internal.c (re_string_reconstruct):
10179         Don't assume UCHAR_MAX == 255.
10180         * lib/regex_internal.h (bitset_set_all): Likewise.
10181         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
10182         All uses changed.
10183         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
10184         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
10185         All uses changed.
10186         (BITSET_WORD_MAX): New macro.
10187         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
10188         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
10189         (bitset_empty, bitset_copy):
10190         Prefer sizeof (bitset) to multiplying it out ourselves.
10191         (bitset_not_merge): Remove; unused.
10192         (bitset_contain): Return bool, not unsigned int with one bit on.
10193         All callers changed.
10194         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
10195         alignment than re_node_set; do this by defining a new internal
10196         type struct dests_alloc and using it to allocate memory.
10197
10198 2005-09-05  Bruno Haible  <bruno@clisp.org>
10199
10200         * gnulib-tool (func_import): Fix comparison in handling of symbolic
10201         links.
10202
10203 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
10204
10205         * modules/size_max (Makefile.am): Add size_max.h
10206
10207 2005-09-04  Derek Price  <derek@ximbiot.com>
10208
10209         * gnulib-tool (func_import): Fix reversed $symbolic logic.
10210
10211 2005-09-03  Simon Josefsson  <jas@extundo.com>
10212
10213         * gnulib-tool: Fix typo.
10214
10215 2005-09-03  Simon Josefsson  <jas@extundo.com>
10216
10217         * config/srclist.txt: Add glibc bug 1293.
10218
10219 2005-09-03  Derek Price  <derek@ximbiot.com>
10220
10221         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
10222         From Larry Jones <lawrence.jones@ugs.com>.
10223
10224 2005-09-02  Simon Josefsson  <jas@extundo.com>
10225
10226         * modules/socklen: New file.
10227
10228 2005-09-02  Simon Josefsson  <jas@extundo.com>
10229
10230         * modules/havelib: New module.
10231
10232         * modules/gettext, modules/iconv, modules/lock, modules/readline:
10233         Use havelib.
10234
10235 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10236
10237         Check for arithmetic overflow when calculating sizes, to prevent
10238         some buffer-overflow issues.  These patches are conservative, in the
10239         sense that when I couldn't determine whether an overflow was possible,
10240         I inserted a run-time check.
10241         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
10242         macros.
10243         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
10244         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
10245         (re_xnrealloc, re_x2nrealloc): New inline functions.
10246         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
10247         parse_bracket_exp):
10248         (build_equiv_class, build_charclass): Check for arithmetic overflow
10249         in size expression calculations.
10250         * lib/regex_internal.c (re_string_realloc_buffers):
10251         (build_wcs_upper_buffer, re_node_set_add_intersect):
10252         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
10253         (re_dfa_add_node, register_state): Likewise.
10254         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
10255         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
10256         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
10257         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
10258
10259 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10260
10261         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
10262         m4/ulonglong.m4.  Problem reported by Martin Lambers.
10263
10264 2005-09-02  Bruno Haible  <bruno@clisp.org>
10265
10266         Support for lib vs. lib64 distinction on biarch platforms.
10267         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
10268         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
10269         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
10270
10271 2005-09-02  Bruno Haible  <bruno@clisp.org>
10272
10273         * gnulib-tool (import): In the other first-use case, provide defaults
10274         as well.
10275
10276 2005-09-02  Bruno Haible  <bruno@clisp.org>
10277
10278         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
10279         patches not yet found in the latest gettext release.
10280
10281 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10282
10283         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
10284         to avoid a collision with bits/local_lim.h in glibc.
10285         All uses changed.  Problem reported by Dmitry V. Levin in
10286         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
10287
10288         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
10289         bugs in int versus size_t comparisons.
10290         (re_string_context_at): Fix bug where the code assumed that
10291         Idx is signed.
10292
10293         Use bool where appropriate.
10294         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
10295         All callers changed.
10296         (calc_eclosure_iter): Likewise, for ROOT arg.
10297         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
10298         (build_charclass_op): Likewise, for NON_MATCH arg.
10299         * lib/regex_internal.c (re_string_allocate, re_string_construct):
10300         (re_string_construct_common): Likewise, for ICASE arg.
10301         * lib/regexec.c (re_search_2_stub, re_search_stub):
10302         Likewise, for RET_LEN arg.
10303         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
10304         (set_regs): Likewise, for FL_BACKTRACK arg.
10305         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
10306         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
10307         (calc_eclosure_iter, parse_bracket_exp):
10308         Use bool for internal variables that are booleans.
10309         * lib/regexec.c (re_search_internal, check_matching,
10310         proceed_next_node):
10311         (set_regs, build_sifted_states, sift_states_bkref):
10312         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
10313         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
10314         (find_collation_sequence_value):
10315         Likewise.
10316         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
10317         (re_node_set_compare):
10318         Return bool, not int. All callers changed.
10319         * lib/regexec.c (check_halt_node_context, check_dst_limits):
10320         (build_trtable, check_node_accept): Likewise.
10321         * lib/regex_internal.h: Include stdbool.h.
10322
10323         Fix bugs uncovered when converting to bool.
10324         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
10325         failure instead of charging ahead blindly.
10326         * lib/regex_internal.c (register_state): Likewise.
10327         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
10328         for freeing internal storage.
10329         (group_nodes_into_DFA_states): Use unsigned int, not int, for
10330         bitset pieces used as boolean, to avoid undefined behavior
10331         on hosts that do int overflow checking.
10332
10333 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10334
10335         * config/srclist.txt: Add glibc bugs 1285-1287.
10336
10337 2005-09-01  Jim Meyering  <jim@meyering.net>
10338
10339         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
10340         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
10341         Require gl_STAT_MACROS, too.
10342
10343 2005-09-01  Bruno Haible  <bruno@clisp.org>
10344
10345         * gnulib-tool (import): In the first-use case, provide defaults.
10346
10347 2005-09-01  Bruno Haible  <bruno@clisp.org>
10348
10349         * gnulib-tool (func_import): Remove the .tmp files.
10350
10351 2005-09-01  Bruno Haible  <bruno@clisp.org>
10352
10353         * gnulib-tool (func_import): Fix handling of symbolic links.
10354
10355 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10356
10357         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
10358         old glibc regex code mishandles strings longer than 2**31 bytes.
10359         This patch fixes this when the regex code is used in gnulib
10360         (i.e., outside glibc).
10361
10362         This patch should not affect the use of the regex code inside
10363         glibc.  No doubt this problem also needs to be handled for glibc
10364         as well, but the result will be an incompatible change to the
10365         glibc ABI, and the old ABI will have to be supported too.  That
10366         can be the the subject for another patch.
10367
10368         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
10369         governing whether the rest of this patch is active.  By default,
10370         the macro is disabled and the patch has no effect.
10371         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
10372         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
10373         (struct re_pattern_buffer, re_search, re_search_2, re_match):
10374         (re_match_2, re_set_registers): Use the new types.
10375         * lib/regex_internal.h (Idx, re_hashval_t): New types.
10376         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
10377         New macros.
10378         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
10379         (re_string_context_at, bin_tree_t, re_dfastate_t):
10380         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
10381         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
10382         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
10383         (re_string_char_size_at, re_string_wchar_at):
10384         (re_string_elem_size_at):
10385         Use the new types and macros to port to 64-bit hosts.
10386         Use unsigned types for internal values, so that the code
10387         mostly works even for arrays larger than SSIZE_MAX.
10388         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
10389         (search_duplicated_node, calc_eclosure_iter, fetch_number):
10390         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
10391         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
10392         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
10393         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
10394         (calc_inveclosure, parse_dup_op, build_range_exp):
10395         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
10396         (fetch_number, create_token_tree, mark_opt_subexp):
10397         Likewise.
10398         * lib/regex_internal.c (re_string_construct_common,
10399         create_ci_newstate):
10400         (create_cd_newstate, re_string_allocate, re_string_construct):
10401         (re_string_realloc_buffers, build_wcs_upper_buffer):
10402         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
10403         (re_string_reconstruct, re_string_peek_byte_case):
10404         (re_string_fetch_byte_case, re_string_context_at):
10405         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
10406         (re_node_set_init_copy, re_node_set_add_intersect):
10407         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10408         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10409         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
10410         (re_acquire_state, re_acquire_state_context, register_state):
10411         Likewise.
10412         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
10413         search_cur_bkref_entry):
10414         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
10415         (re_search_internal, re_search_2_stub, re_search_stub)
10416         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
10417         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
10418         (update_cur_sifted_state, check_dst_limits):
10419         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10420         (check_subexp_limits, sift_states_bkref, merge_state_array):
10421         (check_subexp_matching_top, get_subexp, get_subexp_sub):
10422         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
10423         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
10424         (expand_bkref_cache, check_node_accept_bytes):
10425         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
10426         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
10427         (acquire_init_state_context, check_halt_node_context):
10428         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
10429         (sift_states_backward, clean_state_log_if_needed):
10430         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
10431         (find_recover_state, transit_state_sb, transit_state_mb):
10432         (transit_state_bkref, build_trtable, match_ctx_clean):
10433         Likewise.
10434         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
10435         to work around an assumption that REG_MISSING is negative.
10436
10437         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
10438         (seek_collating_symbol_entry) [defined _LIBC]:
10439         (lookup_collation_sequence_value) [defined _LIBC]:
10440         (build_range_exp, build_collating_symbol) [defined _LIBC]:
10441         Use prototypes rather than old-style function definitions.
10442         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
10443         (transit_state_sb) [0]:
10444         (find_collation_sequence_value) [defined _LIBC]: Likewise.
10445
10446         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
10447         rm_eo.
10448
10449         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
10450         (optimize_subexps, lower_subexp):
10451         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
10452         since the signed shift might overflow.  Use 1u<<31 instead.
10453         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10454         Likewise.
10455         * lib/regexec.c (check_dst_limits_calc_pos_1,
10456         check_subexp_matching_top): Likewise.
10457
10458         * lib/regcomp.c (optimize_subexps, lower_subexp):
10459         Use CHAR_BIT rather than 8, for clarity.
10460         * lib/regexec.c (check_dst_limits_calc_pos_1):
10461         (check_subexp_matching_top): Likewise.
10462         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
10463         have to worry about portability issues when shifting it left.
10464         Remove no-longer-needed test for table_size > 0.
10465         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
10466         in a word, as the resulting behavior is undefined.
10467         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
10468         in one case, a <= should have been an <, and in another case the
10469         whole test was missing.
10470         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
10471         the standard name CHAR_BIT.
10472         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
10473         this is not true on one's complement and signed-magnitude hosts.
10474
10475         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
10476         next_last_offset.
10477         (struct re_dfa_t): Remove unused member states_alloc.
10478         * lib/regcomp.c (init_dfa): Don't initialize unused members.
10479
10480 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10481
10482         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
10483         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
10484         and large-file glibc and in 32-bit large-file Solaris.
10485
10486 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10487
10488         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
10489         lengths fit in regoff_t; this isn't true if regoff_t is the same
10490         width as size_t.
10491         * lib/regex.c (re_search_internal): 5th arg is LAST_START
10492         (= START + RANGE) instead of RANGE.  This avoids overflow
10493         problems when regoff_t is the same width as size_t.
10494         All callers changed.
10495         (re_search_2_stub): Check for overflow when adding the
10496         sizes of the two strings.
10497         (re_search_stub): Check for overflow when adding START
10498         to RANGE; if it occurs, substitute the extreme value.
10499
10500 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10501
10502         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
10503
10504 2005-08-31  Jim Meyering  <jim@meyering.net>
10505
10506         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
10507         a pointer-to-const.
10508         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
10509         (register_state): Likewise.
10510         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
10511         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10512         (group_nodes_into_DFAstates): Likewise.
10513
10514 2005-08-31  Jim Meyering  <jim@meyering.net>
10515
10516         * check-module: Add a FIXME comment.
10517
10518 2005-08-31  Eric Blake  <ebb9@byu.net>
10519
10520         * modules/unistd-safer (Files): Add unistd--.h.
10521         * modules/stdio-safer (Files): Add stdio--.h.
10522
10523 2005-08-31  Derek Price  <derek@ximbiot.com>
10524
10525         * lib/getdelim.c (getdelim): Return EOF on EOF.
10526         Reported by Larry Jones <lawrence.jones@ugs.com>.
10527
10528 2005-08-31  Bruno Haible  <bruno@clisp.org>
10529
10530         Avoid unnecessary diffs in the generated lib/Makefile.am.
10531         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
10532         the generated files.
10533         (func_import): Don't set cmd.
10534
10535 2005-08-31  Bruno Haible  <bruno@clisp.org>
10536
10537         * lib/strstr.c: Include <stddef.h>, for NULL.
10538         * lib/strcasestr.c: Likewise.
10539         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10540
10541 2005-08-31  Bruno Haible  <bruno@clisp.org>
10542
10543         * gnulib-tool: New option --macro-prefix.
10544         (func_import): Use macro_prefix.
10545         (import): Handle option --macro-prefix.
10546
10547 2005-08-31  Bruno Haible  <bruno@clisp.org>
10548
10549         * gnulib-tool (import): Rename most ac_* variables to cached_*.
10550         Also use new variables cached_lgpl, cached_libtool.
10551
10552 2005-08-31  Bruno Haible  <bruno@clisp.org>
10553
10554         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
10555         always instantiating them.
10556
10557 2005-08-31  Bruno Haible  <bruno@clisp.org>
10558
10559         * gnulib-tool (func_import): Read the previous cached settings
10560         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
10561         earlier added by gnulib but are now dropped. Warn when a gnulib file
10562         overwrites a non-gnulib file.
10563
10564 2005-08-31  Bruno Haible  <bruno@clisp.org>
10565
10566         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
10567         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
10568         projects that don't keep autogenerated files in CVS. Put into
10569         actioncmd only the specified modules, not the transitive closure.
10570
10571 2005-08-31  Bruno Haible  <bruno@clisp.org>
10572
10573         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
10574         Create directories that shall be filled.
10575         (import): Don't look for gl_* macros in configure.ac. Recurse across
10576         all directories containing a gnulib-cache.m4 files, if meaningful.
10577
10578 2005-08-31  Bruno Haible  <bruno@clisp.org>
10579
10580         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
10581         (import): Set seen_libtool when we see gl_LIBTOOL.
10582
10583 2005-08-31  Bruno Haible  <bruno@clisp.org>
10584
10585         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
10586         declaration macro definitions from generated gnulib.m4.
10587
10588 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
10589
10590         * lib/iconvme.h: Add prototype for iconv_alloc.
10591
10592 2005-08-29  Simon Josefsson  <jas@extundo.com>
10593
10594         * lib/iconvme.c: Fix errno.
10595
10596 2005-08-29  Bruno Haible  <bruno@clisp.org>
10597
10598         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
10599         that it works when the directory contains spaces.
10600
10601 2005-08-29  Bruno Haible  <bruno@clisp.org>
10602
10603         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
10604
10605 2005-08-29  Bruno Haible  <bruno@clisp.org>
10606
10607         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
10608         Emit more advice.
10609
10610 2005-08-29  Bruno Haible  <bruno@clisp.org>
10611         and Stepan Kasal  <kasal@ucw.cz>
10612
10613         * check-module: If more parameters are given, check each of them
10614         separately; add more exceptions, as noted by Jim Meyering.
10615         (check_module): New procedure.
10616         (%exempt_header): Now contains all exceptions.
10617
10618 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
10619
10620         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
10621
10622 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
10623
10624         * lib/iconvme.c: Split iconv_string into iconv_alloc.
10625
10626 2005-08-28  Bruno Haible  <bruno@clisp.org>
10627
10628         * m4/gnulib-tool.m4: New file.
10629
10630 2005-08-27  Jim Meyering  <jim@meyering.net>
10631
10632         * modules/unistd-safer (Files): Add pipe-safer.c.
10633         * modules/fcntl-safer (Files): Add creat-safer.c.
10634
10635 2005-08-27  Jim Meyering  <jim@meyering.net>
10636
10637         * m4/stdlib-safer.m4: New file.  From coreutils.
10638         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
10639         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
10640         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
10641         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
10642         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
10643
10644 2005-08-27  Jim Meyering  <jim@meyering.net>
10645
10646         * lib/fopen-safer.c: Merge minor changes from coreutils.
10647         * lib/dup-safer.c: Likewise.
10648         * lib/fd-safer.c: Likewise.
10649
10650         Merge from coreutils.
10651         * lib/stdio--.h: New file.
10652         * lib/stdlib--.h: New file.
10653         * lib/mkstemp-safer.c: New file.
10654
10655         GNU tar needs these.
10656         * lib/pipe-safer.c: New file.
10657         * lib/creat-safer.c: New file.
10658         * lib/fcntl--.h (creat): Define to creat_safer.
10659         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
10660         * lib/unistd--.h (pipe): Define to pipe_safer.
10661         * lib/unistd-safer.h: Declare pipe_safer.
10662
10663 2005-08-26  Simon Josefsson  <jas@extundo.com>
10664
10665         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
10666         Haible <bruno@clisp.org>.
10667
10668 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
10669
10670         * lib/regex_internal.h: Remove all references to
10671         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
10672         or better.
10673         (bitset_not, bitset_merge, bitset_not_merge):
10674         (bitset_mask, re_string_allocate, re_string_construct):
10675         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
10676         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
10677         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
10678         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
10679         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10680         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10681         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
10682         (re_acquire_state_context):
10683         Remove unnecessary forward decls.
10684         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
10685         Put __attribute at function definition,
10686         now that the function decl has been removed.
10687         * lib/regex_internal.c (re_string_peek_byte_case):
10688         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
10689         Likewise.
10690
10691 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
10692
10693         * m4/regex.m4: Add AC_PREREQ(2.50).
10694         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
10695
10696 2005-08-25  Simon Josefsson  <jas@extundo.com>
10697
10698         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
10699         __fsetlocking.
10700
10701 2005-08-25  Simon Josefsson  <jas@extundo.com>
10702
10703         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
10704         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
10705         GLIBC specific code.
10706
10707 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10708
10709         Make regex safe for g++.  This fixes one real bug (an "err"
10710         that should have been "*err").  g++ problem reported by
10711         Sam Steingold.
10712         * lib/regex_internal.h (re_calloc): New macro, consistent with
10713         re_malloc etc.  All callers of calloc changed to use re_calloc.
10714         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
10715         not int.  All callers changed.
10716         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
10717         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
10718         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
10719         (find_recover_state): Change "err" to "*err"; this fixes what
10720         appears to be a real bug.
10721         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
10722         versus int.
10723
10724 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10725
10726         * modules/regex (Depends-on): Add malloc, since the code
10727         assumes that !malloc(0) means failure.
10728
10729 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10730
10731         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
10732
10733         alloca modernization/simplification for regex.
10734         * lib/regex.c: Remove portability cruft for alloca.  This no longer
10735         needs to be at the start of the file, and can be moved into
10736         regex_internal.h and simplified.
10737         * lib/regex_internal.h: Include <alloca.h>.
10738         (__libc_use_alloca) [!defined _LIBC]: New macro.
10739         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
10740         now works outside glibc.
10741
10742 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
10743
10744         * config/srclist.txt: Add glibc bugs 1241, 1245.
10745
10746 2005-08-25  Jim Meyering  <jim@meyering.net>
10747
10748         * lib/open-safer.c: Include <config.h>.
10749         Otherwise, we'd lose LARGEFILE support in any file using
10750         e.g. "fcntl--.h"
10751
10752 2005-08-25  Bruno Haible  <bruno@clisp.org>
10753
10754         * m4/minmax.m4: Require autoconf 2.52.
10755         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
10756         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
10757         alternatives of translit over the alphabet.
10758         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
10759
10760 2005-08-24  Simon Josefsson  <jas@extundo.com>
10761
10762         * tests/test-getpass.c: New file.
10763
10764 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10765
10766         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
10767         for GNU regex features.
10768
10769 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10770
10771         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
10772         * lib/regex.h (regerror): Likewise.
10773
10774         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
10775         requires this.  (The code never needed it.)
10776
10777         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
10778         All uses of recently-renamed identifiers changed to use the new,
10779         POSIX-compliant names.  The code will build and run just fine
10780         without these changes, but it's better to eat our own dog food
10781         and use the standard-conforming names.
10782
10783         * lib/regex.h: Fix a multitude of POSIX name space violations.
10784         These changes have an effect only for programs that define
10785         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
10786         do not change anything for programs compiled in the normal way.
10787         Also, there is no effect on the ABI.
10788
10789         (_REGEX_SOURCE): New macro.
10790         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
10791         defined and _GNU_SOURCE is not; this fixes a name space violation.
10792
10793         Rename the following macros to obey POSIX requirements.
10794         The old names are still visible as macros if _REGEX_SOURCE is defined.
10795         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
10796         RE_BACKSLASH_ESCAPE_IN_LISTS.
10797         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
10798         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
10799         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
10800         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
10801         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
10802         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
10803         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
10804         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
10805         (REG_INTERVALS): renamed from RE_INTERVALS.
10806         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
10807         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
10808         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
10809         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
10810         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
10811         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
10812         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
10813         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
10814         RE_UNMATCHED_RIGHT_PAREN_ORD.
10815         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
10816         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
10817         (REG_DEBUG): renamed from RE_DEBUG.
10818         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
10819         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
10820         unusual, since we can't clash with the POSIX REG_ICASE.
10821         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
10822         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
10823         (REG_NO_SUB): renamed from RE_NO_SUB.
10824         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
10825         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
10826         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
10827         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
10828         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
10829         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
10830         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
10831         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
10832         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
10833         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
10834         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
10835         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
10836         RE_SYNTAX_POSIX_MINIMAL_BASIC.
10837         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
10838         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
10839         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
10840         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
10841         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
10842         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
10843         (REG_FIXED): Renamed from REGS_FIXED.
10844         (REG_NREGS): Renamed from RE_NREGS.
10845
10846         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
10847         of other REG_* macros, since POSIX says the user is allowed to
10848         #undef these macros selectively.
10849
10850         (reg_errcode_t): Update comment stating what other tables need
10851         to be consistent.
10852
10853         Rename the following enum values to obey POSIX requirements.
10854         The old names are still visible as macros.
10855         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
10856         is not defined, since GNU is supposed to be a superset of POSIX as
10857         much as possible, and since we want reg_errcode_t to be a signed
10858         type for implementation consistency.
10859         (_REG_NOERROR): Renamed from REG_NOERROR.
10860         (_REG_NOMATCH): Renamed from REG_NOMATCH.
10861         (_REG_BADPAT): Renamed from REG_BADPAT.
10862         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
10863         (_REG_ECTYPE): Renamed from REG_ECTYPE.
10864         (_REG_EESCAPE): Renamed from REG_EESCAPE.
10865         (_REG_ESUBREG): Renamed from REG_ESUBREG.
10866         (_REG_EBRACK): Renamed from REG_EBRACK.
10867         (_REG_EPAREN): Renamed from REG_EPAREN.
10868         (_REG_EBRACE): Renamed from REG_EBRACE.
10869         (_REG_BADBR): Renamed from REG_BADBR.
10870         (_REG_ERANGE): Renamed from REG_ERANGE.
10871         (_REG_ESPACE): Renamed from REG_ESPACE.
10872         (_REG_BADRPT): Renamed from REG_BADRPT.
10873         (_REG_EEND): Renamed from REG_EEND.
10874         (_REG_ESIZE): Renamed from REG_ESIZE.
10875         (_REG_ERPAREN): Renamed from REG_ERPAREN.
10876         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
10877         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
10878         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
10879         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
10880
10881         (_REG_RE_NAME, _REG_RM_NAME): New macros.
10882         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
10883         changed.  But support the old name if the new one is not defined
10884         and if _REGEX_SOURCE.
10885
10886         Change the following member names in struct re_pattern_buffer.
10887         The old names are still supported if !_REGEX_SOURCE.
10888         The new names are always supported, regardless of _REGEX_SOURCE.
10889         (re_buffer): Renamed from buffer.
10890         (re_allocated): Renamed from allocated.
10891         (re_used): Renamed from used.
10892         (re_syntax): Renamed from syntax.
10893         (re_fastmap): Renamed from fastmap.
10894         (re_translate): Renamed from translate.
10895         (re_can_be_null): Renamed from can_be_null.
10896         (re_regs_allocated): Renamed from regs_allocated.
10897         (re_fastmap_accurate): Renamed from fastmap_accurate.
10898         (re_no_sub): Renamed from no_sub.
10899         (re_not_bol): Renamed from not_bol.
10900         (re_not_eol): Renamed from not_eol.
10901         (re_newline_anchor): Renamed from newline_anchor.
10902
10903         Change the following member names in struct re_registers.
10904         The old names are still supported if !_REGEX_SOURCE.
10905         The new names are always supported, regardless of _REGEX_SOURCE.
10906         (rm_num_regs): Renamed from num_regs.
10907         (rm_start): Renamed from start.
10908         (rm_end): Renamed from end.
10909
10910         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
10911         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
10912         Prepend __ to parameter names.
10913
10914         Undo yesterday's changes.
10915
10916 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
10917
10918         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
10919         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
10920         lib/regex.c.
10921
10922 2005-08-24  Jim Meyering  <jim@meyering.net>
10923
10924         Sync from coreutils.
10925         * m4/fcntl-safer.m4: New file.
10926
10927         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
10928         and object files for this module.
10929
10930 2005-08-24  Jim Meyering  <jim@meyering.net>
10931
10932         Sync from coreutils.
10933         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
10934
10935 2005-08-24  Jim Meyering  <jim@meyering.net>
10936
10937         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
10938         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
10939
10940 2005-08-24  Jim Meyering  <jim@meyering.net>
10941
10942         * modules/fcntl-safer: New module.
10943         * modules/fts (Depends-on): Add fcntl-safer.
10944         * MODULES.html.sh (File descriptor based Input/Output):
10945         Add fcntl-safer.
10946
10947 2005-08-24  Bruno Haible  <bruno@clisp.org>
10948
10949         Support for unit test modules.
10950         * modules/README: Mention tests modules.
10951         * modules/TEMPLATE-TESTS: New file.
10952         * gnulib-tool: New options --extract-tests-module, --with-tests and
10953         --tests-base (unused for the moment).
10954         (testsbase, inctests): New variables.
10955         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
10956         (func_verify_module): Exclude TEMPLATE-TESTS.
10957         (func_verify_nontests_module, func_verify_tests_module): New functions.
10958         (func_get_dependencies): Add implicit dependency for tests modules.
10959         (func_get_tests_module): New function.
10960         (func_modules_transitive_closure): When --with-tests was specified,
10961         include the unit tests as well, unless explicitly avoided.
10962         (func_emit_lib_Makefile_am): Ignore the tests modules here.
10963         (func_emit_tests_Makefile_am): New function.
10964         (func_create_testdir): When --with-tests was specified, emit a
10965         tests/ directory.
10966         * MODULES.html.sh (Future developments): Update.
10967
10968 2005-08-24  Bruno Haible  <bruno@clisp.org>
10969
10970         * modules/tls-tests: New file.
10971         * tests/test-tls.c: New file, from GNU gettext.
10972
10973 2005-08-24  Bruno Haible  <bruno@clisp.org>
10974
10975         * modules/lock-tests: New file.
10976         * tests/test-lock.c: New file, from GNU gettext.
10977
10978 2005-08-24  Bruno Haible  <bruno@clisp.org>
10979
10980         * lib/lock.h: Add multiple inclusion guard.
10981         * lib/tls.h: Add multiple inclusion guard.
10982
10983 2005-08-24  Bruno Haible  <bruno@clisp.org>
10984
10985         * gnulib-tool: Add support for the --aux-dir option to
10986         --create-testdir, --create-megatestdir, --test, --megatest.
10987         (func_create_testdir, func_create_megatestdir): Optionally emit a
10988         AC_CONFIG_AUX_DIR directive.
10989         (create-testdir, create-megatestdir, test, megatest): Provide a
10990         default value for $auxdir.
10991
10992 2005-08-24  Bruno Haible  <bruno@clisp.org>
10993
10994         * gnulib-tool (import): Use compound statement instead of subshell
10995         where possible.
10996
10997 2005-08-24  Bruno Haible  <bruno@clisp.org>
10998
10999         * gnulib-tool (import): Change --aux-dir default to "build-aux".
11000
11001 2005-08-24  Bruno Haible  <bruno@clisp.org>
11002
11003         * gnulib-tool (func_version): Update.
11004
11005 2005-08-24  Bruno Haible  <bruno@clisp.org>
11006
11007         * gnulib-tool (func_import, func_create_testdir,
11008         func_create_megatestdir): Quote all autoconf macro arguments.
11009
11010 2005-08-24  Bruno Haible  <bruno@clisp.org>
11011
11012         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
11013         option --force, because --force causes the aclocal.m4 of each
11014         subdirectory to be newer than the corresponding config.h.in.
11015
11016 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11017
11018         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
11019         All contents moved to gl_REGEX.
11020         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
11021         assume that it does.
11022
11023 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11024
11025         * lib/regex.h (REG_NOSYS)
11026         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
11027         Define, since POSIX requires it as of 2001.
11028         (_REG_ENOSYS)
11029         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
11030         New private symbol, used to keep the enum signed in all cases.
11031         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
11032         Youngman in
11033         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
11034
11035         * lib/regex_internal.c (re_string_skip_chars, register_state):
11036         (calc_state_hash):
11037         Remove forward decls; no longer needed now that we use prototypes.
11038         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
11039         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
11040         (clean_state_log_if_needed): Likewise.
11041
11042 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11043
11044         * config/srclist.txt: Add glibc bugs 1231-1233.
11045
11046 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11047
11048         Fix problems reported by Sam Steingold in
11049         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
11050         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
11051         assumed that reg_errcode_t is a signed type, which is not
11052         necessarily true if _XOPEN_SOURCE is not defined.
11053         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
11054         since some compilers warn about it otherwise.
11055
11056 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11057
11058         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
11059         (init_word_char, create_initial_state, duplicate_node_closure):
11060         (fetch_token, peek_token_bracket, build_range_exp):
11061         (build_collating_symbol): Remove forward decls; no longer needed
11062         now that we use prototypes.
11063
11064         * lib/regcomp.c:
11065         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
11066         (re_compile_fastmap_iter, regcomp, regerror, regfree):
11067         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
11068         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
11069         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
11070         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
11071         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
11072         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
11073         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
11074         (build_range_exp, build_collating_symbol, parse_bracket_exp):
11075         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
11076         (build_charclass, build_charclass_op, fetch_number, create_tree):
11077         (create_token_tree, mark_opt_subexp, duplicate_tree):
11078         Use prototypes rather than old-style definitions.
11079
11080         * lib/regex_internal.c:
11081         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
11082         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
11083         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11084         (re_string_reconstruct, re_string_peek_byte_case):
11085         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
11086         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11087         (re_node_set_init_copy, re_node_set_add_intersect):
11088         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11089         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11090         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11091         (re_acquire_state, re_acquire_state_context, register_state):
11092         (create_ci_newstate, create_cd_newstate, free_state):
11093         Likewise.
11094         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
11095         re_search_2):
11096         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
11097         (re_search_internal, prune_impossible_nodes):
11098         (acquire_init_state_context, check_matching, static):
11099         (check_halt_node_context, check_halt_state_context, proceed_next_node):
11100         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
11101         (update_regs, sift_states_backward, build_sifted_states):
11102         (clean_state_log_if_needed, merge_state_array):
11103         (update_cur_sifted_state, add_epsilon_src_nodes):
11104         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
11105         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
11106         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
11107         (find_recover_state, check_subexp_matching_top, transit_state_mb):
11108         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
11109         (check_arrival, check_arrival_add_next_nodes):
11110         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11111         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11112         (check_node_accept_bytes, check_node_accept, extend_buffers):
11113         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
11114         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
11115         (sift_ctx_init):
11116         Likewise.
11117
11118         * lib/regex_internal.h:
11119         (re_string_allocate, re_string_construct, re_string_reconstruct):
11120         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
11121         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
11122         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
11123         (re_string_context_at, re_string_peek_byte_case):
11124         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
11125         is defined, since we now use prototypes always.
11126
11127         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
11128         C89 or better.  All uses removed.
11129
11130 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11131
11132         * config/srclist.txt: Add glibc bugs 1220-1227.
11133
11134 2005-08-20  Jim Meyering  <jim@meyering.net>
11135
11136         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
11137         of unused local, dfa.
11138
11139 2005-08-20  Bruno Haible  <bruno@clisp.org>
11140
11141         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
11142
11143 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11144
11145         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
11146         (re_node_set_insert_last, re_dfa_add_node):
11147         Rename local variables to avoid GCC shadowing warnings.
11148
11149 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11150
11151         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
11152         [defined lint]: Suppress bogus uninitialized-variable warnings.
11153
11154         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
11155         and let the caller return REG_ESPACE if out of space.  This
11156         removes an uninitialied-variable warning with GCC 4.0.1, and also
11157         avoids taking the address of a local variable.  All callers
11158         changed.
11159
11160 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11161
11162         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
11163         $LIBCSRC/posix/regexec.c.
11164         Add glibc bug 1217 for regcomp.c.
11165
11166 2005-08-19  Jim Meyering  <jim@meyering.net>
11167
11168         * lib/regexec.c (proceed_next_node): Redo local variables to
11169         avoid GCC shadowing warnings.
11170
11171 2005-08-18  Bruno Haible  <bruno@clisp.org>
11172
11173         * lib/strstr.c (strstr): Fix return value in multibyte case.
11174         * lib/strcasestr.c (strcasestr): Likewise.
11175
11176 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11177
11178         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
11179
11180 2005-08-17  Jim Meyering  <jim@meyering.net>
11181
11182         Make the %s format (seconds since the epoch) work for a negative
11183         number and when used with a zero-padded field width, e.g. %015s.
11184
11185         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
11186         label so that it precedes the code to set `digits'.  Otherwise,
11187         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
11188         print `00-22'.  Now, it prints `-0022', as it should.
11189
11190 2005-08-17  Bruno Haible  <bruno@clisp.org>
11191
11192         * modules/strstr (Files): Add m4/mbrtowc.m4.
11193         (Depends-on): Add mbuiter.
11194
11195 2005-08-17  Bruno Haible  <bruno@clisp.org>
11196
11197         * modules/strcasestr: New file.
11198         * MODULES.html.sh (String handling, based on ANSI C 89): Add
11199         strcasestr.
11200
11201 2005-08-17  Bruno Haible  <bruno@clisp.org>
11202
11203         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
11204
11205 2005-08-17  Bruno Haible  <bruno@clisp.org>
11206
11207         * modules/mbuiter: New file.
11208         * MODULES.html.sh (Extended multibyte and wide character utilities):
11209         Add mbuiter.
11210
11211 2005-08-17  Bruno Haible  <bruno@clisp.org>
11212
11213         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
11214         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
11215
11216 2005-08-17  Bruno Haible  <bruno@clisp.org>
11217
11218         * m4/strcasestr.m4: New file.
11219
11220 2005-08-17  Bruno Haible  <bruno@clisp.org>
11221
11222         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
11223         * lib/strstr.c: Completely rewritten, with multibyte locale support.
11224
11225 2005-08-17  Bruno Haible  <bruno@clisp.org>
11226
11227         * lib/strcasestr.h: New file.
11228         * lib/strcasestr.c: New file.
11229
11230 2005-08-17  Bruno Haible  <bruno@clisp.org>
11231
11232         * lib/strcasecmp.c: Use mbuiter.h.
11233
11234 2005-08-17  Bruno Haible  <bruno@clisp.org>
11235
11236         * lib/mbuiter.h: New file.
11237
11238 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11239
11240         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
11241         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
11242         and gl_GETOPT are both invoked via different paths (as happens
11243         with GNU tar CVS because it uses both argp and getopt), the former
11244         wins.
11245
11246 2005-08-16  Bruno Haible  <bruno@clisp.org>
11247
11248         * modules/tls: New file.
11249         * MODULES.html.sh (Multithreading): Add tls.
11250
11251 2005-08-16  Bruno Haible  <bruno@clisp.org>
11252
11253         * modules/strnlen1: New file.
11254         * MODULES.html.sh (String handling): Add strnlen1.
11255
11256 2005-08-16  Bruno Haible  <bruno@clisp.org>
11257
11258         * modules/strcase (Files): Add m4/mbrtowc.m4.
11259         (Depends-on): Add strnlen1, mbchar.
11260
11261 2005-08-16  Bruno Haible  <bruno@clisp.org>
11262
11263         * modules/mbiter: New file.
11264         * MODULES.html.sh (Extended multibyte and wide character utilities):
11265         Add mbiter.
11266
11267 2005-08-16  Bruno Haible  <bruno@clisp.org>
11268
11269         * modules/mbfile: New file.
11270         * MODULES.html.sh (Extended multibyte and wide character utilities):
11271         Add mbfile.
11272
11273 2005-08-16  Bruno Haible  <bruno@clisp.org>
11274
11275         * modules/mbchar: New file.
11276         * MODULES.html.sh (Extended multibyte and wide character utilities):
11277         New section.
11278
11279 2005-08-16  Bruno Haible  <bruno@clisp.org>
11280
11281         * m4/tls.m4: New file, from GNU gettext.
11282
11283 2005-08-16  Bruno Haible  <bruno@clisp.org>
11284
11285         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
11286         always.
11287         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
11288
11289 2005-08-16  Bruno Haible  <bruno@clisp.org>
11290
11291         * m4/mbiter.m4: New file.
11292
11293 2005-08-16  Bruno Haible  <bruno@clisp.org>
11294
11295         * m4/mbfile.m4: New file.
11296
11297 2005-08-16  Bruno Haible  <bruno@clisp.org>
11298
11299         * m4/mbchar.m4: New file.
11300
11301 2005-08-16  Bruno Haible  <bruno@clisp.org>
11302
11303         * lib/tls.h: New file, from GNU gettext.
11304         * lib/tls.c: New file, from GNU gettext.
11305
11306 2005-08-16  Bruno Haible  <bruno@clisp.org>
11307
11308         * lib/strnlen1.h: New file.
11309         * lib/strnlen1.c: New file.
11310
11311 2005-08-16  Bruno Haible  <bruno@clisp.org>
11312
11313         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
11314         (mbi_init): Update.
11315         (mbi_avail, mbi_advance): Let the iteration end before the terminating
11316         NUL byte, not after it.
11317
11318 2005-08-16  Bruno Haible  <bruno@clisp.org>
11319
11320         * lib/strcase.h (strcasecmp): Add note in comments.
11321         * lib/strncasecmp.c: Use code from strcasecmp.c.
11322         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
11323         (strcasecmp): Work correctly in multibyte locales.
11324
11325 2005-08-16  Bruno Haible  <bruno@clisp.org>
11326
11327         * lib/mbiter.h: New file.
11328
11329 2005-08-16  Bruno Haible  <bruno@clisp.org>
11330
11331         * lib/mbfile.h: New file.
11332
11333 2005-08-16  Bruno Haible  <bruno@clisp.org>
11334
11335         * lib/mbchar.h: New file.
11336         * lib/mbchar.c: New file.
11337
11338 2005-08-16  Bruno Haible  <bruno@clisp.org>
11339
11340         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
11341         the valid ones. Makes the comparison operations transitive:
11342         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
11343         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
11344
11345 2005-08-15  Simon Josefsson  <jas@extundo.com>
11346
11347         * modules/ssize_t (License): Change to 'unlimited'.
11348
11349         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
11350
11351 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11352
11353         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
11354         Add comments for each pending glibc patch.
11355
11356 2005-08-15  Bruno Haible  <bruno@clisp.org>
11357
11358         * lib/regex.h (__restrict_arr): Don't define to __restrict if
11359         __cplusplus is defined.
11360
11361 2005-08-14  Jim Meyering  <jim@meyering.net>
11362
11363         Sync from coreutils.
11364
11365         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
11366         Use the hash-table-based cycle-detection code not just when
11367         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
11368         Reported by James Youngman in
11369         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
11370         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
11371         FTS_TIGHT_CYCLE_CHECK.
11372         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
11373         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
11374         once again.
11375         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
11376         * lib/fts.c (fd_safer): Remove decl.
11377         Include fcntl--.h rather than unistd-safer.h
11378         (fts_safe_changedir): Don't call fd_safer; no longer needed
11379         now that we include fcntl--.h.
11380
11381 2005-08-12  Simon Josefsson  <jas@extundo.com>
11382
11383         * modules/getndelim2: Use ssize_t module.
11384         * modules/getnline: Likewise.
11385         * modules/safe-read: Likewise.
11386         * modules/xreadlink: Likewise.
11387
11388         * modules/ssize_t: New file.
11389
11390 2005-08-12  Simon Josefsson  <jas@extundo.com>
11391
11392         * m4/readline.m4: Look for termcap, curses or ncurses if required.
11393
11394 2005-08-12  Simon Josefsson  <jas@extundo.com>
11395
11396         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11397         ssize_t.
11398
11399 2005-08-12  Simon Josefsson  <jas@extundo.com>
11400
11401         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
11402         readline, getdelim and check_version.
11403         (Support for systems lacking ISO C 99: Sizes of integer types):
11404         Add size_max.
11405
11406 2005-08-12  Bruno Haible  <bruno@clisp.org>
11407
11408         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
11409
11410 2005-08-11  Simon Josefsson  <jas@extundo.com>
11411
11412         * modules/readline: New file.
11413
11414         * modules/strnlen (Files): Add strnlen.h.
11415
11416 2005-08-11  Simon Josefsson  <jas@extundo.com>
11417
11418         * m4/readline.m4: New file.
11419
11420 2005-08-11  Simon Josefsson  <jas@extundo.com>
11421
11422         * lib/readline.h, readline.c: New file.
11423
11424 2005-08-11  Simon Josefsson  <jas@extundo.com>
11425
11426         * doc/gnulib.texi (Initial import, Finishing touches): Mention
11427         gl_AVOID.
11428
11429 2005-08-11  Bruno Haible  <bruno@clisp.org>
11430
11431         * lib/strnlen.h (strnlen): Change parameter name to match comment.
11432
11433 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
11434
11435         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
11436
11437 2005-08-10  Simon Josefsson  <jas@extundo.com>
11438
11439         * tests/test-iconvme.c: New file.
11440
11441 2005-08-10  Simon Josefsson  <jas@extundo.com>
11442
11443         * m4/strnlen.m4: New file.
11444
11445         * m4/strndup.m4: Don't check for strnlen declaration, done in
11446         strnlen.m4.
11447
11448 2005-08-10  Simon Josefsson  <jas@extundo.com>
11449
11450         * lib/strndup.c: Use strnlen.h.
11451
11452         * lib/strnlen.h: New file.
11453
11454 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11455
11456         * README: Typos.
11457
11458 2005-08-02  Simon Josefsson  <jas@extundo.com>
11459
11460         * modules/readline: New file.
11461
11462 2005-08-02  Simon Josefsson  <jas@extundo.com>
11463
11464         * modules/getdelim: New file.
11465
11466         * modules/getline: Rewrite, don't use getndelim2.
11467
11468 2005-08-02  Simon Josefsson  <jas@extundo.com>
11469
11470         * m4/getline.m4: Separate out getdelim stuff into separate module.
11471
11472         * m4/getdelim.m4: New file.
11473
11474 2005-08-02  Simon Josefsson  <jas@extundo.com>
11475
11476         * lib/getline.h, getline.c: Rewrite.
11477
11478         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
11479
11480 2005-07-31  Bruno Haible  <bruno@clisp.org>
11481
11482         * lib/lock.h (gl_lock_initializer): New macro.
11483         (gl_lock_define_initialized): Use it.
11484         (gl_rwlock_initializer): New macro.
11485         (gl_rwlock_define_initialized): Use it.
11486         (gl_recursive_lock_initializer): New macro.
11487         (gl_recursive_lock_define_initialized): Use it.
11488
11489 2005-07-30  Karl Berry  <karl@gnu.org>
11490
11491         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
11492         Report from Ben Pfaff, regarding getopt.
11493
11494 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
11495
11496         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
11497         normal way.
11498         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
11499         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
11500         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
11501         (gl_GETOPT): Use the new macros.  Most of the implementation
11502         is moved to the new macros.  This is for programs like Emacs
11503         that don't want all the functionality of gl_GETOPT.
11504
11505 2005-07-26  Bruno Haible  <bruno@clisp.org>
11506
11507         * m4/lock.m4: Update from GNU gettext.
11508
11509 2005-07-26  Bruno Haible  <bruno@clisp.org>
11510
11511         * lib/lock.h: Update from GNU gettext.
11512         * lib/lock.c: Update from GNU gettext.
11513
11514 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
11515
11516         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
11517         obsolescent AC_TRY_RUN.  Include the default includes files, for
11518         'exit'.
11519
11520 2005-07-24  Bruno Haible  <bruno@clisp.org>
11521
11522         * modules/visibility: New file.
11523         * MODULES.html.sh (Misc): Add visibility.
11524
11525 2005-07-24  Bruno Haible  <bruno@clisp.org>
11526
11527         * m4/visibility.m4: New file.
11528
11529 2005-07-24  Bruno Haible  <bruno@clisp.org>
11530
11531         * doc/visibility.texi: New file.
11532
11533 2005-07-22  Bruno Haible  <bruno@clisp.org>
11534
11535         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
11536         $(ALLOCA_H), redundant through BUILT_SOURCES.
11537         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
11538         redundant through BUILT_SOURCES.
11539         * modules/byteswap (Makefile.am): Remove explicit dependency on
11540         $(BYTESWAP_H), redundant through BUILT_SOURCES.
11541         * modules/fnmatch (Makefile.am): Remove explicit dependency on
11542         $(FNMATCH_H), redundant through BUILT_SOURCES.
11543         * modules/getopt (Makefile.am): Remove explicit dependency on
11544         $(GETOPT_H), redundant through BUILT_SOURCES.
11545         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
11546         redundant through BUILT_SOURCES.
11547         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
11548         redundant through BUILT_SOURCES.
11549         * modules/stdbool (Makefile.am): Remove explicit dependency on
11550         $(STDBOOL_H), redundant through BUILT_SOURCES.
11551         * modules/stdint (Makefile.am): Remove explicit dependency on
11552         $(STDINT_H), redundant through BUILT_SOURCES.
11553         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
11554         Remove explicit dependency on $(SYSEXITS_H).
11555         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
11556
11557 2005-07-18  Simon Josefsson  <jas@extundo.com>
11558
11559         * lib/check-version.c (check_version): Accept identical versions too.
11560
11561 2005-07-18  Bruno Haible  <bruno@clisp.org>
11562
11563         * modules/lock: New file.
11564         * MODULES.html.sh (Multithreading): New section.
11565
11566 2005-07-18  Bruno Haible  <bruno@clisp.org>
11567
11568         * m4/lock.m4: New file, from GNU gettext.
11569
11570 2005-07-18  Bruno Haible  <bruno@clisp.org>
11571
11572         * lib/lock.h: New file, from GNU gettext.
11573         * lib/lock.c: New file, from GNU gettext.
11574
11575 2005-07-18  Bruno Haible  <bruno@clisp.org>
11576
11577         * lib/lock.h (gl_once_t): New type.
11578         (gl_once_define, gl_once): New macros.
11579         * lib/lock.c (fresh_once): New variable.
11580         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
11581         functions.
11582
11583 2005-07-16  Simon Josefsson  <jas@extundo.com>
11584
11585         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
11586         workaround, suggested by Bruno.
11587
11588 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11589
11590         * modules/xalloc (Depends-on): Add xalloc-die.
11591         * modules/xvasprintf (Depends-on): Add xalloc-die.
11592
11593 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11594
11595         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
11596         with a minor change.
11597
11598 2005-07-15  Bruno Haible  <bruno@clisp.org>
11599
11600         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
11601         When using lib/poll.c, define poll as rpl_poll.
11602
11603 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
11604
11605         * modules/argp (Depends-on): Remove unlocked-io.
11606
11607 2005-07-14  Derek Price  <derek@ximbiot.com>
11608
11609         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
11610         for glob symlink bug.
11611
11612 2005-07-14  Bruno Haible  <bruno@clisp.org>
11613
11614         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
11615         Instead, test for *_unlocked function declarations directly.
11616
11617 2005-07-11  Simon Josefsson  <jas@extundo.com>
11618
11619         * modules/size_max: New file.
11620
11621         * modules/xsize: Depend on size_max module for size_max.m4.
11622
11623 2005-07-11  Simon Josefsson  <jas@extundo.com>
11624
11625         * lib/size_max.h: New file.
11626
11627 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
11628
11629         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
11630         copyright symbol and the year.
11631         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
11632         (version_etc_va): Use parameterized copyright notice.
11633         Reword to conform to the current GNU coding standards.
11634
11635 2005-07-11  Karl Berry  <karl@gnu.org>
11636
11637         * doc/gnulib.texi (Quoting): new node.
11638         (Initial import): more info, from Patrice.
11639
11640 2005-07-11  Bruno Haible  <bruno@clisp.org>
11641
11642         * gnulib-tool (func_usage): Document option --avoid.
11643         (Command line options): Handle --avoid.
11644         (func_acceptable): New function.
11645         (func_modules_transitive_closure): Use it.
11646
11647 2005-07-11  Bruno Haible  <bruno@clisp.org>
11648
11649         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
11650         Reported by Jim Meyering.
11651
11652 2005-07-10  Bruno Haible  <bruno@clisp.org>
11653
11654         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
11655         Needed when size_t is smaller than 'unsigned int'.
11656         Reported by Paul Eggert.
11657
11658 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11659
11660         * modules/argp (Depends-on): Add unlocked-io
11661
11662 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11663
11664         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
11665         block of defines.
11666
11667 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11668
11669         * config/srclist.txt: Comment out regcomp.c, since we have a porting
11670         fix now.
11671
11672 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
11673         and Paul Eggert  <eggert@cs.ucla.edu>
11674
11675         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
11676         in wint_t, not wchar_t.  Remove now-unnecessary cast.
11677
11678 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11679
11680         * modules/regex (Files): Add lib/regex_internal.c,
11681         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
11682         (Depends-on): Add extensions.
11683         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
11684
11685 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11686
11687         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
11688         pathconf.
11689         * m4/same.m4 (gl_SAME): Likewise.
11690         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
11691
11692         * m4/regex.m4: Adjust to new libc regex implementation.
11693         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
11694         all the .c and .h parts of (the new) regex.
11695         Quote the m4 stuff better.
11696         Check for RE_ICASE bug of old gnulib.
11697         Check for REG_STARTEND of recent libc.
11698         Rename local variables from jm_* to gl_*.
11699         Quote operand of "test -f".
11700         Say "recent enough" version of libc, not "version 2".
11701         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
11702         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
11703         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
11704         Remove check for btowc, isascii.
11705         Require AM_LANGINFO_CODESET.
11706
11707 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11708
11709         * lib/regex.c, regex.h: Sync from libc.
11710         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
11711         * lib/regexec.c:
11712         New files, synced from libc, except that regex_internal.h
11713         currently has a small porting fix.
11714
11715 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
11716
11717         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
11718         regex_internal.c, regexec.c.
11719         Add regex_internal.h too, but as a comment, since the libc version
11720         is currently broken in gnulib mode.
11721
11722 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11723
11724         Support programs like Emacs that use gnulib but not gettext.
11725         * MODULES.html.sh (Internationalization functions): Add gettext-h.
11726         * modules/gettext-h: New file.
11727         * modules/gettext (Files): Remove lib/gettext.h.
11728         (Depends-on): Add gettext-h.
11729         (Makefile.am): Remove lib_SOURCES.
11730         * modules/argmatch, modules/c-stack, modules/closeout:
11731         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
11732         * modules/execute, modules/file-type, modules/getaddrinfo:
11733         * modules/getopt, modules/human, modules/javacomp:
11734         * modules/javaexec, modules/mkdir-p, modules/obstack:
11735         * modules/openat, modules/pagealign_alloc, modules/pipe:
11736         * modules/quotearg, modules/regex, modules/rpmatch:
11737         * modules/unicodeio, modules/userspec, modules/version-etc:
11738         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
11739         * modules/xsetenv:
11740         Depend on gettext-h, not gettext.
11741
11742 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11743
11744         * gnulib-tool (func_import): Add support for 'public domain' license.
11745         * modules/alloca, modules/atexit, modules/memmove:
11746         Now public domain, not GPL.
11747         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
11748         * modules/realloc, modules/strerror, modules/strtod:
11749         Now LGPL, not GPL.
11750
11751 2005-07-05  Bruno Haible  <bruno@clisp.org>
11752
11753         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
11754         autoconf CVS. Needed for mingw.
11755
11756 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11757
11758         Remove the dependency of the strftime module on the tzset module.
11759         * modules/strftime (Depends-on): Remove dependency on tzset.
11760
11761 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11762
11763         Remove the dependency of the strftime module on the tzset module.
11764         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
11765         gl_FUNC_TZSET_CLOBBER.
11766
11767 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11768
11769         Remove the dependency of the strftime module on the tzset module.
11770         * lib/strftime.c (my_strftime)
11771         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
11772         Copy the input structure, to work around some of the bug with
11773         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
11774         Solaris releases, you should also use the tzset module, but we won't
11775         require it as a dependency any more since we don't want LGPLed code
11776         to depend on GPLed code.
11777
11778 2005-07-02  Jim Meyering  <jim@meyering.net>
11779
11780         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
11781         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
11782         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
11783         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
11784
11785 2005-07-02  Jim Meyering  <jim@meyering.net>
11786
11787         * lib/backupfile.c (backup_args): Change a `0' to NULL.
11788
11789 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11790
11791         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
11792         declares only 'struct timespec;' (!).
11793
11794 2005-07-01  Jim Meyering  <jim@meyering.net>
11795
11796         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
11797         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
11798         * lib/save-cwd.c, tempname.c:
11799         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
11800         and don't include <sys/file.h>).
11801
11802 2005-06-29  Jim Meyering  <jim@meyering.net>
11803
11804         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
11805         type name.  Use the variable name instead.
11806         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
11807         Likewise.
11808
11809 2005-06-28  Simon Josefsson  <jas@extundo.com>
11810
11811         * modules/check-version (Files): Add check-version.m4.
11812
11813 2005-06-28  Simon Josefsson  <jas@extundo.com>
11814
11815         * m4/check-version.m4: New file, suggested by Jim Meyering
11816         <jim@meyering.net>.
11817
11818 2005-06-28  Simon Josefsson  <jas@extundo.com>
11819
11820         * lib/check-version.h, lib/check-version.c: New files.
11821
11822 2005-06-28  Simon Josefsson  <jas@extundo.com>
11823
11824         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
11825         collision with global variable.  Better indentation.  Don't
11826         increment buffer pointer beyond buffer end.  Based on comments
11827         from Paul Eggert <eggert@cs.ucla.edu>.
11828
11829         * lib/base64.h: Indent.
11830
11831 2005-06-28  Simon Josefsson  <jas@extundo.com>
11832
11833         * doc/gnulib.texi (Library version handling): New section.
11834
11835 2005-06-28  Jim Meyering  <jim@meyering.net>
11836
11837         * check-module (find_included_lib_files): Hard-code another
11838         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
11839         but modules/fts-lgpl (correctly) does not list those files.
11840
11841         * modules/canonicalize (Files): Add lib/pathmax.h.
11842
11843 2005-06-25  Simon Josefsson  <jas@extundo.com>
11844
11845         * modules/check-version: New file.
11846
11847 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
11848
11849         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
11850         initializer of struct addrinfo, as an indication that we don't
11851         care how many members the structure has.
11852
11853 2005-06-24  Derek Price  <derek@ximbiot.com>
11854         and Bruno Haible  <bruno@clisp.org>
11855
11856         Remove stat module & update lstat.
11857         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
11858         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
11859         * m4/stat.m4: Remove this file.
11860
11861 2005-06-24  Derek Price  <derek@ximbiot.com>
11862         and Bruno Haible  <bruno@clisp.org>
11863
11864         Remove stat module & update lstat.
11865         * lib/stat.c: Remove this file...
11866         (slash_aware_lstat): ...moving this content and its support...
11867         * lib/lstat.c (rpl_lstat): ...into here.
11868         * lib/lstat.h: New file.
11869
11870 2005-06-24  Derek Price  <derek@ximbiot.com>
11871         and Bruno Haible  <bruno@clisp.org>
11872
11873         Remove stat module & update lstat.
11874         * config/srclist.txt (libc sources): Remove stat.
11875
11876 2005-06-24  Derek Price  <derek@ximbiot.com>
11877         and Bruno Haible  <bruno@clisp.org>
11878
11879         Remove stat module & update lstat.
11880         * MODULES.html.sh (stat): Remove.
11881         * MODULES.html: Regenerated.
11882         * modules/lstat (Description): Correct function name.
11883         (Files): Add "lstat.h".
11884         (Depends-on): Remove stat, add xalloc, stat-macros.
11885         * modules/stat: Remove this file.
11886         (Include): Add "lstat.h", remove <sys/stat.h>.
11887
11888 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
11889
11890         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
11891         (ranged_convert): Don't save conversion in a temporary struct.
11892         This causes a warning with GCC 4.0.0, and anyway in the typical
11893         case it's not worth the extra 100 bytes or so of code.
11894         (ranged_convert, __mktime_internal): When calling a function via a
11895         pointer P, use P () rather than (*P) (), as we now assume C89 or
11896         better.
11897
11898 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
11899
11900         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
11901         "who -r" failed to give output.  Problem reported by Tim Waugh.
11902
11903         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
11904         (xcalloc): Use it to avoid needless tests.
11905         Problem reported by Jim Meyering.
11906
11907 2005-06-20  Derek Price  <derek@ximbiot.com>
11908
11909         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
11910         unnecessary for Autoconfs > 2.59c.
11911
11912 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11913
11914         * lib/argp.h (__option_is_short): Check upper limit of
11915         __key. Isprint() requires its argument to have the value
11916         of an unsigned char or EOF.
11917
11918 2005-06-16  Jim Meyering  <jim@meyering.net>
11919
11920         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
11921         when either N or S is zero.
11922
11923 2005-06-16  Derek Price  <derek@ximbiot.com>
11924
11925         * m4/bison.m4: Declare YACC & YFLAGS precious.
11926
11927 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
11928
11929         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
11930         multibyte string or pattern, fall back on unibyte matching.
11931         Problem reported by James Youngman.
11932
11933 2005-06-08  Bruno Haible  <bruno@clisp.org>
11934
11935         * modules/csharpcomp: New file.
11936         * MODULES.html.sh (C#): Add csharpcomp.
11937
11938 2005-06-08  Bruno Haible  <bruno@clisp.org>
11939
11940         * m4/csharpcomp.m4: New file, from GNU gettext.
11941
11942 2005-06-08  Bruno Haible  <bruno@clisp.org>
11943
11944         * lib/csharpcomp.h: New file, from GNU gettext.
11945         * lib/csharpcomp.c: New file, from GNU gettext.
11946         * lib/csharpcomp.sh.in: New file, from GNU gettext.
11947
11948 2005-06-08  Bruno Haible  <bruno@clisp.org>
11949
11950         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
11951         warning on mingw.
11952
11953 2005-06-07  Derek Price  <derek@ximbiot.com>
11954
11955         Sync from CVS.
11956         * lib/glob_.h: Indent nested #ifdef.
11957
11958 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
11959
11960         Sync from coreutils.
11961         Use "file name" when talking about file names, instead of "filename"
11962         or "path", as per the GNU coding standards.
11963         * lib/mkdir-p.c: Renamed from makepath.c.
11964         (make_dir_parents): Renamed from make_path.  All callers changed.
11965         * lib/mkdir-p.h: Likewise.  All includers changed.
11966         * lib/filenamecat.c: Renamed from path-concat.c.
11967         (file_name_concat): Renamed from path_concat.  All callers changed.
11968         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
11969         * lib/filenamecat.h: Likewise.  All includers changed.
11970         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
11971         in comments or local variable names.
11972         * lib/basename.c: Likewise.
11973         * lib/canonicalize.c, canonicalize.h: Likewise.
11974         * lib/dirname.c, dirname.h: Likewise.
11975         * lib/euidaccess.c: Likewise.
11976         * lib/exclude.c: Likewise
11977         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
11978         * lib/fsusage.c, fsuage.h: Likewise.
11979         * lib/fts.c, fts_.h: Likewise.
11980         * lib/getcwd.c: Likewise.
11981         * lib/getloadavg.c: Likewise.
11982         * lib/mkstemp.c: Likewise.
11983         * lib/mountlist.c, mountlist.h: Likewise.
11984         * lib/openat.c, openat.h: Likewise.
11985         * lib/readlink-stub.c: Likewise.
11986         * lib/readutmp.c, readutmp.h: Likewise.
11987         * lib/rename.c: Likewise.
11988         * lib/rmdir.c: Likewise.
11989         * lib/same.c: Likewise.
11990         * lib/savedir.c: Likewise.
11991         * lib/stripslash.c: Likewise.
11992         * lib/tempname.c: Likewise.
11993         * lib/xreadlink.c: Likewise.
11994         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
11995         All uses changed.
11996         * lib/exclude.h: Likewise.
11997
11998         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
11999         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12000         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
12001         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12002         * lib/pathmax.h: Include <limits.h> unconditionally, since other
12003         files have been getting away with it for years (MORE/BSD 4.3
12004         is extinct now).
12005         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
12006         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12007
12008         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
12009         Define to 256, not 255, as per modern POSIX.
12010
12011 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12012
12013         Sync from coreutils.
12014         Use "file name" when talking about file names, instead of "filename"
12015         or "path", as per the GNU coding standards.
12016         * MODULES.html.sh: mkdir-p renamed from makepath.
12017         filenamecat renamed from path-concat.
12018         * modules/filenamecat: Renamed from modules/path-concat.
12019         (Files): filenamecat.h and filenamecat.c renamed from
12020         path-concat.h and path-concat.c.
12021         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
12022         (Include): filenamecat.h, not path-concat.h.
12023         * modules/mkdir-p: Renamed from modules/makepath.
12024         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
12025         makepath.c.
12026         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
12027         (Include): mkdir-p.h, not makepath.h.
12028
12029 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12030
12031         Sync from coreutils.
12032         * m4/mkdir-p.m4: Renamed from makepath.m4.
12033         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
12034         Rename files from makepath.c to mkdir-p.c, and from
12035         makepath.h to mkdir-p.h.
12036         * m4/filenamecat.m4: Renamed from path-concat.m4.
12037         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
12038         Rename files from path-concat.c to filenamecat.c,
12039         and from path-concat.h to filenamecat.h.
12040         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
12041         "file name" in local variables or comments.
12042         * m4/rename.m4: Likewise.
12043
12044 2005-06-01  Bruno Haible  <bruno@clisp.org>
12045
12046         * modules/csharpexec: New file.
12047         * MODULES.html.sh (C#): New section.
12048
12049 2005-06-01  Bruno Haible  <bruno@clisp.org>
12050
12051         * m4/csharp.m4: New file, from GNU gettext.
12052         * m4/csharpexec.m4: New file, from GNU gettext.
12053
12054 2005-06-01  Bruno Haible  <bruno@clisp.org>
12055
12056         * lib/csharpexec.h: New file, from GNU gettext.
12057         * lib/csharpexec.c: New file, from GNU gettext.
12058         * lib/csharpexec.sh.in: New file, from GNU gettext.
12059
12060 2005-05-31  Derek Price  <derek@ximbiot.com>
12061             Paul Eggert  <eggert@cs.ucla.edu>
12062
12063         Sync from cvs.
12064         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12065
12066 2005-05-31  Derek Price  <derek@ximbiot.com>
12067             Paul Eggert  <eggert@cs.ucla.edu>
12068
12069         Sync from cvs.
12070         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12071
12072 2005-05-29  Derek Price  <derek@ximbiot.com>
12073
12074         * config/srclist.txt (glob_.h, glob.c): Add these files.
12075
12076 2005-05-29  Derek Price  <derek@ximbiot.com>
12077
12078         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
12079         * modules/glob: New file.
12080         * modules/getlogin_r: Add link to POSIX spec in description.
12081
12082 2005-05-29  Derek Price  <derek@ximbiot.com>
12083             Paul Eggert  <eggert@cs.ucla.edu>
12084
12085         * m4/glob.m4: New file.
12086
12087 2005-05-29  Derek Price  <derek@ximbiot.com>
12088             Paul Eggert  <eggert@cs.ucla.edu>
12089
12090         * lib/glob_.h, lib/glob.c: New files.
12091
12092 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12093
12094         * modules/fts (Files): Remove m4/inttypes-pri.m4.
12095         * modules/fts-lgpl (Depends-on): Remove gettext.
12096
12097 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12098
12099         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
12100         and don't require gt_INTTYPES_PRI.
12101
12102 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12103
12104         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
12105
12106         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
12107         the configuration hassle isn't worth it.
12108         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
12109         (LONGEST_MODIFIER, PRIuMAX): Remove.
12110
12111 2005-05-27  Bruno Haible  <bruno@clisp.org>
12112
12113         * lib/getlogin_r.h: Remove second include of <stddef.h>.
12114
12115 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
12116
12117         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
12118         _POSIX_PTHREAD_SEMANTICS for Solaris.
12119
12120 2005-05-25  Derek Price  <derek@ximbiot.com>
12121
12122         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
12123
12124 2005-05-25  Derek Price  <derek@ximbiot.com>
12125             Paul Eggert  <eggert@cs.ucla.edu>
12126
12127         * modules/getlogin_r, m4/getlogin_r.m4: New files.
12128         * lib/getlogin_r.c, getlogin_r.h: New files.
12129
12130 2005-05-25  Bruno Haible  <bruno@clisp.org>
12131             Derek Price  <derek@ximbiot.com>
12132
12133         * lib/getlogin_r.h: Simplify API documentation.
12134
12135 2005-05-23  Derek Price  <derek@ximbiot.com>
12136
12137         * modules/minmax (Files): Add m4/minmax.m4.
12138         (configure.ac): Add gl_MINMAX.
12139
12140 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
12141
12142         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
12143         so that unistd-safer.h (GPL'ed code) need not be included.
12144
12145 2005-05-22  Bruno Haible  <bruno@clisp.org>
12146
12147         * m4/minmax.m4: New file.
12148         Based on a patch by Derek Price <derek@ximbiot.com>.
12149
12150 2005-05-22  Bruno Haible  <bruno@clisp.org>
12151
12152         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
12153         (INT64_MIN): Fix definition.
12154         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
12155
12156         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
12157         NEED_SIGNED_INT_TYPES.
12158
12159         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
12160         HAVE_SYSTEM_INTTYPES.
12161
12162 2005-05-22  Bruno Haible  <bruno@clisp.org>
12163
12164         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
12165         Also include <sys/param.h> if it defines MIN, MAX.
12166         Based on a patch by Derek Price <derek@ximbiot.com>.
12167
12168 2005-05-21  Jim Meyering  <jim@meyering.net>
12169
12170         * modules/fts (Files): Add m4/inttypes-pri.m4.
12171         (Depends-on): Add lstat and remove gettext.  Alphabetize.
12172
12173 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12174
12175         New fts module.
12176         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
12177         (setup_dir, free_dir): New functions.
12178         (enter_dir, leave_dir): Define trivial
12179         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
12180         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
12181         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
12182         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
12183         Move to fts-cycle.c.
12184         (fts_open): Use setup_dir.
12185         (fts_close): Use free_dir.
12186         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
12187         This adds a label and some gotos, but the alternatives were messier.
12188         Check for memory allocation failure when entering a dir.
12189         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
12190         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
12191         (FTS): New member fts_cycle, that is a union that contains the
12192         old active_dir_ht and cycle_state.  All uses changed to mention
12193         fts_cycle.ht and fts_cycle.state.
12194         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
12195         fts.c, with the following changes:
12196         (setup_dir, free_dir): New functions.
12197         (enter_dir): Now returns bool.  Return true if successful, false
12198         if memory exhausted.  All callers changed.
12199         Do not bother partly cleaning up on
12200         memory allocation failure; that is free_dir's job.
12201         However, free ad if hash_insert fails, to avoid memory leak.
12202         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
12203         fts->fts_options to see which union member to use.
12204
12205 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12206
12207         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
12208         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
12209
12210 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12211
12212         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
12213
12214 2005-05-20  Jim Meyering  <jim@meyering.net>
12215
12216         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
12217         Now a macro, to pacify GCC.
12218
12219 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12220
12221         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
12222         of -1.
12223
12224 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12225
12226         * lib/chown.c (rpl_chown): Return -1 on failure.
12227
12228 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12229
12230         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
12231         Don't check for stddef.h.
12232         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
12233         don't use its results.
12234         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
12235         since we include them unconditionally.  Don't require
12236         AM_STDBOOL_H, since stdbool is a prerequisite.
12237         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
12238         since we assume C89 or better.
12239         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
12240         as we don't use their results.
12241         Don't check for fchdir, memmove, memset, strrchr, as we use
12242         them unconditionally.
12243         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
12244         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
12245
12246 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12247
12248         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
12249         Include <stddef.h> unconditionally, since we assume C89 now.
12250         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
12251         * lib/fts.c: Include fts_.h first, to check interface.
12252         Do not include intprops.h; no longer needed.
12253         Include cycle-check.h and hash.h, since fts_.h no longer does.
12254         Remove unnecessary casts of closedir to void.
12255         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
12256         decide whether to decrement nlinks.
12257         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
12258         (FTS): Use struct hash_table * instead of Hash_table, so that
12259         we no longer need to include hash.h here.
12260
12261 2005-05-18  Jim Meyering  <jim@meyering.net>
12262
12263         * modules/dirfd (License): Change to LGPL.  Most of the code
12264         is already in the public domain.
12265
12266 2005-05-18  Jim Meyering  <jim@meyering.net>
12267
12268         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
12269         Reported by Yoann Vandoorselaere.
12270
12271 2005-05-17  Jim Meyering  <jim@meyering.net>
12272
12273         * m4/fts.m4: New file, from coreutils.
12274
12275 2005-05-17  Jim Meyering  <jim@meyering.net>
12276
12277         * lib/fts.c, lib/fts_.h: New files, from coreutils.
12278
12279 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12280
12281         Sync from coreutils.
12282         * m4/unlinkdir.m4: New file.
12283
12284 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12285
12286         Sync from coreutils.
12287         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
12288         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
12289         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
12290         White space changes only.
12291         * lib/makepath.c (make_path): Port to hosts where leading "//" is
12292         special.
12293         * lib/yesno.c: Include getline.h, not ctype.h.
12294         (yesno): Don't remove leading white space; POSIX doesn't allow it.
12295         Use getline to remove arbitrary restriction on response length.
12296
12297 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12298
12299         * config/srclist-update: Spell out "Street" in FSF postal
12300         mail address; this is the style the FSF seems to prefer.
12301
12302         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
12303         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
12304         this updates FSF postal mail address.
12305
12306         Sync from coreutils.
12307         * modules/unlinkdir: New file.
12308         * modules/yesno (Depends-on): Add getline.
12309         * MODULES.html.sh (File system functions): Add unlinkdir.
12310
12311 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12312
12313         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
12314         lib/strsep.h:
12315         Change the initial comment to refer to GPL, not LGPL.
12316         gnulib-tool will change it to LGPL as needed.
12317
12318         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
12319         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
12320         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
12321         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
12322         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
12323         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
12324         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
12325         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
12326         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
12327         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
12328         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
12329         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
12330         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
12331         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
12332         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
12333         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
12334         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
12335         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
12336         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
12337         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
12338         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
12339         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
12340         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
12341         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
12342         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
12343         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
12344         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
12345         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
12346         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
12347         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
12348         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
12349         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
12350         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
12351         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
12352         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
12353         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
12354         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
12355         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
12356         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
12357         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
12358         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
12359         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
12360         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
12361         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
12362         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
12363         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
12364         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
12365         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
12366         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
12367         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
12368         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12369         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
12370         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
12371         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
12372         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
12373         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
12374         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
12375         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
12376         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
12377         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
12378         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
12379         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
12380         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
12381         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
12382         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
12383         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
12384         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
12385         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
12386         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
12387         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
12388         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
12389         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
12390         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
12391         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
12392         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
12393         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
12394         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
12395         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
12396         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
12397         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
12398         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
12399         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
12400         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
12401         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
12402         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
12403         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
12404         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
12405         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
12406         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
12407         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
12408         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
12409         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
12410         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
12411         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
12412         lib/yesno.c, lib/yesno.h:
12413         Update FSF postal mail address.
12414
12415 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12416
12417         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
12418         tests/test-memmem.c, tests/test-stpncpy.c:
12419         Update FSF postal mail address.
12420
12421 2005-05-13  Bruno Haible  <bruno@clisp.org>
12422
12423         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
12424         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
12425         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
12426         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
12427         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
12428         Add support for 64-bit integers in the MSVC compiler.
12429
12430 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12431
12432         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
12433
12434 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
12435
12436         * gnulib-tool (func_import): Sort and uniquify recommended includes.
12437
12438 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
12439
12440         * doc/getdate.texi (General date syntax): Don't say that date
12441         date --iso-8601=ns generates acceptable dates; it doesn't yet.
12442         Problem reported by Nic Ferrier.
12443
12444 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12445
12446         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
12447         specified in ai_socktype. Fix invalid ai_protocol
12448         check. ai_protocol is usually set to 0 or depending on
12449         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
12450         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
12451         ai_socktype / ai_protocol in the returned addrinfo structure.
12452
12453 2005-05-10  Simon Josefsson  <jas@extundo.com>
12454
12455         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
12456         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12457
12458 2005-05-10  Karl Berry  <karl@gnu.org>
12459
12460         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
12461         (from http://www.gnu.org/licenses).
12462         * doc/COPYING.LIB: also rename to COPYING.LESSER.
12463         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
12464         fdl.texi suffices.
12465
12466 2005-05-10  Karl Berry  <karl@gnu.org>
12467
12468         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
12469         (COPYING.DOC): remove.
12470
12471         * config/srclist-update: new FSF address.
12472
12473 2005-05-10  Derek Price  <derek@ximbiot.com>
12474
12475         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
12476         possible.
12477
12478 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12479             Bruno Haible  <bruno@clisp.org>
12480
12481         * modules/inet_ntop: New file.
12482         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12483         inet_ntop.
12484
12485 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12486             Bruno Haible  <bruno@clisp.org>
12487
12488         * m4/inet_ntop.m4: New file.
12489
12490 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12491             Bruno Haible  <bruno@clisp.org>
12492
12493         * lib/inet_ntop.h: New file.
12494         * lib/inet_ntop.c: New file, from glibc with modifications.
12495
12496 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
12497
12498         * modules/time_r (License): Change to LGPL.
12499         * modules/extensions (License): Change to LGPL.  Actually,
12500         the license is more permissive than that, but currently gnulib-tool
12501         doesn't know how to handle more-permissive licenses.
12502
12503         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
12504         Problem reported by Dave Love.
12505
12506 2005-05-08  Jim Meyering  <jim@meyering.net>
12507
12508         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
12509         blank.
12510
12511 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12512
12513         * modules/argmatch (Depends-on): Add stdbool.
12514         * modules/backupfile (Depends-on): Likewise.
12515         * modules/chdir-long (Depends-on): Likewise.
12516         * modules/closeout (Depends-on): Likewise.
12517         * modules/cycle-check (Depends-on): Likewise.
12518         * modules/dirname (Depends-on): Likewise.
12519         * modules/fnmatch (Depends-on): Likewise.
12520         * modules/fsusage (Depends-on): Likewise.
12521         * modules/fwriteerror (Depends-on): Likewise.
12522         * modules/getcwd (Depends-on): Likewise.
12523         * modules/getloadavg (Depends-on): Likewise.
12524         * modules/hard-locale (Depends-on): Likewise.
12525         * modules/makepath (Depends-on): Likewise.
12526         * modules/mountlist (Depends-on): Likewise.
12527         * modules/nanosleep (Depends-on): Likewise.
12528         * modules/posixtm (Depends-on): Likewise.
12529         * modules/quotearg (Depends-on): Likewise.
12530         * modules/readtokens (Depends-on): Likewise.
12531         * modules/readtokens0 (Depends-on): Likewise.
12532         * modules/readutmp (Depends-on): Likewise.
12533         * modules/save-cwd (Depends-on): Likewise.
12534         * modules/strftime (Depends-on): Likewise.
12535         * modules/userspec (Depends-on): Likewise.
12536         * modules/utimecmp (Depends-on): Likewise.
12537         * modules/xgetcwd (Depends-on): Likewise.
12538         * modules/xnanosleep (Depends-on): Likewise.
12539         * modules/xstrtod (Depends-on): Likewise.
12540         * modules/yesno (Depends-on): Likewise.
12541
12542 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
12543
12544         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
12545         needless checks.
12546
12547 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12548
12549         Merge from coreutils.  Among other things,
12550         add bulletproofing for cases where stdin, stdout, or stderr are closed.
12551         * lib/fd-safer.c: New file.
12552         * lib/fcntl-safer.h, open-safer.c: Remove.
12553         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
12554         * lib/dup-safer.c: Include unistd-safer.h first.
12555         Don't include errno.h.
12556         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
12557         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
12558         * lib/file-type.c: Rely on file-type.h change.
12559         * lib/getloadavg.c: Include unistd-safer.h.
12560         (getloadavg): Use safer open.
12561         * lib/getusershell.c: Include "stdio-safer.h".
12562         (getusershell): Use safer fopen.
12563         * lib/long-options.c (long_options): Use NULL rather than 0.
12564         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
12565         'free'.
12566         * lib/modechange.c: Likewise.
12567         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
12568         (MODE_DONE): New constant.
12569         (struct mode_change): Remove 'next' member.
12570         (make_node_op_equals): New function; like the old one of the
12571         same name, except it allocates an array.
12572         (mode_compile, mode_create_from_ref): Use it.
12573         (mode_compile): Allocate result as an array, not a linked list.
12574         Parse octal string ourself, so that we catch mistakes like "+0".
12575         (mode_adjust): Arg is an array, not a linked list.
12576         * lib/modechange.c: Include stat-macros.h, xalloc.h.
12577         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
12578         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
12579         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
12580         Remove.  This is now stat-macros.h's job.
12581         (talloc): Remove.  All callers replaced by xalloc, so that
12582         our invokers don't have to worry about reporting memory failures.
12583         (make_node_op_equals): Remove.
12584         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12585         New constants.
12586         (struct mode_change): Moved here from modechange.h.
12587         (mode_append_entry): Remove.
12588         (mode_compile): Remove MASKED_OPS arg, since it encouraged
12589         apps to have incorrect behavior.  Use simpler algorithm for head
12590         and tail.  Don't futz with umask; that's now the job of mode_adjust.
12591         Detect more invalid usages rather than having somewhat-random behavior.
12592         Don't insert an "a=" action, as that leads to incorrect behavior.
12593         (mode_compile, mode_create_from_ref): Return NULL on error instead
12594         of an enum, since now there's only one way to have an error.  All
12595         callers changed.
12596         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
12597         at the correct time.  Simplify calculation of "+u" and its ilk.
12598         Don't mishandle "+X".
12599         (mode_free): Remove "register" and localize decls.
12600         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12601         (struct mode_change): Move to modechange.c; callers don't
12602         need to see this stuff.
12603         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
12604         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
12605         (mode_change, mode_adjust): Reflect the new signatures noted above.
12606         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
12607         that might redefine system include files.
12608         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
12609         (my_usleep): Use NULL rather than (void *) 0.
12610         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
12611         Use siginterrupt to specify that system calls should be interrupted.
12612         (rpl_nanosleep): Move initialization of suspended closer to call of
12613         my_usleep.
12614         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
12615         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
12616         (desirable_utmp_entry): New function.
12617         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
12618         using x2nrealloc, to simplify logic.
12619         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
12620         size calculation.  Do not assume utmp file is a regular file.
12621         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
12622         (READ_UTMP_CHECK_PIDS): New constant.
12623         * lib/save-cwd.c: Include unistd-safer.h.
12624         (save_cwd): Use fd_safer.
12625         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
12626         [!_LIBC] Include "stat-macros.h" instead.
12627         * lib/unistd-safer.h (fd_safer): New decl.
12628
12629 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12630
12631         * modules/getloadavg (Depends-on): Add unistd-safer.
12632         * modules/getusershell (Depends-on): Add stdio-safer.
12633         * modules/lstat (Depends-on): Remove xalloc.
12634         * modules/mkstemp (Depends-on): Add stat-macros.
12635         * modules/modechange (Depends-on): Remove xstrtol.
12636         Add stat-macros, xalloc.
12637         * modules/save-cwd (Depends-on): Add unistd-safer.
12638         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
12639         * modules/unistd-safer (Files): Add lib/fd-safer.c
12640         (Makefile.am): Remove lib_SOURCES.
12641
12642         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
12643         Remove fcntl-safer; unistd-safer supersedes it.
12644
12645 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12646
12647         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
12648         AC_HEADER_STAT.
12649         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
12650         (gl_PREREQ_CHOWN): Remove.
12651         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
12652         it.  Don't require AC_HEADER_STAT.
12653         (gl_PREREQ_LSTAT): Remove.
12654         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
12655         Don't require AC_HEADER_STAT.
12656         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
12657         (gl_PREREQ_RMDIR): Remove.
12658         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
12659         mention stat-macros.h or AC_HEADER_STAT, since we'll make
12660         the stat-macros module a prerequisite.
12661         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
12662         * m4/filemode.m4 (gl_FILEMODE): Likewise.
12663         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
12664         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
12665         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
12666         variable names.
12667         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
12668         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
12669         variable prefixes.
12670         * m4/fcntl-safer.m4: Remove.
12671         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
12672         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
12673         Invoke gl_PREREQ_FD_SAFER.
12674         (gl_PREREQ_FD_SAFER): New macro.
12675         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
12676         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
12677         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
12678         Remove duplicate call to AC_LIBOBJ(readutmp).
12679         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
12680
12681         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
12682         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
12683
12684 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12685
12686         * MODULES.html.sh (Misc): Add byteswap.
12687
12688 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12689
12690         * modules/getcwd (Depends-on): Add extensions.
12691         * modules/openat (Depends-on): Likewise.
12692
12693 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12694
12695         * modules/byteswap: New file.
12696
12697 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12698
12699         * m4/byteswap.m4: New file.
12700
12701 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
12702
12703         * lib/byteswap_.h: New file.
12704
12705 2005-04-25  Karl Berry  <karl@gnu.org>
12706
12707         * m4/gettext.m4: Update from GNU gettext 0.14.4.
12708
12709 2005-04-25  Albert Chin  <china@thewrittenword.com>
12710
12711         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
12712         Toolkit C bug.
12713
12714 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
12715
12716         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
12717         (func_ln_if_changed) Remove forcibly for no error message
12718         in case file does not exist.
12719
12720 2005-04-19  Simon Josefsson  <jas@extundo.com>
12721
12722         * gnulib-tool (Options): Make --symlink mean --symbolic.
12723
12724 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
12725
12726         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
12727
12728 2005-04-16  Simon Josefsson  <jas@extundo.com>
12729
12730         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
12731
12732 2005-04-15  Simon Josefsson  <jas@extundo.com>
12733
12734         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
12735
12736 2005-04-15  Simon Josefsson  <jas@extundo.com>
12737
12738         * gnulib-tool: Rename --symlink to --symbolic.
12739
12740 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
12741
12742         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
12743         symbolic links to files instead of copying/moving.  Add --aux-dir,
12744         specifying directory relative --dir where auxiliary build tools
12745         are placed.
12746
12747 2005-04-14  Bruno Haible  <bruno@clisp.org>
12748
12749         * modules/allocsa (License): Change to LGPL.
12750         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
12751
12752 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12753
12754         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
12755         that "UTC +1 second" continues to work.  Problem reported
12756         by Dmitry V. Levin.
12757         (relunit_snumber): New rule.
12758         (relunit): Use it.
12759
12760 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
12761
12762         * lib/getdate.y (universal_time_zone_table): New constant.
12763         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
12764         universal_time_zone_table.
12765         (lookup_zone): Prefer universal_time_zone_table to
12766         local_time_zone_table, so that "GMT" time stamps are allowed in
12767         London during the summer.  Problem reported by Ian Abbott.
12768
12769 2005-04-12  Jim Meyering  <jim@meyering.net>
12770
12771         * lib/human.c (humblock): Set *options even when returning due to
12772         xstrtoumax conversion failure.  Thanks to a used-uninitialized
12773         warning from gcc-4.
12774
12775 2005-04-09  Jim Meyering  <jim@meyering.net>
12776
12777         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
12778         -Wuninitialized: initialize tm0.tm_year.
12779
12780 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
12781
12782         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
12783         count, since there's no maximum.  All uses changed.
12784         Add member dsts_seen.
12785         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
12786         not being INT_MAX.
12787         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
12788         Use pc_rels_seen to decide whther a date is absolute.
12789
12790         * lib/getdate.y (number): Don't overwrite year.
12791         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
12792         check.
12793
12794 2005-04-02  Simon Josefsson  <jas@extundo.com>
12795
12796         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
12797         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
12798
12799 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
12800
12801         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
12802         where no absolute path name can be longer than PATH_MAX.
12803
12804 2005-03-27  Jim Meyering  <jim@meyering.net>
12805
12806         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
12807
12808 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
12809
12810         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
12811         "one's complement" -> "ones' complement" in comment, as per Knuth.
12812         "value of type" -> "type or expression" in comment.
12813         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
12814
12815 2005-03-26  Jim Meyering  <jim@meyering.net>
12816
12817         Comment nits.
12818         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
12819         Correct typos: s/or/of/.
12820
12821 2005-03-26  Jim Meyering  <jim@meyering.net>
12822
12823         * modules/check-include-files: Move to ../ and rename to...
12824         * check-module: ...this.
12825
12826 2005-03-25  Jim Meyering  <jim@meyering.net>
12827
12828         * modules/xvasprintf (Files): Add xalloc.h.
12829
12830 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
12831
12832         * modules/gettext (Files): config/config.rpath ->
12833         build-aux/config.rpath
12834         * modules/iconv (Files): Likewise.
12835         Problem reported by Oskar Liljeblad.
12836
12837 2005-03-23  Jim Meyering  <jim@meyering.net>
12838
12839         * modules/check-include-files: New script to check for
12840         missing dependencies, multiple includes, etc.
12841
12842         * modules/c-strtold (Depends-on): Add xalloc.
12843         * modules/c-strtod (Depends-on): Add xalloc.
12844         * modules/hash (Depends-on): Add xalloc.
12845         (Files): Remove lib/xalloc.h.
12846
12847         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
12848         * modules/userspec (Files): Add lib/inttostr.h.
12849
12850 2005-03-23  Jim Meyering  <jim@meyering.net>
12851
12852         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
12853
12854 2005-03-22  Jim Meyering  <jim@meyering.net>
12855
12856         * modules/stat-macros: New module.
12857         * modules/canonicalize, modules/euidaccess, modules/file-type,
12858         * modules/filemode, modules/lchown, modules/makepath,
12859         * modules/rmdir, modules/stat: Depend on new stat-macros module
12860         rather than listing lib/stat-macros.h manually.
12861         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
12862
12863 2005-03-22  Jim Meyering  <jim@meyering.net>
12864
12865         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
12866
12867 2005-03-22  Bruno Haible  <bruno@clisp.org>
12868
12869         * config/srclist.txt: Replace target directory 'config' with
12870         'build-aux'.
12871         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
12872         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
12873         ../build-aux/.
12874
12875 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
12876
12877         * modules/chdir-long (Depends-on): Add mempcpy.
12878
12879         * modules/acl, modules/backupfile, modules/c-strtod,
12880         modules/c-strtold, modules/canon-host, modules/canonicalize,
12881         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
12882         modules/exclude, modules/exitfail, modules/file-type,
12883         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
12884         modules/getdate, modules/getline, modules/getpagesize,
12885         modules/getpass, modules/getugroups, modules/group-member,
12886         modules/hard-locale, modules/hash, modules/human, modules/idcache,
12887         modules/inttostr, modules/long-options, modules/makepath,
12888         modules/md5, modules/memcasecmp, modules/memcoll,
12889         modules/modechange, modules/mountlist, modules/path-concat,
12890         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
12891         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
12892         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
12893         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
12894         modules/strftime, modules/strndup, modules/strverscmp,
12895         modules/timespec, modules/unlocked-io, modules/userspec,
12896         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
12897         modules/yesno:
12898         Remove lib_SOURCES line from Makefile.am section, as this is now
12899         done automatically by the corresponding Autoconf macro.
12900
12901 2005-03-21  Jim Meyering  <jim@meyering.net>
12902
12903         Changes imported from coreutils.
12904
12905         * lib/cycle-check.c: Don't include xalloc.h.
12906
12907         * lib/path-concat.c: Don't include assert.h.
12908         (path_concat): Remove assertion that would have triggered
12909         for ABASE starting with more than one slash.
12910         Reported by Andreas Schwab.
12911
12912         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
12913         properly when ABASE is an absolute file name.
12914         Correct the description of this function.
12915         Include <assert.h>.
12916         Add an assertion and a test driver.
12917         This fixes a bug introduced on 2004-07-02.
12918         Andreas Schwab reported the resulting failure of cp --parents:
12919         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
12920
12921 2005-03-21  Jim Meyering  <jim@meyering.net>
12922
12923         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
12924         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
12925
12926 2005-03-21  Jim Meyering  <jim@meyering.net>
12927         and  Paul Eggert  <eggert@cs.ucla.edu>
12928
12929         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
12930         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
12931         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
12932         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
12933         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
12934         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
12935         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
12936         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
12937         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
12938         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
12939         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
12940         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
12941         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
12942         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
12943         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
12944         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
12945         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
12946         for these modules.
12947
12948 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
12949
12950         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
12951         (which shouldn't happen), generate nothing instead of returning 0
12952         immediately, so that nstrftime (NULL, ...) doesn't return 0.
12953
12954 2005-03-16  Bruno Haible  <bruno@clisp.org>
12955
12956         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
12957         HAVE_LONGLONG_64BIT.
12958
12959 2005-03-16  Bruno Haible  <bruno@clisp.org>
12960
12961         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
12962         HAVE_LONGLONG_64BIT.
12963
12964 2005-03-16  Bruno Haible  <bruno@clisp.org>
12965
12966         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
12967         HAVE_LONGLONG_64BIT.
12968
12969 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
12970
12971         * lib/strftime.c (my_strftime): Prepend space to format so that we can
12972         reliably distinguish strftime failure from empty output on POSIX
12973         hosts.
12974
12975 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
12976
12977         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
12978         (iconv_string): Don't guess a size-zero buffer, as that might cause
12979         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
12980         result would be 'too large', where 'too large' is (heuristically)
12981         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
12982         overflow concerns.  This will prevent some unwanted malloc failures
12983         when the inputs are very large.
12984
12985 2005-03-15  Karl Berry  <karl@gnu.org>
12986
12987         * config/srclist.txt (config.rpath): from gettext.
12988         * config/config.rpath: update.
12989
12990 2005-03-15  Bruno Haible  <bruno@clisp.org>
12991
12992         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
12993         to 'negate'.
12994
12995         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
12996         variable.
12997
12998         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
12999         results.
13000
13001 2005-03-14  Simon Josefsson  <jas@extundo.com>
13002
13003         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
13004         <fx@gnu.org>.
13005
13006 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
13007
13008         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
13009         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
13010         intprops.h.
13011         * lib/strtol.c: Likewise.
13012
13013 2005-03-14  Jim Meyering  <jim@meyering.net>
13014
13015         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
13016         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
13017         to be nonzero so that we (and caller) can detect the difference
13018         between a valid zero-length expansion and an error return, even
13019         when the underlying strftime fails before writing anything into
13020         that location.
13021
13022 2005-03-14  Bruno Haible  <bruno@clisp.org>
13023
13024         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
13025         Update from GNU gettext 0.14.3.
13026
13027 2005-03-10  Jim Meyering  <jim@meyering.net>
13028
13029         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
13030
13031 2005-03-10  Jim Meyering  <jim@meyering.net>
13032
13033         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
13034         so that this module works on systems without fchdir.
13035
13036 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
13037
13038         Factor int-properties macros into a single file, except for
13039         glibc-related files.
13040         * lib/intprops.h: New file.
13041         * lib/getloadavg.c: Include it instead of limits.h.
13042         (INT_STRLEN_BOUND): Remove.
13043         * lib/human.c: Include intprops.h.
13044         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
13045         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
13046         302/1000.
13047         * lib/inttostr.h: Include intprops.h instead of limits.h.
13048         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
13049         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
13050         for consistency with intprops.h.
13051         (time_t_is_integer, twos_complement_arithmetic): Use them.
13052         * lib/sig2str.h: Include <signal.h>, intprops.h.
13053         (INT_STRLEN_BOUND): Remove.
13054         * lib/strftime.c (TYPE_SIGNED): Remove.
13055         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
13056         * lib/strtol.c: Adjust comments to match intprops.h.
13057         * lib/userspec.c: Include intprops.h.
13058         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
13059         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
13060         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
13061         instead of rolling our own expressions.
13062         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
13063
13064         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
13065         instead of int.
13066         (my_strftime): Do not mishandle years close to INT_MAX, by doing
13067         the right thing even if adding 1900 would overflow.  Similarly
13068         for tm_mon + 1 and tm_yday + 1.
13069         Make %Y always equivalent to %C%y, and similarly for %G and %g.
13070         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
13071         (DO_SIGNED_NUMBER): New macro.
13072         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
13073
13074 2005-03-07  Bruno Haible  <bruno@clisp.org>
13075
13076         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
13077
13078 2005-03-07  Bruno Haible  <bruno@clisp.org>
13079
13080         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
13081
13082 2005-03-04  Derek R. Price  <derek@ximbiot.com>
13083
13084         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
13085         (func_import): Only replace files via --import when they have actually
13086         changed.
13087
13088 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13089
13090         * m4/mmap-anon.m4: New file.
13091         * m4/pagealign_alloc.m4: New file.
13092
13093 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13094             Bruno Haible  <bruno@clisp.org>
13095
13096         * modules/pagealign_alloc: New file.
13097         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
13098
13099 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13100             Bruno Haible  <bruno@clisp.org>
13101
13102         * lib/pagealign_alloc.h: New file.
13103         * lib/pagealign_alloc.c: New file.
13104
13105 2005-03-03  Bruno Haible  <bruno@clisp.org>
13106
13107         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
13108         Use an all-permissive copyright notice, recommended by RMS.
13109
13110 2005-03-02  Bruno Haible  <bruno@clisp.org>
13111
13112         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
13113         of AIX, the replacement has to be done only after <string.h> is
13114         included, therefore not in config.h. stpncpy.h does the replacement,
13115         and stpncpy.c uses it.
13116
13117 2005-03-02  Bruno Haible  <bruno@clisp.org>
13118
13119         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
13120         stpncpy.c uses it.
13121
13122 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13123
13124         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
13125         The workaround isn't strictly needed for POSIX conformance, and
13126         it's too much of a pain to configure and maintain.  We'll ask
13127         people to fix their kernels instead.
13128         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
13129         (NANOSLEEP_BUG_WORKAROUND): Remove.
13130         (xnanosleep): Remove the workaround.
13131
13132 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13133
13134         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
13135         Reported by Derek Price.
13136         (Include): Add "timespec.h".
13137
13138         * modules/xnanosleep (Depends-on): Remove gethrxtime.
13139
13140 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13141
13142         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
13143         to detect nanosleep bug.
13144
13145 2005-03-01  Bruno Haible  <bruno@clisp.org>
13146
13147         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
13148
13149 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13150
13151         * modules/gethrxtime: New file.
13152         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
13153         (Depends-on): Add gethrxtime.
13154         (configure.ac): Add gl_XNANOSLEEP.
13155         (Makefile.am): Remove lib_SOURCES line.
13156
13157 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13158
13159         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
13160         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
13161
13162 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13163
13164         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
13165         * lib/timespec.h (gettime): Return void, since it always
13166         succeeds now.  All uses changed.
13167         * lib/gettime.c (gettime) Likewise.
13168         [HAVE_NANOTIME]: Prefer nanotime.
13169         Assume gettimeofday succeeds, as POSIX requires.
13170         Assime time () succeeds, since other code already does.
13171         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
13172         (timespec_subtract): Remove.
13173         (NANOSLEEP_BUG_WORKAROUND): New constant.
13174         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
13175         things considerably.  Use it only on GNU/Linux hosts, since the
13176         workaround shouldn't be needed elsewhere.
13177
13178 2005-02-24  Bruno Haible  <bruno@clisp.org>
13179
13180         * modules/gettext (Files): Add m4/glibc2.m4.
13181
13182 2005-02-24  Bruno Haible  <bruno@clisp.org>
13183
13184         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
13185         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
13186         * m4/progtest.m4:
13187         Update from GNU gettext 0.14.2.
13188         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
13189
13190 2005-02-24  Bruno Haible  <bruno@clisp.org>
13191
13192         * lib/localcharset.c: Update from GNU gettext 0.14.2.
13193         * lib/config.charset: Update from GNU gettext 0.14.2.
13194
13195 2005-02-24  Bruno Haible  <bruno@clisp.org>
13196
13197         * lib/gettext.h: Update from GNU gettext 0.14.2.
13198
13199 2005-02-23  Simon Josefsson  <jas@extundo.com>
13200
13201         * m4/iconvme.m4: New file.
13202
13203 2005-02-23  Jim Meyering  <jim@meyering.net>
13204
13205         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
13206         change.
13207         Thanks to Bruno Haible for catching it.
13208
13209 2005-02-22  Simon Josefsson  <jas@extundo.com>
13210
13211         * modules/iconvme: New file.
13212
13213         * MODULES.html.sh: Add iconvme.
13214
13215 2005-02-22  Simon Josefsson  <jas@extundo.com>
13216
13217         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
13218
13219 2005-02-22  Simon Josefsson  <jas@extundo.com>
13220
13221         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
13222
13223 2005-02-22  Jim Meyering  <jim@meyering.net>
13224
13225         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
13226         s/ifndef/ifdef/.
13227
13228 2005-02-20  Neil Conway  <neilc@samurai.com>
13229
13230         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
13231         returned by OSX/Darwin if the specified buffer is not large
13232         enough for the hostname.
13233
13234 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13235
13236         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
13237         pass it to _help, otherwise the latter coredumps trying to
13238         dereference state.root_argp.
13239
13240 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13241
13242         * modules/chdir-long (Depends-on): Add memrchr.
13243         * modules/memrchr (Files): Add lib/memrchr.h.
13244         (Include): "memrchr.h".
13245
13246 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13247
13248         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
13249
13250 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13251
13252         * lib/memrchr.h: New file.
13253         * lib/chdir-long.c: Include it.
13254         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
13255         Don't bother including stddef.h.
13256
13257 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
13258
13259         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
13260         inclusion.
13261         Include <sys/types.h>, for dev_t.
13262         (ME_DUMMY, ME_REMOTE): Move from here....
13263         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
13264         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
13265         Dmitry V. Levin.
13266         Include mountlist.h first, to test the interface.
13267
13268 2005-01-29  Bruno Haible  <bruno@clisp.org>
13269
13270         * lib/progname.c (program_name): Initialize.
13271         Needed when linking statically on MacOS X.
13272
13273 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13274
13275         Sync from coreutils.
13276         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
13277         (Depends-on): Add c-strtod.
13278         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
13279
13280 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13281
13282         Sync from coreutils.
13283         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
13284
13285         Remove files that are specific to coreutils.
13286         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
13287
13288 2005-01-28  Bruno Haible  <bruno@clisp.org>
13289
13290         * modules/javacomp: New file.
13291         * MODULES.html.sh (Java): Add javacomp.
13292
13293 2005-01-28  Bruno Haible  <bruno@clisp.org>
13294
13295         * m4/javacomp.m4: New file, from GNU gettext.
13296
13297 2005-01-28  Bruno Haible  <bruno@clisp.org>
13298
13299         * lib/javacomp.sh.in: New file, from GNU gettext.
13300         * lib/javacomp.h: New file, from GNU gettext.
13301         * lib/javacomp.c: New file, from GNU gettext.
13302
13303 2005-01-26  Simon Josefsson  <jas@extundo.com>
13304
13305         * lib/gai_strerror.c: Use GPL in header.
13306
13307 2005-01-26  Bruno Haible  <bruno@clisp.org>
13308
13309         * modules/javaexec: New file.
13310         * MODULES.html.sh (Java): Add javaexec.
13311
13312 2005-01-26  Bruno Haible  <bruno@clisp.org>
13313
13314         * m4/javaexec.m4: New file, from GNU gettext.
13315
13316 2005-01-26  Bruno Haible  <bruno@clisp.org>
13317
13318         * lib/javaexec.sh.in: New file, from GNU gettext.
13319         * lib/javaexec.h: New file, from GNU gettext.
13320         * lib/javaexec.c: New file, from GNU gettext.
13321
13322 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13323
13324         * modules/lchown (Depends-on): Remove lchown.h
13325
13326 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13327
13328         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
13329         must be defined if the header file was not found, in order
13330         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
13331
13332 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13333
13334         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
13335         initializers for struct pentry_state.
13336         (__argp_error): Check return value of __asprintf
13337         (__argp_failure): Translate error message
13338
13339         * lib/argp-parse.c: Removed braces around the expansion of N_()
13340
13341 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13342
13343         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
13344         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
13345         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
13346         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
13347         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
13348         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
13349         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
13350         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
13351         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
13352         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
13353         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
13354         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
13355         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
13356         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
13357         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
13358         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
13359         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
13360         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
13361         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
13362         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
13363         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
13364         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
13365         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
13366         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
13367         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
13368         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
13369         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
13370         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
13371         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
13372         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
13373         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
13374         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
13375         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
13376         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
13377         xstrtol.m4, xstrtoumax.m4, yesno.m4:
13378         Use an all-permissive copyright notice, recommended by RMS.
13379
13380 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
13381
13382         * modules/chdir-long (Depends-on): Remove mempcpy.
13383
13384 2005-01-21  Jim Meyering  <jim@meyering.net>
13385
13386         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
13387         same value as for Solaris 9.
13388
13389         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
13390         component length.  This included changing the parameter to be
13391         of type `char *' rather than `char const *'.
13392         * lib/chdir-long.h (chdir_long): Update prototype.
13393
13394         * lib/openat.c (fdopendir, fstatat): New functions.
13395         * lib/openat.h: Include headers required for use of DIR and struct
13396         stat.
13397         [AT_SYMLINK_NOFOLLOW]: Define.
13398         (fdopendir, fstatat): Add prototypes.
13399
13400 2005-01-21  Bruno Haible  <bruno@clisp.org>
13401
13402         * modules/classpath: New file.
13403         * MODULES.html.sh (Java): Add classpath.
13404
13405 2005-01-21  Bruno Haible  <bruno@clisp.org>
13406
13407         * lib/classpath.h: New file, from GNU gettext.
13408         * lib/classpath.c: New file, from GNU gettext.
13409
13410 2005-01-20  Simon Josefsson  <jas@extundo.com>
13411
13412         * modules/version-etc-fsf: New file.
13413
13414 2005-01-20  Simon Josefsson  <jas@extundo.com>
13415
13416         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
13417         * lib/version-etc.c: Remove version_etc_copyright.
13418         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
13419         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
13420
13421 2005-01-20  Simon Josefsson  <jas@extundo.com>
13422
13423         * lib/base64.h (isbase64): Add.
13424
13425         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
13426         using a unsigned prototype, don't inline.
13427         (base64_decode): Use it.
13428
13429 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13430
13431         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
13432         it.
13433
13434 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13435
13436         * lib/save-cwd.c (save_cwd): Remove code to support the case
13437         where fchdir is missing or flaky.
13438
13439 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13440
13441         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
13442
13443 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
13444
13445         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
13446         AC_LIBSOURCES now does this.
13447         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
13448         with new ullong_max module.
13449
13450 2005-01-19  Bruno Haible  <bruno@clisp.org>
13451
13452         * modules/sh-quote: New file.
13453         * MODULES.html.sh (Executing programs): Add sh-quote.
13454
13455 2005-01-19  Bruno Haible  <bruno@clisp.org>
13456
13457         * lib/sh-quote.h: New file, from GNU gettext.
13458         * lib/sh-quote.c: New file, from GNU gettext.
13459
13460 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13461
13462         Merge from coreutils.
13463         * m4/ullong_max.m4: New file.
13464         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
13465         (gl_MACROS): Assume localeconv exists.
13466
13467 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13468
13469         Merge changes from coreutils, as described below in several
13470         changelogs dated today.
13471
13472         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
13473         (O_DIRECTORY): Remove; not needed here, since "." must be
13474         a directory.  All uses removed.
13475         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
13476         universal on Suns, and we also need to test for IRIX.
13477         Revamp code to use 'if' rather than '#if'.
13478         Avoid unnecessary comparison of cwd->desc to 0.
13479
13480         * lib/utimens.c (futimens): Robustify the previous patch, by checking
13481         for known valid error numbers rather than observed invalid ones.
13482
13483 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13484
13485         * modules/ullong_max: New file.
13486
13487         * modules/chdir-long, modules/openat: New files.
13488         * modules/save-cwd (Depends-on): Depend on chdir-long.
13489         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
13490
13491 2005-01-18  Jim Meyering  <jim@meyering.net>
13492
13493         Merge from coreutils.
13494         * m4/chdir-long.m4, m4/openat.m4: New files.
13495         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
13496         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
13497         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
13498         is sane and DOES follow symlinks.  Besides, testing 20 different
13499         systems found no broken chown implementations.
13500         Prompted by a change in rsync's copy of this macro.
13501         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
13502
13503         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
13504
13505         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
13506         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
13507         NULL-means-set-to-current-time semantics.
13508         Remove temporary file immediately, rather than waiting
13509         for configure's at-exit trap code to do it.
13510
13511 2005-01-18  Jim Meyering  <jim@meyering.net>
13512
13513         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13514
13515         * lib/utimens.c (futimens): Account for the fact that futimes
13516         can also fail with errno == ENOSYS or errno == ENOENT.
13517         Patch from Dmitry V. Levin.
13518
13519         Change the name of the robust chdir function from chdir to chdir_long.
13520         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
13521         (restore_cwd): Use chdir_long, not chdir.
13522         * lib/chdir-long.c: Renamed from chdir.c.
13523         * lib/chdir-long.h: Renamed from chdir.h.
13524         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
13525         Hurd.
13526
13527 2005-01-18  Bruno Haible  <bruno@clisp.org>
13528
13529         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
13530         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
13531         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
13532         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
13533         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
13534         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
13535         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
13536         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
13537         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
13538         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
13539         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
13540         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
13541         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
13542         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
13543         Use an all-permissive copyright notice, recommended by RMS.
13544
13545 2005-01-18  Bob Proulx  <bob@proulx.com>
13546
13547         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
13548         simplify offsetof() macro construct to avoid compile failure with
13549         native HP-UX 11.0 ANSI C compiler.
13550
13551 2005-01-17  Bruno Haible  <bruno@clisp.org>
13552
13553         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
13554         redundant because stpncpy.m4 takes care of it.
13555
13556 2005-01-17  Bruno Haible  <bruno@clisp.org>
13557
13558         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
13559
13560 2005-01-17  Bruno Haible  <bruno@clisp.org>
13561
13562         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
13563         used.
13564
13565 2005-01-17  Bruno Haible  <bruno@clisp.org>
13566
13567         * lib/fwriteerror.h (fwriteerror): Change specification to include
13568         fclose.
13569         * lib/fwriteerror.c: Include <stdbool.h>.
13570         (fwriteerror): At the end, close the file stream. Record whether
13571         stdout was already closed.
13572
13573 2005-01-17  Bruno Haible  <bruno@clisp.org>
13574
13575         * lib/execute.c (environ): Declare if needed.
13576         * lib/pipe.c (environ): Likewise.
13577         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
13578
13579 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13580
13581         * modules/argp: Depend on vsnprintf
13582
13583 2005-01-10  Jim Meyering  <jim@meyering.net>
13584
13585         * modules/closeout (Depends-on): Add atexit.
13586
13587 2005-01-06  Bruno Haible  <bruno@clisp.org>
13588
13589         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
13590
13591 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13592
13593         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
13594         definitions to be after all include files, to avoid collisions.
13595         Problem reported by Bob Proulx.
13596
13597 2005-01-04  Jim Meyering  <jim@meyering.net>
13598
13599         Changes imported from coreutils.
13600         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
13601         as the mkstemp template, use a temporary directory and an
13602         8.3-friendly template to avoid trouble on systems like DJGPP.
13603         Reported by Juan M. Guerrero via Stepan Kasal.
13604         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
13605         close. Remove the temporary directory right away, rather than waiting
13606         for configure's at-exit trap code to do it.
13607         Suggestion from Stepan Kasal.
13608
13609 2005-01-01  Simon Josefsson  <jas@extundo.com>
13610
13611         * gnulib-tool: Print #include directives when --import'ing.
13612
13613 2004-12-28  Simon Josefsson  <jas@extundo.com>
13614
13615         * tests/test-base64.c: Include required header files.  Remove
13616         unused variables.
13617
13618 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13619
13620         * modules/error (Depends-on): Remove gettext.
13621
13622 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13623
13624         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
13625         not needed.  This removes a dependency on the gettext module.
13626         [defined _LIBC]: Do not include <libintl.h>; not needed.
13627
13628 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13629
13630         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
13631         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
13632
13633 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
13634
13635         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
13636         HAVE_DECL_STRTOLD.
13637
13638 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13639
13640         * modules/getdate (Depends-on): Remove alloca-opt.
13641
13642 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13643
13644         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
13645
13646 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
13647
13648         * lib/argp-parse.c: Include <stddef.h>.
13649         (alignof, alignto): New macros.
13650         (parser_init): Don't assume that void * is aligned sufficiently
13651         for struct option.
13652
13653         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
13654         need to extend the stack.
13655         (YYINITDEPTH): New macro, so that the initial stack isn't overly
13656         large.
13657
13658 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13659
13660         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
13661
13662 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13663
13664         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
13665         (2004-10-24) change.  Apparently this was a false alarm.
13666
13667         * modules/getdate: Depend on alloca-opt, not alloca.
13668
13669 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
13670
13671         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
13672         Remove now-obsolete comment about AIX.
13673         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
13674         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
13675         (YYMAXDEPTH): New macro.
13676
13677 2004-12-18  Simon Josefsson  <jas@extundo.com>
13678
13679         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
13680
13681 2004-12-18  Bruno Haible  <bruno@clisp.org>
13682
13683         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
13684
13685 2004-12-18  Bruno Haible  <bruno@clisp.org>
13686
13687         * lib/fatal-signal.c (fatal_signals): Make non-const.
13688         (init_fatal_signals): New function.
13689         (uninstall_handlers, install_handlers): Ignore signals that were set to
13690         SIG_IGN.
13691         (at_fatal_signal): Call init_fatal_signals.
13692         (init_fatal_signal_set): Likewise. Ignore signals that were set to
13693         SIG_IGN.
13694         Reported by Paul Eggert.
13695
13696 2004-12-18  Bruno Haible  <bruno@clisp.org>
13697
13698         * doc/alloca.texi: New file.
13699         * doc/alloca-opt.texi: New file.
13700
13701 2004-12-17  Jim Meyering  <jim@meyering.net>
13702
13703         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
13704         Otherwise, install-sh could exit with improper exit status when
13705         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
13706
13707 2004-12-16  Simon Josefsson  <jas@extundo.com>
13708
13709         * tests/test-base64.c: Add license.
13710
13711 2004-12-15  Stepan Kasal  <address@hidden>
13712
13713         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
13714
13715 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
13716
13717         * modules/getcwd (Files): Add m4/d-ino.m4.
13718         Suggested by Mark D. Baushke.
13719
13720 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13721
13722         * lib/getdate.y (textint): New member "negative".
13723         (time_zone_hhmm): New function.
13724         Expect 14 shift-reduce conflicts, not 13.
13725         (o_colon_minutes): New rule.
13726         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
13727         (yylex): Set the "negative" member of signed numbers.
13728
13729 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
13730
13731         * doc/getdate.texi (Time of day items, Time zone items):
13732         Describe new formats +00:00, UTC+00:00.
13733
13734 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13735
13736         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
13737         spurious "-l"s.  Problem reported by Stepan Kasal.
13738
13739 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
13740
13741         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
13742         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
13743
13744 2004-12-04  Simon Josefsson  <jas@extundo.com>
13745
13746         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
13747         Vandoorselaere <yoann@prelude-ids.org>.
13748
13749 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13750
13751         Changes imported from coreutils.
13752         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
13753         exist.
13754         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
13755
13756 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13757
13758         Changes imported from coreutils.
13759         * lib/hard-locale.c: Assume <locale.h> exists.
13760         Include "strdup.h".
13761         (GLIBC_VERSION): New macro.
13762         (hard_locale): Assume setlocale exists.
13763         Rewrite to avoid #ifdef.
13764         Use strdup rather than malloc + strcpy.
13765         * lib/human.c: Assume <locale.h> exists.
13766         (human_readable): Assume localeconv exists.
13767
13768 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
13769
13770         * modules/hard-locale (Depends-on): Add strdup.
13771
13772 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
13773
13774         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
13775         convert T2, not T.  (Imported from libc.)
13776
13777 2004-11-30  Simon Josefsson  <jas@extundo.com>
13778
13779         * modules/restrict (License): Change to LGPL.
13780
13781 2004-11-30  Simon Josefsson  <jas@extundo.com>
13782
13783         * m4/restrict.m4: Add copyright and copying conditions.
13784
13785 2004-11-30  Simon Josefsson  <jas@extundo.com>
13786
13787         * m4/base64.m4: New file.
13788
13789 2004-11-30  Simon Josefsson  <jas@extundo.com>
13790
13791         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
13792         base64.
13793
13794         * tests/test-base64.c: New file.
13795
13796         * modules/base64: New file.
13797
13798 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13799
13800         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
13801         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
13802
13803         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
13804
13805 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
13806
13807         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
13808         (__getcwd.c): Don't restore errno; glibc doesn't.
13809         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
13810         first, falling back to our code only if its results look suspicious.
13811         Ensure that the resulting buffer is only as large as necessary.
13812
13813         * lib/readutmp.c: Include readutmp.h first.
13814         Include <errno.h>, since readutmp.h no longer does that.
13815         * lib/readutmp.h: Don't include <errno.h>,
13816         <sys/param.h>, <time.h>; not needed to establish interface.
13817         (errno): Remove decl.
13818         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
13819         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
13820         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
13821
13822 2004-11-28  Simon Josefsson  <jas@extundo.com>
13823
13824         * lib/base64.h, base64.c: New file.
13825
13826 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
13827
13828         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
13829
13830 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
13831
13832         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
13833         (Depends-on): Remove pathmax, same.  Add mempcpy.
13834         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
13835         (Makefile.am): Append getcwd.h to lib_SOURCES.
13836         (Include): Add getcwd.h.
13837         (Maintainer): Change from Jim Meyering to "all, glibc",
13838         since getdate now uses intended-for-glibc code.
13839         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
13840         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
13841
13842 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13843
13844         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
13845         HP's ANSI C compiler.
13846         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
13847         Declaring int functions causes warnings on some modern systems and
13848         shouldn't be needed to compile on ancient ones.
13849         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
13850         defined.
13851
13852         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
13853         with the following changes.
13854         (__set_errno): Parenthesize properly.
13855         Include <stdbool.h>.
13856         (MIN, MAX, MATCHING_INO): New macros.
13857         (__getcwd): Define with prototype, not K&R form.
13858         Use heuristics to allocate default buffer on stack if possible.
13859         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
13860         behavior, and to avoid the PATH_MAX limit when computing
13861         ../../../../...
13862         Use MATCHING_INO to compare inode number to file.
13863         Check for arithmetic overflow in size calculations.
13864         Fix bug in reallocation of dot array that caused getcwd to fail
13865         on directories nested deeper than 75.
13866         Be more careful about saving errno on error.
13867         Do not use realloc; use only free+malloc, as this is a bit
13868         more flexible and avoids a needless copy operation.
13869         Do not inspect st_dev and st_ino for symbolic links; POSIX
13870         doesn't specify the latter.
13871         Check for closedir errors.
13872         Avoid needless casts.
13873         Use "#ifdef weak_alias" around weak_alias, to be like other
13874         glibc code.
13875         The following changes to getcwd.c have effect only when used in
13876         gnulib; they have no effect inside glibc proper.
13877         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
13878         as alloca isn't used.
13879         (alloca, __alloca): Likewise.
13880         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
13881         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
13882         unconditionally, as gnulib assumes C89 or better.
13883         Do not include <sys/param.h>.
13884         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
13885         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
13886         better.
13887         (NULL) [!defined NULL]: Remove; we assume C89 or better.
13888         Include <dirent.h> in a way that is compatible with modern Autoconf.
13889         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
13890         New macros, if not already defined.
13891         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
13892         Use "_LIBC", not "defined _LIBC", for consistency.
13893         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
13894         a mempcpy module.
13895         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
13896         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
13897         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
13898         credit only to Jim Meyering and adjust the copyright dates.
13899         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
13900         <stdlib.h>, <unistd.h>, "pathmax.h".
13901         Instead, include "xgetcwd.h" (first) and "getcwd.h".
13902         (INITIAL_BUFFER_SIZE): Remove.
13903         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
13904
13905 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13906
13907         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
13908         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
13909         Use the _ONCE methods, for efficiency.
13910         Check for fcntl.h.  In test program, include <errno.h>
13911         and <fcntl.h> if available.  Remove old K&R cruft from
13912         test program.  Check for common errors in GNU/Linux,
13913         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
13914         don't do AC_LIBOBJ, as that's getcwd.m4's job.
13915         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
13916         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
13917         name accordingly.
13918         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
13919         accommodate new getcwd.c.
13920         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
13921         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
13922         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
13923         that's all we need now.
13924
13925 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13926
13927         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
13928         argp-parse.c depends on getopt internals, that means we should
13929         always use our getopt, to be on the safe side.
13930         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
13931         order not to spoil the result of an eventual previous invocation
13932         of gl_GETOPT_SUBSTITUTE.
13933
13934 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13935
13936         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
13937         redefinition warnings. To avoid them, include the defines
13938         in `#if !defined __need_getopt ... #endif'. The only place
13939         where __getopt_argv_const is used is in definitions
13940         of getopt_long and getopt_long_only below, which are as well
13941         protected by `#ifndef __need_getopt'.
13942         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
13943         __need_getopt after including <stdio.h> and <unistd.h> These
13944         headers might have defined it.
13945
13946 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
13947
13948         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
13949
13950 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
13951
13952         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
13953         (futimens): New function, which uses futimes if available.
13954         (futimens, utimens): Support timespec==NULL, with same semantics
13955         as utime and utimens.
13956         * lib/utimens.h (futimens): New decl.
13957
13958 2004-11-23  Jim Meyering  <jim@meyering.net>
13959
13960         * lib/getopt_.h: Remove trailing blanks.
13961
13962 2004-11-23  Jim Meyering  <jim@meyering.net>
13963
13964         * lib/__fpending.c: Add comment.
13965
13966 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
13967
13968         * modules/canonicalize (Depends-on): Add xreadlink.
13969         Problem reported by James Youngman.
13970
13971 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
13972
13973         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
13974         New macros.
13975         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
13976         optopt): Use them instead of invoking ## directly; otherwise, the
13977         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
13978
13979 2004-11-19  Bruno Haible  <bruno@clisp.org>
13980
13981         * lib/strtok_r.c: Move comments from here...
13982         * lib/strtok_r.h: ... to here.
13983
13984 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
13985
13986         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
13987         implementations that mishandle size_t overflow.
13988
13989 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
13990
13991         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
13992         might fail.  Problem reported by Yoann Vandoorselaere.
13993         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
13994         implementations that mishandle size_t overflow.
13995
13996 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
13997
13998         * modules/canon-host (Depends-on): Add strdup.
13999
14000 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14001
14002         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
14003
14004 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14005
14006         * lib/canon-host.c: Include "strdup.h".
14007         (canon_host): Use getaddrinfo if available, so that IPv6 works.
14008         Use strdup instead of malloc/strcpy to duplicate strings.
14009
14010         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
14011         (human_space_before_unit): New constant.
14012         * lib/human.c (human_readable): Support it.
14013
14014         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
14015         (xgetcwd): Set errno correctly when failing.
14016         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
14017         the failure is actually due to a PATH_MAX problem.
14018
14019         Further getopt changes to make it more likely that glibc will
14020         buy the changes back.
14021         * lib/getopt.c (POSIXLY_CORRECT): New constant.
14022         (getopt): Use it, so to preserve glibc semantic
14023         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
14024         when compiling for libc.
14025         * lib/getopt_.h (__getopt_argv_const): Bring it back.
14026         (getopt_long, getopt_long_only): Use it.
14027
14028         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14029         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
14030         (getopt): Argv is now char * const *, as per standard.
14031         (_getopt_internal_r, _getopt_internal): Argv is now char **,
14032         not char *__getopt_argv_const *.
14033         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14034         _getopt_long_only_r): Likewise.
14035         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
14036         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14037         _getopt_long_r, _getopt_long_only_r): Likewise.
14038         * lib/getopt_.h (__getopt_argv_const): Remove.
14039         (getopt): Argv is now char * const *, as per standard.
14040
14041         * lib/getdate.y (tORDINAL): New token.
14042         (day, relunit): Allow it for relative times.
14043         (relative_time_table): Use tORDINAL for ordinals.
14044
14045 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14046
14047         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
14048         Document that "second" isn't allowed as an ordinal number.
14049
14050 2004-11-16  Jim Meyering  <jim@meyering.net>
14051
14052         * modules/closeout (Depends-on): Add fpending.
14053
14054 2004-11-15  Jim Meyering  <jim@meyering.net>
14055
14056         * lib/closeout.c: Include "__fpending.h" once again.
14057         Include <stdbool.h>.
14058         (close_stdout): Don't fail just because stdout was closed initially,
14059         since some programs don't write to stdout in the normal course of
14060         operation (other than --version and --help), and we don't want this
14061         function to make e.g. `touch file >&-' fail.
14062         But do fail if it was closed and someone has tried to write to it.
14063         E.g., `printf foo >&-' must fail.
14064
14065 2004-11-13  Jim Meyering  <jim@meyering.net>
14066
14067         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
14068
14069 2004-11-12  Simon Josefsson  <jas@extundo.com>
14070
14071         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
14072         small doc fix is still pending.
14073
14074 2004-11-11  Simon Josefsson  <jas@extundo.com>
14075
14076         * modules/strtok_r: New file.
14077
14078         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14079         strtok_r.
14080
14081 2004-11-11  Simon Josefsson  <jas@extundo.com>
14082
14083         * m4/strtok_r.m4: New file.
14084
14085         * m4/getopt.m4: Replace opterr.
14086
14087 2004-11-11  Simon Josefsson  <jas@extundo.com>
14088
14089         * lib/strtok_r.h, strtok_r.c: New file.
14090
14091 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14092
14093         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
14094         of replacing opterr, getopt, etc.  This should handle the
14095         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
14096
14097 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14098
14099         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
14100         we can stop lying to compilers about the constness of argv when we
14101         are compiled outside glibc.
14102         (getopt, getopt_long, getopt_long_only): Use it.
14103         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14104         _getopt_internal, getopt): Likewise.
14105         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14106         _getopt_long_only_r): Likewise.
14107         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14108         _getopt_long_r, _getopt_long_only_r): Likewise.
14109
14110         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
14111         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
14112         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
14113         the other external symbols.
14114         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
14115         declaration, since the above renaming now works around collisions.
14116
14117 2004-11-11  Jim Meyering  <jim@meyering.net>
14118
14119         * lib/linebreak.c: Remove trailing blanks.
14120         * lib/alloca_.h: Likewise.
14121         * lib/acosl.c: Likewise.
14122         * lib/euidaccess.c: Likewise.
14123         * lib/allocsa.h: Likewise.
14124
14125 2004-11-10  Simon Josefsson  <jas@extundo.com>
14126
14127         * m4/getaddrinfo.m4: New file.
14128
14129 2004-11-10  Simon Josefsson  <jas@extundo.com>
14130
14131         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
14132
14133 2004-11-10  Simon Josefsson  <jas@extundo.com>
14134
14135         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14136         getaddrinfo.
14137
14138         * modules/getaddrinfo: New file.
14139
14140 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14141
14142         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
14143
14144 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14145
14146         * lib/mktime.c (SHR): New macro, which is a portable
14147         substitute for >> that should work even on Crays.
14148         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
14149         Problem reported by Mark D. Baushke in
14150         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
14151         * lib/getdate.y (SHR): Likewise.
14152         (tm_diff): Use it.
14153         * lib/strftime.c (SHR): Likewise.
14154         (tm_diff): Use it.
14155         * lib/quotearg.c (struct quoting_options): Use unsigned int for
14156         quote_these_too, so that right shifts are well defined.  All uses
14157         changed.
14158
14159 2004-11-10  Jim Meyering  <jim@meyering.net>
14160
14161         Ensure that no close failure goes unreported.
14162         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
14163         return early when it seems there's nothing to flush.
14164         Don't include __fpending.h.
14165
14166 2004-11-10  Jim Meyering  <jim@meyering.net>
14167
14168         * modules/closeout (Depends-on): Remove fpending.
14169
14170 2004-11-10  Jim Meyering  <jim@meyering.net>
14171
14172         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
14173
14174 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14175
14176         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
14177         gl_FUNC_STRFTIME.
14178         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
14179         and AC_REQUIRE when possible, to avoid duplicate checks.
14180         Check for <wchar.h>.
14181
14182 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14183
14184         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
14185
14186 2004-11-09  Bruno Haible  <bruno@clisp.org>
14187
14188         * m4/sockpfaf.m4: New file.
14189
14190 2004-11-05  Bruno Haible  <bruno@clisp.org>
14191
14192         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
14193         Reported by Mark D. Baushke <mdb@cvshome.org>.
14194
14195 2004-11-04  Bruno Haible  <bruno@clisp.org>
14196
14197         2004-09-11  Bruno Haible  <bruno@clisp.org>
14198                 * allocsa.valgrind: New file.
14199         2004-02-06  Bruno Haible  <bruno@clisp.org>
14200                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
14201                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
14202                 Reported by Christopher Seip <chris.seip@hp.com>.
14203
14204 2004-11-04  Bruno Haible  <bruno@clisp.org>
14205
14206         * modules/allocsa (Files): Add lib/allocsa.valgrind.
14207         (Makefile.am): Distribute it.
14208
14209 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
14210
14211         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
14212         with errno == ERANGE if the buffer is too small.
14213         Problem reported by Mark D. Baushke.
14214
14215 2004-11-03  Albert Chin  <china@thewrittenword.com>
14216             Paul Eggert  <eggert@cs.ucla.edu>
14217
14218         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
14219         equivalent, substitute $ac_type for equivalent type rather than
14220         blindly using uint32_t *always* which won't work if uint32_t is not
14221         available.  Define _UINT32_T to work around typedef of uint32_t if
14222         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
14223         2.5.1.
14224
14225 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14226
14227         * m4/jm-macros.m4: Sync from coreutils.
14228         (gl_MACROS): Check for mbrlen, for pathchk.
14229         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
14230
14231 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14232
14233         * lib/xreadlink.c (MAXSIZE): New macro.
14234         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
14235         size does not exceed MAXSIZE.  Avoid cast.
14236         As suggested by Mark D. Baushke in
14237         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
14238         if readlink fails with buffer size just under MAXSIZE, try again
14239         with MAXSIZE.
14240
14241 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14242
14243         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
14244
14245 2004-11-02  Derek R. Price  <derek@ximbiot.com>
14246         and  Paul Eggert  <eggert@cs.ucla.edu>
14247
14248         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
14249         (get_date): Overparenthesize to avoid GCC warning.
14250
14251 2004-11-02  Bruno Haible  <bruno@clisp.org>
14252
14253         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
14254         returns void.
14255
14256 2004-11-02  Bruno Haible  <bruno@clisp.org>
14257
14258         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
14259         function returns void.
14260
14261 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14262
14263         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
14264         fflush_unlocked, flockfile, funlockfile, funlockfile,
14265         fputs_unlocked, putc_unlocked.
14266
14267 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14268
14269         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14270         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
14271         already declared.
14272
14273 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14274
14275         * modules/getdate (Files): Add doc/getdate.texi.
14276         (Depends-on): Add setenv, xalloc.
14277
14278 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14279
14280         * lib/getdate.y: Add support for TZ="foo" within a date string.
14281         Fix some bugs near time_t boundaries.  Reject dates with
14282         out-of-range components, e.g., "Sept 31".
14283         Include <stdlib.h>, "setenv.h", "xalloc.h".
14284         (ISDIGIT_LOCALE): Remove; unused.
14285         Note that the TZ and time functions used here are not reentrant.
14286         (mktime_ok, get_tz): New functions.
14287         (TZBUFSIZE): New constant.
14288         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
14289         This requires that we sometimes generate our own TZ="XXX..." setting.
14290
14291 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14292
14293         * doc/getdate.texi: New file, from coreutils with modifications for
14294         the new TZ parsing.
14295
14296 2004-10-27  Derek R. Price  <derek@ximbiot.com>
14297
14298         * lib/mktime.c (not_equal_tm): Remove redundant check.
14299
14300 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14301
14302         * modules/regex (lib_SOURCES): Add regex.c.
14303         Reported by James Youngman in
14304         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
14305
14306 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14307
14308         * lib/getdate.y: Use Bison 1.875 features, and some minor
14309         code cleanups.  This change does not affect semantics.
14310         Don't include <stdlib.h>; no longer needed.
14311         Don't include unlocked-io.h; only the "#if TEST" code uses
14312         stdio, and performance isn't crucial there.
14313         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
14314         Bison 1.875 features as described below.
14315         All uses of "PC." replaced by "pc->".
14316         (YYSTYPE): Add a forward declaration.
14317         (yylex, yyerror): Use full prototypes in forward decls.
14318         Use "%pure-parser" rather than obsolescent "%pure_parser".
14319         Use %parse-param and %lex-param instead of obsolescent
14320         YYPARSE_PARAM and YYLEX_PARAM.
14321         (meridian_table, month_and_day_table, time_units_table,
14322         relative_time_table, time_zone_table, military_table,
14323         lookup_zone, lookup_word, get_date):
14324         Use NULL instead of 0 where appropriate.
14325         (to_hour): Avoid abort (), to avoid a dependency on
14326         stdlib.h.
14327         (yyerror, yylex): Now accepts parser_control * arg.
14328         (main) [TEST]: Use '\0' rather than 0 for char.
14329
14330 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14331
14332         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
14333
14334 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14335
14336         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
14337         It's now the caller's responsibility to handle the case where
14338         !HAVE_GETPAGESIZE && !defined getpagesize.
14339
14340         * lib/mktime.c (leapyear): Arg is long int, not int.
14341
14342 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
14343
14344         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
14345
14346 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
14347
14348         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
14349         missing.  Problem reported by James Youngman.
14350
14351 2004-10-16  Simon Josefsson  <jas@extundo.com>
14352
14353         * gnulib-tool: Fix comments.  Fix parse problem.
14354         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
14355
14356 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
14357
14358         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
14359         implementation of getopt_long.  Problem reported by Alexander Taler in:
14360         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
14361
14362 2004-10-15  Bruno Haible  <bruno@clisp.org>
14363
14364         * gnulib-tool: Untabify. Initialize supplied_libname.
14365         (func_usage): More homogenous output.
14366         (func_modules_transitive_closure, func_modules_to_filelist,
14367         func_emit_lib_Makefile_am): New functions.
14368         (func_import): New function, extracted from big case statement. Use
14369         func_get_license, func_modules_transitive_closure,
14370         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
14371         opt_lgpl. Don't use test -a, as it's not portable.
14372         (func_create_testdir): Use func_modules_transitive_closure,
14373         func_modules_to_filelist, func_emit_lib_Makefile_am.
14374
14375 2004-10-15  Bruno Haible  <bruno@clisp.org>
14376
14377         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
14378
14379 2004-10-15  Bruno Haible  <bruno@clisp.org>
14380
14381         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
14382         the portions belonging to each module.
14383         Suggested by Derek Robert Price <derek@ximbiot.com>.
14384
14385 2004-10-12  Simon Josefsson  <jas@extundo.com>
14386
14387         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14388         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
14389         to real functions.
14390
14391 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14392
14393         * modules/vsnprintf: New file.
14394
14395 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14396
14397         * m4/vsnprintf.m4: New file.
14398
14399 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14400
14401         * lib/vsnprintf.h: New file.
14402         * lib/vsnprintf.c: New file.
14403
14404 2004-10-11  Bruno Haible  <bruno@clisp.org>
14405
14406         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
14407         vsnprintf.
14408
14409 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14410
14411         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
14412
14413 2004-10-07  Bruno Haible  <bruno@clisp.org>
14414
14415         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
14416         fits into the provided buffer.
14417
14418 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14419
14420         * lib/diacrit.c, diacrit.h: Add GPL notice.
14421
14422         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
14423         notice.
14424         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
14425         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
14426         This avoids a potential constant-folding bug.
14427
14428 2004-10-05  Bruno Haible  <bruno@clisp.org>
14429
14430         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
14431         for the declaration of strsep.
14432
14433 2004-10-05  Bruno Haible  <bruno@clisp.org>
14434
14435         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
14436
14437 2004-10-04  Simon Josefsson  <jas@extundo.com>
14438
14439         * modules/memmem: New file.
14440         * tests/test-memmem.c: New file.
14441         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
14442
14443 2004-10-04  Simon Josefsson  <jas@extundo.com>
14444
14445         * m4/memmem.m4: New file.
14446
14447 2004-10-04  Simon Josefsson  <jas@extundo.com>
14448
14449         * lib/memmem.h: New file.
14450         * lib/memmem.c: New file, taken from glibc.
14451
14452 2004-10-04  Simon Josefsson  <jas@extundo.com>
14453
14454         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
14455         '#ifdef USE_UNLOCKED_IO'.
14456
14457 2004-10-04  Simon Josefsson  <jas@extundo.com>
14458
14459         * config/srclist.txt: Add memmem from glibc.
14460
14461 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14462
14463         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
14464
14465         * modules/argmatch, modules/argp, modules/closeout, modules/error,
14466         modules/exclude, modules/getdate, modules/getline,
14467         modules/getndelim2, modules/getpass, modules/getpass-gnu,
14468         modules/getusershell, modules/linebuffer, modules/md5,
14469         modules/mountlist, modules/posixtm, modules/readtokens,
14470         modules/readutmp, modules/regex, modules/sha1,
14471         modules/version-etc, modules/yesno:
14472         Remove dependency on unlocked-io.
14473
14474 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14475
14476         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
14477
14478         * m4/unlocked-io.m4: Add copyright notice.
14479         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
14480
14481 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14482
14483         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
14484         * lib/xmalloc.c (xmemdup): Likewise.
14485         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
14486         XFREE): Remove these long-obsolescent macros.
14487         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
14488         * lib/xstrdup.c: Remove.
14489
14490         * lib/regex.c (re_comp): Cast gettext return value to char *,
14491         Problem reported by Martin Neitzel via Mark D. Baushke.
14492
14493 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14494
14495         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
14496         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
14497         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
14498         regex.c, sha1.c, version-etc.c, yesno.c:
14499         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
14500         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
14501         the includer's responsibility.
14502
14503         Sync from coreutils.
14504
14505         * lib/modechange.c (mode_compile): Don't decrement a pointer that
14506         points to the start of a string, as the C Standard says the
14507         resulting behavior is undefined.
14508
14509         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
14510         simple -> simple_backups, numbered_existing ->
14511         numbered_existing_backups, numbered -> numbered_backups
14512         to avoid shadowing problems.  All uses changed.
14513         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
14514         * lib/backupfile.c (check_extension, numbered_backup):
14515         Rename locals to avoid shadowing 'basename'.
14516         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
14517         once.
14518
14519         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
14520         * lib/.cvsignore: Add getopt.h.
14521
14522 2004-10-04  Bruno Haible  <bruno@clisp.org>
14523
14524         * modules/README: New file.
14525         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
14526         not a module.
14527
14528 2004-10-02  Jim Meyering  <jim@meyering.net>
14529
14530         * lib/dirfd.h, getpagesize.h: Add copyright notice.
14531
14532 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14533
14534         * modules/strsep: New file.
14535
14536 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14537
14538         * m4/strsep.m4: New file.
14539
14540 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14541
14542         * lib/strsep.h: New file.
14543         * lib/strsep.c: New file.
14544
14545 2004-10-01  Simon Josefsson  <jas@extundo.com>
14546
14547         * lib/snprintf.c (snprintf): Handle size==0.
14548
14549 2004-10-01  Simon Josefsson  <jas@extundo.com>
14550             Bruno Haible  <bruno@clisp.org>
14551
14552         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
14553         (snprintf): Declare 'args'.
14554
14555 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
14556
14557         * lib/snprintf.c: Remove comments as to why each header is needed.
14558
14559 2004-10-01  Bruno Haible  <bruno@clisp.org>
14560
14561         * MODULES.html.sh: Add strsep.
14562
14563 2004-09-30  Simon Josefsson  <jas@extundo.com>
14564
14565         * modules/snprintf: New file.
14566
14567 2004-09-30  Simon Josefsson  <jas@extundo.com>
14568
14569         * m4/snprintf.m4: New file.
14570
14571 2004-09-30  Simon Josefsson  <jas@extundo.com>
14572
14573         * lib/snprintf.h, lib/snprintf.c: New files.
14574
14575 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14576
14577         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
14578         (hol_entry_help): Never translate an empty string.
14579         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
14580         * lib/argp.h (OPTION_NO_TRANS): New option.
14581
14582 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14583
14584         * modules/argp (Maintainer): Replace Simon Josefsson
14585         by Sergey Poznyakoff.
14586
14587 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14588
14589         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
14590         changes merged back into glibc.
14591
14592 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14593
14594         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
14595
14596 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14597
14598         * lib/xvasprintf.c: Include xalloc.h.
14599         (xvasprintf): Use xalloc_die, not xmalloc_die.
14600
14601 2004-09-29  Bruno Haible  <bruno@clisp.org>
14602
14603         * modules/alloca-opt: New file, derived from modules/alloca.
14604         * modules/allocsa: Depend on alloca-opt instead of alloca.
14605         * modules/setenv: Likewise.
14606         * modules/vasnprintf: Likewise.
14607         * MODULES.html.sh: Add alloca-opt.
14608
14609 2004-09-28  Simon Josefsson  <jas@extundo.com>
14610
14611         * gnulib-tool: New parameter --lgpl, to asseert that modules are
14612         LGPL, and to replace license template from GPL to LGPL.
14613
14614 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14615
14616         * modules/dummy: Change license to LGPL.
14617
14618 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14619
14620         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
14621
14622 2004-09-24  Simon Josefsson  <jas@extundo.com>
14623
14624         * modules/minmax (License): Change from GPL to LGPL.
14625
14626 2004-09-23  Simon Josefsson  <jas@extundo.com>
14627
14628         * gnulib-tool (--import): Typo.
14629
14630 2004-09-23  Simon Josefsson  <jas@extundo.com>
14631
14632         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
14633
14634 2004-09-22  Bruno Haible  <bruno@clisp.org>
14635
14636         * modules/*: Add 'License' field.
14637         * gnulib-tool: Accept --extract-license option.
14638         (func_get_license): New function.
14639
14640 2004-09-21  Bruno Haible  <bruno@clisp.org>
14641
14642         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
14643         Reported by Simon Josefsson.
14644
14645 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14646
14647         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
14648         gl_AC_TYPE_LONG_LONG.
14649
14650 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
14651
14652         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
14653
14654 2004-09-18  Simon Josefsson  <jas@extundo.com>
14655         and  Paul Eggert  <eggert@cs.ucla.edu>
14656
14657         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
14658         calls with autoreconf.  Define GL_LIB.
14659
14660 2004-09-14  Karl Berry  <karl@gnu.org>
14661
14662         * config/srclist.txt: unsync setenv.c, sigh.
14663
14664 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14665
14666         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
14667         Problem reported by Bruno Haible in:
14668         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
14669
14670 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
14671
14672         * config/srclist.txt: Comment out argp-pvh.c.
14673
14674 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
14675
14676         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
14677         in case some system header has #define'd it.  Problem reported by
14678         Soeren D. Schulze in
14679         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
14680
14681 2004-09-09  Karl Berry  <karl@gnu.org>
14682
14683         * regex.[ch]: delete from the root.  These were supposed to be
14684                 synced with emacs cvs, but this has not happened for about
14685                 a year, and anyway nothing else uses emacs regex.[ch].
14686                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
14687                 lib/regex[.ch] is untouched.
14688
14689 2004-09-09  Bruno Haible  <bruno@clisp.org>
14690
14691         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
14692
14693 2004-09-09  Bruno Haible  <bruno@clisp.org>
14694
14695         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
14696         modifications.
14697         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
14698
14699 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14700
14701         * modules/xvasprintf: New file.
14702         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
14703
14704 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
14705
14706         * lib/xvasprintf.h: New file.
14707         * lib/xvasprintf.c: New file.
14708         * lib/xasprintf.c: New file.
14709
14710 2004-09-08  Bruno Haible  <bruno@clisp.org>
14711
14712         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
14713
14714 2004-09-08  Bruno Haible  <bruno@clisp.org>
14715
14716         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
14717         length is > INT_MAX.
14718         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
14719         more.
14720
14721 2004-09-08  Bruno Haible  <bruno@clisp.org>
14722
14723         * lib/stdint_.h: New file, taken from GNU clisp.
14724
14725 2004-09-08  Bruno Haible  <bruno@clisp.org>
14726             Oskar Liljeblad  <oskar@osk.mine.nu>
14727
14728         * modules/stdint: New file.
14729         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
14730
14731 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14732
14733         Import from coreutils.
14734         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
14735         strings on unbounded length.  alloca's performance benefits aren't
14736         that important here.
14737         (V_STRDUP): Remove.
14738         (parse_with_separator): New function, with most of the internals
14739         of the old parse_user_spec.  Allow user to omit both user and group,
14740         for compatibility with FreeBSD.
14741         Clone only the user name, not the entire spec.
14742         Do not set *uid, *gid unless entirely successful.
14743         Avoid memory leak in some failing cases.
14744         Fix regression for USER.GROUP reported by Dmitry V. Levin in
14745         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
14746         (parse_user_spec): Rewrite to use parse_with_separator.
14747
14748 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14749
14750         * modules/userspec: Don't depend on alloca.
14751
14752 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14753
14754         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
14755
14756 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
14757
14758         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
14759         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
14760         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
14761
14762 2004-08-16  Simon Josefsson  <jas@extundo.com>
14763
14764         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
14765         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
14766         Add --dry-run for --import.
14767         Let user provided command line parameters override configure.ac
14768         settings.
14769
14770 2004-08-12  Simon Josefsson  <jas@extundo.com>
14771
14772         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
14773         as discussed with Paul Eggert in threads rooted at
14774         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
14775         and
14776         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
14777         Before, the test was empty, and relied on ELIDE_CODE in source
14778         code.)
14779         (gl_PREREQ_GETOPT): New macro.
14780         (gl_GETOPT): Use them.
14781
14782 2004-08-12  Simon Josefsson  <jas@extundo.com>
14783
14784         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
14785         * lib/getopt_.h: Renamed from getopt.h.
14786
14787 2004-08-12  Simon Josefsson  <jas@extundo.com>
14788
14789         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
14790         Change default library name from libfoo to libgnu.
14791         Now, if you have a configure.ac that says:
14792                 gl_SOURCE_BASE(gl)
14793                 gl_M4_BASE(gl/m4)
14794                 gl_MODULES(error getopt etcetera)
14795                 gl_INIT
14796         you can import all you need by running:
14797                 ../gnulib/gnulib-tool --import
14798
14799         * modules/getopt (Files): Rename getopt.h to getopt_.h.
14800         (Makefile.am): Rewrite, use logic from argz.
14801         (Include): Use <getopt.h> instead of "getopt.h".
14802
14803 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14804
14805         * modules/argp (Files): Add m4/unlocked-io.m4.
14806         (Depends-on): Add extensions.
14807
14808 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14809
14810         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
14811         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
14812         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
14813         Check for program_invocation_name, program_invocation_short_name,
14814         flockfile, funlockfile, features.h, _getopt_long_only_r.
14815
14816 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14817
14818         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
14819         its complicated substitute.
14820         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
14821         and program_invocation_name.
14822         (__argp_basename) [!_LIBC]: Remove; the only use was
14823         replaced by its body.
14824         (__argp_short_program_name): Change condition from
14825         !defined __argp_short_program_name to
14826         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
14827         to match argp-namefrob.h.
14828         (__argp_failure): Don't assume strerror_r returns char *.
14829         * lib/argp-parse.c (N_): Define unconditionally.
14830         (argp_default_options): Fill out initializers with 0 to avoid
14831         gcc warnings.
14832
14833 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
14834
14835         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
14836         getopt1.c.
14837
14838 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14839
14840         Merge from coreutils.
14841
14842         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
14843
14844         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
14845         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
14846
14847 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14848
14849         Merge from coreutils.
14850
14851         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
14852         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
14853         for Reliant Unix 5.43.
14854
14855         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
14856         (union fooround): Use uintmax_t, not long int.
14857         The rest is a merge from libc:
14858         [defined _LIBC]: Include <shlib-compat.h>.
14859         (_obstack) [defined _LIBC]: Remove after 2.3.4.
14860
14861         * lib/settime.c (settime): Recode to avoid warning with
14862         Sun Forte C 6U2.
14863
14864         * lib/strverscmp.c: Convert to UTF-8.
14865
14866 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
14867
14868         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14869         m4/uintmax_t.m4.
14870
14871 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14872
14873         * modules/xalloc-die: New file.
14874         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
14875
14876         * modules/md5 (Files): Add m4/uint32_t.m4.
14877         * modules/sha1: Renamed from modules/sha.
14878         (Files):
14879         Rename lib/sha.h to lib/sha1.h.
14880         Rename lib/sha.c to lib/sha1.c.
14881         Rename m4/sha.m4 to m4/sha1.m4.
14882         (lib_SOURCES): Likewise.
14883         (configure.ac): Rename gl_SHA to gl_SHA1.
14884         (Include): sha.h -> sha1.h.
14885
14886 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14887
14888         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
14889         * m4/sha1.m4: Renamed from sha.m4.
14890         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
14891
14892 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
14893
14894         * lib/obstack.h (obstack_empty_p):
14895         Don't assume that chunk->contents is suitably aligned.
14896         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
14897         Likewise. Problem reported by Benno in
14898         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
14899
14900         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
14901         readable.  This could be improved further but it'd take some work.
14902
14903 2004-08-08  Simon Josefsson  <jas@extundo.com>
14904
14905         * modules/xgethostname (Depends-on): Remove exit and error (not
14906         used).
14907
14908         * modules/getpass-gnu: Add getpass.h.
14909         (Depends-on): Add stdbool.
14910         * modules/getpass: Add getpass.h.
14911
14912 2004-08-08  Simon Josefsson  <jas@extundo.com>
14913
14914         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
14915         Check getpass declaration.
14916
14917 2004-08-08  Simon Josefsson  <jas@extundo.com>
14918
14919         * lib/xgethostname.c: Don't include error.h (not used).
14920
14921         * lib/getpass.h: Add.
14922         * lib/getpass.c: Include getpass.h first.
14923
14924 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
14925
14926         * lib/xalloc-die.c: New file.
14927         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
14928         All uses removed.
14929         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
14930         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
14931         xalloc-die.c.
14932         (_, N_, xalloc_die): Move to xalloc-die.c.
14933         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
14934         so that we needn't mess with xalloc_msg_memory_exhausted.
14935
14936         * lib/sha1.h: Renamed from sha.h.
14937         (SHA1_H): Renamed from _SHA_H.
14938         (sha1_ctx): Renamed from sha_ctx.
14939         (sha1_init_ctx): Renamed from sha_init_ctx.
14940         (sha1_process_block): Renamed from sha_process_block.
14941         (sha1_process_bytes): Renamed from sha_process_bytes.
14942         (sha1_finish_ctx): Renamed from sha_finish_ctx.
14943         (sha1_read_ctx): Renamed from sha_read_ctx.
14944         (sha1_stream): Renamed from sha_stream.
14945         (sha1_buffer): Renamed from sha_buffer.
14946         * lib/sha1.c: Likewise; renamed from sha.c.
14947         Do not include <sys/types.h>.
14948         Include <stddef.h> rather than <stdlib.h>.
14949
14950 2004-08-08  Bruno Haible  <bruno@clisp.org>
14951
14952         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
14953         FILESYSTEM_PREFIX_LEN.
14954         * lib/progreloc.c: Likewise.
14955         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
14956
14957 2004-08-06  Simon Josefsson  <jas@extundo.com>
14958
14959         * modules/progname (Depends-on): Don't depend on stdbool.
14960
14961 2004-08-06  Simon Josefsson  <jas@extundo.com>
14962
14963         * modules/getsubopt: New file.
14964         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14965         getsubopt.
14966
14967 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
14968
14969         More merge from coreutils.
14970
14971         * m4/utimens.m4, m4/utimecmp.m4: New files.
14972         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
14973         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
14974         prereq.m4, sha.m4: Import changes from coreutils.
14975
14976 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
14977
14978         More merge from coreutils.
14979         * modules/raise, modules/readtokens0, modules/utimens:
14980         * modules/utimecmp, module/xnanosleep: New files.
14981         * modules/strftime: Add lib/strftime.h.
14982         Change include from <time.h> to "strftime.h".
14983         * modules/yesno: Add lib/yesno.h.
14984         * modules/backupfile: Remove lib/addext.c.
14985         * modules/euidaccess: Add stat-macros.h.
14986         * modules/canonicalize, modules/euidaccess,
14987         modules/filemode, modules/lchown, modules/makepath,
14988         modules/rmdir, modules/stat: Likewise.
14989
14990 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
14991
14992         Merge from tar.
14993         * lib/argp-help.c (make_hol, hol_append): Don't assume that
14994         SIZE_MAX is a valid preprocessor constant.
14995         (__argp_basename): Change from "#ifndef _LIBC"
14996         to "#ifndef __argp_short_program_name", so that
14997         we don't compile these functions for tar.
14998
14999         More merges from coreutils.
15000         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
15001         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
15002         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
15003         * lib/addext.c: Remove; no longer needed.
15004         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
15005         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
15006         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
15007         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
15008         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
15009         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
15010         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
15011         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
15012         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
15013         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15014         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
15015         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
15016         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
15017         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
15018         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
15019         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
15020         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
15021         Import changes from coreutils.
15022
15023 2004-08-05  Simon Josefsson  <jas@extundo.com>
15024
15025         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
15026
15027 2004-08-05  Simon Josefsson  <jas@extundo.com>
15028
15029         * m4/getsubopt.m4: New file.
15030
15031 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15032
15033         Merge from coreutils.
15034
15035         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
15036         * m4/getcwd-path-max.m4: New files.
15037
15038         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
15039         FILESYSTEM_PREFIX_LEN ->
15040         FILE_SYSTEM_PREFIX_LEN.
15041         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
15042         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
15043         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
15044         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
15045
15046         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
15047         prerequisite modules now handle the DOS stuff.
15048         Don't check for unistd.h.
15049
15050 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15051
15052         Merge from coreutils.
15053
15054         * lib/.gdb-history: Remove; this doesn't belong here.
15055
15056         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
15057         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
15058         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
15059         * lib/getcwd.c: New files.
15060
15061         * lib/dirname.h: Include <stdbool.h>.
15062         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
15063         for consistency with POSIX terminology.  All uses changed.
15064         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
15065         (strip_trailing_slashes): Use bool for booleans.
15066         * lib/stripslash.c (strip_trailing_slashes): Likewise.
15067
15068         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
15069         sometimes returns a positive errno value even when it succeeds.
15070         (print_errno_message) [!LIBC]: Fall back on strerror if
15071         __strerror_r fails.
15072
15073         * lib/path-concat.c (mempcpy): Don't define if a system header defines
15074         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
15075         (longest_relative_suffix): New function.
15076         (path_concat): Use it.  Assume first argument is not NULL.
15077         Port to DOS.  Omit redundant separators.
15078         Report an error instead of returning NULL.
15079         Use mempcpy instead of memcpy.
15080         (xpath_concat): Remove: not declared or used.
15081
15082         * lib/same.h: Include <stdbool.h>
15083         (same_name): Return bool, not int.
15084         * lib/same.c (same_name): Likewise.
15085         (errno): Don't declare; we assume C89 or better now.
15086
15087         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
15088         if not already defined.
15089
15090         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
15091         * lib/dup-safer.c (errno): Likewise.
15092
15093 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15094
15095         Merge from coreutils.
15096         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
15097         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
15098         * modules/path-concat: Don't depend on strdup.
15099
15100 2004-08-03  Simon Josefsson  <jas@extundo.com>
15101
15102         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
15103         * lib/progname.h: Don't include stdbool.h.
15104
15105 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15106
15107         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
15108         * MODULES.html.sh (func_all_modules): Remove fatal.
15109
15110 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15111
15112         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
15113
15114 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15115
15116         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
15117         working.
15118
15119 2004-08-02  Simon Josefsson  <jas@extundo.com>
15120
15121         * lib/getsubopt.h: New file, with comments from Bruno Haible.
15122         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
15123         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
15124
15125 2004-08-01  Simon Josefsson  <jas@extundo.com>
15126
15127         * lib/xgetdomainname.c: Include stdlib.h, for free().
15128
15129 2004-07-19  Bruno Haible  <bruno@clisp.org>
15130
15131         * MODULES.html.sh (func_all_modules): Add dummy.
15132
15133 2004-07-16  Simon Josefsson  <jas@extundo.com>
15134
15135         * modules/dummy: New file.
15136
15137 2004-07-16  Simon Josefsson  <jas@extundo.com>
15138
15139         * lib/dummy.c: New file.
15140
15141 2004-07-16  Bruno Haible  <bruno@clisp.org>
15142
15143         * lib/backupfile.h: Add extern "C" for C++.
15144         * lib/closeout.h: Likewise.
15145         * lib/copy-file.h: Likewise.
15146         * lib/findprog.h: Likewise.
15147         * lib/full-write.h: Likewise.
15148         * lib/pathname.h: Likewise.
15149         * lib/progname.h: Likewise.
15150         * lib/stpcpy.h: Likewise.
15151         * lib/stpncpy.h: Likewise.
15152         * lib/strcase.h: Likewise.
15153         * lib/strstr.h: Likewise.
15154         * lib/xalloc.h: Likewise.
15155
15156         * lib/mbswidth.h: Add extern "C" for C++.
15157         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
15158
15159 2004-07-13  Robert Millan  <robertmh@gnu.org>
15160
15161         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
15162
15163 2004-07-09  Simon Josefsson  <jas@extundo.com>
15164
15165         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
15166         failed without this.)
15167
15168 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15169
15170         * modules/chown (Files): Add lib/fchown-stub.c, since
15171         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
15172
15173 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15174
15175         * lib/fchown-stub.c: New file.
15176
15177 2004-06-24  Jim Meyering  <jim@meyering.net>
15178
15179         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
15180
15181 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15182
15183         * modules/argz: Omit "#include".
15184
15185         * MODULES.html.sh (func_all_modules): Add calloc, to match
15186         2004-06-01 addition of calloc module.
15187
15188 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15189
15190         * m4/argz.m4: New file, which is autoupdated from libtool.
15191
15192 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15193
15194         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
15195         libtool.
15196
15197 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15198
15199         * config/srclist-update: Don't insist on "USA." before the
15200         close-comment, as libtool omits the period and puts the */ on a
15201         separate line.
15202         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
15203         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
15204
15205 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
15206
15207         * modules/argz: New file.
15208         * MODULES.html.sh (func_all_modules): Add argz.
15209
15210 2004-06-12  Jim Meyering  <jim@meyering.net>
15211         and  Paul Eggert  <eggert@cs.ucla.edu>
15212
15213         * modules/hash (Files): Add lib/xalloc.h.
15214         * modules/pipe (Depends-on): Add wait-process.
15215         * modules/stat (Depends-on): Add xalloc.
15216         * modules/userspec (Files): Add lib/userspec.h.
15217         * modules/xstrto
15218
15219         Upgrade from gettext-0.13.
15220         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
15221         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
15222         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
15223
15224 2004-06-10  Jim Meyering  <jim@meyering.net>
15225
15226         * lib/calloc.c: New file.
15227
15228 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
15229
15230         * lib/getdate.y (yylex): Allow space between sign and number.
15231         Problem reported by Dan Jacobson.
15232
15233 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15234
15235         Merge from coreutils CVS.
15236
15237         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
15238         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
15239         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
15240         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
15241         xstrtol.m4: Fix copyright date and/or serial number.
15242
15243         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
15244         See if we need an fchown replacement.
15245         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
15246         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
15247         and use the replacement function if we detect either defect.
15248
15249         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
15250         gl_UTIMECMP.
15251
15252 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15253         and  Jim Meyering  <jim@meyering.net>
15254
15255         Merge from coreutils CVS.
15256
15257         * lib/stat-macros.h: New file, with contents from file-type.h
15258         and coreutils' system.h.
15259         * lib/file-type.c: Include "stat-macros.h".
15260         * lib/file-type.h (file_type): Move all macro definitions to new file,
15261         stat-macros.h.
15262
15263         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
15264         Wrap old code with this conditional.
15265         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
15266         function that does not dereference symlinks.
15267         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
15268
15269         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
15270         dependency problems.
15271         (xreadlink): Accept new arg SIZE, for efficiency.
15272         All decls and uses changed.
15273         * lib/xreadlink.h: Include <stddef.h>, for size_t.
15274
15275         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
15276         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
15277
15278         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
15279         sysexits.h.
15280
15281 2004-06-01  Jim Meyering  <jim@meyering.net>
15282
15283         * m4/calloc.m4: New file.
15284
15285 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
15286
15287         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
15288         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
15289         Also, fix a typo in a diagnostic.
15290
15291 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15292
15293         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
15294         or AC_FUNC_REALLOC.
15295
15296 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15297
15298         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
15299         macros to be defined.
15300         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
15301         the allocator returns NULL because the requested size is zero.
15302
15303 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15304
15305         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
15306         var.  Add comment explaining why libc still defines it.  This
15307         merges the following patch from glibc:
15308         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
15309
15310 2004-05-20  Andreas Schwab  <schwab@suse.de>
15311
15312         * m4/free.m4: Replace free if it not known to work, not the other
15313         way round.
15314
15315 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
15316
15317         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
15318         present in glibc since revision 1.1 of this file.
15319         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
15320         obstack_alignment_mask, obstack_alloc, obstack_base,
15321         obstack_blank, obstack_blank_fast, obstack_chunk_size,
15322         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
15323         obstack_grow0, obstack_init, obstack_int_grow,
15324         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
15325         obstack_next_free, obstack_object_size, obstack_ptr_grow,
15326         obstack_ptr_grow_fast, obstack_room): Remove declarations of
15327         nonexistent functions.
15328
15329 2004-05-18  Karl Berry  <karl@gnu.org>
15330
15331         * config/srclist.txt: break link for vasnprintf.c.
15332
15333 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15334
15335         Port obstack to the AS/400, where pointers are 16 bytes wide and
15336         you cannot cast an integer to a valid pointer.  This patch is
15337         currently waiting to be integrated into glibc; see
15338         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
15339
15340         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
15341         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
15342         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
15343         (struct obstack): temp member is now a union of a pointer and
15344         an integer, instead of an integer.  All integer uses changed.
15345         This does not affect the physical layout of struct obstack,
15346         except on hosts (like the AS/400) where the size or alignment of
15347         void * is greater than that of ptrdiff_t.
15348         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
15349         __STDC__)]: Store temporary in pointer member of union, not
15350         integer member.
15351         * lib/obstack.c: Include <stddef.h>, for offsetof.
15352         (struct fooalign): Remove; it doesn't need a name.
15353         (union fooround): Change double to long double, and add void *.
15354         (DEFAULT_ALIGNMENT): Use offsetof to compute.
15355         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
15356         not a macro.  Hence the values are always int; so remove all
15357         casts-to-int in uses.
15358
15359 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15360
15361         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
15362         we can get this patch merged into glibc.
15363
15364 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15365             Paul Eggert  <eggert@cs.ucla.edu>
15366
15367         * m4/argp: Depend on alloca.
15368
15369 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15370             Paul Eggert  <eggert@cs.ucla.edu>
15371
15372         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
15373         freecoding.
15374
15375 2004-05-17  Bruno Haible  <bruno@clisp.org>
15376
15377         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
15378         precision that consists of a '.' followed by an empty digit string.
15379         Patch by Tor Lillqvist <tml@iki.fi>.
15380
15381 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15382
15383         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
15384         for backward compatibility with older code.  We need our own
15385         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
15386         it under some other name, and our alloca.h will define it.
15387
15388 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15389             Derek Price  <derek@ximbiot.com>
15390
15391         * lib/alloca.c: Include <alloca.h>, to get our interface.
15392         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
15393         include <alloca.h> first.  Use C89 prototype for alloca; this
15394         requires including <stddef.h> for size_t.  Use extern "C" if C++.
15395         Use #elif for simplicity, since we can assume C89 now.
15396         Don't try to source the system alloca.h since it will not be found
15397         and to prevent recursively including its replacement.
15398         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
15399         * lib/regex.c: Likewise.
15400
15401 2004-05-16  Derek Price  <derek@ximbiot.com>
15402             Paul Eggert  <eggert@cs.ucla.edu>
15403
15404         getline cleanup.  This changes the getndelim2 API: both order of
15405         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
15406         no delimiter).
15407
15408         * lib/getline.c: Don't include stddef.h or stdio.h, since our
15409         interface does that.
15410         (getline): Always use getdelim, so that we don't have two
15411         copies of this code.
15412         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
15413         if available.
15414         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
15415         (GETNDELIM2_MAXIMUM): New macro.
15416         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
15417         instead of the old practice of delim2==0.  All callers changed.
15418         Return -1 on overflow, instead of returning junk.
15419         Do not set *linesize unless allocation succeeds.
15420         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
15421         that we include sys/types.h.
15422         * lib/getnline.h: Likewise.
15423         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
15424         (getndelim2): Reorder arguments.
15425         * lib/getnline.c (getnline, getndelim):
15426         Don't discard the NMAX argument.
15427         (getnline): Invoke getndelim, to avoid code duplication.
15428         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
15429         of (size_t) -1 by callers of the getnline family.
15430
15431 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15432
15433         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
15434         Check for gettimeofday.
15435         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
15436         Check for settimeofday, stime.
15437
15438 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15439
15440         * lib/nanosleep.c (suspended): Change its type from int to
15441         sig_atomic_t volatile.
15442         (first_call): Make it private to rpl_nanosleep, and have it
15443         be zero initially as that's a bit faster.
15444         (my_usleep): Round up fractional times instead of truncating them,
15445         as this is the usual meaning for 'sleep'.
15446
15447         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
15448         doesn't work.
15449         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
15450         (ENOSYS): Define if not defined.
15451         (settime): Fall back on stime if it exists and settimeofday fails.
15452         But don't bother with fallbacks if a method fails with errno == EPERM.
15453
15454 2004-05-11  Jim Meyering  <jim@meyering.net>
15455
15456         Prior to this change, the save_cwd caller required read access to the
15457         current directory on most systems (ones with the fchdir function).
15458
15459         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
15460         fails, try write-only, and finally, resort to using xgetcwd.
15461
15462 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15463
15464         * lib/obstack.c, obstack.h: Import changes from libc.
15465
15466 2004-04-28  Bruno Haible  <bruno@clisp.org>
15467
15468         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
15469         also implicitly appends .exe to executables.
15470         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
15471         accepts Windows pathnames.
15472         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15473         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15474         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15475         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15476         Reported by Derek Robert Price <derek@ximbiot.com>.
15477
15478 2004-04-21  Karl Berry  <karl@gnu.org>
15479
15480         * config/srclist.txt (localcharset.c): break sync.
15481
15482 2004-04-20  Paul Eggert  <eggert@twinsun.com>
15483
15484         * m4/host-os.m4: Add a copyright notice.
15485
15486 2004-04-20  Jim Meyering  <jim@meyering.net>
15487
15488         Change UTILS_ to gl_ in AC_DEFINE'd names.
15489         Change utils_- and jm_-prefixed variables, too.
15490         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
15491         UTILS_FUNC_MKDIR_TRAILING_SLASH.
15492         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
15493
15494         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
15495         Don't emit trailing blanks.
15496         Also rename jm_-prefixed variables to have gl_ prefix.
15497
15498         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
15499         Also rename jm_-prefixed variables to have gl_ prefix.
15500
15501         * m4/jm-macros.m4: Reflect the renamings.
15502         * m4/prereq.m4: Likewise.
15503
15504 2004-04-20  Jim Meyering  <jim@meyering.net>
15505
15506         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
15507         memory.
15508
15509 2004-04-20  Jim Meyering  <jim@meyering.net>
15510             Bruno Haible  <bruno@clisp.org>
15511
15512         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
15513         memory when realloc fails.
15514
15515 2004-04-19  Jim Meyering  <jim@meyering.net>
15516
15517         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
15518         now that readutmp.c may call `free (0)'.
15519
15520 2004-04-19  Bruno Haible  <bruno@clisp.org>
15521
15522         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
15523         * m4/inttypes_h.m4: Likewise.
15524         * m4/stdint_h.m4: Likewise.
15525         * m4/intmax_t.m4: Likewise.
15526         * m4/uintmax_t.m4: Likewise.
15527
15528 2004-04-18  Jim Meyering  <jim@meyering.net>
15529
15530         * m4/prereq.m4: Don't forbid jm_ prefix.
15531
15532         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
15533         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
15534         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
15535         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
15536         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
15537         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
15538         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
15539         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
15540         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
15541         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
15542         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
15543         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
15544         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
15545         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
15546         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
15547         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
15548         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
15549         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
15550         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
15551
15552 2004-04-18  Jim Meyering  <jim@meyering.net>
15553
15554         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
15555         failure, don't leak memory and do call END_UTMP_ENT.
15556
15557 2004-04-16  Jim Meyering  <jim@meyering.net>
15558
15559         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
15560         coreutils' stat program.
15561         (gl_PREREQ): Don't require jm_PREREQ_STAT.
15562
15563 2004-04-11  Paul Eggert  <eggert@twinsun.com>
15564
15565         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
15566         C89.
15567         (CHAR_BIT): Remove, since we assume C89.
15568         Include <stdint.h> if available, as per current Autoconf CVS advice.
15569
15570 2004-03-31  Jim Meyering  <jim@meyering.net>
15571
15572         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
15573         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
15574         * m4/xalloc.m4: Likewise.
15575
15576 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15577
15578         Merge from coreutils.
15579
15580         * m4/inttostr.m4: New file.
15581         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
15582         Require AM_STDBOOL_H and gl_TIMESPEC instead.
15583         Require gl_CLOCK_TIME.
15584         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
15585
15586 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15587
15588         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
15589         not bool, to be more consistent with Unix conventions.
15590         Suggested by Bruno Haible.
15591
15592         Merge from coreutils.
15593
15594         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
15595         * lib/umaxtostr.c: New files.
15596
15597         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
15598         the usual <time.h> dance.
15599         (get_date): Change signature to support fractional time stamps.
15600         All callers changed.
15601         * lib/getdate.y: Include "getdate.h" first, as we can now
15602         assume C89 and don't need to worry about 'const'.
15603         Similarly, include "unlocked-io.h" near start, not in middle.
15604         Include <limits.h>.
15605         (textint.value): Use long int rather than int.
15606         (textint.digits): Use size_t rather than int.
15607         (BILLION, LOG10_BILLION): New constants.
15608         (parser_control): New member rel_ns.  Members day_ordinal,
15609         time_zone, month, day, hour, minutes, rel_year, rel_month,
15610         rel_day, rel_hour, rel_minutes, rel_seconds
15611         are now long int, not int.  Member seconds is now struct timespec,
15612         not int.  New member timespec_seen.  Members dates_seen, days_seen,
15613         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
15614         not int.
15615         (%union.intval): Now long int, not int.
15616         New member timespec.
15617         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
15618         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
15619         (spec): Now is a timespec or an item list.
15620         (timespec, items): New nonterminals.
15621         (time, rel, relunit, number, get_date):
15622         Add support for fractional seconds.
15623         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
15624         (gmtime, localtime, mktime): Remove decls; not needed with C89.
15625         (to_hour): First arg is now long int, not int.
15626         (to_year): Returns long int, not int.
15627         Don't treat year -70 like 70.
15628         (tm_diff): Returns long int, not int.
15629         (lookup_word): Use bool instead of int when appropriate.
15630         (yylex): Use size_t for count, not int.
15631         Detect overflow when parsing large integer constants.
15632         Add support for fractions.
15633         (get_date): Make pointers 'const' if possible.
15634         Use more-portable code to detect integer overflow.
15635         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
15636         Don't use ctime; it's not reliable if the year has >4 digits.
15637
15638         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
15639         This is for compatibility with BSD.
15640
15641         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
15642         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
15643         From coreutils' system.h.
15644
15645         * lib/userspec.c: Don't include "posixver.h".
15646         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
15647         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
15648         compatible extension.  Simplify code by removing a boolean int
15649         that was always nonzero if a string was nonnull.
15650
15651 2004-03-30  Jim Meyering  <jim@meyering.net>
15652
15653         Merge from coreutils.
15654
15655         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
15656         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
15657         on some systems one must include <grp.h> before it.
15658         Reported by Christian Krackowizer.
15659
15660 2004-03-30  Jim Meyering  <jim@meyering.net>
15661
15662         Merge from coreutils.
15663
15664         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
15665
15666         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
15667         an empty input stream.
15668
15669         * lib/readtokens.c: Include <stdbool.h>.
15670         (readtoken): Use `size_t' rather than int/long.
15671         All callers adjusted.
15672         Use `bool' rather than `int' where appropriate.
15673         Use memset rather than an explicit loop.
15674         Use x2nrealloc rather than xrealloc.
15675         Allow the use of `\0' as a delimiter.
15676         (readtokens): Likewise.
15677         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
15678
15679 2004-03-30  Jim Meyering  <jim@meyering.net>
15680
15681         * m4/realloc.m4: Remove file, since now it does no more than
15682         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
15683         the `configure.ac' section of module/realloc.
15684         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
15685
15686 2004-03-30  Bruno Haible  <bruno@clisp.org>
15687
15688         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
15689         nonnull.
15690
15691 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15692
15693         Merge changes to getloadavg.c from coreutils and Emacs.
15694
15695         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
15696         Define to an expression, not to the empty string.
15697         Include cloexec.h and xalloc.h.
15698         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
15699         Use set_cloexec_flag rather than rolling our own.
15700         * lib/cloexec.c, lib/cloexec.h: New files.
15701
15702 2004-03-29  Paul Eggert  <eggert@twinsun.com>
15703
15704         * m4/cloexec.m4: New file.
15705
15706 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15707
15708         * lib/getopt.h: Sync with libc CVS.
15709
15710 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15711             Bruno Haible  <bruno@clisp.org>
15712
15713         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
15714         mbswidth.
15715
15716 2004-03-18  Paul Eggert  <eggert@twinsun.com>
15717             Bruno Haible  <bruno@clisp.org>
15718
15719         * lib/mbswidth.h: Include <wchar.h> only if
15720         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
15721         <wchar.h>.
15722         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
15723
15724 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15725
15726         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
15727         Sync with libc CVS.
15728         * lib/getopt_int.h: New file, also synced from libc.
15729
15730 2004-03-09  Paul Eggert  <eggert@twinsun.com>
15731
15732         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
15733         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
15734         Bring back getopt.c, getopt.h, getopt1.c.
15735
15736 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15737
15738         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
15739         All uses changed.  Check for sa_sigaction member; this fixes
15740         a bug first reported by Jason Andrade in
15741         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15742
15743 2004-03-07  Paul Eggert  <eggert@twinsun.com>
15744
15745         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
15746         '#if' expressions.  Unlike the code it replaces, it does not
15747         depend on (defined _SC_PAGESIZE).  However, it does depend on
15748         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
15749         first reported by Jason Andrade in
15750         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
15751
15752 2004-02-25  Simon Josefsson  <jas@extundo.com>
15753
15754         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
15755
15756 2004-02-25  Simon Josefsson  <jas@extundo.com>
15757
15758         * lib/strdup.h: New file.
15759         * lib/strdup.c: Include it.
15760         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
15761         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
15762
15763 2004-02-23  Karl Berry  <karl@gnu.org>
15764
15765         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
15766         (from fencepost.gnu.org:/gd/gnuorg).
15767
15768 2004-02-23  Karl Berry  <karl@gnu.org>
15769
15770         * config/srclistvars.sh (GNUORG) [karl]: redefine.
15771         * config/srclist.txt: add maintain/standards documents.
15772
15773 2004-02-18  Bruno Haible  <bruno@clisp.org>
15774
15775         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
15776         Reported by Derek Robert Price <derek@ximbiot.com>.
15777
15778 2004-02-16  Karl Berry  <karl@gnu.org>
15779
15780         * config/mkinstalldirs, install-sh: update from automake.
15781
15782 2004-02-06  Karl Berry  <karl@gnu.org>
15783
15784         * m4/po.m4: update from gettext 0.14.1.
15785
15786 2004-02-06  Karl Berry  <karl@gnu.org>
15787
15788         * lib/config.charset: update from gettext 0.14.1.
15789
15790 2004-02-05  Paul Eggert  <eggert@twinsun.com>
15791
15792         Add comments and code, prompted by suggestions from Bruno Haible
15793         for sh-quote.
15794         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
15795         describing the enum quoting_style values.
15796         * lib/quotearg.c (quotearg_alloc): New function.
15797         (quotearg_buffer_restyled): Treat lone { and } as special.
15798         Treat = as special.  Work around bug with older shells
15799         that "see" a '\' that is really the 2nd byte of a multibyte char.
15800         Quote empty string with shell_quoting_style.
15801
15802 2004-02-03  Bruno Haible  <bruno@clisp.org>
15803
15804         * m4/pipe.m4: New file, from GNU gettext.
15805
15806 2004-02-03  Bruno Haible  <bruno@clisp.org>
15807
15808         * lib/pipe.h: New file, from GNU gettext.
15809         * lib/pipe.c: New file, from GNU gettext.
15810
15811 2004-01-27  Bruno Haible  <bruno@clisp.org>
15812
15813         * m4/execute.m4: New file, from GNU gettext.
15814
15815 2004-01-27  Bruno Haible  <bruno@clisp.org>
15816
15817         * lib/execute.h: New file, from GNU gettext.
15818         * lib/execute.c: New file, from GNU gettext.
15819         * lib/w32spawn.h: New file, from GNU gettext.
15820
15821 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15822
15823         Merge from diffutils.
15824
15825         * lib/file-type.c (file_type): Add typed memory objects.
15826         * lib/file-type.h (S_TYPEISTMO): New macro.
15827
15828         * lib/c-stack.h (c_stack_action): Remove argv argument.
15829         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
15830         (die): Don't calculate message unless segv_action returns.
15831         (get_stack_location, min_address_from_argv, max_address_from_argv,
15832         volatile stack_base, volatile_stack_size): Remove.
15833         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
15834         that every segmentation violation is a stack overflow.  (Ouch!)
15835         See Debian bug 136249 (still outstanding) for more info about why
15836         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
15837
15838 2004-01-24  Paul Eggert  <eggert@twinsun.com>
15839
15840         Exit-status fix from coreutils.
15841
15842         Use exit_failure consistently in place of EXIT_FAILURE,
15843         so that program exit statuses are consistent on failure.
15844
15845         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
15846         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
15847         * lib/argmatch.h: Comment fix to match the above.
15848         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
15849         Now a macro referring to exit_failure, instead of a separate
15850         variable.  Include "exitfail.h" to get it.
15851         * lib/xstrtol.h: Include "exitfail.h".
15852         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
15853
15854         * lib/long-options.c (parse_long_options): Use prototype
15855         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
15856         for clarity.
15857
15858 2004-01-21  Jim Meyering  <jim@meyering.net>
15859
15860         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
15861         so as not to conflict with a different-sized __mktime_internal
15862         function in GNU libc.
15863         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
15864         Problem building statically-linked `ls' reported by Michael Brunnbauer.
15865
15866 2004-01-20  Karl Berry  <karl@gnu.org>
15867
15868         * config/config.guess: update from config.
15869
15870         * config/srclistvars.sh: GNUWWWLICENSES for karl.
15871
15872 2004-01-20  Bruno Haible  <bruno@clisp.org>
15873
15874         Safer stack allocation.
15875         * lib/setenv.c: Include allocsa.h.
15876         (alloca): Remove fallback definition.
15877         (freea): Remove macro.
15878         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
15879         instead of freea.
15880
15881 2004-01-20  Bruno Haible  <bruno@clisp.org>
15882
15883         * m4/eealloc.m4: New file, from GNU gettext.
15884
15885 2004-01-20  Bruno Haible  <bruno@clisp.org>
15886
15887         * m4/allocsa.m4: New file, from GNU gettext.
15888
15889 2004-01-20  Bruno Haible  <bruno@clisp.org>
15890
15891         * lib/xallocsa.h: New file, from GNU gettext.
15892         * lib/xallocsa.c: New file, from GNU gettext.
15893
15894 2004-01-20  Bruno Haible  <bruno@clisp.org>
15895
15896         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
15897
15898 2004-01-20  Bruno Haible  <bruno@clisp.org>
15899
15900         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
15901         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
15902         specially.
15903
15904 2004-01-20  Bruno Haible  <bruno@clisp.org>
15905
15906         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
15907         patch.
15908
15909 2004-01-20  Bruno Haible  <bruno@clisp.org>
15910
15911         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
15912
15913 2004-01-20  Bruno Haible  <bruno@clisp.org>
15914
15915         * lib/eealloc.h: New file.
15916
15917 2004-01-20  Bruno Haible  <bruno@clisp.org>
15918
15919         * lib/binary-io.h: Avoid warnings on Cygwin.
15920
15921 2004-01-20  Bruno Haible  <bruno@clisp.org>
15922
15923         * lib/allocsa.h: New file, from GNU gettext.
15924         * lib/allocsa.c: New file, from GNU gettext.
15925
15926 2004-01-18  Karl Berry  <karl@gnu.org>
15927
15928         * doc/gpl.texi, doc/lgpl.texi: new files.
15929
15930 2004-01-18  Karl Berry  <karl@gnu.org>
15931
15932         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
15933         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
15934
15935 2004-01-15  Paul Eggert  <eggert@twinsun.com>
15936
15937         Merge from coreutils.
15938
15939         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
15940         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
15941         (gl_DEFAULT_POSIX2_VERSION): Move
15942         the documentation from 'configure' into 'config.hin',
15943         so that 'configure --help' isn't burdened by it and
15944         we don't have to worry about its formatting there.
15945         Reword the documentation so that it's more succinct
15946         and can be run together into a single paragraph.
15947         * m4/same.m4 (gl_SAME): Check for pathconf.
15948
15949 2004-01-15  Paul Eggert  <eggert@twinsun.com>
15950
15951         Merge from coreutils.
15952
15953         * lib/posixver.c: Include posixver.h.
15954
15955         * lib/same.c: Include <stdbool.h>, <limits.h>.
15956         (_POSIX_NAME_MAX): Define if not defined.
15957         (MIN): New macro.
15958         (same_name): If file names are silently truncated, report
15959         that the file names are the same if they are the same after
15960         the silent truncation.
15961
15962         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
15963         conversion function.
15964         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
15965         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
15966         longer needed.
15967
15968 2004-01-15  Jim Meyering  <jim@meyering.net>
15969
15970         Merge from coreutils.
15971
15972         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
15973         if no library is required.
15974         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
15975         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
15976         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
15977         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
15978         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
15979         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
15980         value, $ac_cv_search_crypt, if it's "none required".
15981         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
15982         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
15983         not gl_FUNC_GETLOADAVG.
15984         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
15985         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
15986
15987 2004-01-15  Jim Meyering  <jim@meyering.net>
15988
15989         Merge from coreutils.
15990
15991         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
15992         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
15993         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
15994
15995         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
15996         optional configure-time default.
15997
15998         * lib/version-etc.c (version_etc_copyright): Update copyright date.
15999
16000         * lib/xreadlink.c (xreadlink): Correct outdated comment.
16001
16002 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
16003
16004         Merge from coreutils.
16005
16006         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
16007         value, $ac_cv_search_nanosleep, if it's "none required".
16008
16009 2004-01-14  Paul Eggert  <eggert@twinsun.com>
16010
16011         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
16012         with like-named macro in fnmatch.c.
16013         (EXT): Use an internal constant instead.
16014
16015         Merge fnmatch patches from glibc.
16016         * lib/fnmatch.c (mbsinit): Remove define.
16017         Add libc_hidden_ver (__fnmatch, fnmatch).
16018         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
16019         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
16020
16021 2004-01-14  Karl Berry  <karl@gnu.org>
16022
16023         * config/install-sh: update from automake.
16024
16025 2004-01-13  Karl Berry  <karl@gnu.org>
16026
16027         * config/install-sh: update from automake.
16028
16029 2004-01-09  Karl Berry  <karl@gnu.org>
16030
16031         * config/install-sh: update from automake.
16032
16033 2004-01-05  Karl Berry  <karl@gnu.org>
16034
16035         * config/config.{sub,guess}: update from config.
16036
16037 2003-12-31  Karl Berry  <karl@gnu.org>
16038
16039         * config/depcomp: update from automake.
16040
16041 2003-12-14  Karl Berry  <karl@gnu.org>
16042
16043         * lib/config.charset: update from gettext-runtime.
16044
16045 2003-12-03  Paul Eggert  <eggert@twinsun.com>
16046
16047         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
16048         Bug reported by Alfred M. Szmidt.
16049
16050 2003-12-03  Bruno Haible  <bruno@clisp.org>
16051
16052         * m4/gettext.m4: Upgrade from gettext-0.13.
16053         * m4/po.m4: Upgrade from gettext-0.13.
16054         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
16055         * m4/intmax.m4: New file, from gettext-0.13.
16056         * m4/printf-posix.m4: New file, from gettext-0.13.
16057
16058 2003-11-29  Karl Berry  <karl@gnu.org>
16059
16060         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
16061
16062 2003-11-25  Paul Eggert  <eggert@twinsun.com>
16063             Bruno Haible  <bruno@clisp.org>
16064
16065         * lib/printf-parse.h: Don't include sys/types.h.
16066         (ARG_NONE): New macro.
16067         (char_directive): Change type of *arg_index fields to size_t.
16068         * lib/printf-parse.c: Don't include sys/types.h.
16069         (SSIZE_MAX): Remove macro.
16070         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
16071         Remove unnecessary overflow check.
16072         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
16073         fields.
16074
16075 2003-11-25  Bruno Haible  <bruno@clisp.org>
16076
16077         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
16078
16079 2003-11-25  Bruno Haible  <bruno@clisp.org>
16080
16081         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
16082         gt_TYPE_SSIZE_T.
16083
16084 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16085
16086         * modules/alloca: Remove dependency on xalloc.
16087
16088 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16089
16090         * lib/alloca.c: Remove dependency on xalloc module.
16091         (xalloc_die): Remove.
16092         (memory_full) [!defined emacs]: New macro.
16093         [!defined emacs]: Don't include xalloc.h.
16094         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
16095         address arithmetic overflows.  Change datatypes a bit to avoid
16096         unnecessary casts.
16097
16098 2003-11-22  Jim Meyering  <jim@meyering.net>
16099
16100         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
16101         s/size/size_t/.
16102
16103 2003-11-21  Karl Berry  <karl@gnu.org>
16104
16105         * config/config.{sub,guess}: update from config.
16106
16107 2003-11-18  Karl Berry  <karl@gnu.org>
16108
16109         * config/config.{sub,guess}: update from config.
16110
16111         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
16112
16113 2003-11-17  Paul Eggert  <eggert@twinsun.com>
16114
16115         * README: Mention that S+T cannot overflow if S is the size of
16116         an existing object and T is sufficiently small.
16117
16118 2003-11-17  Jim Meyering  <jim@meyering.net>
16119
16120         On systems without utime and without a utimes function capable of
16121         dealing with a NULL struct utimbuf* argument, this utime replacement
16122         could -- in unusual circumstances -- leak a file descriptor.
16123         * lib/utime.c: Include <unistd.h> and <errno.h>.
16124         (utime_null): Be sure to close `fd' and to preserve errno.
16125         Reported by Geoff Collyer via Arnold Robbins.
16126
16127 2003-11-17  Bruno Haible  <bruno@clisp.org>
16128
16129         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
16130         (Depends-on): Add xsize.
16131
16132 2003-11-17  Bruno Haible  <bruno@clisp.org>
16133
16134         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
16135
16136 2003-11-17  Bruno Haible  <bruno@clisp.org>
16137
16138         * lib/vasnprintf.c (alloca): Remove fallback definition.
16139         (freea): Remove definition.
16140         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
16141         Reported by Paul Eggert.
16142
16143 2003-11-16  Paul Eggert  <eggert@twinsun.com>
16144             Bruno Haible  <bruno@clisp.org>
16145
16146         Protect against address arithmetic overflow.
16147         * lib/printf-args.h: Include stddef.h.
16148         (arguments): Change type of field 'count' to size_t.
16149         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
16150         'unsigned int' where appropriate.
16151         * lib/printf-parse.h: Include sys/types.h.
16152         (char_directive): Change type of *arg_index fields to ssize_t.
16153         (char_directives): Change type of fields 'count', max_*_length to
16154         size_t.
16155         * lib/printf-parse.c: Include sys/types.h and xsize.h.
16156         (SSIZE_MAX): Define fallback value.
16157         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
16158         instead of 'int' where appropriate. Check a_allocated, d_allocated
16159         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
16160         * lib/vasnprintf.c: Include xsize.h.
16161         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
16162         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
16163         overflow. Avoid wraparound when converting a width or precision from
16164         decimal to binary.
16165
16166 2003-11-16  Bruno Haible  <bruno@clisp.org>
16167
16168         Update from GNU gettext.
16169         * lib/printf-parse.c: Generalize to it can be compiled for wide
16170         strings.
16171         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
16172         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
16173         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
16174         SNPRINTF): New macros.
16175         Don't include <alloca.h> if the file is used inside libintl.
16176         (local_wcslen): New function, for Solaris 2.5.1.
16177         (VASNPRINTF): Use it instead of wcslen.
16178
16179 2003-11-16  Bruno Haible  <bruno@clisp.org>
16180
16181         * lib/xsize.h (xmax): New function.
16182         (xsum, xsum3, xsum4): Declare as "pure" functions.
16183
16184 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16185
16186         * modules/xalloc (Files): Undo latest change, since xalloc.h
16187         no longer needs SIZE_MAX or PTRDIFF_MAX.
16188
16189 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16190
16191         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
16192         gl_PTRDIFF_MAX.
16193
16194 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16195
16196         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
16197         "return", to pacify some unknown compiler.  Problem reported
16198         by Joerg Schilling.
16199
16200 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16201
16202         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
16203         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
16204         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
16205         heuristic is just as accurate as far as we know, and it removes a
16206         dependency on size_max.m4 and ptrdiff_max.m4.
16207
16208 2003-11-11  Bruno Haible  <bruno@clisp.org>
16209
16210         * modules/xsize (Files): Add m4/size_max.m4.
16211         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
16212
16213 2003-11-11  Bruno Haible  <bruno@clisp.org>
16214
16215         * m4/size_max.m4: New file.
16216         * m4/ptrdiff_max.m4: New file.
16217         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
16218         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
16219         (gl_XALLOC): Invoke it.
16220
16221 2003-11-11  Bruno Haible  <bruno@clisp.org>
16222
16223         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
16224         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
16225         defined.
16226
16227 2003-11-10  Paul Eggert  <eggert@twinsun.com>
16228
16229         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
16230         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
16231         rejected some allocations of exactly SIZE_MAX - 2 bytes.
16232         From Bruno Haible.
16233         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
16234         not (size_t) -1, since it's defined here.
16235
16236 2003-11-09  Karl Berry  <karl@gnu.org>
16237
16238         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
16239
16240 2003-11-06  Paul Eggert  <eggert@twinsun.com>
16241
16242         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
16243         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
16244         Reject sizes of exactly SIZE_MAX bytes.
16245         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
16246         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
16247
16248 2003-11-05  Bruno Haible  <bruno@clisp.org>
16249
16250         * lib/xsize.h: Include limits.h, to avoid a possible collision with
16251         SIZE_MAX defined in <limits.h> on Solaris.
16252
16253 2003-11-04  Jim Meyering  <jim@meyering.net>
16254
16255         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
16256         variable names, rather than @VAR@.
16257         * modules/poll: Likewise.
16258
16259 2003-11-04  Bruno Haible  <bruno@clisp.org>
16260
16261         * modules/xsize: New file.
16262         * modules/linebreak: Depend on xsize.
16263         * MODULES.html.sh (func_all_modules): Add xsize.
16264
16265 2003-11-04  Bruno Haible  <bruno@clisp.org>
16266
16267         * m4/xsize.m4: New file.
16268
16269 2003-11-04  Bruno Haible  <bruno@clisp.org>
16270
16271         * lib/xsize.h: New file.
16272         * lib/linebreak.c: Include xsize.h.
16273         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
16274         argument for overflow.
16275         Suggested by Paul Eggert.
16276
16277 2003-11-03  Karl Berry  <karl@gnu.org>
16278
16279         * config/config.{guess,sub}: update from config.
16280
16281 2003-11-03  Jim Meyering  <jim@meyering.net>
16282
16283         * modules/userspec (lib_SOURCES): Add userspec.h.
16284         (Include): Add "userspec.h".
16285         Improve description.
16286
16287 2003-11-03  Jim Meyering  <jim@meyering.net>
16288
16289         * lib/userspec.c: Include "userspec.h".
16290         * lib/userspec.h: New file.
16291
16292 2003-11-03  Bruno Haible  <bruno@clisp.org>
16293
16294         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
16295
16296 2003-11-03  Bruno Haible  <bruno@clisp.org>
16297
16298         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
16299         available, to avoid (extremely rare) race condition.
16300         Suggested by Paul Eggert.
16301
16302 2003-11-02  Karl Berry  <karl@gnu.org>
16303
16304         * config/srclist.txt (vasprintf.c): sync broken, sigh.
16305
16306 2003-10-31  Paul Eggert  <eggert@twinsun.com>
16307
16308         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
16309         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
16310         (read_filesystem_list): Set and use me_type_malloced.
16311         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
16312         whatever the type happens to be), for brevity and consistency.
16313         Check for size calculation overflow on Alphas running OSF/1.
16314
16315 2003-10-31  Jim Meyering  <jim@meyering.net>
16316
16317         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
16318
16319         * lib/linebuffer.c: Include <string.h> for declaration of memset.
16320
16321 2003-10-30  Paul Eggert  <eggert@twinsun.com>
16322             Bruno Haible  <bruno@clisp.org>
16323
16324         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
16325         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
16326
16327 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16328
16329         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
16330         netbsd*-gnu*.  Suggested by Robert Millan.
16331
16332 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16333
16334         * modules/group-member: Depend on stdbool.
16335
16336 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16337
16338         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
16339
16340 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16341
16342         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
16343         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
16344         after the 'gnu' in these cases.  This fixes some bugs in the
16345         previous change, and is based on suggestions by Robert Millan.
16346
16347 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16348
16349         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
16350         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
16351         no longer needed.
16352         * lib/quotearg.c (quotearg_n_options): Use it.
16353         * lib/group-member.c: Include <stdbool.h>.
16354         (free_group_info): Arg is now const *; don't free arg.
16355         (get_group_info): Now returns bool and accepts struct group_info *,
16356         rather than returning a malloc'ed struct group_info *.
16357         All uses changed.  Check for overflow in internal size calculation.
16358
16359         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
16360         rather than xmalloc/xrealloc.
16361         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
16362         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
16363         conformance bug: the old code used a pointer after freeing the
16364         storage that it addressed.
16365         * lib/hash.c (hash_initialize): Simplify the code by using
16366         xalloc_oversized rather than doing it by hand.
16367         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
16368         the buffer preserved.  Use free and xmalloc instead.
16369         * lib/quotearg.c (quotearg_n_options): Likewise.
16370         Use a simpler test for size overflow.  Don't use xalloc_oversized
16371         because unsigned int might be wider than size_t (!); this suggests
16372         that we should switch from unsigned int to size_t for slot numbers.
16373
16374 2003-10-28  Paul Eggert  <eggert@twinsun.com>
16375
16376         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
16377         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
16378         NetBSD kernels.  Requested by Richard Stallman.
16379
16380 2003-10-27  Paul Eggert  <eggert@twinsun.com>
16381
16382         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
16383         to allocate the returned structure.  Do not allocate a subarray,
16384         as x2nrealloc will do that.
16385         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
16386         instead of xnrealloc.
16387         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
16388
16389 2003-10-27  Bruno Haible  <bruno@clisp.org>
16390
16391         * lib/stdbool_.h: Better support for BeOS.
16392
16393 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16394
16395         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
16396         now uses inline.
16397
16398 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16399
16400         * lib/xalloc.h (xalloc_oversized): New static inline function, for
16401         callers that want to do their own size-overflow checking.  Include
16402         <stdbool.h>, since xalloc_oversized returns bool.
16403         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
16404         to use xalloc_oversized.
16405
16406         Add two functions x2realloc, x2nrealloc, for programs that grow
16407         arrays dynamically by doubling their sizes.
16408         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
16409         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
16410         New functions.
16411
16412         Port to C99 semantics for 'inline' of external functions.
16413         Bug reported by Bruno Haible.
16414         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
16415         with the old contents of xnmalloc.
16416         (xnmalloc, xmalloc): Use it.
16417         (xnrealloc_inline): New static inline function,
16418         with the old contents of xnrealloc.
16419         (xnrealloc, xrealloc): Use it.
16420
16421         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
16422         that.
16423
16424 2003-10-26  Karl Berry  <karl@gnu.org>
16425
16426         * config/srclist.txt (COPYING.DOC): no longer available from
16427         /gd/gnuorg; don't know where the ultimate source is.
16428
16429 2003-10-25  Paul Eggert  <eggert@twinsun.com>
16430
16431         Fix several address-calculation bugs in the hash modules,
16432         plus some minor code cleanup.
16433
16434         * lib/hash.h: Include <stdbool.h>, for bool.
16435         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
16436         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
16437         hash_get_n_entries, hash_get_max_bucket_length,
16438         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
16439         hash_rehash): Use size_t rather than unsigned.
16440         * lib/hash.c (struct hash_table, hash_get_n_buckets,
16441         hash_get_n_buckets_used, hash_get_n_entries,
16442         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
16443         hash_get_entries, hash_do_for_each, hash_string, is_prime,
16444         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
16445         Likewise.
16446         (SIZE_MAX): Define if not defined.
16447         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
16448         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
16449         hash_print):
16450         Use const * when possible.
16451         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
16452         (check_tuning): Fix bug: if tuning parameters were very close to
16453         0 or 1, rounding errors could have caused subscript violations.
16454         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
16455         (hash_initialize): Add 'fail:' label
16456         to free table and return NULL, and use it to simplify code.
16457         Use calloc rather than clearing the storage ourself.
16458         (hash_initialize, hash_rehash): Check for arithmetic overflow in
16459         buffer size calculations.
16460         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
16461         Include <stddef.h>, for size_t.
16462         * lib/hash-pjw.c (hash_pjw): Likewise.
16463         Switch to method described by Bruno Haible.
16464         Include <limits.h>, for CHAR_BIT.
16465         (SIZE_BITS): New macro.
16466
16467 2003-10-23  Paul Eggert  <eggert@twinsun.com>
16468
16469         * m4/getline.m4 (AM_FUNC_GETLINE):
16470         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
16471         hosts.  Problem reported by Derek Robert Price in
16472         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
16473         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
16474         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
16475
16476 2003-10-21  Paul Eggert  <eggert@twinsun.com>
16477
16478         * lib/getndelim2.c (getndelim2): When size calculation overflows,
16479         ceiling the allocation at NMAX bytes rather than silently
16480         discarding input bytes before NMAX is reached.  This makes
16481         a difference only if NMAX exceeds SIZE_MAX / 2.
16482
16483         * lib/obstack.c: Merge from glibc.
16484         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
16485         Add libc_hidden_def (_obstack_newchunk).
16486         (_obstack_free) [! defined _LIBC]: Remove.
16487         [defined _LIBC]: Make a strong alias from obstack_free, rather than
16488         a clone of the function body.
16489         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
16490         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
16491
16492         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
16493         glibc.
16494         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
16495         arg to memcpy.
16496
16497         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
16498         (obstack_ptr_grow_fast, obstack_int_grow_fast):
16499         Don't use lvalue casts, as GCC plans to remove support for them
16500         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
16501         was also present in the non-GCC version, indicating that this
16502         code had always been buggy and had never been widely used.
16503         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
16504         Use the fast variant of each macro, rather than copying the
16505         definiens of the fast variant; that way, we'll be more likely to
16506         catch future bugs in the fast variants.
16507
16508 2003-10-20  Bruno Haible  <bruno@clisp.org>
16509
16510         * modules/wait-process: New file.
16511         * MODULES.html.sh (func_all_modules): Add wait-process.
16512
16513 2003-10-20  Bruno Haible  <bruno@clisp.org>
16514
16515         * m4/wait-process.m4: New file.
16516
16517 2003-10-20  Bruno Haible  <bruno@clisp.org>
16518
16519         * lib/wait-process.h: New file, from GNU gettext.
16520         * lib/wait-process.c: New file, from GNU gettext.
16521
16522 2003-10-19  Jim Meyering  <jim@meyering.net>
16523
16524         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
16525         HPUX 10.20.
16526
16527 2003-10-18  Karl Berry  <karl@gnu.org>
16528
16529         * config/config.guess: update from config.
16530
16531 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16532
16533         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
16534         (getgroups): First arg is int, not size_t.
16535         Don't let 'free' mangle errno.
16536
16537 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16538
16539         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
16540
16541 2003-10-16  Karl Berry  <karl@gnu.org>
16542
16543         * config/config.{guess,sub}: update from config.
16544
16545 2003-10-16  Jim Meyering  <jim@meyering.net>
16546
16547         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
16548         memcpy.
16549
16550 2003-10-15  Paul Eggert  <eggert@twinsun.com>
16551
16552         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
16553         (SIZE_MAX): Remove.
16554         (new_exclude, add_exclude_file): Initial size no longer needs to
16555         be a power of 2.
16556         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
16557         our own address arithmetic overflow checking.
16558
16559         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
16560         (fnmatch): Do not alloca more than 2000 wide characters;
16561         instead, use malloc for large buffers.
16562         Check for address arithmetic overflow, and return -1
16563         with errno set to ENOMEM in that case.
16564         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
16565         (NEW_PATTERN): Do not alloca more than 8000 bytes;
16566         instead, return -1.  Check for address arithmetic overflow.
16567
16568 2003-10-14  Paul Eggert  <eggert@twinsun.com>
16569
16570         Handle invalid suffixes and overflow independently, so that
16571         callers can treat them independently as needed.  Fix some bugs in
16572         suffix handling, e.g., "100k@" was not diagnosed as an invalid
16573         suffix for a human-readable blocksize.  The major caller-visible
16574         change is the addition of a new
16575         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
16576         that both overflow and suffix chars were found.
16577
16578         * lib/human.c (humblock): Don't check separately for invalid suffix
16579         char; that is xstrtoumax's job (now that its bug is fixed).
16580         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
16581         INTMAX_MAX]: New macros.
16582         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
16583         TYPE_MAXIMUM): New macros.
16584         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
16585         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
16586         if overflow occurs, as it's what __strtol does and it's more useful
16587         in practice.
16588         (__xstrtol): If __strtol reports some error other than ERANGE,
16589         reflect it to the caller as LONGINT_INVALID.  If it reports
16590         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
16591         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
16592         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
16593         value.
16594         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
16595         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
16596         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
16597         [defined UINTMAX_MAX]: New macros.
16598
16599 2003-10-14  Bruno Haible  <bruno@clisp.org>
16600
16601         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
16602
16603 2003-10-14  Bruno Haible  <bruno@clisp.org>
16604
16605         * m4/sig_atomic_t: New file, from GNU gettext.
16606         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
16607
16608 2003-10-14  Bruno Haible  <bruno@clisp.org>
16609
16610         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
16611         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
16612         Also use volatile where needed.
16613
16614 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16615
16616         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
16617         Change maintainer from Bruno Haible to 'all'.
16618
16619 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16620
16621         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
16622
16623 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16624
16625         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
16626         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
16627         and define in terms of the other primitives.
16628         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
16629         (SIZE_MAX): Define if not already defined.
16630         (array_size_overflow): New function.
16631         (xalloc_die): Abort instead of exiting if 'error' returns.
16632         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
16633         (xmalloc, xrealloc): Use them.
16634         (xcalloc): Check for address arithmetic overflow.
16635         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
16636         a bit faster than strcpy.
16637
16638 2003-10-10  Simon Josefsson  <jas@extundo.com>
16639
16640         * modules/argp (Depends-on): Add restrict and strcase.
16641
16642 2003-10-10  Simon Josefsson  <jas@extundo.com>
16643
16644         * m4/argp.m4: Add AC_C_INLINE.
16645
16646 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16647
16648         Merge getpass from libc, plus a few fixes.
16649
16650         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
16651         Include <stdbool.h>.
16652         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
16653         __fsetlocking to empty.
16654         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
16655         do include <bits/libc-lock.h>.
16656         Do not include <fcntl.h>; not needed.
16657         [_LIBC]: Include <wchar.h>.
16658         (NOTCANCEL_MODE): New macro.
16659         (flockfile, funlockfile) [_LIBC]: New macros.
16660         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
16661         [!_LIBC]: New macros.
16662         (call_fclose): New function.
16663         (getpass): Use it.  Save tty stream separately; this simplifies the
16664         code and makes it more reliable if stdin happens to equal stdout.
16665         Invoke __fsetlocking on tty.
16666         Handle thread cancellation if needed.
16667         Namespace cleanup (use __tcgetattr, __getline).
16668         Use bool for Booleans.
16669         [USE_IN_LIBIO]: Handle wide streams.
16670         [!_LIBC]: Unconditionally do the fseek, since we don't know what
16671         stream might go where.
16672
16673         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
16674         doesn't have to include <stdio.h> before us.
16675         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
16676         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
16677         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
16678         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
16679         if not declared, so that we can use getpass.c code from libc without
16680         rewriting it.
16681         (flockfile, ftrylockfile, funlockfile): New macros.
16682
16683 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16684
16685         * modules/getpass: Depend on stdbool.
16686
16687 2003-10-08  Paul Eggert  <eggert@twinsun.com>
16688
16689         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
16690
16691 2003-10-07  Karl Berry  <karl@gnu.org>
16692
16693         * config/config.{guess,sub}: update from config.
16694
16695 2003-10-06  Jim Meyering  <jim@meyering.net>
16696             Bruno Haible  <bruno@clisp.org>
16697
16698         This lets translators provide better translations for the
16699         "Written by ..." part of --version output.
16700         * lib/version-etc.h: Include stdarg.h.
16701         (version_etc_copyright): Declare as readonly.
16702         (version_etc): Make this function variadic with a NULL-terminated list
16703         of author name strings.
16704         (version_etc_va): New declaration.
16705         * lib/version-etc.c: Include stdarg.h, stdlib.h.
16706         (version_etc_copyright): Declare as readonly.
16707         (version_etc_va): New function. Provide a different translatable string
16708         for each possible number of authors < 10. Abbreviate when there are 10
16709         authors or more.
16710         (version_etc): Make this function variadic. Call version_etc_va.
16711         Suggestion from Gary V. Vaughan.
16712
16713         * lib/long-options.h (parse_long_options): Change prototype: the
16714         authors string is moved to the end and becomes variadic.
16715         * lib/long-options.c: Include stdarg.h.
16716         (parse_long_options): Make this function variadic, too.
16717         Call version_etc_va, not version_etc.
16718
16719 2003-10-06  Bruno Haible  <bruno@clisp.org>
16720
16721         * modules/version-etc-2: Remove file.
16722         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
16723
16724 2003-10-06  Bruno Haible  <bruno@clisp.org>
16725
16726         * modules/fatal-signal: New file.
16727         * MODULES.html.sh (func_all_modules): Add fatal-signal.
16728
16729 2003-10-06  Bruno Haible  <bruno@clisp.org>
16730
16731         * m4/fatal-signal.m4: New file.
16732         * m4/signalblocking.m4: New file, from GNU gettext.
16733
16734 2003-10-06  Bruno Haible  <bruno@clisp.org>
16735
16736         * lib/version-etc-2.h: Remove file.
16737         * lib/version-etc-2.c: Remove file.
16738
16739 2003-10-06  Bruno Haible  <bruno@clisp.org>
16740
16741         * lib/fatal-signal.h: New file, from GNU gettext.
16742         * lib/fatal-signal.c: New file, from GNU gettext.
16743
16744 2003-10-05  Paul Eggert  <eggert@twinsun.com>
16745
16746         * README: Rework advice for preventing empty .o files.
16747         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
16748         not <sys/types.h>.
16749
16750 2003-10-04  Karl Berry  <karl@gnu.org>
16751
16752         * lib/argp*: update from libc.
16753
16754 2003-10-04  Karl Berry  <karl@gnu.org>
16755
16756         * config/config.{guess,sub}: update from config.
16757
16758 2003-10-02  Bruno Haible  <bruno@clisp.org>
16759
16760         * modules/lchown (Include): Add lchown.h.
16761         * modules/time_r (Include): Use "..." syntax.
16762         * modules/xgetdomainname (Include): Add xgetdomainname.h.
16763
16764 2003-10-01  Simon Josefsson  <jas@extundo.com>
16765
16766         * MODULES.html.sh (func_all_modules): Move gethostname from section
16767         'based on' to section 'lacking' POSIX:2001.
16768
16769 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
16770
16771         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
16772         to output mode on the same stream.
16773
16774 2003-09-29  Paul Eggert  <eggert@twinsun.com>
16775
16776         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
16777         Fix arg typo in previous patch.
16778
16779 2003-09-28  Jim Meyering  <jim@meyering.net>
16780
16781         * lib/error.c: Correct cpp indentation.
16782
16783 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16784
16785         * modules/free: New file.
16786
16787 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16788
16789         * m4/free.m4: New file.
16790
16791 2003-09-27  Paul Eggert  <eggert@twinsun.com>
16792
16793         * lib/minmax.h (MIN, MAX)
16794         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
16795         Omit the special code that used __typeof__, since we worry that
16796         it could be more trouble than it's worth.  See:
16797         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
16798         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
16799
16800         * lib/free.c: New file.
16801
16802 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
16803
16804         Trivial fixes to Makefile.am parts of module listings.
16805         * modules/strstr: Append strstr.h to lib_SOURCES.
16806         * modules/strcase: Likewise, for strcase.h.
16807
16808 2003-09-27  Karl Berry  <karl@gnu.org>
16809
16810         * config/mkinstalldirs: update from automake.
16811
16812 2003-09-26  Paul Eggert  <eggert@twinsun.com>
16813
16814         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
16815         (error_tail): Do not loop, reallocating temporary buffer, since
16816         the output cannot contain more wide characters than the input
16817         contains bytes, the size must be big enough already.  This avoids
16818         one potential size overflow calculation.  Check for size overflow
16819         when calculating temporary buffer size.  Free temporary buffer
16820         when done, if it was allocated with malloc; this plugs a memory
16821         leak.  Remove casts from void * to pointers, that are no longer
16822         needed now that we're assuming C89 or better.
16823
16824         Merge error changes from glibc.
16825
16826         * lib/error.c, error.h: Update copyright notice header to match glibc.
16827         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
16828         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
16829         Disable cancellation while printing error.
16830         * lib/error.h: Prepend __ to parameter names.
16831
16832 2003-09-26  Jim Meyering  <jim@meyering.net>
16833
16834         * lib/error.c (error_tail): Move some declarations
16835         into inner scope where the local variables are used.
16836
16837 2003-09-26  Bruno Haible  <bruno@clisp.org>
16838
16839         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
16840         stpncpy().
16841         Don't define stpncpy through config.h; it's now done through stpncpy.h.
16842
16843 2003-09-26  Bruno Haible  <bruno@clisp.org>
16844
16845         * lib/stpncpy.h (gnu_stpncpy): New declaration.
16846         (stpncpy): Define as alias for gnu_stpncpy.
16847         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
16848
16849 2003-09-25  Simon Josefsson  <jas@extundo.com>
16850
16851         * lib/xgetdomainname.h: New file.
16852         * lib/xgetdomainname.c: New file.
16853
16854 2003-09-25  Simon Josefsson  <jas@extundo.com>
16855             Bruno Haible  <bruno@clisp.org>
16856
16857         * modules/getdomainname: New file.
16858         * modules/xgetdomainname: New file.
16859         * MODULES.html.sh (func_all_modules): Add getdomainname,
16860         xgetdomainname.
16861
16862 2003-09-25  Simon Josefsson  <jas@extundo.com>
16863             Bruno Haible  <bruno@clisp.org>
16864
16865         * m4/getdomainname.m4: New file.
16866
16867 2003-09-25  Simon Josefsson  <jas@extundo.com>
16868             Bruno Haible  <bruno@clisp.org>
16869
16870         * lib/getdomainname.h: New file.
16871         * lib/getdomainname.c: New file.
16872
16873 2003-09-25  Karl Berry  <karl@gnu.org>
16874
16875         * lib/argp-fmtstream.c, argp-help.c: update from libc.
16876
16877 2003-09-25  Karl Berry  <karl@gnu.org>
16878
16879         * config/install-sh: update from automake.
16880
16881 2003-09-25  Bruno Haible  <bruno@clisp.org>
16882
16883         * modules/version-etc-2: New file, from modules/version-etc with
16884         modifications.
16885         * MODULES.html.sh (func_all_modules): Add version-etc-2.
16886
16887 2003-09-25  Bruno Haible  <bruno@clisp.org>
16888
16889         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
16890         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
16891
16892 2003-09-24  Simon Josefsson  <jas@extundo.com>
16893
16894         * modules/xgethostname: Add xgethostname.h.
16895
16896 2003-09-24  Paul Eggert  <eggert@twinsun.com>
16897
16898         * lib/linebuffer.c (freebuffer): Don't free the argument, just
16899         the buffer associated with the argument.  Bug reported by
16900         Simon Josefsson.
16901
16902 2003-09-24  Paul Eggert  <eggert@twinsun.com>
16903
16904         * README: Document assumptions that 'int' is at least 32 bits
16905         wide, that integer arithmetic is 2's complement without overflow,
16906         that there are no holes in integer values, that adding sizes of
16907         two nonoverlapping objects can't overflow, and that all-bits-zero
16908         yields scalar zero.  Fix spelling and capitalization typos.
16909
16910 2003-09-19  Karl Berry  <karl@gnu.org>
16911
16912         * lib/argp.h: update from libc.
16913
16914 2003-09-17  Paul Eggert  <eggert@twinsun.com>
16915
16916         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
16917         to avoid spurious warnings like "AC_RUN_IFELSE was called before
16918         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
16919
16920 2003-09-17  Paul Eggert  <eggert@twinsun.com>
16921
16922         * gnulib-tool: Use "test -h", not "test -L", for portability
16923         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
16924         (tags_regexp): Remove, since \| doesn't conform to POSIX.
16925         (sed_extract_prog): Issue s commands one-by-one, rather than
16926         using \| in one s command.
16927
16928 2003-09-16  Paul Eggert  <eggert@twinsun.com>
16929
16930         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
16931         input error, instead of returning NULL the next time we are called
16932         (and therefore losing track of errno).
16933
16934 2003-09-16  Bruno Haible  <bruno@clisp.org>
16935
16936         * gnulib-tool (func_create_testdir): Warn about duplicated
16937         dependencies.
16938
16939 2003-09-15  Paul Eggert  <eggert@twinsun.com>
16940
16941         * modules/argmatch, modules/fatal, modules/obstack,
16942         modules/xalloc, modules/xgethostname: Sort dependencies by
16943         importance, not alphabetically.
16944
16945 2003-09-15  Paul Eggert  <eggert@twinsun.com>
16946
16947         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
16948         fails, so that the caller gets the proper errno.
16949
16950         * lib/readutmp.c (read_utmp): Likewise.
16951         Check for fstat error.  Close stream and free storage
16952         when failing.
16953
16954 2003-09-14  Karl Berry  <karl@gnu.org>
16955
16956         * config/srclist.txt (strdup.c): disable for c89 changes.
16957
16958 2003-09-14  Jim Meyering  <jim@meyering.net>
16959
16960         * lib/getloadavg.c: Correct cpp indentation.
16961         * lib/strdup.c: Likewise.
16962         * lib/vasnprintf.c: Likewise.
16963
16964 2003-09-14  Bruno Haible  <bruno@clisp.org>
16965
16966         * modules/fwriteerror: New file.
16967         * MODULES.html.sh (func_all_modules): Add fwriteerror.
16968
16969 2003-09-14  Bruno Haible  <bruno@clisp.org>
16970
16971         * lib/fwriteerror.h: New file.
16972         * lib/fwriteerror.c: New file.
16973
16974 2003-09-12  Paul Eggert  <eggert@twinsun.com>
16975
16976         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
16977         modules/xgethostname, modules/xalloc: Depend on exit.
16978
16979 2003-09-12  Paul Eggert  <eggert@twinsun.com>
16980
16981         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
16982
16983         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
16984         and AC_MINIX, too, so that their extensions are available.
16985
16986         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
16987         This macro has been superseded by gl_BACKUPFILE.
16988
16989         More patches to assume C89 or better.
16990
16991         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
16992
16993         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
16994         unconditionally.
16995         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
16996         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
16997         Include <string.h>, <stdlib.h> unconditionally.
16998         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
16999         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
17000         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
17001         headers or for string.h.
17002         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
17003         or strtoul.
17004
17005         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
17006         headers.
17007         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
17008         * m4/userspec.m4 (gl_USERSPEC): Likewise.
17009         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
17010         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
17011         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
17012         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
17013         memcpy, memset.
17014         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
17015         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
17016         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
17017         strtol.
17018         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
17019         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
17020         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
17021         strtoul.
17022
17023 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17024
17025         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
17026         * lib/obstack.c [!defined _LIBC]: Likewise.
17027         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
17028         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
17029         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
17030
17031         More changes to assume C89 or better.
17032
17033         * lib/error.c (error_tail): Assume vprintf.
17034
17035         * lib/argmatch.c (getenv): Remove decl.
17036         * lib/progreloc.c (get_full_program_name): Define via prototype.
17037         * lib/setenv.c (clearenv): Likewise.
17038         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
17039         needed.
17040         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
17041         (malloc, memcpy): Remove decls.
17042         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
17043         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
17044         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17045         (memcpy): Remove macro.
17046         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
17047         (__P): Remove.  All uses removed.
17048         (PTR): Remove.  All uses changed to void *.
17049         (CHAR_BIT, NULL): Remove.
17050         (spaces, zeros, memset_space, memset_zero)
17051         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
17052         Remove.
17053         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
17054         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
17055         Define with prototype.
17056         Remove now-unnecessary prototype decl.
17057         (extra_args_spec): Assume ANSI C.  All uses changed.
17058         (extra_args_spec_iso): Remove.
17059         (my_strftime, emacs_strftimeu): Define via prototype.
17060         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
17061         unconditionally.
17062         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
17063         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
17064         (strtoul, strtol): Remove decls.
17065         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
17066         LONG_MAX): Remove.
17067         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17068         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
17069         (LOCALE_PARAM_PROTO): New macro.
17070         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
17071         (INTERNAL (strtol), strtol): Define with a prototype.
17072         (PARAMS): Remove.  All uses removed.
17073         * lib/tempname.c: Include <string.h> unconditionally.
17074         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
17075         * lib/xgethostname.c (main): Define with a prototype.
17076         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
17077         Include <stdlib.h> unconditionally.
17078         (calloc, malloc, realloc, free): Remove decls.
17079         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
17080         Include <stdlib.h> unconditionally.  Sort include file names.
17081         (strtod): Remove.
17082         (xstrtod): Define with a prototype.
17083         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
17084         (strtol, strtoul): Remove decls.
17085
17086 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17087
17088         More patches to assume C89 or better.
17089         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
17090         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
17091         string.h, memchr, STDC_HEADERS.
17092
17093 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17094
17095         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
17096         Include <stdlib.h>, <string.h> unconditionally.
17097         Remove now-unnecessary cast to char *.
17098         * lib/strnlen.c: Include <string.h> unconditionally.
17099         * lib/yesno.c (yesno): Define with a prototype.
17100
17101 2003-09-11  Bruno Haible  <bruno@clisp.org>
17102
17103         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
17104
17105 2003-09-10  Jim Meyering  <jim@meyering.net>
17106
17107         * lib/error.c: Correct indentation of cpp directives.
17108
17109 2003-09-10  Bruno Haible  <bruno@clisp.org>
17110
17111         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
17112         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
17113         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
17114         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
17115         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
17116         <stdlib.h> and <string.h> checks.
17117         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
17118         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
17119
17120 2003-09-10  Bruno Haible  <bruno@clisp.org>
17121
17122         * lib/strcspn.c: Include <string.h> unconditionally.
17123         * lib/strpbrk.c: Include <string.h> unconditionally.
17124         * lib/strstr.c: Include <string.h> unconditionally.
17125         * lib/unicodeio.c: Include <string.h> unconditionally.
17126         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
17127         * lib/unsetenv.c: Likewise.
17128         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
17129         * lib/yesno.c: Include <stdlib.h> unconditionally.
17130         (rpmatch): Add prototype.
17131
17132 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17133
17134         More patches to assume C89 or better.
17135         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
17136         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
17137         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
17138         or for string.h.
17139         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
17140         stdlib.h.
17141         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
17142         C headers.
17143         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
17144         string.h.
17145         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
17146         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
17147         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
17148         or for string.h.
17149         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
17150         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
17151         C headers.
17152         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
17153         memcpy.
17154         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
17155         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
17156         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
17157         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
17158         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
17159         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
17160         string.h, free.
17161         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
17162         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
17163         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
17164         C headers, or for string.h.
17165         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
17166         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
17167         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
17168         headers, memory.h, stdlib.h, string.h, strings.h.
17169         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
17170         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
17171         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
17172         strchr.
17173         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
17174         headers, memory.h, string.h.
17175         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
17176         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
17177         free.
17178         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
17179         headers.
17180         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
17181         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
17182         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
17183         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
17184         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
17185
17186 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17187
17188         More K&R removal.
17189
17190         * lib/acosl.c (main): Use a prototype.
17191         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
17192         tanl.c: Likewise.
17193
17194         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
17195
17196         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
17197         (getopt, etopt_long, getopt_long_only, _getopt_internal)
17198         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
17199         with a prototype.
17200         * lib/getopt.c (const): Remove macro.
17201         Include <string.h> unconditionally.
17202         (my_index): Remove; all uses changed to strchr.
17203         (strlen): Remove decl.
17204         (exchange): Remove forward decl; no longer needed.
17205         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
17206         Define with prototype.
17207         * lib/getopt1.c (const): Remove macro.
17208         (getopt_long, getopt_long_only, main): Define with prototype.
17209
17210         * lib/getugroups.c: Include <string.h> unconditionally.
17211
17212         * lib/getusershell.c: Include <stdlib.h> unconditionally.
17213         (getusershell, setusershell, endusershell, readname, main):
17214         Define with prototypes.
17215
17216         * lib/group-member.c: Include group-member.h first.
17217         Include <stdlib.h> unconditionally.
17218
17219         * lib/hard-locale.c: Include hard-locale.h first.
17220         Include <stdlib.h>, <string.h> unconditionally.
17221
17222         * lib/hash.c (free, malloc): Remove decls.
17223         Include <stdlib.h> unconditionally.
17224
17225         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
17226         (getenv): Do not declare.
17227
17228         * lib/idcache.c: Include <string.h> unconditionally.
17229
17230         * lib/long-options.c: Include long-options.h first, to test interface.
17231         Include <stdlib.h> unconditionally.
17232
17233         * lib/makepath.c: Include makepath.h first, to test interface.
17234         Include <stdlib.h> and <string.h> unconditionally.
17235
17236         * lib/linebuffer.c: Include <stdlib.h>.
17237         (free): Remove decl.
17238
17239         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
17240         stddef.h. rpl_malloc returns void *, not char *.
17241         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
17242         prototype.
17243
17244         * lib/md5.h: Include <limits.h> unconditionally.
17245         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
17246         (__P): Remove; all uses removed.
17247         * lib/md5.c: Include "md5.h" first.
17248         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
17249         md5_buffer, md5_process_bytes, md5_process_block):
17250         Define with prototypes.
17251         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
17252         * lib/sha.c: Include "sha.h" first.
17253         Include <stdlib.h>, <string.h> unconditionally.
17254
17255         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
17256         * lib/memcmp.c (__ptr_t): Likewise.
17257         * lib/memrchr.c (__ptr_t): Likewise.
17258         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
17259         Include <string.h> unconditionally.
17260         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
17261         * lib/memchr.c: Include <stdlib.h> unconditionally.
17262         * lib/memchr.c (LONG_MAX): Remove.
17263         * lib/memrchr.c (LONG_MAX): Likewise.
17264         * lib/memchr.c (__memchr): Define via a prototype.
17265         * lib/memrchr.c (__memrchr): Likewise.
17266         * lib/memcmp.c (__P): Remove, and remove all uses.
17267         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
17268         Remove forward decls; no longer needed.
17269         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
17270         Use types required by C89 in prototype.
17271
17272         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
17273         * lib/savedir.c: Likewise.
17274         * lib/mkdir.c (free): Remove decl.
17275         * lib/rmdir.c (rmdir): Define with a prototype.
17276         * lib/savedir.c: Include savedir.h first, to test interface.
17277
17278         * lib/mktime.c (STDC_HEADERS): Remove.
17279         Include <stdlib.h>, <string.h> unconditionally.
17280
17281         * lib/modechange.c: Include <stdlib.h> unconditionally.
17282         (malloc): Remove decl.
17283
17284         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
17285         (free): Remove decl.
17286
17287         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
17288         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
17289         (This type really should be intptr_t, but that's a C99ism.)
17290         (_obstack_memcpy): Remove: all uses changed to memcpy.
17291         Include <string.h> unconditionally.
17292         (struct obstack): Assume __STDC__ for types of members
17293         chunkfun, freefun, extra_arg.
17294         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
17295         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
17296         obstack_begin, obstack_specify_allocation,
17297         obstack_specify_allocation_with_arg, obstack_chunkfun,
17298         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
17299         Remove unprototyped decls and the macros that use them.
17300         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
17301         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
17302         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
17303         (defined __STDC__ && __STDC__)]:
17304         Remove nonprototyped code.
17305         Include <stdlib.h> unconditionally.
17306         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
17307         _obstack_allocated_p, _obstack_free, obstack_free,
17308         _obstack_memory_used, print_and_abort):
17309         Define using prototypes.
17310         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
17311         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
17312         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
17313         obstack_next_free, obstack_object_size, obstack_room) [0]:
17314         Remove unused, unprototyped code.
17315
17316         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
17317
17318         * lib/physmem.c (physmem_total, physmem_available, main): Define
17319         with prototypes.
17320
17321         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
17322         (main): Define with a prototype.
17323
17324         * lib/posixver.c (getenv): Remove decl.
17325
17326         * lib/putenv.c (malloc): Returns void *, not char *.
17327         Include <string.h> unconditionally.
17328         (strchr, memcpy, NULL): Do not define.
17329
17330         * lib/readtokens.c: Include readtokens.h first, to test interface.
17331         Include <stdlib.h>, <string.h> unconditionally.
17332         (init_tokenbuffer): Define with a prototype.
17333
17334         * lib/regex.c (PARAMS): Remove.  All uses removed.
17335         All uses of _RE_ARGS removed, too.
17336         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17337         unconditionally.
17338         (bzero): Assume memset exists.
17339         (memcmp, memcpy, NULL): Remove.
17340         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
17341         char, or assignments to local vars of type signed char.
17342         (init_syntax_once, PREFIX(extract_number_and_incr),
17343         PREFIX(print_partial_compiled_pattern),
17344         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
17345         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
17346         PREFIX(regex_grow_registers), PREFIX(regex_compile),
17347         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
17348         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
17349         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
17350         wcs_compile_range, byte_compile_range, truncate_wchar,
17351         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
17352         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
17353         count_mbs_length, wcs_re_match_2_internal,
17354         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
17355         PREFIX(alt_match_null_string_p),
17356         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
17357         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
17358         regfree, PREFIX(extract_number)): Define with prototype.  Remove
17359         now-unnecessary declaration, if any.
17360         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
17361         regcomp, regexec):
17362         Remove now-unnecessary casts among pointer types.
17363         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
17364
17365         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
17366         (free): Remove decl.
17367
17368         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
17369
17370         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
17371         (free): Remove decl.
17372
17373         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
17374         * lib/xgetcwd.c: Likewise.
17375
17376         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
17377         (free): Remove decl.
17378
17379         * lib/strchrnul.c (strchrnul): Define with a prototype.
17380         Fix bug: c_in was not converted to char before searching.
17381
17382         The following changes are not K&R related:
17383
17384         * lib/group-member.h: Include <sys/types.h>, so that this file is
17385         self-contained.
17386         * lib/makepath.h: Likewise.
17387
17388         * lib/getusershell.c (readname, default_index, line_size, readname):
17389         Use size_t, not int, for sizes.
17390         (readname): If the size overflows, report an error instead of
17391         looping forever.
17392
17393 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17394
17395         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
17396         libc.
17397
17398 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17399
17400         * README: New section: portability guidelines.
17401
17402 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17403
17404         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
17405         C89 spec.
17406
17407 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17408
17409         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
17410
17411 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17412
17413         Assume C89 or better; remove K&R cruft.
17414         A few of these changes were first proposed by Derek Robert Price
17415         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
17416
17417         * lib/addext.c: Include <string.h> unconditionally.
17418         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
17419         Don't declare getenv or malloc.
17420
17421         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
17422         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
17423         (NULL): Remove.
17424         (find_stack_direction, alloca): Use prototypes.
17425
17426         * lib/atexit.c (atexit): Define using a prototype.
17427
17428         * lib/basename.c, dirname.c, stripslash.c:
17429         Include <string.h> unconditionally.
17430
17431         * lib/bcopy.c: Include <stddef.h>.
17432         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
17433
17434         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
17435
17436         * lib/error.h (error, error_at_line, error_print_progname)
17437         [! (defined (__STDC__) && __STDC__)]: Remove decls.
17438         * lib/error.c: Include error.h first, to check interface.
17439         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17440         (VA_START): Remove; all uses changeed to va_start.
17441         (exit, strerror): Remove decls.
17442         (error_print_progname): Prototype uncondionally.
17443         Don't include <errno.h>; no longer needed.
17444         (private_strerror): Remove.
17445         (error_tail): Always define.
17446         (error, error_at_line): Assume C89 or better; always use prototypes.
17447         * lib/fatal.c: Include "fatal.h" first, to test interface.
17448         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17449         (VA_START): Remove; all uses changed to va_start.
17450         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
17451         this case.
17452         (exit): Remove decl.
17453         (fatal): Prototype unconditionally.  Assume va_start works.
17454         Abort at end, to pacify gcc.
17455
17456         * lib/euidaccess.c (main): Define with a prototype.
17457
17458         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
17459
17460         * lib/exitfail.c: Include <stdlib.h> unconditionally.
17461
17462         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
17463         prototypes.
17464         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
17465         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
17466         (getenv): Remove decl.
17467         (fnmatch): Define using a prototype.
17468         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
17469         (FCT): Define using a prototype.
17470
17471         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
17472
17473         * lib/gethostname.c: Include <stddef.h>.
17474         (gethostname): Define with prototype.  Length is size_t, not int.
17475
17476 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17477
17478         Assume C89 or better; remove K&R cruft.
17479         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
17480         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
17481         string.h, getenv, malloc.
17482         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
17483         headers.
17484         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
17485         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
17486         do not check for strerror.
17487         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
17488         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
17489         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
17490         do not check for doprnt or vprintf.
17491         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
17492         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
17493
17494 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17495
17496         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
17497         getversion.c should have been removed then, but was accidentally
17498         preserved.
17499
17500         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
17501         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
17502
17503 2003-09-08  Karl Berry  <karl@gnu.org>
17504
17505         * config/config.sub, config.guess, srclistvars.sh: update from savannah
17506                 config, forget about prep.
17507
17508         * config/depcomp, missing: update from automake.
17509
17510 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17511
17512         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
17513         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17514
17515 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17516
17517         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
17518         copy_tm_result.  Bug reported by Simon Josefsson in
17519         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17520
17521 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17522
17523         * m4/time_r.m4: New file.
17524         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
17525         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
17526         is. Check for timegm declaration.
17527         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
17528         Do not check for gmtime_r.
17529         Replace mktime if __mktime_internal does not exist and if mktime
17530         hasn't been replaced already.
17531
17532 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17533
17534         * lib/time_r.c, lib/time_r.h: New files.
17535
17536         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
17537         __localtime_r.
17538         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
17539         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
17540
17541         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
17542         __gmtime_r.
17543         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
17544         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
17545         Include <time_r.h>.
17546
17547         * lib/timegm.c: Switch to glibc implementation, with the following
17548         changes:
17549         [defined HAVE_CONFIG_H]: Include <config.h>.
17550         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
17551         (__mktime_internal) [!defined _LIBC]: New decl.
17552         (__gmtime_r) [!defined _LIBC]: New macro and function.
17553         (timegm): Use a prototype, since gnulib assumes C89.
17554         Do not bother declaring tmp to be const, as it's not really usefu.
17555         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
17556         (timegm): Declare only if HAVE_DECL_TIMEGM.
17557
17558 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17559
17560         * MODULES.html.sh (func_all_modules): Add time_r.
17561         * modules/time_r: New file.
17562         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
17563         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
17564
17565 2003-09-03  Paul Eggert  <eggert@twinsun.com>
17566
17567         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
17568         Bug reported by Lute Kamstra in
17569         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
17570
17571         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
17572         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
17573         course with correspondingly smaller numbers for tomorrow and
17574         yesterday.  From Tadayoshi Funaba.  Originally installed into
17575         sh-utils on 1999-08-07, but the patch got lost (I guess during the
17576         coreutils merge?).
17577
17578 2003-08-31  Simon Josefsson  <jas@extundo.com>
17579
17580         * modules/timegm: New file.
17581         * MODULES.html.sh (func_all_modules): Add timegm.
17582
17583 2003-08-31  Simon Josefsson  <jas@extundo.com>
17584
17585         * m4/timegm.m4: New file.
17586
17587 2003-08-31  Simon Josefsson  <jas@extundo.com>
17588
17589         * lib/timegm.h: New file.
17590         * lib/timegm.c: New file.  Based on
17591         wget-1.8.2/src/http.c:mktime_from_utc.
17592
17593 2003-08-31  Karl Berry  <karl@gnu.org>
17594
17595         * lib/argp.h: update from libc.
17596
17597 2003-08-28  Bruno Haible  <bruno@clisp.org>
17598
17599         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
17600         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
17601         followed by '#define fnmatch fnmatch_posix' gives an error.
17602
17603 2003-08-28  Bruno Haible  <bruno@clisp.org>
17604
17605         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
17606         warning on QNX, which defines O_BINARY to 000000.
17607
17608 2003-08-27  Jim Meyering  <jim@meyering.net>
17609
17610         * m4/mkstemp.m4: Require that the system mkstemp be able to create
17611         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
17612         would fail after 32.  Reported by Danny Levinson.  Details here:
17613         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
17614
17615 2003-08-24  Bruno Haible  <bruno@clisp.org>
17616
17617         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
17618         MSVC7 <stdio.h> is included later.
17619
17620 2003-08-22  Simon Josefsson  <jas@extundo.com>
17621
17622         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
17623
17624 2003-08-20  Karl Berry  <karl@gnu.org>
17625
17626         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
17627
17628 2003-08-20  Bruno Haible  <bruno@clisp.org>
17629
17630         * modules/progname: New file.
17631         * MODULES.html.sh (func_all_modules): Add progname.
17632
17633 2003-08-20  Bruno Haible  <bruno@clisp.org>
17634
17635         * lib/progname.h: New file, from GNU gettext.
17636         * lib/progname.c: New file, from GNU gettext.
17637         * lib/progreloc.c: New file, from GNU gettext.
17638
17639 2003-08-19  Jim Meyering  <jim@meyering.net>
17640
17641         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
17642         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
17643
17644 2003-08-19  Bruno Haible  <bruno@clisp.org>
17645
17646         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
17647         more.
17648
17649 2003-08-19  Bruno Haible  <bruno@clisp.org>
17650
17651         * lib/xstrdup.c: Assume <string.h> exists.
17652
17653 2003-08-18  Paul Eggert  <eggert@twinsun.com>
17654
17655         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
17656         in makefile rules.
17657
17658 2003-08-18  Jim Meyering  <jim@meyering.net>
17659
17660         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
17661         * m4/lib-ld.m4: Likewise.
17662
17663 2003-08-18  Jim Meyering  <jim@meyering.net>
17664
17665         * lib/setenv.h: Indent nested cpp directive.
17666         * lib/vasnprintf.c: Remove trailing blanks.
17667
17668 2003-08-17  Simon Josefsson  <jas@extundo.com>
17669
17670         * modules/xstrndup: New file.
17671         * MODULES.html.sh (func_all_modules): Add xstrndup.
17672
17673 2003-08-17  Simon Josefsson  <jas@extundo.com>
17674
17675         * modules/argp: Fix autoconf macro name. Add more dependencies.
17676
17677 2003-08-17  Simon Josefsson  <jas@extundo.com>
17678
17679         * m4/xstrndup.m4: New file.
17680
17681 2003-08-17  Simon Josefsson  <jas@extundo.com>
17682
17683         * m4/argp.m4: New file.
17684
17685 2003-08-17  Simon Josefsson  <jas@extundo.com>
17686             Bruno Haible  <bruno@clisp.org>
17687
17688         * lib/xstrndup.h: New file.
17689         * lib/xstrndup.c: New file.
17690
17691 2003-08-17  Bruno Haible  <bruno@clisp.org>
17692
17693         * modules/strndup (Files, Include): Add lib/strndup.h.
17694
17695 2003-08-17  Bruno Haible  <bruno@clisp.org>
17696
17697         * modules/euidaccess (Files): Add lib/euidaccess.h.
17698
17699 2003-08-17  Bruno Haible  <bruno@clisp.org>
17700
17701         * lib/strndup.h: New file.
17702
17703 2003-08-17  Bruno Haible  <bruno@clisp.org>
17704
17705         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
17706         like AC_GNU_SOURCE.
17707         * modules/extensions (configure.ac): Comment out the invocation of
17708         gl_USE_SYSTEM_EXTENSIONS.
17709
17710 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17711
17712         Merges from coreutils, etc.
17713         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
17714         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
17715         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
17716         fixing a typo.
17717         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
17718         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
17719
17720 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17721
17722         Document merge from coreutils.
17723         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
17724         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
17725         * modules/utime: Add m4/utimes-null.m4.
17726
17727 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17728
17729         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
17730         space, undoing this 2003-08-12 change:
17731         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17732
17733 2003-08-16  Paul Eggert  <eggert@twinsun.com>
17734
17735         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
17736         strtoul.c from libc, undoing this 2003-08-12 change:
17737         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
17738
17739 2003-08-16  Jim Meyering  <jim@meyering.net>
17740
17741         Merges from coreutils.
17742         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
17743         prefix.  Adjust cache variables similarly.  Create 500 rather than
17744         just 300 files, to exercise bug on Darwin6.5, too.
17745         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
17746         $missing_dir.
17747         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
17748         AM_SYS_POSIX_TERMIOS.
17749         Reported by mkc@mathdogs.com.
17750         Also change use of $am_cv_sys_posix_termios
17751         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
17752         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
17753         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
17754         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
17755         in /proc/mounts until it finds one with matching device number.  This
17756         is unnecessary when the FILE argument *is* a mount point.  No stat call
17757         is necessary in that case.  So, disable the statvfs-testing code on
17758         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
17759         as RedHat bug# 84846.
17760         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17761         to 1MB, so as not to render systems with no stack size limit (e.g.,
17762         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17763         Include <unistd.h>.  On some systems,
17764         it is required for the definition of _SC_PAGESIZE.
17765
17766 2003-08-16  Jim Meyering  <jim@meyering.net>
17767
17768         Merge from coreutils.
17769         * lib/xstrtoimax.c: #else #if -> #elif.
17770         * lib/xstrtoumax.c: Likewise.
17771
17772 2003-08-16  Jim Meyering  <jim@meyering.net>
17773
17774         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
17775         * m4/utimes.m4: Removed.
17776         * m4/utimes-null.m4: Renamed from utimes.m4.
17777
17778         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
17779         to 1MB, so as not to render systems with no stack size limit (e.g.,
17780         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
17781         Include <unistd.h>.  On some systems,
17782         it is required for the definition of _SC_PAGESIZE.
17783
17784 2003-08-16  Jim Meyering  <jim@meyering.net>
17785         and Paul Eggert  <eggert@cs.ucla.edu>
17786
17787         Merges from coreutils, etc.
17788
17789         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
17790         using the latest version from cvs.  This avoids problems with #line
17791         directives using a vendor (Sun) compiler.
17792         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
17793         Don't set GETGROUPS_LIB here; now it's
17794         done via getgroups.m4's wrapper function.
17795         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
17796         rather than just in sh-util/configure.in, so that the
17797         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
17798         same.
17799         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
17800         AC_FUNC_GETLOADAVG where to find getloadavg.c.
17801         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
17802         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
17803         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
17804         Remove code that is now done by the newly-required macros.
17805         Append $(EXEEXT) to DF_PROG.
17806         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
17807         Do not invoke or require the following here,
17808         since prereq.m4 or some gnulib .m4 now does this for us:
17809         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
17810         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
17811         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
17812         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
17813         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
17814         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
17815         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
17816         AC_FUNC_OBSTACK.
17817         Do not replace the following functions, as this is now the job
17818         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
17819         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
17820         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
17821         atexit getpass, strdup, getpagesize.
17822         Replace 'raise'.
17823         Do not check for the following functions, as this is now the job
17824         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
17825         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
17826         setregid.
17827         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
17828         Check for sys/sysctl.h.
17829         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
17830         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
17831         of checking for ssize_t ourselves.
17832
17833         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
17834         Require every macro that gnulib/modules/* suggests for us.
17835         (jm_PREREQ_ADDEXT): New macro.
17836         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
17837         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
17838
17839         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
17840         (gl_PHYSMEM): Use it.
17841         Also check for `table' function.
17842         Check for new headers and functions.
17843         Add check for sys/sysmp.h.
17844         With suggestions from Kaveh Ghazi.
17845         Ignore headers that are present but cannot be compiled.  This
17846         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
17847         C 5.4.
17848
17849 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17850
17851         Document merge from coreutils.
17852         * modules/userspec: Depend on posixver.
17853         * modules/strftime: Depend on tzset.
17854
17855 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17856
17857         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
17858         rather than tab, after '#' in shell-script copyright notices.
17859         Suggested by Bruno Haible.
17860
17861 2003-08-15  Paul Eggert  <eggert@twinsun.com>
17862
17863         * config/srclist-update: Use three spaces, rather than tab, after '#'
17864         in shell-script copyright notices.  Suggested by Bruno Haible.
17865         Remove unnecessary parenthesization in regular expression.
17866
17867 2003-08-15  Jim Meyering  <jim@meyering.net>
17868
17869         Merge from coreutils.
17870         * lib/xgethostname.c: Include <stdlib.h>.
17871         (xghostname): Don't exit for anything other than memory-related
17872         failure; just return NULL.
17873         * lib/userspec.c: Include "posixver.h".
17874         (parse_user_spec): Accept `.' as a separator only
17875         in pre-POSIX-200112 mode.
17876         * lib/strtoimax.c: Use #elif rather than #else #if.
17877         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
17878         Remove function, now that we can rely on a working tzset function.
17879         [!_LIBC]: Ensure that the required autoconf test has been run.
17880         [!defined _NL_CURRENT && HAVE_STRFTIME]:
17881         Use underlying_strftime for %r.
17882         * lib/sha.c: Merge in some clean-up and optimization changes from
17883         glibc.
17884         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
17885         Ensure that it is a multiple of 64.
17886         Rearrange loop exit tests so as to avoid performing an
17887         additional fread after encountering an error or EOF.
17888         * lib/realloc.c: Update copyright date.
17889
17890 2003-08-15  Jim Meyering  <jim@meyering.net>
17891         and Paul Eggert  <eggert@twinsun.com>
17892
17893         Merge from coreutils.
17894         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
17895         member but strut utmpx does not.  Needed for AIX 4.3.3.
17896         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
17897
17898 2003-08-15  Jim Meyering  <jim@meyering.net>
17899         and Paul Eggert  <eggert@cs.ucla.edu>
17900
17901         Merges from coreutils, etc.
17902         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
17903         Require gl_FUNC_TZSET_CLOBBER.
17904         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
17905         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
17906         members.
17907
17908 2003-08-14  Paul Eggert  <eggert@twinsun.com>
17909
17910         Help the merge from coreutils.
17911         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
17912         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
17913         * m4/tzset.m4: Use it too.
17914
17915 2003-08-14  Paul Eggert  <eggert@twinsun.com>
17916
17917         * modules/tzset: New file.
17918
17919 2003-08-14  Jim Meyering  <jim@meyering.net>
17920
17921         Merges from coreutils.
17922         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
17923         variable names, rather than @FNMATCH_H@.
17924         * modules/alloca: Likewise for $(ALLOCA_H).
17925
17926         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
17927         the three copies of the literal target, `fnmatch.h'.
17928         * modules/alloca (alloca.h): Likewise.
17929
17930 2003-08-14  Jim Meyering  <jim@meyering.net>
17931
17932         Merge from coreutils.
17933         * m4/tzset.m4: New file.
17934         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
17935         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
17936         otherwise, AIX 5.1 systems would end up using the latter.
17937         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
17938         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
17939         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
17940         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
17941
17942 2003-08-14  Jim Meyering  <jim@meyering.net>
17943
17944         Merge from coreutils.
17945         * lib/obstack.h: Whitespace changes.
17946         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
17947         and xcalloc return values.
17948         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
17949         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
17950         hang on OSF/1 5.1 for DIR on both local and remote file systems.
17951         Reported by (and fix confirmed by) Nelson H. F. Beebe.
17952         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
17953         error from mntctl.
17954         Use mntctl's return value to drive the entry-processing loop, since
17955         we can't rely on the value of the vmt_length member in the last
17956         entry.  On some systems doing so could result in exhausting
17957         virtual memory.  Based in part on a patch from Mike Jetzer.
17958
17959 2003-08-14  Jim Meyering  <jim@meyering.net>
17960         and Paul Eggert  <eggert@twinsun.com>
17961
17962         Merges from coreutils, plus other fixes.
17963         * lib/physmem.c: Merge in portability changes from gcc/libiberty
17964         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
17965         for credits and details.  Thanks to Kaveh Ghazi for helping
17966         to keep these files in sync.
17967         (ARRAY_SIZE): Define it.
17968         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
17969         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
17970         (memcasecmp): Don't assume size_t fits in unsigned int.
17971         Remove casts and duplicate code.
17972         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
17973         (memcpy): Remove definition.
17974         Merge in some clean-up and optimization changes from glibc.
17975         [BLOCKSIZE]: Move definition to top of file.
17976         Ensure that it is a multiple of 64.
17977         Rearrange loop exit tests so as to avoid performing an
17978         additional fread after encountering an error or EOF.
17979         * lib/md5.h (md5_uintptr): Define.
17980         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
17981         return to the initial working directory.  Preserve errno
17982         for caller.
17983         * lib/idcache.c: Include "xalloc.h".
17984         (xmalloc, xrealloc): Remove decls.
17985         (getuser): Remove casts no longer required in C89.
17986         * lib/human.c: Include stdio.h, for sprintf.
17987         * lib/group-member.c: Include "xalloc.h".
17988         (xmalloc, xrealloc): Remove decls.
17989         (get_group_info): Remove casts no longer required in C89.
17990         * lib/getusershell.c (readname): Remove casts no longer required in
17991         C89.
17992         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
17993         * lib/getline.c: Whitespace fix, from coreutils.
17994
17995 2003-08-13  Paul Eggert  <eggert@twinsun.com>
17996
17997         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
17998         Check for isascii.
17999
18000         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18001         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18002         Undo previous (whitespace-only) change.
18003
18004 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18005
18006         * lib/exclude.c: Include <ctype.h>
18007         (IN_CTYPE_DOMAIN): New macro.
18008         (is_space): New fn.
18009         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
18010         and empty lines.
18011
18012         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18013         Undo previous (whitespace-only) change.
18014
18015 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18016
18017         * config/srclist-update: Change update back to the old behavior,
18018         leaving whitespace alone.  Use one 'sed' command rather than a
18019         pipeline.
18020         (fixlicense): Now a variable, not a function.
18021         (remove_trailing_blanks): Remove.
18022         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
18023         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18024         Undo previous (whitespace-only) change.
18025
18026 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18027
18028         Merge from coreutils.
18029         * modules/euidaccess: Add lib_SOURCES, include for new
18030         file euidaccess.h
18031
18032 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18033
18034         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18035         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18036         Normalize leading white space and remove trailing white space.
18037
18038         Merge from coreutils
18039         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
18040
18041         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
18042         0.12.1.  These files are now being upgraded automatically by
18043         ../config/srclist-update.
18044
18045 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18046
18047         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18048         Normalize leading white space and remove trailing white space.
18049         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
18050         notice, as per ../config/srclist-update.
18051
18052         Merge from coreutils.
18053         * lib/euidaccess.h: New file.
18054         * lib/euidaccess.c: Include it.
18055         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
18056         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
18057         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
18058
18059 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18060
18061         * config/srclist-update: Add copyright notice.
18062         (remove_id_lines, remove_trailing_blanks): New constants.
18063         (fixfile): Use them to normalize spacing a bit in copied files.
18064         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18065         Normalize leading white space and remove trailing white space.
18066
18067         * config/texinfo.tex: Sync with texinfo.
18068
18069         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
18070         strtoul.c from libc, to merge coreutils whitespace changes.
18071
18072         * config/srclist.txt: Get the following m4 files from gettext:
18073         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
18074         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
18075         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
18076         wint_t.m4.
18077
18078 2003-08-12  Karl Berry  <karl@gnu.org>
18079
18080         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
18081         been made.
18082
18083 2003-08-11  Paul Eggert  <eggert@twinsun.com>
18084
18085         * modules/gnu-source, m4/gnu-source.m4:
18086         Remove; we're assuming Autoconf 2.54 or later now.
18087         Suggested by Bruno Haible.
18088         * MODULES.html.sh (func_all_modules): Remove gnu-source.
18089
18090 2003-08-11  Bruno Haible  <bruno@clisp.org>
18091
18092         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
18093
18094 2003-08-11  Bruno Haible  <bruno@clisp.org>
18095
18096         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
18097         (vasnprintf): Use it instead of wcslen.
18098
18099 2003-08-11  Bruno Haible  <bruno@clisp.org>
18100
18101         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
18102         value to ensure that _Bool promotes to int. Use #define for _Bool when
18103         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
18104
18105 2003-08-10  Karl Berry  <karl@gnu.org>
18106
18107         * lib/regex.h: update from libc (whitespace fix).
18108
18109 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18110
18111         Merge some files from coreutils.  These changes were
18112         originally made by Jim Meyering.
18113         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
18114         many older Unixes require this.
18115         * lib/alloca.c (alloca): Remove cast to argument of free;
18116         no longer needed in C89.
18117         * lib/alloca_.h, regex.h: Fix white space to match
18118         what GNU indent does.
18119
18120 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18121
18122         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
18123         apparently Emacs's Unicode mode got confused before my 2003-08-05
18124         checkin.
18125
18126 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18127
18128         * m4/extensions.m4: New file.
18129         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
18130         Require gl_USE_SYSTEM_EXTENSIONS.
18131         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
18132         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
18133
18134 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18135
18136         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
18137         * modules/extensions, modules/gnu-source: New files.
18138         * modules/timespec, modules/unlocked-io: Depend on extensions.
18139
18140 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18141
18142         * modules/restrict: New file.
18143         * MODULES.html.sh (func_all_modules): Add restrict.
18144         * modules/regex: Depend on restrict.
18145
18146 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18147
18148         * m4/restrict.m4: New file.
18149         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
18150
18151 2003-08-07  Bruno Haible  <bruno@clisp.org>
18152
18153         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
18154         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
18155
18156 2003-08-07  Bruno Haible  <bruno@clisp.org>
18157
18158         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
18159         makes the module 'getndelim2' compatible with the module 'getline'.
18160
18161 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18162
18163         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
18164         byte with "\201" to avoid glitches when editing that source file
18165         with multi-gnome-terminal.
18166
18167 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18168
18169         * lib/bumpalloc.h: Remove.
18170
18171 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18172
18173         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
18174         * modules/bumpalloc: Remove.
18175
18176 2003-08-04  Paul Eggert  <eggert@twinsun.com>
18177
18178         * lib/getloadavg.c: Change copyright notice and spacing to conform to
18179         GNU coding style.
18180
18181         Merge from coreutils.
18182         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
18183         1. From glibc.
18184         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
18185         from Karl Berry, implemented by Jim Meyering.
18186         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
18187         from Dmitry V. Levin.
18188         Remove anachronistic cast of xrealloc.
18189         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
18190         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
18191         type. Otherwise, it wouldn't compile with at least /bin/cc on
18192         ymp-cray-unicos9.0.2.X.
18193         Combine two mostly-identical uses of alloca into one.
18194         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
18195
18196 2003-08-04  Dave Love  <d.love@dl.ac.uk>
18197
18198         [From Emacs.]
18199
18200         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
18201         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
18202         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
18203         obsolete NLIST_NAME_UNION.
18204         [__GNU__]: Undef BSD and FSCALE.
18205         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
18206
18207 2003-08-03  Paul Eggert  <eggert@twinsun.com>
18208
18209         * lib/stdbool_.h (_Bool): Make it signed char, instead of
18210         an enum type, so that it's guaranteed to promote to int.  See:
18211         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
18212
18213 2003-08-03  Karl Berry  <karl@gnu.org>
18214
18215         * config/depcomp: update from automake.
18216
18217 2003-07-31  Paul Eggert  <eggert@twinsun.com>
18218
18219         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
18220         (strerror): Don't assume that a printable int fits in 14 bytes.
18221
18222 2003-07-31  Bruno Haible  <bruno@clisp.org>
18223
18224         * modules/getpass-gnu: New file.
18225         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
18226
18227 2003-07-31  Bruno Haible  <bruno@clisp.org>
18228
18229         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
18230
18231 2003-07-24  Karl Berry  <karl@gnu.org>
18232
18233         * config/missing: update from automake.
18234
18235 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
18236             Bruno Haible  <bruno@clisp.org>
18237
18238         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
18239         * lib/getline.c (getline, getdelim): Likewise.
18240         Remove _GNU_SOURCE define; now it's defined in config.h through
18241         m4/getline.m4.
18242
18243 2003-07-23  Karl Berry  <karl@gnu.org>
18244
18245         * config/config.sub: update from prep.
18246
18247 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18248
18249         * modules/xalloc (Depends-on): Add exitfail.
18250         * modules/xmemcoll: Likewise.
18251
18252 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18253
18254         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
18255         over-parenthesization in macros.
18256
18257         Sync with coreutils.
18258
18259         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
18260         required by C99.
18261
18262         Use `exit_failure' for xalloc and xmemcoll instead of their own
18263         private exit-failure variables.
18264         * lib/xalloc.h (xalloc_exit_failure): Remove.
18265         * lib/xmalloc.c: Likewise.  Include exitfail.h.
18266         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
18267         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
18268         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
18269         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
18270
18271 2003-07-20  Jim Meyering  <jim@meyering.net>
18272
18273         * modules/closeout (Depends-on): Add exitfail.
18274         Suggestion from Bruno Haible.
18275
18276 2003-07-19  Karl Berry  <karl@gnu.org>
18277
18278         * config/config.sub: update from prep.
18279
18280 2003-07-18  Paul Eggert  <eggert@twinsun.com>
18281
18282         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
18283         Remove.
18284         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
18285         to test that it can stand by itself.  Include "exitfail.h".
18286         Clients should set exit_failure instead.
18287         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
18288
18289 2003-07-18  Bruno Haible  <bruno@clisp.org>
18290
18291         * modules/getndelim2: New file.
18292         * modules/getline: Share files with module getndelim2.
18293         * modules/getnline: Depend on getndelim2 instead of sharing files with
18294         it. Add getnline.c to lib_SOURCES.
18295         * MODULES.html.sh (func_all_modules): Add getndelim2.
18296
18297 2003-07-18  Bruno Haible  <bruno@clisp.org>
18298
18299         * m4/getndelim2.m4: New file.
18300         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
18301         invoke gl_PREREQ_GETNDELIM2.
18302         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
18303         gl_PREREQ_GETNDELIM2.
18304         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
18305         gl_GETNDELIM2.
18306
18307 2003-07-18  Bruno Haible  <bruno@clisp.org>
18308
18309         * lib/getndelim2.h: New file.
18310         * lib/getndelim2.c: Make into a module of its own. Include config.h,
18311         getndelim2.h.
18312         (getndelim2): Make non-static. Change return type to ssize_t.
18313         * lib/getline.h: Change argument names.
18314         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
18315         * lib/getnline.c: Include getndelim2.h.
18316
18317 2003-07-18  Andreas Schwab  <schwab@suse.de>
18318
18319         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
18320
18321 2003-07-17  Karl Berry  <karl@gnu.org>
18322
18323         * config/config.sub: update from prep.
18324
18325 2003-07-17  Bruno Haible  <bruno@clisp.org>
18326
18327         * modules/getnline: New file.
18328         * modules/getline: Add lib/getndelim2.c to source file list.
18329         * MODULES.html.sh (func_all_modules): Add getnline.
18330
18331 2003-07-17  Bruno Haible  <bruno@clisp.org>
18332
18333         * m4/getnline.m4: New file.
18334
18335 2003-07-17  Bruno Haible  <bruno@clisp.org>
18336
18337         * m4/Makefile.am.in: Remove file.
18338         * m4/Makefile.am: Remove file.
18339         * m4/Makefile.in: Remove file.
18340
18341 2003-07-17  Bruno Haible  <bruno@clisp.org>
18342
18343         * lib/getnline.h: New file.
18344         * lib/getnline.c: New file.
18345         * lib/getndelim2.c: New file, extracted from getline.c.
18346         (getndelim2): Renamed from getdelim2, with added nmax argument.
18347         * lib/getline.c: Include getndelim2.c.
18348         (getdelim2): Moved out to getndelim2.c.
18349         (getline, getdelim): Update.
18350
18351 2003-07-17  Bruno Haible  <bruno@clisp.org>
18352
18353         * lib/Makefile.am: Remove file.
18354         * lib/Makefile.in: Remove file.
18355
18356 2003-07-17  Bruno Haible  <bruno@clisp.org>
18357
18358         * configure.in: Remove file.
18359         * Makefile.in: Remove file.
18360
18361 2003-07-17  Bruno Haible  <bruno@clisp.org>
18362
18363         * MODULES.html.sh: Put the </BODY> right before </HTML>.
18364
18365 2003-07-16  Karl Berry  <karl@gnu.org>
18366
18367         * config/srclist-update: was running fixlicense twice, which caused
18368                 texinfo.tex to be nullified for some reason.  Simplify,
18369                 $gplsrc is no longer needed as far as I can see?
18370
18371 2003-07-16  Jim Meyering  <jim@meyering.net>
18372
18373         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
18374
18375 2003-07-15  Paul Eggert  <eggert@twinsun.com>
18376
18377         * config/srclist.txt: Get the following files from gettext-runtime/intl
18378         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
18379         ref-del.sin.  From Bruno Haible.
18380         * config/srclist-update (fixfile): Change grep pattern again, since the
18381         previous fix didn't work (there was another trailing $).  Use
18382         '[$]' to escape the $s.
18383
18384 2003-07-15  Karl Berry  <karl@gnu.org>
18385
18386         * lib/vasnprintf.c: update from gettext.
18387
18388 2003-07-15  Karl Berry  <karl@gnu.org>
18389
18390         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
18391         gets expanded when surrounded by '$'.
18392
18393 2003-07-15  Jim Meyering  <jim@meyering.net>
18394
18395         * modules/save-cwd: Don't depend on error.  From Derek Price.
18396
18397 2003-07-15  Jim Meyering  <jim@meyering.net>
18398
18399         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
18400
18401 2003-07-14  Simon Josefsson  <jas@extundo.com>
18402
18403         * modules/mempcpy: New file.
18404         * MODULES.html.sh (func_all_modules): Add mempcpy.
18405
18406 2003-07-14  Simon Josefsson  <jas@extundo.com>
18407
18408         * m4/mempcpy.m4: New file.
18409
18410 2003-07-14  Simon Josefsson  <jas@extundo.com>
18411
18412         * lib/mempcpy.h: New file.
18413         * lib/mempcpy.c: New file.
18414
18415 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18416
18417         * modules/getdate, modules/posixtm: Depend on mktime.
18418
18419 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18420
18421         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
18422         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
18423         unicodeio.c, unicodeio.h, unlocked-io.h:
18424         Switch from LGPL to GPL.
18425
18426 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18427
18428         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
18429         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
18430         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
18431         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
18432         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
18433         updated automatically by ../config/srclist-update.  This changes
18434         their license from LPGL to GPL.
18435
18436 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18437
18438         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
18439         assumed to refer to the root of the most recent stable gettext version.
18440         * config/srclistvars.sh: Add defaults for eggert.
18441         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
18442         Match "This program" as well as "The program".  This is needed
18443         for gettext.
18444
18445 2003-07-14  Jim Meyering  <jim@meyering.net>
18446
18447         Don't emit diagnostics.  Let callers do that.
18448         * lib/save-cwd.c: Don't include "error.h".
18449         (save_cwd): Don't call error.  Ensure that errno is valid
18450         when returning nonzero.
18451
18452         * lib/save-cwd.h (restore_cwd): Update prototype.
18453         * lib/save-cwd.c (restore_cwd): Remove two parameters.
18454         Simplify.  Don't call error upon failure.  Let callers do that.
18455         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
18456         when auditing is enabled.  But don't bother updating the #if.
18457
18458 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
18459
18460         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
18461         it breaks C++ compilation.
18462         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
18463
18464 2003-07-10  Simon Josefsson  <jas@extundo.com>
18465
18466         * modules/strchrnul (Makefile.am): Add strchrnul.h.
18467
18468 2003-07-10  Jim Meyering  <jim@meyering.net>
18469
18470         * m4/clock_time.m4: Remove trailing blank.
18471         * m4/intmax_t.m4: Likewise.
18472
18473 2003-07-10  Jim Meyering  <jim@meyering.net>
18474
18475         * lib/vasnprintf.c: Remove trailing blanks.
18476         Make cpp indentation consistent.
18477
18478 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18479
18480         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
18481         posixver.c, strftime.c, strnlen.c, strverscmp.c:
18482         Switch from LGPL to GPL.
18483
18484 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18485
18486         * config/srclist.txt: Sort sublists.  Add
18487         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
18488         that differ from gnulib for one reason or another; we'd like this list
18489         to be smaller but for now let's document what we have.
18490
18491 2003-07-08  Paul Eggert  <eggert@twinsun.com>
18492
18493         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
18494         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
18495         and sweeter "eval x=$x".
18496         * config/srclist.txt: Get lib/argp* from glibc.
18497
18498 2003-07-07  Paul Eggert  <eggert@twinsun.com>
18499
18500         * lib/mktime.c: Fix some boundary cases and remove need for floating
18501         point.
18502
18503         Issue a compile-time diagnostic if time_t is floating point, or if
18504         two's complement arithmetic is not in effect, or if arithmetic
18505         right shift does not propagate the sign.  These assumptions were
18506         all in the original code but they weren't checked.
18507
18508         (TIME_T_MIDPOINT, verify): New macros.
18509         (__isleap): Remove; it has integer overflow problems.
18510         (leapyear): New function, without those problems.
18511         (ydhms_tm_diff): Remove; splitting into two parts.
18512         (ydhms_diff): New function, containing the arithmetic part of
18513         the old ydhms_tm_diff function.  Issue a compile-time
18514         diagnostic if we are not using C99 integer division.
18515         Avoid casts when possible.
18516         (guess_time_tm): New function, containing the checking part of
18517         the old ydhms_tm_diff function.  Return the new value, rather than
18518         the difference between it and the old.  Accept a new argument T
18519         so that *T specifies the old value.  Check for overflow in the result.
18520
18521         (__mktime_internal): Use a time_t offset, not a long int offset.
18522         This undoes the 2003-06-04 change, which is no longer needed now
18523         that we have better overflow checking.
18524         (localtime_offset): Likewise.
18525
18526         (__mktime_internal): Avoid harmful overflow on hosts where time_t
18527         and long are 64-bit but int is only 32-bit.
18528         (ydhms_diff): Use long int to store year1 and yday1.
18529         Issue a compile-time diagnostic if long int is not wide enough.
18530
18531         (__mktime_internal): Use long int to store adjusted year and yday.
18532         Use plain C rather than preprocessor commands, if that doesn't
18533         affect efficiency.
18534         Check for overflow (and try to repair) after each probe
18535         rather than checking only at the very end.  This avoids some bugs
18536         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
18537         does not equal GMT offset at maximum time).
18538         Use integer to check for overflow rather than floating point; this
18539         is more portable to non-IEEE hosts, and is a tad faster.
18540         When we detect that we are oscillating between two values,
18541         don't check whether tm_isdst has the requested value, since
18542         we already know the answer.  When tm_isdst has the wrong value,
18543         use a different heuristic to find the right one, based on the
18544         extreme values actually observed in practice in tz2003a,
18545         rather than the (overly optimistic) "previous 3 calendar quarters".
18546
18547         (not_equal_tm, print_tm, check_result): Use "const T" rather than
18548         "T const" to accommodate glibc style.
18549         (check_result): Use less-confusing report format.  "long" -> "long int.
18550         (main): Likewise.
18551         Don't loop if the iteration overflows time_t.
18552         Allow a negative step in the iteration.
18553
18554 2003-07-06  Karl Berry  <karl@gnu.org>
18555
18556         * config/depcomp: update from automake.
18557         * config/config.sub: update from prep.
18558
18559 2003-07-03  Karl Berry  <karl@gnu.org>
18560
18561         * config/config.guess: update from prep.
18562
18563 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18564
18565         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
18566         xreadlink.c now includes it unconditionally.
18567
18568 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18569
18570         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
18571         having it depend on HAVE_SYS_TYPES_H.
18572
18573 2003-07-01  Bruno Haible  <bruno@clisp.org>
18574
18575         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
18576         <sys/types.h> should be sufficient.
18577         Reported by Paul Eggert.
18578
18579 2003-06-26  Karl Berry  <karl@gnu.org>
18580
18581         * config/depcomp: update from automake.
18582
18583 2003-06-26  Bruno Haible  <bruno@clisp.org>
18584
18585         * modules/human: Depend on module stdbool.
18586
18587 2003-06-25  Bruno Haible  <bruno@clisp.org>
18588
18589         * modules/readlink: New file.
18590         * modules/xreadlink: Depend on it.
18591         * MODULES.html.sh (func_all_modules): Add readlink.
18592
18593 2003-06-25  Bruno Haible  <bruno@clisp.org>
18594
18595         * m4/readlink.m4: New file.
18596
18597 2003-06-25  Bruno Haible  <bruno@clisp.org>
18598
18599         * lib/readlink.c: New file.
18600
18601 2003-06-22  Karl Berry  <karl@gnu.org>
18602
18603         * config/srclist.txt: update mkinstalldirs from automake.
18604         * config/mkinstalldirs: update.
18605
18606 2003-06-22  Bruno Haible  <bruno@clisp.org>
18607
18608         Portability to mingw32.
18609         * m4/ssize_t.m4: New file, from GNU gettext.
18610         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
18611         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
18612
18613 2003-06-22  Bruno Haible  <bruno@clisp.org>
18614
18615         * modules/safe-read: Add m4/ssize_t.m4.
18616         * modules/xreadlink: Add m4/ssize_t.m4.
18617
18618 2003-06-20  Bruno Haible  <bruno@clisp.org>
18619
18620         Assume C89, so PARAMS isn't needed.
18621         * lib/unicodeio.h (PARAMS): Remove.
18622         * lib/unicodeio.c: Don't use PARAMS.
18623
18624 2003-06-18  Karl Berry  <karl@gnu.org>
18625
18626         * config/config.{guess,sub}: update from prep.
18627
18628 2003-06-18  Jim Meyering  <jim@meyering.net>
18629
18630         Merge changes from coreutils.
18631         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
18632         Remove explicit declarations of xmalloc and realloc.
18633         Include xalloc.h.
18634         (read_utmp): Remove anachronistic cast of xmalloc.
18635
18636 2003-06-17  Paul Eggert  <eggert@twinsun.com>
18637
18638         Assume C89, so PARAMS isn't needed.
18639         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
18640         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
18641         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
18642         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
18643         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
18644         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
18645         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
18646         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
18647         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
18648         lib/xstrtod.h, lib/xstrtol.h: Likewise.
18649         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
18650         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
18651         no longer needed. Anyway, config.h should always be included before any
18652         other file.
18653
18654 2003-06-11  Simon Josefsson  <jas@extundo.com>
18655
18656         * modules/sysexits: New file.
18657         * MODULES.html.sh (func_all_modules): Add sysexits.
18658
18659 2003-06-11  Simon Josefsson  <jas@extundo.com>
18660
18661         * lib/sysexit_.h: New file.
18662
18663 2003-06-11  Derek Price  <derek@ximbiot.com>
18664
18665         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
18666         necessary.
18667
18668 2003-06-11  Bruno Haible  <bruno@clisp.org>
18669
18670         * m4/sysexits.m4: New file.
18671
18672 2003-06-10  Simon Josefsson  <jas@extundo.com>
18673
18674         * lib/argp.h: New file, from glibc.
18675         * lib/argp-ba.c: New file, from glibc.
18676         * lib/argp-eexst.c: New file, from glibc.
18677         * lib/argp-fmtstream.c: New file, from glibc.
18678         * lib/argp-fmtstream.h: New file, from glibc.
18679         * lib/argp-fs-xinl.c: New file, from glibc.
18680         * lib/argp-help.c: New file, from glibc.
18681         * lib/argp-namefrob.h: New file, from glibc.
18682         * lib/argp-parse.c: New file, from glibc.
18683         * lib/argp-pv.c: New file, from glibc.
18684         * lib/argp-pvh.c: New file, from glibc.
18685         * lib/argp-xinl.c: New file, from glibc.
18686
18687 2003-06-10  Simon Josefsson  <jas@extundo.com>
18688
18689         * modules/strchrnul: New file.
18690
18691 2003-06-10  Simon Josefsson  <jas@extundo.com>
18692
18693         * modules/argp: New file.
18694
18695 2003-06-10  Simon Josefsson  <jas@extundo.com>
18696
18697         * m4/strchrnul.m4: New file.
18698
18699 2003-06-10  Simon Josefsson  <jas@extundo.com>
18700
18701         * lib/strchrnul.h: New file.
18702         * lib/strchrnul.c: New file.
18703
18704 2003-06-10  Bruno Haible  <bruno@clisp.org>
18705
18706         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
18707
18708 2003-06-07  Karl Berry  <karl@gnu.org>
18709
18710         * config/config.{guess,sub}: update from prep.
18711
18712 2003-06-07  Jim Meyering  <jim@meyering.net>
18713
18714         * modules/strtod: Use $(...) notation, not @...@ for
18715         AC_REPLACE'd variables.
18716         * modules/localcharset: Likewise.
18717
18718 2003-06-07  Jim Meyering  <jim@meyering.net>
18719
18720         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
18721         in place of my name in the copyright comment.
18722         Remove definition and uses of __P.
18723
18724         From coreutils.
18725         * lib/stat.c: Don't declare xmalloc explicitly.
18726         Instead, include "xalloc.h".
18727         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
18728         xrealloc, and xcalloc return values.
18729         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
18730         Improve comment.
18731         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
18732
18733 2003-06-07  Bruno Haible  <bruno@clisp.org>
18734
18735         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
18736         avoid AC_CONFIG_LINKS.
18737         * modules/fnmatch (Makefile.am): Use explicit creation rule for
18738         fnmatch.h, to avoid AC_CONFIG_LINKS.
18739         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
18740
18741 2003-06-07  Bruno Haible  <bruno@clisp.org>
18742
18743         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
18744         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
18745         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18746         directory.
18747         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
18748         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
18749         directory.
18750
18751 2003-06-06  Jim Meyering  <jim@meyering.net>
18752
18753         Merge from coreutils.
18754         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
18755         Consolidate declarations and initializations of *_base* locals.
18756
18757         Merge from coreutils.
18758         This avoids a core dump on systems without GNU putenv,
18759         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
18760         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
18761         (unsetenv): New static function, from GNU libc.
18762         (rpl_putenv): Use it.
18763
18764         * lib/modechange.c: Remove trailing blanks.
18765
18766         Merge from coreutils.
18767         * lib/fsusage.c: Remove declaration of statfs.
18768         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
18769
18770         * lib/posixtm.c: Include <stdbool.h> unconditionally.
18771
18772 2003-06-06  Jim Meyering  <jim@meyering.net>
18773
18774         * lib/stdbool_.h: Renamed from stdbool.h.in.
18775
18776 2003-06-06  Jim Meyering  <jim@meyering.net>
18777             Bruno Haible  <bruno@clisp.org>
18778
18779         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
18780         Adjust Makefile.am snippet not to redirect directly to target.
18781         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
18782
18783 2003-06-05  Paul Eggert  <eggert@twinsun.com>
18784
18785         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
18786         mismatch, look in future quarters as well as past.  This fixes a
18787         bug when processing fall-backwards gaps immediately after a long
18788         period of daylight-saving time.
18789
18790         * lib/mktime.c: Assume freestanding C89 or better.
18791         (HAVE_LIMITS_H): Remove.  Assume it's 1.
18792         (__P): Remove; not used.
18793         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
18794         (mktime, not_equal_tm, print_tm, check_result,
18795         main): Use prototypes.  Use const * where appropriate.
18796         (main): Fix typo in testing code that uncovered by above changes.
18797         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
18798
18799 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18800
18801         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
18802         locale.h, localeconv.  This merges changes from coreutils.
18803
18804         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
18805         It can be removed after the next Autoconf is released.
18806         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
18807         needed.
18808
18809 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18810
18811         * lib/mktime.c: Fix Debian bug 177940
18812         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
18813         (localtime_offset): Now long int, not time_t, because we want it
18814         to be guaranteed to be signed.  All uses changed.
18815         (__mktime_internal): If overflow would occur when adding offset,
18816         don't add it.
18817
18818         Merge 'human' changes from coreutils.  Rewrite to support
18819         locale-specific notations like thousands separators.
18820         * lib/human.c: Simplify authorship notice.
18821         Include human.h immediately after config.h.
18822         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
18823         <limits.h>: Do not include, since human.h does.
18824         (SIZE_MAX, UINTMAX_MAX): New macros.
18825         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
18826         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
18827         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
18828         (power_letter): Renamed from suffixes.
18829         (generate_suffix_backwards): Remove.
18830         (adjust_value): Now takes int style (because of human.h changes)
18831         and long double value (for greater precision on some platforms).
18832         (group_number): New function.
18833         (human_readable): Use it.  Use integer options, not enum.
18834         Put the options before the sizes in the arg list.
18835         Support all the new options.
18836         The old human_readable function has been removed;
18837         use inttostr.h instead.
18838         (human_readable, default_block_size, humblock):
18839         Use uintmax_t, not int, for block sizes.
18840         (human_readable_inexact, block_size_types): Remove.
18841         (block_size_opts): New constant.
18842         (human_options): Renamed from human_block_size, with new signature
18843         that allows block sizes up to UINTMAX_MAX.  All callers changed.
18844         * lib/human.h: Add copyright and authorship notice.
18845         Include <limits.h> and <stdbool.h> unconditionally.
18846         (PARAMS): Remove.  All uses removed.
18847         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
18848         (enum human_inexact_style): Remove tag; now a nameless enum.
18849         (human_floor, human_ceiling, human_round_to_even): Now have
18850         values 2, 0, 1 rather than -1, 1, 0.
18851         (human_group_digits, human_suppress_point_zero, human_autoscale,
18852         human_base_1024, human_SI, human_B): New constants.
18853         (human_readable_inexact, human_block_size): Remove.
18854         (human_readable): Size args are now uintmax_t, not int.
18855         (human_options): New decl.
18856
18857         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
18858         unnecessary now that we assume C89 or better.  This change
18859         imported from coreutils.
18860
18861         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
18862         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
18863         in the 2003-05-30 sync from glibc.
18864
18865         .h files should stand alone, but we shouldn't include <sys/types.h>
18866         if we can get away with just <stddef.h>.
18867
18868         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
18869         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
18870         rather than <sys/types.h>, as we merely need size_t.
18871         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
18872         to get size_t.
18873         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
18874         Include <stdio.h>, to get FILE.
18875         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
18876         memcasecmp.h has included <stddef.h> and all we need is size_t.
18877         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
18878         our interface, instead of including <sys/types.h>
18879
18880 2003-06-04  Paul Eggert  <eggert@twinsun.com>
18881
18882         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
18883         now, as glibc mktime is buggy on non-glibc systems.
18884
18885 2003-06-03  Karl Berry  <karl@gnu.org>
18886
18887         * config/config.sub: update from prep.
18888
18889 2003-06-02  Paul Eggert  <eggert@twinsun.com>
18890
18891         [from coreutils]
18892         Fix some minor time-related bugs with POSIX time arguments.
18893         Some valid time stamps were being rejected (notably -1, and
18894         time stamps before 1900 on 64-bit hosts).  And some invalid
18895         time stamps were being accepted, e.g. September 31.
18896
18897         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
18898         that we can return (time_t) -1 successfully.
18899         * lib/posixtm.c: Likewise.
18900         [HAVE_STDBOOL_H]: Include <stdbool.h>.
18901         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
18902         (t): Remove static var.
18903         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
18904         of static var.  All uses changed.
18905         (year): Do not reject years before 1900; they can occur with
18906         64-bit time_t.
18907         (posix_time_parse): Do not check for out-of-range components;
18908         that is now the caller's responsibility, since our checks were
18909         only approximations.
18910         (posixtime): Use mktime to check for out-of-range components,
18911         since it knows them exactly.
18912         If mktime returns (time_t) -1, check whether an error actually occurred
18913         by invoking localtime on -1.
18914         (main) [TEST_POSIXTIME]: Check for input data errors, and report
18915         posixtime failures better.
18916         Improve the test data (in comments only).
18917
18918 2003-06-02  Karl Berry  <karl@gnu.org>
18919
18920         * config/mkinstalldirs (version): new variable.
18921         (--version): new option.
18922         (usage): improve message.
18923
18924 2003-05-30  Karl Berry  <karl@gnu.org>
18925
18926         * lib/mktime.c: update from libc.
18927
18928 2003-05-30  Bruno Haible  <bruno@clisp.org>
18929
18930         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
18931         * config/config.rpath: Upgrade to gettext-0.12.1.
18932
18933 2003-05-30  Bruno Haible  <bruno@clisp.org>
18934
18935         * m4/gettext.m4: Upgrade to gettext-0.12.1.
18936         * m4/nls.m4: New file, from gettext-0.12.1.
18937         * m4/po.m4: New file, from gettext-0.12.1.
18938         * m4/progtest.m4: Upgrade to gettext-0.12.1.
18939
18940 2003-05-30  Bruno Haible  <bruno@clisp.org>
18941
18942         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
18943         * lib/localcharset.h: Likewise.
18944         * lib/localcharset.c: Likewise.
18945
18946 2003-05-29  Karl Berry  <karl@gnu.org>
18947
18948         * config/config.rpath: update from gettext.
18949
18950 2003-05-28  Paul Eggert  <eggert@twinsun.com>
18951
18952         Assume the headers required for C89 freestanding compilers.
18953         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
18954         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
18955         * m4/human.m4 (gl_HUMAN): Likewise.
18956         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
18957         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
18958         * m4/userspec.m4 (gl_USERSPEC): Likewise.
18959         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
18960         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
18961         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
18962
18963 2003-05-28  Paul Eggert  <eggert@twinsun.com>
18964
18965         Assume the headers required for C89 freestanding compilers.
18966         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
18967         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
18968         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
18969         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
18970         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
18971         define, since <limits.h> is guaranteed to do that.
18972         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
18973         * lib/exclude.c: Include <stdbool.h> unconditionally.
18974         * lib/tempname.c: Include <stddef.h> unconditionally.
18975         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
18976         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
18977         <stddef.h> does that.
18978         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
18979         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
18980         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
18981         needed.
18982         * lib/xstrtol.c: Likewise.
18983         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
18984         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
18985
18986         * lib/addext.c (addext): Use assignment rather than cast, to avoid
18987         warnings on some platforms.
18988
18989         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
18990         arbitrarily.
18991
18992 2003-05-26  Jim Meyering  <jim@meyering.net>
18993
18994         Merge in a change from coreutils:
18995         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
18996         that is guaranteed to be `no'.  Use `no_such_member' to indicate
18997         that condition, rather than `-1' which is slightly misleading.
18998         Change the name of the cache variable to have the gl_ prefix.
18999         Prompted by a patch from Richard Dawe for DJGPP.
19000
19001 2003-05-24  Karl Berry  <karl@gnu.org>
19002
19003         * config/config.guess: update from prep.
19004
19005 2003-05-22  Karl Berry  <karl@gnu.org>
19006
19007         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
19008
19009 2003-05-20  Karl Berry  <karl@gnu.org>
19010
19011         * config/config.guess: update from prep.
19012
19013 2003-05-18  Karl Berry  <karl@gnu.org>
19014
19015         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
19016         might actually be set by the user.
19017
19018         * config/depcomp, install-sh, mdate-sh: update from automake.
19019
19020 2003-05-17  Bruno Haible  <bruno@clisp.org>
19021
19022         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
19023         invalid expansion for AC_EGREP_CPP.
19024         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
19025         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
19026         Suggested by Akim Demaille <akim@epita.fr> in
19027         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
19028
19029 2003-05-12  Jim Meyering  <jim@meyering.net>
19030
19031         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
19032         the space-padded-by-default conversion specifiers, %e, %k, %l.
19033
19034 2003-05-12  Bruno Haible  <bruno@clisp.org>
19035
19036         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
19037         the string is longer than 4 KB.
19038
19039 2003-05-11  Karl Berry  <karl@gnu.org>
19040
19041         * config/config.{guess,sub}: update from prep.
19042
19043 2003-05-09  Bruno Haible  <bruno@clisp.org>
19044
19045         * modules/error: Add m4/strerror_r.m4 to file list.
19046
19047 2003-05-03  Bruno Haible  <bruno@clisp.org>
19048
19049         Upgrade to Unicode-4.0.
19050         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
19051         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
19052         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
19053         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
19054         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
19055         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
19056         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
19057         Change width of U+E0100..U+E01EF from 1 to 0.
19058
19059 2003-04-25  Jim Meyering  <jim@meyering.net>
19060
19061         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
19062         of type size_t, not int.
19063
19064 2003-04-25  Bruno Haible  <bruno@clisp.org>
19065
19066         * lib/copy-file.c: Include <stddef.h>, for size_t.
19067
19068 2003-04-21  Paul Eggert  <eggert@twinsun.com>
19069
19070         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
19071         code which expansion is under static control.  Patch imported from
19072         Akim Demaille's patch to Bison; see
19073         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
19074
19075 2003-04-14  Bruno Haible  <bruno@clisp.org>
19076
19077         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
19078
19079 2003-04-11  Jim Meyering  <jim@meyering.net>
19080
19081         Merge changes from Coreutils.
19082
19083         2003-03-22  Jim Meyering  <jim@meyering.net>
19084
19085         * lib/strftime.c (widen): Cast alloca return value to proper type.
19086
19087         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
19088
19089         From GNU libc.
19090         * lib/strftime.c (my_strftime): Handle very large width
19091         specifications for numeric values correctly.  Improve checks for
19092         overflow.
19093
19094         2003-01-19  Jim Meyering  <jim@meyering.net>
19095
19096         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
19097         definitions.
19098         (nl_get_alt_digit) [! defined my_strftime]: Define.
19099         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
19100         _nl_get_alt_digit and _nl_get_walt_digit.
19101
19102         * lib/strftime.c (my_strftime): Merge in locale-related changes from
19103         libc. These changes have no effect outside of _LIBC.
19104
19105 2003-04-10  Bruno Haible  <bruno@clisp.org>
19106
19107         * modules/findprog: New file.
19108         * MODULES.html.sh (func_all_modules): Add it.
19109
19110 2003-04-10  Bruno Haible  <bruno@clisp.org>
19111
19112         * m4/findprog.m4: New file.
19113         * m4/eaccess.m4: New file.
19114
19115 2003-04-10  Bruno Haible  <bruno@clisp.org>
19116
19117         * lib/findprog.h: New file, from GNU gettext.
19118         * lib/findprog.c: New file, from GNU gettext.
19119
19120 2003-04-05  Jim Meyering  <jim@meyering.net>
19121
19122         Merge changes from Coreutils.
19123
19124         * lib/exclude.h (PARAMS): Remove definition and uses.
19125         * lib/exclude.c: Remove uses of `PARAMS'.
19126
19127         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
19128         Add test-cases for DOS filenames. Declare program_name.
19129         (main): Set up program_name.  Patch by Rich Dawe.
19130
19131         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19132         error from mntctl.
19133         Use mntctl's return value to drive the entry-processing loop, since
19134         we can't rely on the value of the vmt_length member in the last
19135         entry.  On some systems doing so could result in exhausting
19136         virtual memory.  Based in part on a patch from Mike Jetzer.
19137
19138 2003-04-04  Bruno Haible  <bruno@clisp.org>
19139
19140         * modules/linebreak: New file.
19141         * MODULES.html.sh (func_all_modules): Add it.
19142
19143 2003-04-04  Bruno Haible  <bruno@clisp.org>
19144
19145         * m4/linebreak.m4: New file.
19146
19147 2003-04-04  Bruno Haible  <bruno@clisp.org>
19148
19149         * lib/linebreak.h: New file, from GNU gettext.
19150         * lib/linebreak.c: New file, from GNU gettext with slight
19151         modifications.
19152         * lib/lbrkprop.h: New file, from GNU gettext.
19153
19154 2003-04-03  Bruno Haible  <bruno@clisp.org>
19155
19156         * modules/utf8-ucs4: New file.
19157         * modules/utf16-ucs4: New file.
19158         * modules/ucs4-utf8: New file.
19159         * modules/ucs4-utf16: New file.
19160         * MODULES.html.sh (func_all_modules): Add them.
19161
19162 2003-04-03  Bruno Haible  <bruno@clisp.org>
19163
19164         * m4/utf-ucs4.m4: New file.
19165         * m4/ucs4-utf.m4: New file.
19166
19167 2003-04-03  Bruno Haible  <bruno@clisp.org>
19168
19169         * lib/utf8-ucs4.h: New file, from GNU gettext.
19170         * lib/utf16-ucs4.h: New file, from GNU gettext.
19171         * lib/ucs4-utf8.h: New file, from GNU gettext.
19172         * lib/ucs4-utf16.h: New file, from GNU gettext.
19173
19174 2003-04-02  Bruno Haible  <bruno@clisp.org>
19175
19176         * modules/binary-io: New file.
19177         * MODULES.html.sh (func_all_modules): Add it.
19178
19179 2003-04-02  Bruno Haible  <bruno@clisp.org>
19180
19181         * lib/binary-io.h: New file, from GNU gettext.
19182
19183 2003-04-01  Bruno Haible  <bruno@clisp.org>
19184
19185         * modules/pathname: New file.
19186         * MODULES.html.sh (func_all_modules): Add it.
19187
19188 2003-04-01  Bruno Haible  <bruno@clisp.org>
19189
19190         * lib/pathname.h: New file, from GNU gettext.
19191         * lib/concatpath.c: New file, from GNU gettext.
19192
19193 2003-03-30  Bruno Haible  <bruno@clisp.org>
19194
19195         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
19196
19197 2003-03-30  Bruno Haible  <bruno@clisp.org>
19198
19199         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
19200         function chown() doesn't exist.
19201
19202 2003-03-28  Bruno Haible  <bruno@clisp.org>
19203
19204         * modules/copy-file: New file.
19205         * MODULES.html.sh (func_all_modules): Add it.
19206
19207 2003-03-28  Bruno Haible  <bruno@clisp.org>
19208
19209         * m4/copy-file.m4: New file.
19210
19211 2003-03-28  Bruno Haible  <bruno@clisp.org>
19212
19213         * lib/copy-file.h: New file, from GNU gettext.
19214         * lib/copy-file.c: New file, from GNU gettext.
19215
19216 2003-03-18  Jim Meyering  <jim@meyering.net>
19217
19218         * lib/quote.c (quote_n): Fix typo in comment.
19219
19220 2003-03-18  Bruno Haible  <bruno@clisp.org>
19221
19222         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
19223         checking.
19224         * m4/onceonly_2_57.m4: Likewise.
19225
19226 2003-03-17  Bruno Haible  <bruno@clisp.org>
19227
19228         * m4/onceonly.m4: Require autoconf 2.54 or newer.
19229         (m4_quote): Remove macro.
19230         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
19231
19232 2003-03-14  Jim Meyering  <jim@meyering.net>
19233
19234         Merge changes from Coreutils.
19235         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
19236         to be const, in order to avoid warnings.
19237         (obstack_room): Likewise.
19238         (obstack_empty_p): Likewise.
19239
19240 2003-03-14  Bruno Haible  <bruno@clisp.org>
19241
19242         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
19243         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
19244
19245 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19246
19247         Merge changes from Bison.
19248         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
19249         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
19250         when compiling Bison 1.875's `bitset bset = obstack_alloc
19251         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
19252         * lib/hash.c: Include <stdbool.h> unconditionally.
19253
19254 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19255
19256         * m4/onceonly.m4 (m4_quote): New macro.
19257         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
19258         Quote AC_FOREACH variable-expansions properly.
19259
19260 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19261
19262         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
19263
19264 2003-03-09  Paul Eggert  <eggert@twinsun.com>
19265
19266         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
19267         Reported by Bruce Becker; see:
19268         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
19269
19270 2003-03-03  Paul Eggert  <eggert@twinsun.com>
19271             Bruno Haible  <bruno@clisp.org>
19272
19273         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
19274         Reported by John Hughes, see
19275         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
19276
19277 2003-02-20  Bruno Haible  <bruno@clisp.org>
19278
19279         * MODULES.html.sh (func_all_modules): Add poll.
19280
19281 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19282
19283         * modules/poll: New file.
19284
19285 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19286
19287         * lib/poll_.h: New file.
19288         * lib/poll.c: New file.
19289
19290 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19291
19292         * m4/poll.m4: New file.
19293
19294 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19295
19296         * modules/mathl: New file.
19297
19298 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19299
19300         * lib/mathl.h: New file.
19301         * lib/acosl.c: New file.
19302         * lib/asinl.c: New file.
19303         * lib/atanl.c: New file.
19304         * lib/ceill.c: New file.
19305         * lib/cosl.c: New file.
19306         * lib/expl.c: New file.
19307         * lib/floorl.c: New file.
19308         * lib/frexpl.c: New file.
19309         * lib/ldexpl.c: New file.
19310         * lib/logl.c: New file.
19311         * lib/sincosl.c: New file.
19312         * lib/sinl.c: New file.
19313         * lib/sqrtl.c: New file.
19314         * lib/tanl.c: New file.
19315         * lib/trigl.c: New file.
19316         * lib/trigl.h: New file.
19317
19318 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19319
19320         * m4/mathl.m4: New file.
19321
19322 2003-02-18  Bruno Haible  <bruno@clisp.org>
19323
19324         * MODULES.html.sh (func_all_modules): Add mathl.
19325
19326 2003-02-17  Bruno Haible  <bruno@clisp.org>
19327
19328         * modules/mkdtemp: New module.
19329         * MODULES.html.sh (func_all_modules): Add it.
19330
19331 2003-02-17  Bruno Haible  <bruno@clisp.org>
19332
19333         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
19334
19335 2003-02-17  Bruno Haible  <bruno@clisp.org>
19336
19337         * lib/mkdtemp.h: New file, from GNU gettext.
19338         * lib/mkdtemp.c: New file, from GNU gettext.
19339
19340 2003-02-02  Jim Meyering  <jim@meyering.net>
19341
19342         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
19343         e.g. glibc-2.2.93.
19344
19345 2003-01-31  Bruno Haible  <bruno@clisp.org>
19346
19347         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
19348         'rpl_rename'.
19349         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
19350         'rpl_strnlen'.
19351         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
19352         'rpl_strtod'.
19353         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
19354         'rpl_utime'.
19355
19356 2003-01-31  Bruno Haible  <bruno@clisp.org>
19357
19358         * lib/rename.c: #undef rename before defining rpl_rename.
19359         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
19360
19361 2003-01-30  Bruno Haible  <bruno@clisp.org>
19362
19363         * modules/vasnprintf, modules/vasprintf: New modules.
19364         * MODULES.html.sh (func_all_modules): Add them.
19365
19366 2003-01-30  Bruno Haible  <bruno@clisp.org>
19367
19368         * m4/signed.m4: New file, from GNU gettext.
19369         * m4/longdouble.m4: New file, from GNU gettext.
19370         * m4/wchar_t.m4: New file, from GNU gettext.
19371         * m4/wint_t.m4: New file, from GNU gettext.
19372         * m4/vasnprintf.m4: New file.
19373         * m4/vasprintf.m4: New file.
19374
19375 2003-01-30  Bruno Haible  <bruno@clisp.org>
19376
19377         * lib/printf-args.h: New file, from GNU gettext.
19378         * lib/printf-args.c: New file, from GNU gettext.
19379         * lib/printf-parse.h: New file, from GNU gettext.
19380         * lib/printf-parse.c: New file, from GNU gettext.
19381         * lib/vasnprintf.h: New file, from GNU gettext.
19382         * lib/vasnprintf.c: New file, from GNU gettext.
19383         * lib/asnprintf.c: New file, from GNU gettext.
19384         * lib/vasprintf.h: New file, from GNU gettext with modifications.
19385         * lib/vasprintf.c: New file, from GNU gettext.
19386         * lib/asprintf.c: New file, from GNU gettext.
19387
19388 2003-01-29  Bruno Haible  <bruno@clisp.org>
19389
19390         * modules/stpncpy: New module.
19391         * MODULES.html.sh (func_all_modules): Add it.
19392
19393 2003-01-29  Bruno Haible  <bruno@clisp.org>
19394
19395         * m4/stpncpy.m4: New file.
19396
19397 2003-01-29  Bruno Haible  <bruno@clisp.org>
19398
19399         * lib/stpncpy.h: New file, from GNU gettext with modifications.
19400         * lib/stpncpy.c: New file, from GNU gettext with modifications.
19401
19402 2003-01-28  Bruno Haible  <bruno@clisp.org>
19403
19404         * modules/c-ctype: New module.
19405         * MODULES.html.sh (func_all_modules): Add it.
19406
19407 2003-01-28  Bruno Haible  <bruno@clisp.org>
19408
19409         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
19410         Paul Eggert.
19411         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
19412         Paul Eggert.
19413
19414 2003-01-27  Bruno Haible  <bruno@clisp.org>
19415
19416         * modules/xsetenv: New module.
19417         * MODULES.html.sh (func_all_modules): Add it.
19418
19419 2003-01-27  Bruno Haible  <bruno@clisp.org>
19420
19421         * lib/xsetenv.h: New file, from GNU gettext.
19422         * lib/xsetenv.c: New file, from GNU gettext.
19423
19424 2003-01-23  Jim Meyering  <jim@meyering.net>
19425
19426         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
19427         from working on systems without dirfd (at least Irix and OSF1/Tru64).
19428
19429 2003-01-23  Bruno Haible  <bruno@clisp.org>
19430
19431         * modules/minmax: New module.
19432         * MODULES.html.sh (func_all_modules): Add it.
19433
19434 2003-01-23  Bruno Haible  <bruno@clisp.org>
19435
19436         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
19437         Eggert.
19438
19439 2003-01-22  Bruno Haible  <bruno@clisp.org>
19440
19441         * modules/exit: New module.
19442         * MODULES.html.sh (func_all_modules): Add it.
19443
19444 2003-01-22  Bruno Haible  <bruno@clisp.org>
19445
19446         * lib/exit.h: New file, from GNU gettext.
19447
19448 2003-01-19  Bruno Haible  <bruno@clisp.org>
19449
19450         * gnulib-tool: Recognize option --extract-maintainer.
19451         (func_get_maintainer): New function.
19452         * modules/*: Add Maintainer entry.
19453
19454 2003-01-16  Jim Meyering  <jim@meyering.net>
19455
19456         * m4/regex.m4: The `regex' struct is both input and output.
19457         Initialize it before each use.  Patch by Tim Waugh.
19458
19459 2003-01-16  Bruno Haible  <bruno@clisp.org>
19460
19461         * MODULES.html.sh: Add a table of contents. Add the module name as
19462         leftmost column. Add hyperlinks.
19463
19464 2003-01-15  Bruno Haible  <bruno@clisp.org>
19465
19466         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
19467
19468 2003-01-15  Bruno Haible  <bruno@clisp.org>
19469
19470         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
19471         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
19472         suffix.
19473
19474 2003-01-15  Bruno Haible  <bruno@clisp.org>
19475
19476         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
19477
19478 2003-01-15  Bruno Haible  <bruno@clisp.org>
19479
19480         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
19481         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
19482
19483 2003-01-14  Jim Meyering  <jim@meyering.net>
19484
19485         * lib/same.c (same_name): Tweak a comment.
19486
19487 2003-01-14  Bruno Haible  <bruno@clisp.org>
19488
19489         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
19490         when a string comparison is sufficient.
19491
19492 2003-01-14  Bruno Haible  <bruno@clisp.org>
19493
19494         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
19495         'unsigned int'.
19496
19497 2003-01-14  Bruno Haible  <bruno@clisp.org>
19498
19499         * lib/hash-pjw.c: Add comment about low quality of this function.
19500
19501 2003-01-13  Bruno Haible  <bruno@clisp.org>
19502
19503         * modules/stpcpy: Distribute lib/stpcpy.h.
19504         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
19505
19506 2003-01-13  Bruno Haible  <bruno@clisp.org>
19507
19508         * modules/*: Add a description.
19509         * modules/strpbrk: Fix Makefile.am snippet.
19510         * modules/strtoimax: Fix dependencies.
19511         * modules/strtoumax: Likewise.
19512
19513 2003-01-13  Bruno Haible  <bruno@clisp.org>
19514
19515         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
19516         * modules/alloca (Makefile.am): All object files depend on alloca.h.
19517         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
19518
19519 2003-01-13  Bruno Haible  <bruno@clisp.org>
19520
19521         * gnulib-tool (func_create_testdir): Store config/* files in the main
19522         directory.
19523         * config.rpath: Move to ...
19524         * config/config.rpath: ... here.
19525         * modules/gettext: Contains config/config.rpath, not config.rpath.
19526         * modules/iconv: Likewise.
19527
19528 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19529
19530         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19531         to avoid collisions with libcurses and libreadline.
19532
19533         * m4/getstr.m4: Remove.
19534         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
19535
19536 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19537
19538         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19539         to avoid collisions with libcurses and libreadline.
19540
19541         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
19542         * lib/getstr.h, getstr.c: Remove.
19543         * lib/getline.c: Include "getline.h", to check interface.
19544         Move body of old getstr.c here: this defines MIN_CHUNK and
19545         declares getdelim2, which is renamed from getstr.
19546         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
19547
19548         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
19549         All uses changed.
19550         * lib/linebuffer.h: Likewise.
19551         (readline): Remove backward-compatibility macro.
19552
19553 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19554
19555         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19556         to avoid collisions with libcurses and libreadline.
19557         * getstr: Remove.
19558         * MODULES.html.sh: Remove getstr.
19559         * modules/getline: Depend on unlocked-io, not getstr.
19560
19561 2003-01-12  Jim Meyering  <jim@meyering.net>
19562
19563         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
19564
19565 2003-01-10  Bruno Haible  <bruno@clisp.org>
19566
19567         * modules/alloca: Change Makefile.am requirements. Simplify Include
19568         requirements. Add lib/alloca_.h to file list.
19569
19570 2003-01-10  Bruno Haible  <bruno@clisp.org>
19571
19572         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
19573
19574 2003-01-10  Bruno Haible  <bruno@clisp.org>
19575
19576         * lib/alloca_.h: New file.
19577         * lib/getdate.y: Unconditionally include alloca.h.
19578         * lib/makepath.c: Likewise.
19579         * lib/setenv.c: Likewise.
19580         * lib/userspec.c: Likewise.
19581
19582 2003-01-09  Karl Berry  <karl@gnu.org>
19583
19584         * MODULES.html.sh: include `dirname $0` in PATH, to find
19585         gnulib-tool.
19586
19587 2003-01-09  Bruno Haible  <bruno@clisp.org>
19588
19589         * modules/stdbool: Change configure.ac, Makefile.am requirements.
19590         Simplify Include requirements. Add lib/stdbool.h.in to file list.
19591
19592 2003-01-09  Bruno Haible  <bruno@clisp.org>
19593
19594         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
19595
19596 2003-01-09  Bruno Haible  <bruno@clisp.org>
19597
19598         * lib/stdbool.h.in: New file.
19599
19600 2003-01-09  Bruno Haible  <bruno@clisp.org>
19601
19602         * gnulib-tool (func_all_modules): Ignore files ending in ~.
19603         * MODULES.html.sh: Likewise.
19604
19605 2003-01-08  Jim Meyering  <jim@meyering.net>
19606
19607         * lib/full-write.c: Undefine and define-away `const' after inclusion
19608         of errno.h, not before.  Suggestion from Bruno Haible.
19609
19610 2003-01-08  Bruno Haible  <bruno@clisp.org>
19611
19612         * modules/full-read: Depend on full-write.
19613
19614 2003-01-08  Bruno Haible  <bruno@clisp.org>
19615
19616         * lib/safe-read.c: Include specification header first, to ensure its
19617         selfcontainedness.
19618         * lib/full-write.c: Likewise.
19619
19620 2003-01-07  Jim Meyering  <jim@meyering.net>
19621
19622         * lib/full-write.c: Rework so that it may serve to define full_read,
19623         too.
19624         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
19625
19626 2003-01-07  Bruno Haible  <bruno@clisp.org>
19627
19628         * lib/strtoimax.c: Include <stdint.h> as an alternative to
19629         <inttypes.h>.
19630         * lib/xstrtol.h: Likewise.
19631         * lib/xstrtoimax.c: Likewise.
19632         * lib/xstrtoumax.c: Likewise.
19633         * lib/human.h: Likewise.
19634
19635         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
19636         on systems that have <inttypes.h> but not <stdint.h>.
19637
19638 2003-01-07  Bruno Haible  <bruno@clisp.org>
19639
19640         * MODULES.html.sh: Add copyright notice.
19641         (missed_files): Omit CVS directory entries.
19642         (func_module): Make it work with sed-3.02.
19643         * MODULES.txt: Remove file.
19644
19645 2003-01-06  Jim Meyering  <jim@meyering.net>
19646
19647         * lib/version-etc.c: Update year in translatable copyright string.
19648
19649 2003-01-03  Karl Berry  <karl@gnu.org>
19650
19651         * config/config.{guess,sub}: update from prep.
19652
19653 2003-01-02  Karl Berry  <karl@gnu.org>
19654
19655         * doc/COPYING.DOC: belatedly updated to 1.2.
19656
19657 2003-01-01  Karl Berry  <karl@gnu.org>
19658
19659         * gnulib-tool (func_verify_module): report module name $module in
19660         error message, not $1.
19661         * gnulib-tool (create-testdir): don't complain if destdir couldn't
19662         be created, only if it doesn't exist.
19663         * gnulib-tool (last_checkin_date): don't expand the $Date here.
19664
19665 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19666
19667         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
19668
19669 2002-12-31  Paul Eggert  <eggert@twinsun.com>
19670
19671         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
19672         memcmp if strcoll doesn't work.
19673
19674 2002-12-31  Bruno Haible  <bruno@clisp.org>
19675
19676         * lib/utime.c (utime_null): No need to call ftruncate if the file was
19677         nonempty.
19678
19679 2002-12-31  Bruno Haible  <bruno@clisp.org>
19680
19681         * lib/memcoll.c (STRCOLL): New macro.
19682         (memcoll): Use it.
19683
19684 2002-12-31  Bruno Haible  <bruno@clisp.org>
19685
19686         * lib/localcharset.h: New file.
19687         * lib/localcharset.c: Include it.
19688         * lib/unicodeio.c: Likewise.
19689
19690 2002-12-31  Bruno Haible  <bruno@clisp.org>
19691
19692         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
19693         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
19694
19695 2002-12-31  Bruno Haible  <bruno@clisp.org>
19696
19697         * lib/getline.h: Include <stddef.h>, for size_t.
19698
19699         * lib/unicodeio.h: Include <stddef.h>, for size_t.
19700         * lib/unicodeio.c: Don't include <stddef.h>.
19701
19702 2002-12-31  Bruno Haible  <bruno@clisp.org>
19703
19704         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
19705         HAVE_TM_ZONE.
19706
19707 2002-12-24  Karl Berry  <karl@gnu.org>
19708
19709         * config/config.guess: update from prep.
19710
19711 2002-12-24  Bruno Haible  <bruno@clisp.org>
19712
19713         General infrasructure.
19714         * m4/README: Rewritten.
19715         * m4/onceonly.m4: New file.
19716         * m4/onceonly_2_57.m4: New file.
19717
19718         Module atexit.
19719         * m4/atexit.m4: New file.
19720
19721         Module strtod.
19722         * m4/strtod.m4: New file.
19723
19724         Module strtol.
19725         * m4/strtol.m4: New file.
19726
19727         Module strtoul.
19728         * m4/strtoul.m4: New file.
19729
19730         Module memchr.
19731         * m4/memchr.m4: New file.
19732
19733         Module memcmp.
19734         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
19735         (jm_FUNC_MEMCMP): Invoke it.
19736
19737         Module memcpy.
19738         * m4/memcpy.m4: New file.
19739
19740         Module memmove.
19741         * m4/memmove.m4: New file.
19742
19743         Module memset.
19744         * m4/memset.m4: New file.
19745
19746         Module strcspn.
19747         * m4/strcspn.m4: New file.
19748
19749         Module strpbrk.
19750         * m4/strpbrk.m4: New file.
19751
19752         Module strstr.
19753         * m4/strstr.m4: New file.
19754
19755         Module strerror.
19756         * m4/strerror.m4: New file.
19757
19758         Module mktime.
19759         * m4/mktime.m4: Renamed from jm-mktime.m4.
19760         (gl_PREREQ_MKTIME): New macro.
19761         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
19762
19763         Module malloc.
19764         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
19765         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
19766         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
19767
19768         Module realloc.
19769         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
19770         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
19771         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
19772
19773         Module strftime.
19774         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
19775         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
19776         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
19777         gl_TM_GMTOFF.
19778         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
19779
19780         Module xalloc.
19781         * m4/xalloc.m4: New file.
19782
19783         Module alloca.
19784         * m4/alloca.m4: New file.
19785
19786         Module putenv.
19787         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
19788         (jm_FUNC_PUTENV): Invoke it.
19789
19790         Module setenv.
19791         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
19792         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
19793         when invoked twice.
19794         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
19795         gt_FUNC_SETENV.
19796
19797         Module memrchr.
19798         * m4/memrchr.m4: New file.
19799
19800         Module stpcpy.
19801         * m4/stpcpy.m4: New file.
19802
19803         Module strcase.
19804         * m4/strcase.m4: New file.
19805
19806         Module strdup.
19807         * m4/strdup.m4: New file.
19808
19809         Module strnlen.
19810         * m4/strnlen.m4: New file.
19811
19812         Module strndup.
19813         * m4/strndup.m4: New file.
19814
19815         Module xstrtod.
19816         * m4/xstrtod.m4: New file.
19817
19818         Module xstrtol.
19819         * m4/xstrtol.m4: New file.
19820
19821         Module getdate.
19822         * m4/getdate.m4: New file.
19823
19824         Module unlocked-io.
19825         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
19826         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
19827         * m4/jm-glibc-io.m4n: Remove file.
19828
19829         Module long-options.
19830         * m4/long-options.m4: New file.
19831
19832         Module md5.
19833         * m4/md5.m4: New file.
19834
19835         Module sha.
19836         * m4/sha.m4: New file.
19837
19838         Module getstr.
19839         * m4/getstr.m4: New file.
19840
19841         Module getline.
19842         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
19843         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
19844         <sys/types.h>, for size_t. Use the function name gnu_getline, not
19845         simply getline. Infoke gl_PREREQ_GETLINE.
19846
19847         Module obstack.
19848         * m4/obstack.m4: New file.
19849
19850         Module hash.
19851         * m4/hash.m4: New file.
19852
19853         Module readtokens.
19854         * m4/readtokens.m4: New file.
19855
19856         Module strverscmp.
19857         * m4/strverscmp.m4: New file.
19858
19859         Module stdbool.
19860         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
19861         OSF/1.
19862
19863         Module strtoll.
19864         * m4/strtoll.m4: New file.
19865
19866         Module strtoull.
19867         * m4/strtoull.m4: New file.
19868
19869         Module strtoimax.
19870         * m4/strtoimax.m4: New file.
19871
19872         Module strtoumax.
19873         * m4/strtoumax.m4: New file.
19874
19875         Module xstrtoimax.
19876         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
19877         jm_AC_PREREQ_XSTRTOIMAX.
19878         Moved the strtol prerequisites to strtol.m4.
19879         Moved the strtoll prerequisites to strtoll.m4.
19880         Moved the strtoimax prerequisites to strtoimax.m4.
19881
19882         Module xstrtoumax.
19883         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
19884         jm_AC_PREREQ_XSTRTOUMAX.
19885         Moved the strtoul prerequisites to strtoul.m4.
19886         Moved the strtoull prerequisites to strtoull.m4.
19887         Moved the strtoumax prerequisites to strtoumax.m4.
19888
19889         Module chown.
19890         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
19891         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
19892
19893         Module dup2.
19894         * m4/dup2.m4: New file.
19895
19896         Module ftruncate.
19897         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
19898         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
19899
19900         Module getgroups.
19901         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
19902         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
19903
19904         Module gettimeofday.
19905         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
19906         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
19907         gl_PREREQ_GETTIMEOFDAY.
19908
19909         Module mkdir.
19910         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
19911         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
19912
19913         Module mkstemp.
19914         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
19915         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
19916         jm_AC_TYPE_UINTMAX_T.
19917         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
19918
19919         Module stat.
19920         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
19921         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
19922
19923         Module lstat.
19924         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
19925         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
19926
19927         Module timespec.
19928         * m4/timespec.m4 (gl_TIMESPEC): New macro.
19929         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
19930         * m4/st_mtim.m4: Indentation.
19931
19932         Module nanosleep.
19933         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
19934         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
19935         gl_PREREQ_NANOSLEEP.
19936
19937         Module regex.
19938         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
19939         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
19940         (gl_REGEX): New macro.
19941
19942         Module rename.
19943         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
19944         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
19945
19946         Module rmdir.
19947         * m4/rmdir.m4: New file.
19948
19949         Module utime.
19950         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
19951         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
19952         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
19953
19954         Module dirname.
19955         * m4/dirname.m4: New file.
19956
19957         Module getopt.
19958         * m4/getopt.m4: New file.
19959
19960         Module unistd-safer.
19961         * m4/unistd-safer.m4: New file.
19962
19963         Module fnmatch.
19964         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
19965         declaration.
19966         (gl_PREREQ_FNMATCH_EXTRA): New macro.
19967         (gl_FUNC_FNMATCH_POSIX): New macro.
19968         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
19969         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
19970         simply fnmatch.
19971
19972         Module exclude.
19973         * m4/exclude.m4: New file.
19974
19975         Module human.
19976         * m4/human.m4: New file.
19977
19978         Module acl.
19979         * m4/acl.m4: Nop.
19980
19981         Module backupfile.
19982         * m4/backupfile.m4: New file.
19983         * m4/d-ino.m4: Indentation.
19984
19985         Module fsusage.
19986         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
19987         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
19988         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
19989
19990         Module dirfd.
19991         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
19992         requirements.
19993
19994         Module euidaccess.
19995         * m4/euidaccess.m4: New file.
19996
19997         Module file-type.
19998         * m4/file-type.m4: New file.
19999
20000         Module fileblocks.
20001         * m4/fileblocks.m4: New file.
20002
20003         Module filemode.
20004         * m4/filemode.m4: New file.
20005
20006         Module isdir.
20007         * m4/isdir.m4: New file.
20008
20009         Module lchown.
20010         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
20011         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
20012
20013         Module makepath.
20014         * m4/makepath.m4: New file.
20015
20016         Module modechange.
20017         * m4/modechange.m4: New file.
20018
20019         Module mountlist.
20020         * m4/mountlist.m4: New file.
20021         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
20022         Indentation.
20023
20024         Module path-concat.
20025         * m4/path-concat.m4: New file.
20026
20027         Module pathmax.
20028         * m4/pathmax.m4: New file.
20029
20030         Module same.
20031         * m4/same.m4: New file.
20032
20033         Module save-cwd.
20034         * m4/save-cwd.m4: New file.
20035
20036         Module savedir.
20037         * m4/savedir.m4: New file.
20038
20039         Module xgetcwd.
20040         * m4/xgetcwd.m4: New file.
20041         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
20042
20043         Module xreadlink.
20044         * m4/xreadlink.m4: New file.
20045
20046         Module safe-read.
20047         * m4/safe-read.m4: New file.
20048
20049         Module safe-write.
20050         * m4/safe-write.m4: New file.
20051
20052         Module closeout.
20053         * m4/closeout.m4: New file.
20054
20055         Module stdio-safer.
20056         * m4/stdio-safer.m4: New file.
20057
20058         Module getpass.
20059         * m4/getpass.m4: New file.
20060
20061         Module getugroups.
20062         * m4/getugroups.m4: New file.
20063
20064         Module group-member.
20065         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
20066         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
20067
20068         Module idcache.
20069         * m4/idcache.m4: New file.
20070
20071         Module userspec.
20072         * m4/userspec.m4: New file.
20073
20074         Module gettime.
20075         * m4/clock_time.m4: New file.
20076         * m4/gettime.m4: New file.
20077
20078         Module settime.
20079         * m4/settime.m4: New file.
20080
20081         Module posixtm.
20082         * m4/posixtm.m4: New file.
20083
20084         Module gethostname.
20085         * m4/gethostname.m4: New file.
20086
20087         Module canon-host.
20088         * m4/canon-host.m4: New file.
20089
20090         Module gettext.
20091         * m4/codeset.m4: New file, from gettext-0.11.5.
20092         * m4/gettext.m4: New file, from gettext-0.11.5.
20093         * m4/glibc21.m4: New file, from gettext-0.11.5.
20094         * m4/iconv.m4: New file, from gettext-0.11.5.
20095         * m4/intdiv0.m4: New file, from gettext-0.11.5.
20096         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
20097         * m4/inttypes.m4: New file, from gettext-0.11.5.
20098         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
20099         * m4/isc-posix.m4: New file, from gettext-0.11.5.
20100         * m4/lcmessage.m4: New file, from gettext-0.11.5.
20101         * m4/lib-ld.m4: New file, from gettext-0.11.5.
20102         * m4/lib-link.m4: New file, from gettext-0.11.5.
20103         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
20104         * m4/progtest.m4: New file, from gettext-0.11.5.
20105         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
20106         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
20107         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
20108
20109         Module localcharset.
20110         * m4/localcharset.m4: New file.
20111
20112         Module hard-locale.
20113         * m4/hard-locale.m4: New file.
20114
20115         Module mbswidth.
20116         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
20117         onceonly macros.
20118         * m4/mbrtowc.m4: Add comment.
20119
20120         Module memcasecmp.
20121         * m4/memcasecmp.m4: New file.
20122
20123         Module memcoll.
20124         * m4/memcoll.m4: New file.
20125
20126         Module unicodeio.
20127         * m4/unicodeio.m4: New file.
20128
20129         Module rpmatch.
20130         * m4/rpmatch.m4: New file.
20131
20132         Module yesno.
20133         * m4/yesno.m4: New file.
20134
20135         Module exitfail.
20136         * m4/exitfail.m4: New file.
20137
20138         Module c-stack.
20139         * m4/c-stack.m4 (gl_C_STACK): New macro.
20140         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
20141
20142         Module error.
20143         * m4/error.m4 (gl_ERROR): New macro.
20144         (jm_PREREQ_ERROR): Use onceonly macros.
20145
20146         Module fatal.
20147         * m4/fatal.m4: New file.
20148
20149         Module getloadavg.
20150         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
20151         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
20152
20153         Module getpagesize.
20154         * m4/getpagesize.m4: New file.
20155
20156         Module getusershell.
20157         * m4/getusershell.m4: New file.
20158
20159         Module physmem.
20160         * m4/physmem.m4: New file.
20161
20162         Module posixver.
20163         * m4/posixver.m4: New file.
20164
20165         Module quotearg.
20166         * m4/quotearg.m4: New file.
20167
20168         Module quote.
20169         * m4/quote.m4: New file.
20170
20171         Module readutmp.
20172         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
20173
20174         Module sig2str.
20175         * m4/sig2str.m4: New file.
20176
20177         Other.
20178         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
20179         ulonglong.m4.
20180         * m4/intmax_t.m4: New file.
20181         * m4/d-type.m4: Indentation.
20182         * m4/jm-macros.m4: Update.
20183         * m4/prereq.m4 (jm_PREREQ): Update.
20184         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
20185         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
20186         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
20187         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
20188         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
20189         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
20190         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
20191         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
20192         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
20193         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
20194         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
20195         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
20196         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
20197         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
20198         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
20199         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
20200         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
20201         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
20202         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
20203
20204 2002-12-24  Bruno Haible  <bruno@clisp.org>
20205
20206         * MODULES.txt: Update according to m4/ changes.
20207
20208         Module gettext.
20209         * config.rpath: New file, from gettext-0.11.5.
20210
20211         * modules/*: New module descriptions.
20212         * gnulib-tool: New file.
20213         * MODULES.html.sh: New file.
20214
20215 2002-12-21  Karl Berry  <karl@gnu.org>
20216
20217         * doc/fdl.texi: update to version 1.2.
20218
20219 2002-12-19  Karl Berry  <karl@gnu.org>
20220
20221         * config/config.guess: update from prep.
20222
20223 2002-12-18  Bruno Haible  <bruno@clisp.org>
20224
20225         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
20226         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
20227
20228 2002-12-17  Bruno Haible  <bruno@clisp.org>
20229
20230         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
20231         stdlib.h, string.h.
20232
20233 2002-12-17  Bruno Haible  <bruno@clisp.org>
20234
20235         * lib/canon-host.c (strdup): Remove unused declaration.
20236
20237         * lib/fsusage.c: Include full_read.h.
20238         (get_fs_usage): Use full_read instead of safe_read.
20239
20240         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
20241
20242 2002-12-12  Karl Berry  <karl@gnu.org>
20243
20244         * config/config.guess: update from prep.
20245
20246 2002-12-11  Bruno Haible  <bruno@clisp.org>
20247
20248         * m4/setenv.m4: New file, from gettext-0.11.5.
20249
20250 2002-12-11  Bruno Haible  <bruno@clisp.org>
20251
20252         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
20253         not unsetenv().
20254         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
20255         modifications:
20256
20257         2002-12-11  Bruno Haible  <bruno@clisp.org>
20258
20259                 * setenv.c (alloca): Fall back to malloc.
20260                 (freea): New macro.
20261                 (setenv): Use freea() to free memory allocated with alloca().
20262
20263         2002-11-13  Bruno Haible  <bruno@clisp.org>
20264
20265                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
20266                 function declarations.
20267                 * unsetenv.c (unsetenv): Likewise.
20268
20269         2002-03-04  Bruno Haible  <bruno@clisp.org>
20270
20271                 Portability to AIX 4.3.3.
20272                 * unsetenv.c: New file, extracted from setenv.c.
20273                 * setenv.c: Move the unsetenv() function to unsetenv.c.
20274
20275         2001-12-20  Bruno Haible  <bruno@clisp.org>
20276
20277                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
20278                 use malloc instead. For SunOS 4.
20279
20280         2001-12-11  Bruno Haible  <bruno@clisp.org>
20281
20282                 * setenv.c: Declare alloca.
20283                 (compar_fn_t): New typedef.
20284                 (KNOWN_VALUE, STORE_VALUE): Use it.
20285
20286         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
20287         setenv.h.
20288
20289 2002-12-10  Paul Eggert  <eggert@twinsun.com>
20290
20291         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
20292         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
20293         Choose values that are less likely to collide with system fnmatch
20294         options.
20295         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
20296         defined (e.g., a pure POSIX system).
20297         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
20298         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
20299
20300 2002-12-06  Paul Eggert  <eggert@twinsun.com>
20301
20302         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
20303         a pain in practice to deal with generated m4 files.  This change
20304         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
20305
20306         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
20307         and jm-glibc-io.m4, as they are no longer a special case.
20308         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
20309         kludge and the auto-generation stuff.  Check only whether the
20310         functions are declared, not whether they exist, since older hosts
20311         that don't declare the functions can't use the optimization anyway.
20312
20313 2002-12-06  Jim Meyering  <jim@meyering.net>
20314
20315         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
20316
20317         Merge in changes from libc's misc/error.c, in preparation
20318         for the merge of gnulib's changes back into libc.
20319
20320         * lib/error.c (_): Define only if not already defined.
20321         Move definition to follow all #include directives.
20322         Include unlocked-io.h only if !_LIBC.
20323         [_LIBC]: Include <libio/libioP.h>.
20324         [USE_IN_LIBIO]: Include <libio/iolibio.h>
20325         (fflush): Tweak definition to use INTUSE.
20326         (putc): Define.
20327
20328 2002-12-05  Paul Eggert  <eggert@twinsun.com>
20329
20330         * lib/alloca.c [defined emacs]: Include "lisp.h".
20331         (xalloc_die) [defined emacs]: New macro.
20332         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
20333         [! defined emacs]: Include <xalloc.h>.
20334         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
20335         (pointer): Typedef to POINTER_TYPE *.
20336         (malloc): Remove decl; we now always use xmalloc.
20337         (alloca): Use old-style definition, since Emacs needs this.
20338         Check for arithmetic overflow when computing combined size.
20339
20340 2002-12-04  Paul Eggert  <eggert@twinsun.com>
20341
20342         Do not generate unlocked-io.h automatically, since it's easier to
20343         maintain it by hand.
20344
20345         * lib/unlocked-io.h: New file, from GNU diffutils,
20346         but with proper copyright notice and attribution.
20347         * lib/gen-uio: Remove.
20348         * lib/Makefile.am: Add copyright notice.
20349         (libfetish_a_SOURCES): Add unlocked-io.h.
20350         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
20351         (DISTCLEANFILES, io_functions): Remove macros.
20352         (EXTRA_DIST): Remove gen_uio.
20353         (unlocked-io.h): Remove rule.
20354
20355 2002-12-04  Jim Meyering  <jim@meyering.net>
20356
20357         Reflect the fact that stat.c and lstat.c are no longer generated.
20358         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
20359         (DISTCLEANFILES): Likewise.
20360         (EXTRA_DIST): Likewise.
20361         (all_local): Don't depend on stat.c or lstat.c.
20362         (stat.c, lstat.c): Remove rules.
20363         (EXTRA_DIST): Remove xstat.in.
20364
20365         * lib/xstat.in: Remove file.  Contents moved into stat.c.
20366         * lib/stat.c: New file.  Contents mostly from xstat.in.
20367         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
20368         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
20369
20370         * lib/safe-read.c: Rework so that it may serve to define safe_write,
20371         too.
20372         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
20373
20374 2002-12-03  Jim Meyering  <jim@meyering.net>
20375
20376         * lib/safe-read.c, safe-write.c: Change variable names and comments,
20377         but not semantics, to minimize the differences between these two files.
20378         (safe_read): Change comment to mention SAFE_READ_ERROR.
20379
20380         * lib/safe-read.c (IS_EINTR): Define.
20381         (safe_read): Use IS_EINTR in place of in-function cpp directives.
20382
20383 2002-12-02  Jim Meyering  <jim@meyering.net>
20384
20385         * lib/safe-read.c (EINTR): Define.
20386         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20387         (INT_MAX): Provide fallback.
20388         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
20389
20390         * lib/safe-read.h (SAFE_READ_ERROR): Define.
20391
20392 2002-12-02  Bruno Haible  <bruno@clisp.org>
20393
20394         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
20395         Define, taken from safe-read.c.
20396         (INT_MAX): Provide fallback.
20397         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
20398         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
20399
20400         * lib/safe-read.c (EINTR): Remove definition.
20401         (safe_read): Don't use EINTR if it is absent.
20402
20403 2002-12-01  Jim Meyering  <jim@meyering.net>
20404
20405         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
20406         zero.
20407         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
20408
20409 2002-11-27  Paul Eggert  <eggert@twinsun.com>
20410
20411         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
20412         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
20413         with `if (! (value < limit)) abort ();', for readability.
20414
20415 2002-11-26  Karl Berry  <karl@gnu.org>
20416
20417         * lib/strdup.c: copy from libc again, with jim's ok.
20418         * lib/.cppi-disable: re-add strdup.c
20419
20420 2002-11-25  Karl Berry  <karl@gnu.org>
20421
20422         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
20423         instead of "strtol.c".
20424
20425 2002-11-25  Karl Berry  <karl@gnu.org>
20426
20427         * config/install-sh: update from automake for variable quoting, $0 in
20428         error msgs, etc.
20429
20430         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
20431         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
20432         entry.
20433
20434 2002-11-25  Jim Meyering  <jim@meyering.net>
20435
20436         * lib/mktime.c: Sync from libc, now that it has the latest fix.
20437
20438 2002-11-24  Karl Berry  <karl@gnu.org>
20439
20440         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
20441         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
20442
20443 2002-11-24  Jim Meyering  <jim@meyering.net>
20444
20445         Update from coreutils:
20446
20447         * lib/mktime.c: Merge in changes from libc.
20448
20449         Avoid a link-time failure on some Linux systems.
20450         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
20451         (otherwise).
20452         (__mon_yday): Declare with the STATIC attribute.
20453         (__mktime_internal): Likewise.
20454         Based on a report from Greg Schafer.
20455
20456 2002-11-23  Jim Meyering  <jim@meyering.net>
20457
20458         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
20459         Use `unsigned', not `int', as type of index.
20460
20461         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
20462
20463         * lib/fsusage.c: Remove unneeded parentheses around operands of
20464         `defined'.
20465
20466 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20467
20468         * lib/quotearg.h: Allow multiple inclusion by surrounding with
20469         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
20470         so that we can be included first.
20471         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
20472         * lib/quotearg.c: Include quotearg.h immediately after config.h.
20473         No need to include stddef.h or sys/types.h any more.
20474         Surround local include files with "", not "<>".
20475         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
20476         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
20477         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
20478         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
20479         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
20480         (ISPRINT): Remove; no longer needed now that we assume C89.
20481
20482         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
20483         Preserve errno.
20484
20485         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
20486         quotearg_char): Use SIZE_MAX rather than
20487         (size_t) -1 when we are talking about "infinity".
20488
20489         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
20490
20491 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20492
20493         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
20494         hint that one should use `if (! x) abort ();' rather than `assert
20495         (x);', and anyway it's one less thing to worry about configuring.
20496         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
20497         hash_rehash, hash_insert): Use abort rather than assert.
20498
20499 2002-11-22  Bruno Haible  <bruno@clisp.org>
20500
20501         * lib/safe-read.h: Assume C89. Add comments.
20502         (safe_read): Change return type to size_t.
20503         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
20504         byte counts > SSIZE_MAX correctly.
20505         * lib/safe-write.h: New file.
20506         * lib/safe-write.c: New file.
20507         * lib/full-read.h: New file.
20508         * lib/full-read.c: New file.
20509         * lib/full-write.h: Assume C89. Add comments.
20510         * lib/full-write.c: Include safe-write.h.
20511         (full_write): Rewritten to use safe_write.
20512         Suggested by Jim Meyering and Paul Eggert.
20513
20514 2002-11-21  Jim Meyering  <jim@meyering.net>
20515
20516         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
20517
20518         Merge in changes from the coreutils.
20519
20520         2002-09-25  Paul Eggert  <eggert@twinsun.com>
20521         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
20522         <stdint.h>.
20523         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
20524         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
20525         int.  Work more efficiently if X is the same width as uintmax_t.
20526         Do not compare X to -1, to avoid bogus compiler warning.
20527         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
20528         Don't assume that f_frsize and f_bsize are the same type.
20529
20530         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
20531         warning on FreeBSD.
20532
20533         * lib/makepath.c (make_path): Restore umask *before* creating the final
20534         component.
20535         (make_path): Minor reformatting.
20536
20537         * lib/xmalloc.c: Adjust to work with new autoconf macros,
20538         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
20539         HAVE_MALLOC/HAVE_REALLOC.
20540
20541         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
20542         dummy ones.  At least on GNU/Linux systems, `auto' means something
20543         else.
20544         From Michael Stone.
20545
20546 2002-11-21  Bruno Haible  <bruno@clisp.org>
20547
20548         Remove case insensitive option matching.
20549         * lib/argmatch.h (argcasematch): Remove declaration.
20550         (ARGCASEMATCH): Remove macro.
20551         (__xargmatch_internal): Remove case_sensitive argument.
20552         (XARGMATCH): Update.
20553         (XARGCASEMATCH): Remove macro.
20554         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
20555         case_sensitive argument.
20556         (argcasematch): Remove function.
20557         (__xargmatch_internal): Remove case_sensitive argument.
20558         (main): Use XARGMATCH instead of XARGCASEMATCH.
20559
20560         * lib/xmalloc.c: Change compile-time error message. Add comment about
20561         required autoconf version.
20562
20563 2002-11-20  Paul Eggert  <eggert@twinsun.com>
20564
20565         Merge argmatch cleanups from Bison.  Assume C89.
20566
20567         * lib/argmatch.c: Include config.h here, not in argmatch.h.
20568         Include stdlib.h, for EXIT_FAILURE.
20569         Always include <string.h>, since we assume C89.
20570         (EXIT_FAILURE): Remove pre-C89 bug workaround.
20571         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
20572         Include <stddef.h> instead, since it's all we need for size_t.
20573         (PARAMS): Remove.  All uses removed.
20574         (ARRAY_CARDINALITY): Do not bother to #undef.
20575         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
20576         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20577         Remove unnecessary parentheses.
20578         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20579         Insert necessary parentheses.
20580         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
20581         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
20582
20583 2002-11-19  Bruno Haible  <bruno@clisp.org>
20584
20585         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
20586         * lib/mbswidth.h: Include <stddef.h>, for size_t.
20587
20588         * lib/mbswidth.h (PARAMS): Remove macro.
20589         (mbswidth, mbsnwidth): Use ANSI C function declarations.
20590         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
20591
20592         * lib/gcd.h (PARAMS): Remove macro.
20593         (gcd): Use ANSI C function declarations.
20594         * lib/gcd.c (gcd): Likewise.
20595
20596 2002-11-15  Bruno Haible  <bruno@clisp.org>
20597
20598         * lib/strcspn.c: Include <stddef.h>.
20599         (strcspn): Use ANSI C function declaration. Change return type to
20600         size_t. Use NULL.
20601         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
20602         (strpbrk): Use NULL.
20603         * lib/strpbrk.h (PARAMS): Remove macro.
20604         (strpbrk): Use ANSI C function declaration.
20605         * lib/strstr.c: Don't include <sys/types.h>.
20606         * lib/strstr.h (PARAMS): Remove macro.
20607         (strstr): Use ANSI C function declarations.
20608
20609 2002-11-14  Karl Berry  <karl@gnu.org>
20610
20611         * config/mkinstalldirs: `do' on separate line, instead of
20612         `for var; do'.
20613
20614 2002-11-06  Bruno Haible  <bruno@clisp.org>
20615
20616         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
20617         * lib/gcd.c (gcd): Likewise.
20618
20619 2002-11-05  Bruno Haible  <bruno@clisp.org>
20620
20621         * lib/gcd.h: New file, from gettext-0.11.5.
20622         * lib/gcd.c: New file, from gettext-0.11.5.
20623
20624 2002-11-05  Bruno Haible  <bruno@clisp.org>
20625
20626         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20627         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20628         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20629         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
20630
20631         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
20632         <libintl.h>.
20633         * lib/makepath.c: Include gettext.h instead of <locale.h> and
20634         <libintl.h>.
20635
20636         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
20637         * lib/human.c: Include gettext.h instead of <libintl.h>.
20638         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
20639         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
20640         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
20641         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
20642         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
20643         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
20644         (textdomain): Remove definition.
20645         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
20646
20647         * lib/long-options.c: Remove include of <libintl.h> and definition of
20648         _.
20649         * lib/same.c: Remove include of <libintl.h> and definition of _.
20650
20651 2002-11-04  Owen Taylor  <otaylor@redhat.com>
20652
20653         * lib/config.charset: A few additions for Solaris.
20654
20655 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20656
20657         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
20658         * lib/localcharset.c (locale_charset): Declare as extern "C".
20659
20660 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
20661
20662         * lib/config.charset: msdos in uk_UA uses CP1125.
20663
20664 2002-11-04  Bruno Haible  <bruno@clisp.org>
20665
20666         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
20667         * lib/strcase.h: New file, from GNU gettext-0.11.5.
20668         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
20669         * lib/strstr.h: New file, from GNU gettext-0.11.5.
20670         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
20671
20672 2002-11-04  Bruno Haible  <bruno@clisp.org>
20673
20674         * lib/localcharset.c (locale_charset): Don't return an empty string.
20675
20676 2002-11-04  Bruno Haible  <bruno@clisp.org>
20677
20678         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
20679         aliases.
20680
20681 2002-11-04  Bruno Haible  <bruno@clisp.org>
20682
20683         * lib/config.charset: Update for newest glibc. Add canonical names
20684         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
20685
20686 2002-11-04  Bruno Haible  <bruno@clisp.org>
20687
20688         * lib/config.charset: Add support for NetBSD.
20689
20690 2002-11-04  Bruno Haible  <bruno@clisp.org>
20691
20692         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
20693
20694 2002-11-01  Bruno Haible  <bruno@clisp.org>
20695
20696         * configure.in: Add AC_CONFIG_AUX_DIR call.
20697         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
20698         test/Makefile.
20699         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
20700
20701 2002-09-28  Karl Berry  <karl@gnu.org>
20702
20703         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
20704         installed automake until the next release, since changes have been
20705         made.
20706
20707 2002-09-25  Karl Berry  <karl@gnu.org>
20708
20709         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
20710         * lib/getopt*: copy from libc/posix.
20711         * lib/gettext.h: copy from gettext.
20712         * lib/.cppi-disable: add strdup.c, gettext.h.
20713
20714 2002-09-25  Karl Berry  <karl@gnu.org>
20715
20716         * config/srclist.txt: enable gettext.h check.
20717         * config/config.{guess,sub}: update from prep.
20718         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
20719                 from automake 1.6.3.
20720         See srclist*.
20721
20722 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
20723
20724         * regex.c (PATFETCH): Remove the translating fetch.
20725         (PATFETCH_RAW): Rename to PATFETCH.
20726         (set_image_of_range): New fun.
20727         (SET_RANGE_TABLE_WORK_AREA): Use it.
20728         (regex_compile): Don't translate the pattern chars so eagerly.
20729         Only do it when inserting an `exactn' bytecode or when handling
20730         a char-range.
20731         (mutually_exclusive_p): Avoid empty statement.
20732
20733 2002-07-06  Jim Meyering  <meyering@lucent.com>
20734
20735         * m4/README: Don't mention Makefile.am.in.
20736         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
20737
20738 2002-07-01  Jim Meyering  <meyering@lucent.com>
20739
20740         * lib/c-stack.c: Include sys/time.h.
20741         From Volker Borchert.
20742
20743 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20744
20745         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
20746
20747 2002-06-26  Paul Eggert  <eggert@twinsun.com>
20748
20749         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
20750         New macro.  Use it uniformly instead of
20751         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
20752         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
20753         reported by Vin Shelton.
20754
20755 2002-06-22  Paul Eggert  <eggert@twinsun.com>
20756
20757         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
20758         Do not assume SA_SIGINFO behavior.
20759         Bug reported by Jim Meyering on NetBSD 1.5.2.
20760
20761 2002-06-22  Jim Meyering  <meyering@lucent.com>
20762
20763         * m4/c-stack.m4: New file, from diffutils-2.8.2.
20764         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
20765
20766         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
20767         now that configure.ac uses AC_GNU_SOURCE.
20768         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
20769         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
20770
20771         Update to latest tools.  Suggestions from Paul Eggert.
20772         * m4/stdbool.m4: New file, from diffutils-2.8.2.
20773         * m4/gnu-source.m4: Update from diffutils-2.8.2.
20774         * m4/fnmatch.m4: Likewise.
20775         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
20776         to AC_HEADER_STDBOOL
20777
20778 2002-06-22  Jim Meyering  <meyering@lucent.com>
20779
20780         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
20781         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
20782
20783 2002-06-22  Jim Meyering  <meyering@lucent.com>
20784
20785         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
20786
20787         * lib/exitfail.c, exitfail.h: Likewise.
20788         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
20789
20790         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
20791         of fnmatch.h.
20792         (EXTRA_DIST): Add fnmatch_loop.c.
20793         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
20794
20795         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
20796         * lib/fnmatch.c: Update from diffutils-2.8.2.
20797         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
20798         * lib/fnmatch.h: Remove file.
20799
20800 2002-06-21  Jim Meyering  <meyering@lucent.com>
20801
20802         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
20803         * m4/mbrtowc.m4: Likewise.
20804
20805         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
20806         * m4/mbswidth.m4: Reflect name change:
20807         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
20808         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
20809
20810         * m4/lib-link.m4: Update from gettext-0.11.2.
20811         * m4/gettext.m4: Likewise.
20812
20813         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
20814         From Alfred M. Szmidt.
20815
20816 2002-06-18  Paul Eggert  <eggert@twinsun.com>
20817
20818         * lib/file-type.h: Report an error if neither S_ISREG nor
20819         S_IFREG is defined, instead of using a test specific to glibc
20820         2.2.  This should be safe, since POSIX requires S_ISREG and
20821         Unix Version 7 had S_IFREG.  We don't need to check for
20822         <sys/types.h> since we don't use any symbols that it defines.
20823
20824 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
20825
20826         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
20827         $@-t, so that each temporary file name is unique and valid in the first
20828         8 characters, for operation under DOS.
20829
20830 2002-06-15  Paul Eggert  <eggert@twinsun.com>
20831
20832         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
20833
20834 2002-06-15  Jim Meyering  <meyering@lucent.com>
20835
20836         Work even with DJGPP 2.03, which lacks support for symlinks.
20837         From Richard Dawe.
20838         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
20839         is defined.
20840         * lib/lchown.c (S_ISLNK): Likewise.
20841
20842 2002-06-15  Jim Meyering  <meyering@lucent.com>
20843
20844         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
20845         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
20846         have been included before this file.
20847
20848 2002-06-14  Jim Meyering  <meyering@lucent.com>
20849
20850         * lib/file-type.h: Use the version from diffutils-2.8.2.
20851         * lib/file-type.c: Likewise.
20852
20853 2002-06-07  Jim Meyering  <meyering@lucent.com>
20854
20855         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
20856         They're needed at least for NetBSD 1.5.2.
20857         ($statxfs_includes): Include those same headers.
20858         ($statxfs_includes): Include sys/vfs.h if available.
20859         ($statxfs_includes): Likewise for sys/statvfs.h.
20860         Check for the following members in both structs statfs and statvfs:
20861         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
20862
20863 2002-06-01  Jim Meyering  <meyering@lucent.com>
20864
20865         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
20866         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
20867
20868 2002-05-28  Jim Meyering  <meyering@lucent.com>
20869
20870         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
20871         Reported by Volker Borchert.
20872
20873 2002-05-27  Jim Meyering  <meyering@lucent.com>
20874
20875         Fix a problem seen only on nonconforming systems whereby ls.c's
20876         use of localtime, and then of gettimeofday would cause trouble:
20877         the localtime call used to initialize rpl_gettimeofday's save
20878         mechanism would clobber ls's current local time information so
20879         that in any long listing the first file would always be listed
20880         with date 1970-01-01.  Analysis by Volker Borchert.
20881
20882         * lib/gettimeofday.c (localtime): Undefine.
20883         (rpl_localtime): New function.
20884
20885 2002-05-27  Jim Meyering  <meyering@lucent.com>
20886
20887         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
20888         localtime.
20889
20890         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
20891         use the replacement function; it wouldn't resolve at link time.
20892         Reported by Volker Borchert.
20893
20894 2002-05-22  Jim Meyering  <meyering@lucent.com>
20895
20896         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
20897         file-type.h.
20898         * lib/file-type.h: New file.
20899         * lib/file-type.c (file_type): New file/function.  Extracted from
20900         diffutils.
20901
20902 2002-04-30  Jim Meyering  <meyering@lucent.com>
20903
20904         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
20905
20906 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20907
20908         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
20909
20910 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20911
20912         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
20913         Do not check for alloca.h (no longer used) or stdbool.h (was never
20914         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
20915
20916 2002-04-29  Paul Eggert  <eggert@twinsun.com>
20917
20918         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
20919
20920 2002-04-29  Jim Meyering  <meyering@lucent.com>
20921
20922         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
20923         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
20924         Use AC_FUNC_STRNLEN here instead.
20925
20926         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
20927         With autoconf-2.53a, it's part of AC_PROG_CC.
20928
20929 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20930
20931         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
20932         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
20933
20934 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20935
20936         * lib/sig2str.h, lib/sig2str.c: New files.
20937         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
20938
20939 2002-04-28  Paul Eggert  <eggert@twinsun.com>
20940
20941         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
20942         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
20943         of 127, since 64 is the largest conceivable number for ancient
20944         nonstandard hosts.
20945         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
20946
20947 2002-04-28  Jim Meyering  <meyering@lucent.com>
20948
20949         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
20950
20951 2002-04-24  Jim Meyering  <meyering@lucent.com>
20952
20953         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
20954         (jm_PREREQ): Use it.
20955
20956         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
20957         mach/mach.h fcntl.h.
20958         Check for this function: setlocale.
20959
20960 2002-04-24  Jim Meyering  <meyering@lucent.com>
20961
20962         * lib/gettext.h: New file, from Gettext.
20963         * lib/Makefile.am (INCLUDES): Remove -I../intl.
20964         (libfetish_a_SOURCES): Add gettext.h.
20965
20966 2002-04-16  Jim Meyering  <meyering@lucent.com>
20967
20968         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
20969         ut_pid, ut_id, ut_exit.
20970
20971 2002-04-16  Jim Meyering  <meyering@lucent.com>
20972
20973         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
20974         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
20975         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
20976
20977 2002-04-12  Jim Meyering  <meyering@lucent.com>
20978
20979         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
20980         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
20981         existence of the getmntinfo function.  Needed for Darwin 5.3.
20982
20983         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
20984         This is necessary at least on Darwin 5.3.
20985
20986         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
20987         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
20988         strnlen.o in the library, and that makes some versions of ranlib
20989         object.
20990
20991 2002-04-12  Jim Meyering  <meyering@lucent.com>
20992
20993         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
20994
20995 2002-04-09  Jim Meyering  <meyering@lucent.com>
20996
20997         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
20998         to be more precise.  Rather than saying we're checking whether the
20999         function `works', say what we're testing.
21000         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
21001         Reported by Bruno Haible.
21002
21003 2002-03-10  Jim Meyering  <meyering@lucent.com>
21004
21005         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
21006         Suggestion from Santiago Vila.
21007
21008 2002-03-08  Jim Meyering  <meyering@lucent.com>
21009
21010         * lib/rename.c: Mention that this wrapper is needed also on
21011         mips-dec-ultrix4.4 systems.
21012
21013 2002-03-02  Jim Meyering  <meyering@lucent.com>
21014
21015         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
21016         not HAVE_CLOCK_SETTIME.
21017
21018 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21019
21020         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
21021         Check for clock_settime.
21022
21023 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21024
21025         * lib/nanosleep.h: Rename to....
21026         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
21027
21028         * lib/gettime.c: New file.
21029         * lib/settime.c: New file.
21030         * lib/stime.c: Remove.
21031
21032         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
21033         timespec.h.  Remove nanosleep.h.
21034
21035 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21036
21037         * m4/acl.m4: New file.
21038         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
21039         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
21040
21041 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21042
21043         * lib/acl.c, lib/acl.h: New files.
21044         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
21045
21046 2002-02-24  Jim Meyering  <meyering@lucent.com>
21047
21048         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
21049         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
21050         cause trouble.  Reported by Nelson Beebe.
21051
21052 2002-02-23  Paul Eggert  <eggert@twinsun.com>
21053
21054         * lib/path-concat.c (xpath_concat): Reorder code to pacify
21055         compilers that don't know that xalloc_die never returns.
21056
21057 2002-02-20  Jim Meyering  <meyering@lucent.com>
21058
21059         * lib/getdate.c: Regenerate using bison-1.33.
21060
21061 2002-02-17  Jim Meyering  <meyering@lucent.com>
21062
21063         * config/config.guess (main): Don't use `head -1'; it's no longer
21064         portable. Use `sed 1q' instead.
21065
21066 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
21067
21068         * m4/codeset.m4: Upgrade to gettext-0.11.
21069         * m4/gettext.m4: Upgrade to gettext-0.11.
21070         * m4/glibc21.m4: Upgrade to gettext-0.11.
21071         * m4/iconv.m4: Upgrade to gettext-0.11.
21072         * m4/isc-posix.m4: Upgrade to gettext-0.11.
21073         * m4/lcmessage.m4: Upgrade to gettext-0.11.
21074         * m4/lib-ld.m4: New file, from gettext-0.11.
21075         * m4/lib-link.m4: New file, from gettext-0.11.
21076         * m4/lib-prefix.m4: New file, from gettext-0.11.
21077         * m4/progtest.m4: Upgrade to gettext-0.11.
21078
21079 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21080
21081         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
21082         (jm_PREREQ): Use it.
21083
21084 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21085
21086         * lib/posixver.c, lib/posixver.h: New files.
21087         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21088
21089 2002-02-02  Paul Eggert  <eggert@twinsun.com>
21090             Bruno Haible  <bruno@clisp.org>
21091
21092         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
21093         (fwrite_success_callback): New declaration.
21094         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
21095         print_unicode_char. Call failure callback instead of error.
21096         (fwrite_success_callback): New function.
21097         (exit_failure_callback): New function.
21098         (fallback_failure_callback): New function.
21099         (print_unicode_char): Call unicode_to_mb.
21100
21101 2002-01-26  Jim Meyering  <meyering@lucent.com>
21102
21103         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
21104         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
21105
21106 2002-01-26  Jim Meyering  <meyering@lucent.com>
21107
21108         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
21109
21110 2002-01-22  Paul Eggert  <eggert@twinsun.com>
21111
21112         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
21113
21114 2002-01-22  Jim Meyering  <meyering@lucent.com>
21115
21116         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
21117         Otherwise, some versions of automake would omit the rule that makes
21118         Makefile from Makefile.in.
21119
21120 2002-01-21  Paul Eggert  <eggert@twinsun.com>
21121
21122         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
21123         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21124         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
21125         (memcoll): Set errno to zero if there is no error.
21126
21127         * lib/quotearg.c (quotearg_buffer_restyled):
21128         Fix bug with quoting buffers containing NUL when backslashing escapes.
21129         This bug was exposed by the other changes in this patch.
21130         (quotearg_n_options): New arg ARGSIZE.
21131         All callers changed.
21132         (quoting_options_from_style): New function.
21133         (quotearg_n_style): Use it.
21134         (quotearg_n_style_mem): New function.
21135
21136         * lib/quotearg.h (quotearg_n_style_mem): New function.
21137
21138 2002-01-19  Jim Meyering  <meyering@lucent.com>
21139
21140         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
21141         Remove useless quotes: DF_PROG="df".
21142         * m4/strnlen.m4: New file.
21143
21144 2002-01-16  Paul Eggert  <eggert@twinsun.com>
21145
21146         * lib/backupfile.c (ISDIGIT): Comment fix.
21147         * lib/getdate.y (ISDIGIT): Likewise.
21148         * lib/posixtm.c (ISDIGIT, year): Likewise.
21149         * lib/strverscmp.c (ISDIGIT): Likewise.
21150         * lib/userspec.c (ISDIGIT): Likewise.
21151
21152 2002-01-16  Jim Meyering  <meyering@lucent.com>
21153
21154         * lib/getdate.y: Add three semicolons, each just before a closing
21155         brace. Bison (as of version 1.31) no longer papers over that mistake.
21156
21157 2002-01-05  Jim Meyering  <meyering@lucent.com>
21158
21159         * lib/version-etc.c (version_etc_copyright): Update copyright year.
21160
21161 2001-12-19  Paul Eggert  <eggert@twinsun.com>
21162
21163         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
21164         not silently exit merely because the output buffer happens to
21165         have nothing pending.
21166
21167 2001-12-18  Paul Eggert  <eggert@twinsun.com>
21168
21169         See the big note in ../ChangeLog.
21170         * lib/human.c (suffixes): Prefer K to k for 1024.
21171         (generate_suffix_backwards): New function.
21172         (human_readable_inexact): Use it.
21173         * lib/xstrtol.c (__xstrtol): If there is no number but there
21174         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
21175         Accept 'K' as well as 'k'.
21176
21177 2001-12-15  Jim Meyering  <meyering@lucent.com>
21178
21179         * lib/regex.h (__restrict_arr): Update from libc.
21180
21181         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
21182         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
21183         (STREQ): Define.
21184
21185 2001-12-14  Jim Meyering  <meyering@lucent.com>
21186
21187         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
21188         Suggestion from Bruno Haible.
21189
21190 2001-12-10  Jim Meyering  <meyering@lucent.com>
21191
21192         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
21193         xrealloc, Instead, include "xalloc.h".
21194         (initbuffer): Don't cast xmalloc return value to char*.
21195         (readline): Reword comment.
21196         Don't cast xrealloc return value to char*
21197         Return NULL, not 0.
21198
21199 2001-12-09  Jim Meyering  <meyering@lucent.com>
21200
21201         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
21202         about `signed and unsigned type in conditional expression'.
21203         * lib/posixtm.c (posix_time_parse): Likewise.
21204
21205         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
21206
21207         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
21208         to avoid a pedantic warning.
21209
21210         * lib/getstr.c: Don't include assert.h.
21211         (getstr): Remove warning-evoking assertions.
21212         Return -1 if offset parameter is out of bounds.
21213         Change the type of a local from int to size_t.
21214
21215         * lib/strftime.c (my_strftime_localtime_r): Include this function
21216         definition in the `#if ! HAVE_TM_GMTOFF' block.
21217
21218         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
21219         Include xalloc.h instead.
21220
21221 2001-12-02  Jim Meyering  <meyering@lucent.com>
21222
21223         * lib/tempname.c: Don't declare getenv, thus reverting the change of
21224         2001-11-18.  It's no longer necessary, now that stdlib.h is always
21225         included.
21226
21227         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
21228         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
21229
21230 2001-11-30  Akim Demaille  <akim@epita.fr>
21231
21232         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
21233         before being defined.
21234
21235 2001-11-27  Paul Eggert  <eggert@twinsun.com>
21236
21237         * lib/quotearg.h (quotearg_n, quotearg_n_style):
21238         First arg is int, not unsigned.
21239         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
21240         (SIZE_MAX, UINT_MAX): New macros.
21241         (quotearg_n_options): Abort if N is negative.
21242         Avoid overflow check on hosts where size_t is 64 bits and int
21243         is 32 bits, as overflow is impossible there.
21244         Fix off-by-one typo that caused unnecessary reallocation.
21245
21246 2001-11-27  Jim Meyering  <meyering@lucent.com>
21247
21248         * lib/tempname.c: Merge with version from libc.
21249         * lib/regex.c: Likewise.
21250
21251         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
21252         systems for which STDC_HEADERS is 0, it was not included, resulting in
21253         a warning about an integer-to-pointer conversion problem with getenv.
21254         Reported by Volker Borchert.
21255
21256 2001-11-26  Jim Meyering  <meyering@lucent.com>
21257
21258         * lib/gtod.h: Remove file.
21259         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
21260         * lib/gettimeofday.c: Don't include gtod.h.
21261         (GTOD_init): Remove function.
21262         (rpl_gettimeofday): Do its job here instead, rather than aborting.
21263         Suggestion from Volker Borchert.
21264
21265 2001-11-23  Jim Meyering  <meyering@lucent.com>
21266
21267         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
21268         it.
21269         * lib/hash.c (struct hash_table): Define it here instead.
21270
21271 2001-11-22  Jim Meyering  <meyering@lucent.com>
21272
21273         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
21274
21275 2001-11-20  Jim Meyering  <meyering@lucent.com>
21276
21277         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
21278         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
21279
21280 2001-11-19  Jim Meyering  <meyering@lucent.com>
21281
21282         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
21283         directory.  Use "conftestXXXXXX" as the template.
21284         Suggestion from Paul Eggert.
21285
21286         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
21287         immediately, so the test doesn't mistakenly hit the max-open-files
21288         limit.
21289
21290 2001-11-18  Paul Eggert  <eggert@twinsun.com>
21291
21292         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
21293         (TEMPORARIES): New macro.
21294         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
21295         removes an artificial limitation (e.g. HP-UX 10.20, where
21296         TMP_MAX is 17576).
21297
21298 2001-11-18  Jim Meyering  <meyering@lucent.com>
21299
21300         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
21301
21302 2001-11-18  Jim Meyering  <meyering@lucent.com>
21303
21304         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
21305         on SunOS 4.
21306
21307         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
21308         files will be created before anything else.
21309
21310 2001-11-17  Paul Eggert  <eggert@twinsun.com>
21311
21312         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
21313         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
21314
21315 2001-11-17  Jim Meyering  <meyering@lucent.com>
21316
21317         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
21318         Prompted by a report from Bob Proulx.
21319
21320         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
21321         Instead, require UTILS_FUNC_MKSTEMP.
21322
21323 2001-11-17  Jim Meyering  <meyering@lucent.com>
21324
21325         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
21326         Now, that's done as part of AC_FUNC_STRTOD.
21327
21328 2001-11-17  Jim Meyering  <meyering@lucent.com>
21329
21330         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
21331         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
21332         rather than group writable.  Patch by Juan F. Codagnone.
21333
21334         * lib/readtokens.c: Remove explicit declarations of xmalloc and
21335         xrealloc, Instead, include "xalloc.h".
21336
21337         * lib/mountlist.c: Include unlocked-io.h after all system headers.
21338         Remove explicit declarations of xmalloc, xrealloc,
21339         and xstrdup.  Instead, include "xalloc.h".
21340
21341         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
21342         unlocked-io.h.
21343         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
21344         Likewise.
21345         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
21346
21347         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
21348         Reported by Padraig Brady.
21349
21350         * lib/mkstemp.c: #undef mkstemp.
21351         Include config.h.
21352         (rpl_mkstemp): Rename from mkstemp.
21353         Protoize.
21354
21355 2001-11-16  Jim Meyering  <meyering@lucent.com>
21356
21357         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
21358         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
21359         determine the amount of total physical memory, use pstat_getstatic.
21360         HPUX-11 doesn't define _SC_PHYS_PAGES.
21361         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
21362         If sysconf couldn't be used to determine the amount of available
21363         physical memory, use both pstat_getstatic and pstat_getdynamic.
21364         Based on a patch from Bob Proulx.
21365
21366 2001-11-10  Jim Meyering  <meyering@lucent.com>
21367
21368         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
21369         (jm_PREREQ): Use it.
21370
21371 2001-11-09  Jim Meyering  <meyering@lucent.com>
21372
21373         * m4/jm-macros.m4: Require autoconf-2.52f.
21374         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
21375         Use these AC_-prefixed names, not the AM_-prefixed ones.
21376
21377         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
21378
21379 2001-11-05  Jim Meyering  <meyering@lucent.com>
21380
21381         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
21382
21383 2001-11-04  Jim Meyering  <meyering@lucent.com>
21384
21385         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
21386         $DEFS.
21387
21388 2001-11-03  Jim Meyering  <meyering@lucent.com>
21389
21390         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
21391         of AC_DEFUN.
21392
21393         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
21394         know the name of the variable in the macro definition.
21395
21396 2001-11-03  Jim Meyering  <meyering@lucent.com>
21397
21398         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
21399         in argmatch_to_argument call.
21400
21401         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
21402         argument.
21403
21404         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
21405         e.g., a fault due to an attempt to free a NULL pointer.
21406
21407 2001-11-01  Jim Meyering  <meyering@lucent.com>
21408
21409         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
21410         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
21411
21412 2001-11-01  Jim Meyering  <meyering@lucent.com>
21413
21414         * lib/dirfd.c, lib/dirfd.h: New files.
21415         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
21416
21417         * lib/hash.c (hash_print) [TESTING]: Clean up.
21418
21419 2001-10-22  Paul Eggert  <eggert@twinsun.com>
21420
21421         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
21422         to avoid a warning if -Wall.
21423
21424 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
21425
21426         * README: New file
21427         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
21428         (per RMS's instructions, this is now the canonical source)
21429         * lgpl/, gpl/: New directories.
21430
21431 2001-10-21  Paul Eggert  <eggert@twinsun.com>
21432
21433         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
21434
21435 2001-10-21  Jim Meyering  <meyering@lucent.com>
21436
21437         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
21438         this code would end up calling gettext even in packages built
21439         with --disable-nls.
21440         * lib/getopt.c (_): Likewise.
21441         * lib/regex.c (_): Likewise.
21442
21443 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21444
21445         * m4/error.m4 (jm_PREREQ_ERROR):
21446         Do not invoke AC_CHECK_FUNCS with strerror_r, as
21447         AC_FUNC_STRERROR_R does that.
21448         Check for strerror declaration.
21449
21450         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
21451         are supposed to have them these days.
21452         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
21453         Merge changes from latest Autoconf CVS.
21454         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
21455         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
21456         POSIX decided to standardize on the int flavor of strerror_r.
21457
21458 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21459
21460         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
21461         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
21462         Use strerror_r that is only a macro, even if it is not a function.
21463         (strerror): Check for HAVE_DECL_STRERROR before declaring.
21464         (private_strerror): Use prototypes, not old-style function definition.
21465         (print_errno_message): New function.
21466         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
21467         char*-flavored one.
21468         (error_tail, error, error_at_line): Use it.
21469
21470 2001-10-11  Jim Meyering  <meyering@lucent.com>
21471
21472         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
21473         and quote_n (1, ... to avoid clobbering a buffer.
21474
21475 2001-10-05  Jim Meyering  <meyering@lucent.com>
21476
21477         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
21478         hash-pjw.h.
21479         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
21480         * lib/hash-pjw.h: New file.
21481
21482 2001-09-30  Jim Meyering  <meyering@lucent.com>
21483
21484         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
21485         `struct fsstat' has the `f_fstypename' member.
21486         Use that to define FS_TYPE, which is now used to make
21487         the getfsstat link test tighter.
21488
21489 2001-09-30  Jim Meyering  <meyering@lucent.com>
21490
21491         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
21492         Include <sys/ucred.h>, for Apple Darwin.
21493         Include sys/mount.h and sys/fs_types.h only if available.
21494         (FS_TYPE): Define.
21495         (read_filesystem_list): Use FS_TYPE.
21496
21497 2001-09-29  Paul Eggert  <eggert@twinsun.com>
21498
21499         * lib/exclude.c (excluded_filename): 0 -> false, since it's
21500         a boolean context.
21501
21502 2001-09-29  Jim Meyering  <meyering@lucent.com>
21503
21504         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21505         [one-argument getmntent function]): Include stdio.h before mntent.h.
21506         SunOS 4.1.x needs it for the declaration of `FILE'.
21507         Patch by Volker Borchert.
21508
21509         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21510         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
21511         sys/fs_types.h, and make the link-test for getfsstat guard #include
21512         directives with appropriate #if HAVE_*_H tests so that we can
21513         detect getfsstat on Apple Darwin1.3.7 systems.
21514         Reported by Nelson Beebe.
21515         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
21516
21517 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21518
21519         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21520         #defines strtoimax.  Also treat the other strto* functions
21521         like strtoimax.
21522
21523         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21524         Check for strtoul and strtoumax,
21525         as those declarations are made even in the signed case.
21526         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
21527         Likewise, for strtol and strtoimax.
21528
21529 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21530
21531         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21532         #defines strtoimax.  Also treat the other strto* functions
21533         like strtoimax.
21534
21535         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
21536         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
21537         (strtoimax, strtoumax): Do not declare if already defined as a macro.
21538
21539 2001-09-26  Jim Meyering  <meyering@lucent.com>
21540
21541         Most macros in unlocked-io.h had the wrong number of arguments.
21542         * lib/gen-uio: New script.
21543         (USE_UNLOCKED_IO): Define to 1 if not already defined.
21544         * lib/unlocked-io.hin: Remove file.
21545         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
21546         rather than trying to embed it here.
21547         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
21548         Reported by Padraig Brady.
21549
21550 2001-09-25  Volker Borchert  <bt@teknon.de>
21551
21552         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
21553         `result'.
21554
21555 2001-09-24  Jim Meyering  <meyering@lucent.com>
21556
21557         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
21558
21559 2001-09-23  Jim Meyering  <meyering@lucent.com>
21560
21561         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
21562         instead of the mere test for existence of mntent.h.  The latter
21563         would get a false-positive on AIX 3.4 systems.
21564         In the outer getmntent if-block, don't die if neither of the getmntent
21565         tests succeeds.  Instead, just fall through and continue with the
21566         remaining tests.
21567
21568 2001-09-23  Jim Meyering  <meyering@lucent.com>
21569
21570         * lib/mountlist.c: Remove useless parentheses in #if directives.
21571         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
21572         the deprecated MOUNTED symbol is no longer defined in mntent.h.
21573
21574 2001-09-22  Jim Meyering  <meyering@lucent.com>
21575
21576         * m4/gettext.m4: New file.  From gettext.
21577         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
21578         * m4/progtest.m4: Likewise
21579         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
21580         * m4/glibc21.m4: Likewise.
21581
21582         * m4/libintl.m4: Remove.  No longer used.
21583
21584 2001-09-22  Jim Meyering  <meyering@lucent.com>
21585
21586         * lib/localcharset.c: Update from latest gettext.
21587         * lib/config.charset: Likewise.
21588
21589 2001-09-20  Jim Meyering  <meyering@lucent.com>
21590
21591         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
21592         strtoimax.
21593         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
21594         strtoumax.
21595
21596 2001-09-20  Jim Meyering  <meyering@lucent.com>
21597
21598         * lib/xstrtol.c (strtoimax): Guard declaration with
21599         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
21600         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
21601         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
21602         (strtoumax): Likewise, for completeness (it wasn't necessary).
21603
21604 2001-09-17  Paul Eggert  <eggert@twinsun.com>
21605
21606         * lib/strtoimax.c (HAVE_LONG_LONG):
21607         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
21608         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
21609         to work around bug in IBM C compiler.
21610
21611 2001-09-17  Jim Meyering  <meyering@lucent.com>
21612
21613         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
21614         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
21615         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
21616         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
21617         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
21618         whenever the right hand side need not be expanded by the shell.
21619
21620 2001-09-16  Paul Eggert  <eggert@twinsun.com>
21621
21622         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
21623         library.  It's not correct, as some older glibcs are buggy.
21624         fnmatch wasn't fixed until glibc 2.2.
21625
21626         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
21627         special shell magic here.
21628
21629 2001-09-16  Jim Meyering  <meyering@lucent.com>
21630
21631         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
21632         * m4/jm-macros.m4: Require it.
21633
21634 2001-09-16  Jim Meyering  <meyering@lucent.com>
21635
21636         * lib/mkdir.c: New file.
21637
21638 2001-09-15  Jim Meyering  <meyering@lucent.com>
21639
21640         * m4/jm-macros.m4: Check for help2man.
21641
21642 2001-09-11  Jim Meyering  <meyering@lucent.com>
21643
21644         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
21645         The body, by Paul Eggert, was moved here from configure.in.
21646         * m4/jm-macros.m4: Require UTILS_HOST_OS.
21647
21648 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21649
21650         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
21651         (jm_PREREQ): Use it.
21652
21653 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21654
21655         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
21656         Use ssize_t, not int, to store result of readlink.
21657         Check for ssize_t overflow as well as size_t overflow,
21658         as POSIX says the result of readlink is implementation-defined
21659         when ssize_t overflows.
21660         Remove unnecessary cast to char*.
21661         Use free+malloc instead of realloc, as the storage doesn't need
21662         to be preserved and it's clearer and can be more efficient that way.
21663         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
21664         * lib/xreadlink.h (xreadlink): Update prototype.
21665
21666 2001-09-04  Paul Eggert  <eggert@twinsun.com>
21667
21668         * lib/xgetcwd.c: Revert some of the previous change; intead,
21669         fix the HAVE_GETCWD_NULL code to behave more like the
21670         !HAVE_GETCWD_NULL code used to.
21671
21672         Include "xalloc.h".
21673         (xgetcwd): Do not return NULL when memory is exhausted; instead,
21674         invoke xalloc_die.
21675
21676 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21677
21678         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
21679         sys/param.h, as pathmax.h includes them.
21680
21681 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21682
21683         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
21684         (jm_PREREQ_XGETCWD): New macro.
21685
21686         * m4/getcwd.m4: New file.
21687
21688 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21689
21690         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
21691         like the HAVE_GETCWD_NULL code.
21692         Include pathmax.h if not HAVE_GETCWD.
21693         Do not include xalloc.h.
21694         (INITIAL_BUFFER_SIZE): New symbol.
21695         Do not use xmalloc / xrealloc, since the caller is responsible for
21696         handling errors.  Preserve errno around `free' during failure.
21697         Do not overrun buffer when using getwd.
21698
21699 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21700
21701         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
21702         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
21703         getcwd (NULL, 0).
21704
21705 2001-09-03  Paul Eggert  <eggert@twinsun.com>
21706
21707         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
21708         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
21709         spotted by Jim Meyering.
21710
21711 2001-09-03  Jim Meyering  <meyering@lucent.com>
21712
21713         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
21714         failure.
21715
21716 2001-09-02  Jim Meyering  <meyering@lucent.com>
21717
21718         * lib/error.c: Update from GNU libc.
21719
21720 2001-09-01  Jim Meyering  <meyering@lucent.com>
21721
21722         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
21723         Used by df.
21724
21725 2001-09-01  Jim Meyering  <meyering@lucent.com>
21726
21727         * lib/xreadlink.c: New file.
21728         * lib/xreadlink.h: New file.
21729         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
21730         xreadlink.h.
21731
21732         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
21733         doesn't conflict with sparc Solaris 7's definition in
21734         /usr/include/sys/int_types.h.
21735
21736         * lib/exclude.c: Use `""', not `<>' to #include non-system header
21737         files.
21738         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
21739         and strncasecmp as r-values.  Unixware didn't have declarations.
21740
21741 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21742
21743         * lib/xstrtol.h: Add copyright notice.
21744         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
21745         LONGINT_INVALID_SUFFIX_CHAR.
21746
21747 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21748
21749         * lib/xstrtol.c (strtoimax): New decl.
21750
21751 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21752
21753         * lib/xgetcwd.c: Don't include pathmax.h.
21754         Include stdlib.h and unistd.h if available.
21755         Include xalloc.h.
21756         (xmalloc, xstrdup, free): Remove decls.
21757         (xgetcwd): Don't assume sizes fit in unsigned.
21758         Check for overflow when computing sizes.
21759         Simplify reallocation code.
21760
21761 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21762
21763         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
21764         a directory's st_size can have an arbitrary value, so the old
21765         usage could waste an arbitrary amount of memory.  All uses
21766         changed.
21767         * lib/savedir.h: Update prototype.
21768
21769 2001-08-31  Paul Eggert  <eggert@twinsun.com>
21770
21771         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
21772
21773         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
21774         old strtoimax.c.
21775
21776         Also, make the following further changes to make this file's
21777         configuration more similar to that of strtol.c:
21778         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
21779         (strtoumax, uintmax_t, strtoull, strtol): Remove.
21780         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
21781         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
21782         changed to signed values.
21783
21784         And make the following changes as well:
21785         Fix copyright notice, as 1999 was missing.
21786         (verify): New macro.
21787         (strtoimax): Check sizes at compile-time, not run-time.
21788         Prefer strtol to strtoll if both work.
21789         (main): Remove; it was not that useful and was a pain to maintain.
21790
21791         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
21792
21793 2001-08-31  Jim Meyering  <meyering@lucent.com>
21794
21795         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
21796         Use an initial, malloc'd, buffer of length 128 rather than
21797         a statically allocated one of length 1024.
21798
21799 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21800
21801         Simplify code, partly by assuming autoconf 2.52 semantics.
21802
21803         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
21804
21805         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
21806         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
21807         All uses removed.
21808         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
21809         Move AC_REQUIRE to next-to-top level, to avoid confusion.
21810         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
21811         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
21812         jm_AC_HEADER_INTTYPES_H.
21813         * m4/jm-macros.m4 (jm_MACROS): Likewise.
21814
21815         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
21816
21817         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21818         Quote first arg of AC_DEFUN.
21819         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
21820         since they are needed to parse the include file even if we need
21821         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
21822         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
21823         but with opposite signedness.
21824
21825 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21826
21827         Merge 'exclude' changes from tar 1.13.22.
21828         This fixes one or two unlikely storage allocation overflow bugs,
21829         but doesn't change user-visible behavior otherwise.
21830
21831 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21832
21833         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
21834         (jm_PREREQ_EXCLUDE): New macro.
21835
21836 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21837
21838         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
21839         tm to be declared.
21840
21841 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21842
21843         * lib/hash.c: Remove '2001' from copyright notice.
21844
21845 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21846
21847         * lib/full-write.h: New file.
21848         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
21849         * lib/full-write.c: Correct credits, as cccp.c no longer
21850         exists and anyway it was so heavily changed from the old cccp
21851         code as to be unrecognizable.  Include full-write.h.
21852         (full_write) Return size_t, with short writes meaning failure.
21853         All callers changed.  This fixes a bug with large buffers
21854         on 64-bit hosts.
21855         * lib/utime.c: Include full-write.h.
21856
21857 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21858
21859         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
21860         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
21861         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
21862         Include if available.
21863         (<xalloc.h>): Include
21864         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
21865         (verify): New macro.  Use it to verify that EXCLUDE macros do not
21866         collide with FNM macros.
21867         (struct patopts): New struct.
21868         (struct exclude): Use it, as exclude patterns now come with options.
21869         (new_exclude): Support above changes.
21870         (new_exclude, add_exclude_file):
21871         Initial size must now be a power of two to simplify overflow checking.
21872         (free_exclude, fnmatch_no_wildcards): New function.
21873         (excluded_filename): No longer requires options arg, as the options
21874         are determined by add_exclude.  Now returns bool, not int.
21875         (excluded_filename, add_exclude):
21876         Add support for the fancy new exclusion options.
21877         (add_exclude, add_exclude_file): Now takes int options arg.
21878         Check for arithmetic overflow when computing sizes.
21879         (add_exclude_file): xrealloc might modify errno, so don't
21880         realloc until after errno might be used.
21881
21882         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
21883         New macros.
21884         (free_exclude): New decl.
21885         (add_exclude, add_exclude_file): Now takes int options arg.
21886         (excluded_filename): No longer requires options arg, as the options
21887         are determined by add_exclude.  Now returns bool, not int.
21888
21889 2001-08-30  Paul Eggert  <eggert@twinsun.com>
21890
21891         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
21892
21893 2001-08-27  Jim Meyering  <meyering@lucent.com>
21894
21895         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
21896
21897         * lib/version-etc.c (N_): Remove definition.
21898         Revert most of last change.
21899         Instead, simply don't mark the `Copyright...' string for translation.
21900         Based on advice from Paul Eggert.
21901
21902         * lib/strtoxmax.c: Tweak comment.
21903
21904 2001-08-26  Jim Meyering  <meyering@lucent.com>
21905
21906         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
21907
21908         * m4/xstrtoimax.m4: New file.
21909         * m4/xstrtoumax.m4: Add comments explaining why we
21910         AC_REPLACE_FUNCS(strtol).
21911
21912 2001-08-26  Jim Meyering  <meyering@lucent.com>
21913
21914         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
21915         of copyright with `%s' so translators don't get an untranslated
21916         message in 2002.
21917         (COPYRIGHT_YEAR): Define.
21918         (version_etc): Use fprintf rather than fputs.
21919         Suggestion from Ulrich Drepper.
21920
21921         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
21922
21923         * lib/strtoll.c: New file, from GNU libc.
21924         * lib/xstrtoimax.c: New file.
21925
21926         * lib/xstrtol.h: Add xstrtoimax.
21927         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
21928         * lib/strtoimax.c: New file.  Likewise, but first define
21929         STRTOUXMAX_SIGNED.
21930
21931         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
21932         ...
21933         * lib/strtoxmax.c: ... then renamed to this.
21934
21935 2001-08-18  Paul Eggert  <eggert@twinsun.com>
21936
21937         * m4/inttypes.m4: Add AC_PREREQ(2.13).
21938         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
21939         (jm_AC_TYPE_INTMAX_T): New macro.
21940         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
21941
21942         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
21943
21944         * m4/longlong.m4: Renamed from ulonglong.m4.
21945         * m4/inttypes.m4: Renamed from inttypes_h.m4.
21946         * m4/uintmax_t.m4: Removed.
21947
21948 2001-08-13  Paul Eggert  <eggert@twinsun.com>
21949
21950         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
21951         Port to Solaris 8, where 'sed' requires a space after the 'r'
21952         command, and where sh dislikes "$/".  Clean up the spacing a bit.
21953         Redirect output to $tmp just once.
21954
21955 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
21956
21957         * lib/addext.c (<errno.h>): Include.
21958         (errno): Declare if not defined.
21959         (addext): Work correctly when pathconf returns -1 and leaves
21960         errno alone because there is no limit.  Also, work even if
21961         pathconf returns a value greater than SIZE_MAX.
21962
21963 2001-08-12  Jim Meyering  <meyering@lucent.com>
21964
21965         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
21966         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
21967         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
21968         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
21969         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
21970         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
21971         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
21972         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
21973         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
21974         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
21975         utime.m4, utimes.m4, xstrtoumax.m4:
21976         Quote the first argument in each use of AC_DEFUN.
21977
21978 2001-08-12  Jim Meyering  <meyering@lucent.com>
21979
21980         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
21981         Simply `return getcwd (NULL, 0);'.
21982         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
21983         Use 1300 as initial value for length, not PATH_MAX.
21984
21985         * lib/pathmax.h: Clean up cpp syntax.
21986
21987 2001-08-12  Jim Meyering  <meyering@lucent.com>
21988
21989         * lib/gettimeofday.c: New file.
21990         * lib/gtod.h: New file.
21991         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
21992
21993 2001-08-05  Jim Meyering  <meyering@lucent.com>
21994
21995         * m4/jm-macros.m4: Require autoconf-2.52.
21996
21997 2001-08-04  Jim Meyering  <meyering@lucent.com>
21998
21999         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
22000         stmt, to get in sync with glibc.
22001
22002 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22003
22004         The following changes are from gettext 0.10.39 as maintained by
22005         Bruno Haible.
22006
22007         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
22008         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
22009         with inverted sense.  All uses changed.
22010
22011         * lib/mbswidth.c: Don't include <limits.h>.
22012         Include <stdlib.h> and <string.h> unconditionally.
22013         (iswcntrl, mbsinit, ISCNTRL): New macros.
22014         (mbsnwidth): Use K&R style function declarations.
22015         Don't bother checking for MB_LEN_MAX == 1, since the compiler
22016         can optimize it when MB_CUR_MAX == 1.
22017         The width of control characters is zero, not 1.
22018
22019 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22020
22021         The following changes are from gettext 0.10.39 as maintained by
22022         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
22023
22024         * m4/codeset.m4: Upgrade to serial AM1.
22025         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
22026         all uses changed.  Quote first arg of AC_DEFUN.
22027         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
22028
22029         * m4/iconv.m4: Upgrade to serial AM2.
22030         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
22031         Add --with-libconv-prefix.
22032         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
22033         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
22034         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
22035         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
22036         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
22037
22038         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
22039         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
22040         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
22041         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
22042         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
22043         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
22044         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
22045         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
22046         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
22047
22048         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
22049         string.h any more.
22050
22051         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
22052         not the default value.
22053
22054         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
22055         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
22056         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
22057         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
22058         Also check for iswcntrl, used for wcwidth fallback.
22059         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
22060         to Autoconf 2.13.
22061
22062 2001-08-03  Jim Meyering  <meyering@lucent.com>
22063
22064         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
22065         as it was in the original.  Reported by Paul Eggert.
22066
22067 2001-07-16  Jim Meyering  <meyering@lucent.com>
22068
22069         * m4/gettimeofday.m4: New file.
22070         Prompted by a report from Bernhard Baehr.
22071
22072 2001-07-15  Jim Meyering  <meyering@lucent.com>
22073
22074         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
22075         stuff. Now it's in ../Makefile.cfg.
22076
22077 2001-07-15  Jim Meyering  <meyering@lucent.com>
22078
22079         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
22080         (BUILT_SOURCES): Add unlocked-io.h.
22081         (io_functions): Define.
22082         (unlocked-io.h): New rule.
22083         (DISTCLEANFILES): Add unlocked-io.h.
22084         (all-local): Depend on unlocked-io.h, to ensure it is created.
22085
22086         * lib/unlocked-io.hin: New file
22087
22088         * lib/regex.c: Update from glibc.
22089
22090 2001-07-05  Jim Meyering  <meyering@lucent.com>
22091
22092         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
22093         recommendation.
22094         (libfetish_a_SOURCES): Put all .h files here instead.
22095         Remove a thus-exposed (better checks in automake) duplicate and
22096         two unnecessary .h files.
22097
22098 2001-07-04  Jim Meyering  <meyering@lucent.com>
22099
22100         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
22101         that generates jm-glibc-io.m4 so that it doesn't trigger any make
22102         distcheck failure.
22103
22104 2001-07-02  Jim Meyering  <meyering@lucent.com>
22105
22106         The following changes were prompted by suggestions from Bruno Haible.
22107
22108         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
22109         is now generated.
22110         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
22111         definition of EXTRA_DIST.
22112         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
22113         ensure that the generated file is created/updated whenever the list
22114         of $(unlocked_functions) is changed.
22115         (jm-glibc-io.m4): New rule.
22116         (unlocked-io.h): New rule -- currently unused.
22117
22118 2001-06-24  Jim Meyering  <meyering@lucent.com>
22119
22120         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
22121         unmatched right bracket, rather than kludging it with an extra,
22122         falsely-matching quote in a comment.  Patch by Akim Demaille.
22123
22124 2001-06-11  Jim Meyering  <meyering@lucent.com>
22125
22126         * lib/regex.c: Update from GNU libc.
22127
22128 2001-05-27  Jim Meyering  <meyering@lucent.com>
22129
22130         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
22131         Check for ut_type in struct utmp.
22132
22133 2001-05-27  Jim Meyering  <meyering@lucent.com>
22134
22135         * lib/readutmp.h (UT_TYPE): Define.
22136
22137 2001-05-24  Jim Meyering  <meyering@lucent.com>
22138
22139         * lib/argmatch.c: Include "quote.h".
22140         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
22141         quote function.  Reported by Göran Uddeborg.
22142
22143 2001-05-22  Jim Meyering  <meyering@lucent.com>
22144
22145         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
22146         now that we use the package-supplied version unconditionally.
22147         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
22148
22149 2001-05-21  Jim Meyering  <meyering@lucent.com>
22150
22151         * m4/regex.m4: Change a couple backticks to single quotes to avoid
22152         shell syntax errors.
22153
22154 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22155
22156         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
22157
22158 2001-05-20  Paul Eggert  <eggert@twinsun.com>
22159
22160         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
22161         Don't bother to check library strftime, since
22162         we'll be using our own my_strftime function anyway.
22163         Define my_strftime instead of strftime.
22164
22165 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
22166
22167         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
22168         which is not yet declared.
22169
22170 2001-05-15  Jim Meyering  <meyering@lucent.com>
22171
22172         * m4/regex.m4: Use proper quoting so brackets appear in the test
22173         program.
22174         Reported by, and with help from, Bruno Haible.
22175
22176 2001-05-13  Jim Meyering  <meyering@lucent.com>
22177
22178         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
22179         undefined.
22180
22181 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22182
22183         dirname code cleanup.  base_name now behaves more compatibly
22184         with POSIX basename when given file names that have trailing
22185         slashes, and similarly for dir_name.  Add new primitives
22186         base_len and dir_len.  Put the directory-name-related decls
22187         into dirname.h.
22188
22189         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
22190         * lib/backupfile.c (base_name): Likewise.
22191         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
22192         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
22193         * lib/makepath.c (strip_trailing_slashes): Likewise.
22194         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
22195         ISSLASH): Likewise.
22196         * lib/rename.c (strip_trailing_slashes): Likewise.
22197         * lib/same.c (base_name): Likewise.
22198         * lib/stripslash.c (ISSLASH): Likewise.
22199
22200         * lib/addext.c: Include <dirname.h> after size_t is defined.
22201         * lib/backupfile.c: Likewise.
22202
22203         * lib/addext.c (addext): Use base_len to trim redundant
22204         trailing slashes instead of doing it ourselves.
22205         But do not trim the last slash if it is not redundant.
22206
22207         * lib/backupfile.c (find_backup_file_name,
22208         max_backup_version): Use base_len instead of rolling it ourselves.
22209         Handle the case of "" and (on DOS) "C:" correctly.
22210
22211         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
22212         needed. Include <string.h>, <dirname.h>.
22213         (base_name): Allow file names ending in slashes, other than names
22214         that are all slashes.  In this case, return the basename followed
22215         by the slashes.  This is more general, and can be used in places
22216         where the original base_name purposely had an assertion failure.
22217         (base_len): New function.
22218
22219         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
22220         Do not include <assert.h>; no longer needed.
22221         Include xalloc.h.
22222         (memrchr): Remove decl.
22223         (dir_name_r): Remove.
22224         (dir_len): Renamed from dirlen.  All callers changed.
22225         Rewrite in terms of base_name, for simplicity and consistency.
22226         (dir_name): Never return NULL.  All callers changed.
22227         Do not include <stdlib.h> in test program; no longer needed.
22228         return 0; is fine for test program.
22229
22230         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
22231         New macros.
22232         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
22233
22234         * lib/path-concat.c (path_concat): Use base_len to compute
22235         base length, not strlen; this means we cannot rely on memcpy
22236         to null-terminate.
22237
22238         * lib/same.c (STREQ): Remove.
22239         (same_name): Handle the case where the basename ends in trailing '/'.
22240
22241         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
22242         a slash was stripped.  Do not strip the last slash after a
22243         file system prefix.
22244
22245 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22246
22247         * lib/Makefile.am (libfetish_a_SOURCES):
22248         Add strftime.c, since we now compile it on all hosts.
22249
22250         * lib/strftime.c (my_strftime):
22251         Define to nstrftime if emacs, but only if my_strftime is not defined.
22252         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
22253         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
22254         Add one more extra argument: a nanoseconds value.
22255         All uses changed.
22256         (ns): New macro.
22257         (my_strftime function): Add %N format.
22258         (emacs_strftimeu): Renamed from emacs_strftime,
22259         with extra ut argument.
22260
22261 2001-05-09  Paul Eggert  <eggert@twinsun.com>
22262
22263         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
22264
22265 2001-04-21  Jim Meyering  <meyering@lucent.com>
22266
22267         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
22268         doesn't interfere.
22269
22270 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22271
22272         * m4/ftruncate.m4: Check for chsize.
22273         Link with ftruncate.o unconditionally if ftruncate is missing.
22274         This was required when cross-compiling to i586-mingw32msvc.
22275
22276 2001-04-08  Jim Meyering  <meyering@lucent.com>
22277
22278         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
22279         recomputed; that's necessary when the offset spans a DST transition.
22280         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
22281
22282 2001-04-02  Jim Meyering  <meyering@lucent.com>
22283
22284         * lib/regex.h, regex.c: Update from GNU libc.
22285
22286 2001-03-24  Jim Meyering  <meyering@lucent.com>
22287
22288         * m4/jm-macros.m4: Require autoconf-2.49d.
22289
22290 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
22291
22292         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
22293
22294 2001-03-19  Paul Eggert  <eggert@twinsun.com>
22295
22296         * lib/version-etc.c (version_etc_copyright): Update to 2001.
22297
22298 2001-03-17  Jim Meyering  <meyering@lucent.com>
22299
22300         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
22301         now that the version in autoconf is equivalent.
22302         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
22303
22304         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
22305         Suggestion from Akim Demaille.
22306
22307         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
22308         (jm_PREREQ_TEMPNAME): New function.
22309
22310 2001-03-16  Paul Eggert  <eggert@twinsun.com>
22311
22312         * lib/tempname.c (uint64_t): Define to uintmax_t if
22313         not defined, and if UINT64_MAX is not defined.
22314         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
22315         Reported by John David Anglin.
22316
22317 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
22318
22319         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
22320         resolve alias if codeset is empty.
22321         * lib/config.charset (BeOS): Use wildcard syntax.
22322
22323 2001-03-13  Jim Meyering  <meyering@lucent.com>
22324
22325         * lib/path-concat.c (path_concat)
22326         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
22327         concatenating e.g., `C:' and `foo'.
22328         From Bruno Haible.
22329
22330 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22331
22332         * lib/localcharset.c (locale_charset): Don't use
22333         setlocale(LC_CTYPE,NULL). Don't return NULL.
22334         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
22335
22336 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22337
22338         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
22339         support for DOS/DJGPP.
22340
22341 2001-03-01  Paul Eggert  <eggert@twinsun.com>
22342
22343         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
22344         lacks mkstemp.  Compile our own tempname.c if we compile our own
22345         mkstemp.c, as mkstemp relies on tempname.
22346
22347 2001-03-01  Jim Meyering  <meyering@lucent.com>
22348
22349         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
22350         AH_VERBATIM really does output its argument verbatim.
22351
22352 2001-02-28  Paul Eggert  <eggert@twinsun.com>
22353
22354         * lib/Makefile.am (libfetish_a_SOURCES):
22355         Add dup-safer.c, fopen-safer.c.
22356         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
22357
22358         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
22359         * lib/unistd-safer.h: New files.
22360
22361 2001-02-25  Paul Eggert  <eggert@twinsun.com>
22362
22363         The mkstemp replacement is taken from glibc 2.2.2, with some
22364         portability fixes for use outside glibc, as follows:
22365
22366         * lib/tempname.c (struct_stat64): New macro.
22367         (direxists, __gen_tempname): Use it.
22368         This avoids a portability problem with Solaris 8.
22369
22370         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
22371         (<stddef.h>, <stdint.h>, <string.h>):
22372         Include only if STDC_HEADERS || _LIBC.
22373         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
22374         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
22375         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
22376         (__set_errno): Define this macro if <errno.h> doesn't.
22377         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
22378         Define these macros if <stdio.h> doesn't.
22379         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
22380         Define these macros if <sys/stat.h>
22381         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
22382         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
22383         __xstat64): Define if not _LIBC.
22384         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
22385         (__gen_tempname): Invoke gettimeofday only if
22386         HAVE_GETTIMEOFDAY || _LIBC;
22387         otherwise, fall back on plain "time".
22388         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
22389
22390         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
22391
22392         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
22393
22394 2001-02-18  Paul Eggert  <eggert@twinsun.com>
22395
22396         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
22397
22398 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22399
22400         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
22401         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
22402         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
22403         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22404
22405 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22406
22407         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
22408         Remove workaround macros for hosts that have mbrtowc but not
22409         mbstate_t, as we now insist on proper declarations for both
22410         before using mbrtowc.
22411
22412 2001-02-17  Jim Meyering  <meyering@lucent.com>
22413
22414         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
22415         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
22416         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
22417         UnixWare 7.1.1.
22418
22419         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
22420         rather than AC_CACHE_VAL.
22421
22422 2001-02-17  Jim Meyering  <meyering@lucent.com>
22423
22424         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
22425         around included file name.
22426
22427         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
22428
22429         * lib/strftime.c: Update from GNU libc (the only changes were to
22430         comments).
22431
22432 2001-02-17  Jim Meyering  <meyering@lucent.com>
22433
22434         * lib/regex.c: Update from libc.
22435
22436 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
22437
22438         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
22439         clash.
22440
22441 2001-02-16  Paul Eggert  <eggert@twinsun.com>
22442
22443         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
22444         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
22445         Reported by Mark Hounschell via Paul Eggert.
22446
22447 2001-02-07  Jim Meyering  <meyering@lucent.com>
22448
22449         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
22450
22451 2001-02-05  Jim Meyering  <meyering@lucent.com>
22452
22453         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
22454         it includes the patch required for `large file' support with at least
22455         HP-UX's 10.20 /bin/cc.
22456
22457 2001-02-03  Jim Meyering  <meyering@lucent.com>
22458
22459         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
22460         AS_IF, now that it works once again (mysteriously).
22461         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22462
22463 2001-01-30  Jim Meyering  <meyering@lucent.com>
22464
22465         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
22466         * m4/chown.m4: Rename conftestchown to conftest.chown.
22467         * m4/rename.m4: s/conftestdir/conftest.d1/ and
22468         s/conftestdir2/conftest.d2/.
22469         * m4/utimes.m4: s/conftestdata/conftest.data/
22470         Inspired by Pavel Roskin's change in autoconf.
22471
22472 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
22473
22474         * lib/config.charset: Update for FreeBSD 4.2.
22475
22476 2001-01-27  Jim Meyering  <meyering@lucent.com>
22477
22478         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
22479         a use of AS_IF.
22480         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22481
22482 2001-01-26  Jim Meyering  <meyering@lucent.com>
22483
22484         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
22485         quotearg.c includes it.
22486
22487 2001-01-26  Jim Meyering  <meyering@lucent.com>
22488
22489         * lib/quotearg.c: Include stddef.h.
22490         * lib/quote.c: Include stddef.h.
22491         Reported by Axel Kittenberger.
22492
22493         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
22494         line in double quotes so that it evokes a better diagnostic.
22495         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
22496         Reported by Axel Kittenberger.
22497
22498 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
22499
22500         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
22501         as if it was a `charset'.
22502
22503 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22504
22505         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
22506         has const.
22507
22508 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22509
22510         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
22511         to avoid a warning.  Add back 'const' to inptr.
22512
22513 2001-01-20  Jim Meyering  <meyering@lucent.com>
22514
22515         Be sure that headers are checked before used in code compiled
22516         for the type checks.
22517         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
22518         In place of that, invoke jm_CHECK_ALL_TYPES.
22519         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
22520         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
22521         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
22522         The check for ssize_t was mistakenly run before the test for unistd.h.
22523
22524         The configure-time check for stdbool.h was missing.
22525         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
22526         (jm_PREREQ_HASH): New function.
22527
22528 2001-01-17  Jim Meyering  <meyering@lucent.com>
22529
22530         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
22531         for autoconf-2.49c.
22532         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
22533
22534 2001-01-16  Jim Meyering  <meyering@lucent.com>
22535
22536         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
22537         From Bruno Haible.
22538
22539 2001-01-14  Jim Meyering  <meyering@lucent.com>
22540
22541         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
22542         foo and bar.  Create conftestdir/ in the script, not in the C code.
22543         Remove directories in the script, not in the C code.
22544         Remove conftestdir{,2} before trying to create the directory.
22545         Make the entire configure script fail if the mkdir fails.
22546
22547 2001-01-14  Jim Meyering  <meyering@lucent.com>
22548
22549         * lib/rename.c: New file.  From Volker Borchert.
22550         Include stdlib.h, string.h or strings.h, and xalloc.h.
22551         Use strip_trailing_slashes rather than open-coding it.
22552
22553 2001-01-03  Paul Eggert  <eggert@twinsun.com>
22554
22555         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
22556
22557 2001-01-03  Jim Meyering  <meyering@lucent.com>
22558
22559         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
22560         of local `inptr' to avoid warning with some system declarations of
22561         iconv.
22562
22563 2001-01-02  Volker Borchert  <bt@teknon.de>
22564
22565         * m4/rename.m4: New file.
22566         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
22567
22568 2001-01-01  Jim Meyering  <meyering@lucent.com>
22569
22570         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
22571         even on systems with utmpx.h.  It's necessary for the declaration of
22572         utmp's ut_user member.  Reported by Andreas Jaeger.
22573
22574         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
22575         available. They are required for the declarations of getgrgid and
22576         getpwuid resp.
22577         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
22578         Reported by Andreas Jaeger.
22579
22580 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
22581
22582         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
22583         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
22584         so `make install' also works in VPATH builds.
22585
22586 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
22587
22588         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
22589         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
22590         can be used in subdirectories.
22591
22592 2000-12-29  Paul Eggert  <eggert@twinsun.com>
22593
22594         * lib/modechange.c: Do not assume that mode_t uses the
22595         traditional octal encoding.  E.g. "chmod 1 FOO" should set
22596         the other-execute bit of FOO even if S_IXOTH != 1.
22597
22598         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
22599         WOTH, XOTH, ALLM): New macros.
22600         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
22601          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
22602         Use them.
22603         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
22604         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
22605         (mode_compile):
22606         No need to use uintmax_t; unsigned long is long enough.
22607         Don't bother to get suffix since we don't use it.
22608
22609 2000-12-26  Jim Meyering  <meyering@lucent.com>
22610
22611         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
22612         better with autoheader.
22613
22614 2000-12-24  Jim Meyering  <meyering@lucent.com>
22615
22616         * lib/hash.c (is_prime): Return explicit boolean values.
22617         (hash_get_first): Return NULL to appease Irix5.6's 89.
22618         Reported by Nelson Beebe.
22619
22620 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
22621
22622         * lib/localcharset.c (locale_charset): Add support for Win32.
22623
22624 2000-12-18  Paul Eggert  <eggert@twinsun.com>
22625
22626         * lib/physmem.h, lib/physmem.c: New files.
22627
22628         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
22629         (noinst_HEADERS): Add physmem.h.
22630
22631         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
22632         't' for compatibility with Solaris 8 sort.
22633
22634 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
22635
22636         * lib/config.charset: Add support for BeOS.
22637
22638 2000-12-17  Jim Meyering  <meyering@lucent.com>
22639
22640         * m4/dos.m4 (jm_AC_DOS): New file and macro.
22641         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
22642
22643 2000-12-16  Jim Meyering  <meyering@lucent.com>
22644
22645         This bug had a serious impact on chown: `chown N:M FILE' (for integer
22646         N and M) would have treated it like `chown N:N FILE'.
22647
22648         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
22649
22650 2000-12-16  Jim Meyering  <meyering@lucent.com>
22651
22652         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
22653         SHELLS_FILE to a file name that's useful on djgpp systems.
22654         Include stdlib.h.
22655         (ADDITIONAL_DEFAULT_SHELLS): Define.
22656         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
22657         Based mostly on a patch from Prashant TR.
22658
22659 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
22660
22661         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
22662         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
22663         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
22664
22665 2000-12-08  Andreas Schwab  <schwab@suse.de>
22666
22667         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
22668         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
22669
22670 2000-12-07  Jim Meyering  <meyering@lucent.com>
22671
22672         * lib/stripslash.c (ISSLASH): Define.
22673         (strip_trailing_slashes): Use ISSLASH rather than comparing against
22674         `/'.
22675         From Prashant TR.
22676
22677         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
22678         (dir_name_r): Declare this function as static.
22679         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
22680         manifest itself on a name containing a mix of slashes and
22681         backslashes.
22682         Make this function work with names starting with a DOS-style
22683         drive letter and colon prefix.
22684         (dir_name): Append `.' if necessary.
22685         Based mostly on patches from Prashant TR and Eli Zaretskii.
22686
22687         * lib/dirname.h (dir_name_r): Remove prototype.
22688
22689 2000-12-06  Paul Eggert  <eggert@twinsun.com>
22690
22691         * m4/off_t-format.m4: Remove this file.
22692         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
22693
22694 2000-12-06  Jim Meyering  <meyering@lucent.com>
22695
22696         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
22697         replacement strtoull, we may well need the replacement strtoul, too.
22698         Check for declarations of strtoul and strtoull.
22699         Check for strtol.  Mainly as a cue to cause automake to include
22700         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
22701         Check for limits.h -- strtol.c needs it.
22702
22703 2000-12-05  Jim Meyering  <meyering@lucent.com>
22704
22705         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
22706
22707 2000-12-04  Jim Meyering  <meyering@lucent.com>
22708
22709         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
22710         Also include memory.h, stdlib.h, unistd.h if appropriate.
22711         Reported by Andreas Jaeger (conflicting declaration of malloc).
22712
22713 2000-12-02  Jim Meyering  <meyering@lucent.com>
22714
22715         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
22716         * m4/jm-macros.m4 (jm_MACROS): require it.
22717
22718 2000-12-02  Jim Meyering  <meyering@lucent.com>
22719
22720         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
22721
22722 2000-12-01  Paul Eggert  <eggert@twinsun.com>
22723
22724         * lib/memrchr.c: Include <config.h> before any system include file.
22725
22726 2000-11-30  Jim Meyering  <meyering@lucent.com>
22727
22728         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
22729
22730 2000-11-30  Jim Meyering  <meyering@lucent.com>
22731
22732         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
22733
22734 2000-11-29  Paul Eggert  <eggert@twinsun.com>
22735
22736         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
22737
22738 2000-11-26  Jim Meyering  <meyering@lucent.com>
22739
22740         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
22741
22742 2000-11-22  Paul Eggert  <eggert@twinsun.com>
22743
22744         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
22745         size of (size_t) -1; it's not portable.
22746
22747 2000-11-17  Jim Meyering  <meyering@lucent.com>
22748
22749         * lib/strstr.c: Update from GNU libc.
22750
22751 2000-11-17  Akim Demaille  <akim@epita.fr>
22752
22753         * lib/obstack.h: Formatting changes.
22754         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
22755         prevent type checking.
22756         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
22757         cast the value to (void *): assigning a `foo *' to a `void *'
22758         variable is valid.
22759         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
22760
22761 2000-11-16  Jim Meyering  <meyering@lucent.com>
22762
22763         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
22764
22765 2000-11-11  Jim Meyering  <meyering@lucent.com>
22766
22767         * lib/error.c: Add a couple #includes, merging from GNU libc version.
22768
22769 2000-11-10  Jim Meyering  <meyering@lucent.com>
22770
22771         * lib/obstack.h: Update from GNU libc.
22772         * lib/obstack.c: Likewise.
22773
22774 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
22775
22776         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
22777
22778 2000-11-06  Paul Eggert  <eggert@twinsun.com>
22779
22780         * lib/getusershell.c (setusershell): Use rewind rather than
22781         fseek/fseeko, to avoid configuration hassles with fseeko.
22782         Don't bother opening SHELLS_FILE if shellstream is NULL;
22783         it's not necessary.
22784
22785 2000-11-05  Jim Meyering  <meyering@lucent.com>
22786
22787         * lib/makepath.h (make_dir): Declare.
22788         * lib/makepath.c (make_dir): Remove `static' attribute.
22789         Tweak a comment.
22790
22791 2000-11-04  Jim Meyering  <meyering@lucent.com>
22792
22793         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
22794
22795 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
22796
22797         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
22798         last one in a bucket, advance to the next bucket.
22799
22800 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
22801
22802         * lib/fnmatch.c: Do not comment out all the code if we are using
22803         the GNU C library, because in some cases we are replacing buggy
22804         code in the GNU C library itself.
22805
22806 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
22807
22808         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
22809         (regex_compile): Catch bogus \(\1\).
22810
22811 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22812
22813         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
22814         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
22815         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
22816
22817 2000-10-30  Paul Eggert  <eggert@twinsun.com>
22818
22819         * lib/error.h, getline.h, modechange.h:
22820         Remove "2000" from Copyright line, as the file hasn't been
22821         changed this year other than in the copyright notice.
22822
22823         * lib/xalloc.h: Add "2000" to Copyright line, as this file
22824         was changed this year.
22825
22826 2000-10-29  Jim Meyering  <meyering@lucent.com>
22827
22828         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
22829         renaming.
22830         * m4/ls-mntd-fs.m4: Likewise
22831
22832 2000-10-29  Jim Meyering  <meyering@lucent.com>
22833
22834         * lib/xstat.in: Fix grammar in comment.
22835
22836 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
22837
22838         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
22839         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
22840         doesn't define __restrict_arr.
22841
22842 2000-10-28  Jim Meyering  <meyering@lucent.com>
22843
22844         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
22845         (jm_PREREQ_MEMCHR): New function.
22846
22847 2000-10-28  Jim Meyering  <meyering@lucent.com>
22848
22849         * lib/memchr.c: Update from libc.
22850         Adjust for portability:
22851         [HAVE_STDLIB_H]: Include stdlib.h.
22852         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
22853         Undef __memchr, too.
22854         [!weak_alias]: Define __memchr to memchr.
22855
22856         * lib/regex.c: Update from libc.
22857         * lib/regex.h: Likewise.
22858         * lib/getopt1.c: Likewise.
22859         * lib/memcmp.c: Likewise.
22860
22861         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
22862         Avoid using fseek, when possible -- it's broken by design.
22863         Patch by Ulrich Drepper.
22864
22865 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
22866
22867         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
22868         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
22869         Giving in to popular pressure to shut up the compiler with casts.
22870
22871 2000-10-26  Jim Meyering  <meyering@lucent.com>
22872
22873         * lib/strftime.c: Update from libc.
22874
22875 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
22876
22877         * regex.c: More `unsigned char' -> `re_char' changes.
22878         Also change several `int' into `re_wchar_t'.
22879         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
22880         (PUSH_FAILURE_POINTER): Don't cast any more.
22881         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
22882         We want GCC to complain, since this piece of code makes
22883         re_match non-reentrant, which *should* be fixed.
22884         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
22885         (EXTEND_BUFFER): Use RETALLOC.
22886         (SET_LIST_BIT): Don't cast.
22887         (re_wchar_t): New type.
22888         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
22889         that those two functions will always properly return.
22890         (IMMEDIATE_QUIT_CHECK): Cast to void.
22891         (analyse_first): Use recursion rather than an explicit stack.
22892         (re_compile_fastmap): Can't fail anymore.
22893         (re_search_2): Don't check re_compile_fastmap for failure.
22894         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
22895         Now also sets the new value (passed in a new argument).
22896         (re_match_2_internal): Use it.
22897         Also, use a new var `reg' of type size_t when looping through regs
22898         rather than reuse the inappropriate `mcnt'.
22899
22900 2000-10-25  Jim Meyering  <meyering@lucent.com>
22901
22902         * lib/obstack.c: Update from libc.
22903
22904 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
22905
22906         * regex.c (regex_compile): Change the way of handling a range from
22907         a char less than 256 to a char not less than 256.
22908
22909 2000-10-24  Andrew Innes  <andrewi@gnu.org>
22910
22911         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
22912         NT-Emacs only.
22913         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
22914         so that re_search functions only quit when callers expect them to.
22915
22916 2000-10-23  Jim Meyering  <meyering@lucent.com>
22917
22918         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
22919         wrong.  That set_locale call must not have any side effects.
22920         From Paul Eggert.
22921
22922 2000-10-22  Jim Meyering  <meyering@lucent.com>
22923
22924         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
22925         [CYCLIC]: Remove now-unused definition.
22926
22927         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
22928         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
22929         Suggestion from Ulrich Drepper.
22930
22931 2000-10-21  Jim Meyering  <meyering@lucent.com>
22932
22933         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
22934         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
22935         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
22936
22937 2000-10-21  Jim Meyering  <meyering@lucent.com>
22938
22939         * lib/dirname.c (memrchr): Declare if necessary.
22940         (dir_name): Remove the restriction that there be no
22941         trailing slashes.  Now, this code skips past them, effectively
22942         ignoring them.
22943         [TEST_DIRNAME] (main): New unit tests.
22944
22945         * lib/memrchr.c: New file from GNU libc.
22946         Undef __memrchr, too.
22947         [!weak_alias]: Define __memrchr to memrchr.
22948         Guard weak_alias use with `#ifdef weak_alias'.
22949
22950 2000-10-21  Jim Meyering  <meyering@lucent.com>
22951
22952         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
22953         (dir_name): Use dir_name_r.
22954         * lib/dirname.h (dir_name_r): Declare it.
22955
22956 2000-10-17  Jim Meyering  <meyering@lucent.com>
22957
22958         * lib/quote.h (PARAMS): Define and use.
22959         Reported by Akim Demaille.
22960
22961         * lib/getopt.c: Update from libc.
22962
22963 2000-10-16  Jim Meyering  <meyering@lucent.com>
22964
22965         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
22966         setlocale.
22967         From Jan Fedak.
22968
22969 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
22970
22971         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
22972
22973 2000-09-25  Jim Meyering  <meyering@lucent.com>
22974
22975         * lib/md5.h (rol): Define (from GnuPG).
22976
22977         * lib/sha.c: Give credit (GnuPG) where due.
22978         (M): Use rol rather than open-coding it.
22979         Add a FIXME comment.
22980
22981 2000-09-21  Jim Meyering  <meyering@lucent.com>
22982
22983         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
22984         Reported by Michael Stone.
22985
22986 2000-09-20  Jim Meyering  <meyering@lucent.com>
22987
22988         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
22989         (noinst_HEADERS): Add sha.h.
22990         Based on code from Scott G. Miller and from GnuPG.
22991
22992 2000-09-18  Jim Meyering  <meyering@lucent.com>
22993
22994         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
22995         LIBS. Otherwise, everyone ends up linking with -lelf for some
22996         configurations.
22997         Reported by Mike Stone.
22998
22999 2000-09-15  Jim Meyering  <meyering@lucent.com>
23000
23001         * lib/regex.c: Update from libc.
23002
23003 2000-09-10  Jim Meyering  <meyering@lucent.com>
23004
23005         * lib/getopt.c (_getopt_internal): Update from glibc.
23006
23007 2000-09-09  Jim Meyering  <meyering@lucent.com>
23008
23009         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
23010         think it should be used as a general replacement for isascii.
23011         * lib/fnmatch.c: Likewise.
23012         * lib/mbswidth.c: Likewise
23013         * lib/regex.c: Likewise.
23014
23015         Don't use atoi.
23016         * lib/userspec.c: Include sys/param.h and limits.h.
23017         Include xstrtol.h.
23018         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23019         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
23020         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
23021         UID, GID.  Check range.
23022
23023 2000-09-06  Jim Meyering  <meyering@lucent.com>
23024
23025         * lib/getopt.c (_getopt_internal): Update from glibc.
23026
23027 2000-08-30  Jim Meyering  <meyering@lucent.com>
23028
23029         * lib/strftime.c: Merge in changes from GNU libc.
23030
23031 2000-08-26  Jim Meyering  <meyering@lucent.com>
23032
23033         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
23034         * m4/fpending.m4: New file.
23035
23036 2000-08-26  Jim Meyering  <meyering@lucent.com>
23037
23038         * lib/closeout.c: Include "__fpending.h".
23039         (close_stdout_status): Return right away if there's nothing to flush.
23040
23041         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
23042         * lib/__fpending.c: New file.
23043         * lib/__fpending.h: New file.
23044
23045 2000-08-20  Jim Meyering  <meyering@lucent.com>
23046
23047         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
23048         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
23049         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
23050
23051 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
23052
23053         Improve fileutils installation on systems where running
23054         programs (like install) can't be unlinked.
23055         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
23056         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
23057
23058 2000-08-07  Paul Eggert  <eggert@twinsun.com>
23059
23060         Standardize on "memory exhausted" instead of "Memory exhausted"
23061         or "virtual memory exhausted".
23062         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
23063         "virtual memory exhausted".
23064         * lib/same.c (same_name): Invoke xalloc_die instead of printing
23065         our own message.
23066         * lib/userspec.c (parse_user_spec): Likewise.
23067         * lib/bumpalloc.h: comment fix
23068         * lib/same.c, userspec.c: Include xalloc.h.
23069
23070         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
23071         not char *const and pointing to a constant array.
23072         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
23073         (xrealloc): Comment fix.
23074
23075         * lib/userspec.c (parse_user_spec):
23076         Don't translate a message until just before returning,
23077         to avoid unnecessary translation.
23078
23079 2000-08-07  Jim Meyering  <meyering@lucent.com>
23080
23081         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
23082         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
23083         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
23084         getgroups.c, gethostname.c, getopt.h, group-member.c,
23085         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
23086         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
23087         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
23088         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
23089         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
23090         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
23091         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
23092         yesno.c: Back out Copyright date changes for each file with no change
23093         this year.  This eases coordination with other programs using the same
23094         source code modules.  From Paul Eggert.
23095
23096 2000-08-06  Paul Eggert  <eggert@twinsun.com>
23097
23098         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
23099         not char, for compatibility with glibc 2.1.3 strftime.c.
23100
23101 2000-08-03  Greg McGary  <greg@mcgary.org>
23102
23103         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
23104         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
23105         (EXTEND_BUFFER): Use them.
23106
23107 2000-08-01  Jim Meyering  <meyering@lucent.com>
23108
23109         * lib/dirname.c (ISSLASH): Define.
23110         (BACKSLASH_IS_PATH_SEPARATOR): Define.
23111         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
23112         both `\' and `/' may be use as path separators.
23113         Based on a patch from Prashant TR.
23114
23115 2000-07-31  Paul Eggert  <eggert@twinsun.com>
23116
23117         * lib/quotearg.c (quotearg_n_options): Don't make the initial
23118         slot vector a constant, since it might get modified.
23119
23120 2000-07-31  Jim Meyering  <meyering@lucent.com>
23121
23122         * lib/xmalloc.c: Use `virtual memory exhausted', not
23123         `Memory exhausted'.
23124         * lib/obstack.c (print_and_abort): Likewise.
23125
23126 2000-07-30  Paul Eggert  <eggert@twinsun.com>
23127
23128         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
23129         buffer, so that the caller can always quote one small
23130         component of a "memory exhausted" message in slot 0.
23131         From a suggestion by Jim Meyering.
23132
23133 2000-07-30  Jim Meyering  <meyering@lucent.com>
23134
23135         * lib/makepath.c (make_path): Quote the other instance, too.
23136
23137         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
23138         (STATIC_BUF_SIZE): Define.
23139         (quotearg_n_options): Use only statically allocated storage when
23140         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
23141         than STATIC_BUF_SIZE.
23142
23143 2000-07-29  Jim Meyering  <meyering@lucent.com>
23144
23145         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
23146         * lib/dirname.c (dir_name): Likewise.
23147
23148         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
23149         `/'.
23150
23151         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
23152         (dir_name): Assert that there are no trailing slashes.
23153
23154 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
23155
23156         * lib/mbswidth.h (mbswidth): Add a flags argument.
23157         (mbswidth): New declaration.
23158         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
23159         * lib/mbswidth.c (mbswidth): Add a flags argument.
23160         (mbsnwidth): New function.
23161
23162 2000-07-24  Jim Meyering  <meyering@lucent.com>
23163
23164         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
23165
23166 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23167
23168         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
23169
23170 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23171
23172         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
23173         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
23174         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
23175         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
23176         invoke multibyte primitives.
23177
23178 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23179
23180         * lib/quotearg.c:
23181         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
23182         so that mbstate_t is always defined.
23183
23184         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
23185         be 1 in at least one GCC installation, and this configuration
23186         error is likely to be common.  Ignoring MB_LEN_MAX hurts
23187         performance on hosts that have mbrtowc but have only unibyte
23188         locales, but I assume these hosts are rare.
23189
23190 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23191
23192         * lib/mbswidth.c (_XOPEN_SOURCE):
23193         Don't define; this causes problems on Solaris 7.
23194         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
23195
23196 2000-07-23  Jim Meyering  <meyering@lucent.com>
23197
23198         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
23199         too: getgrgid, getpwuid, getuid.
23200
23201 2000-07-23  Jim Meyering  <meyering@lucent.com>
23202
23203         * lib/basename.c (base_name): Add an assertion.
23204
23205 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
23206
23207         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
23208         shadow its mbsinit function.
23209
23210 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23211
23212         * lib/mbswidth.h: New file.
23213         * lib/mbswidth.c: New file.
23214         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
23215         (noinst_HEADERS): Add mbswidth.h.
23216
23217 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23218
23219         * lib/config.charset: Add support for FreeBSD. Improve support for
23220         HP-UX and IRIX 6.
23221
23222 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
23223
23224         * m4/mbswidth.m4: New file.
23225         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
23226
23227 2000-07-15  Jim Meyering  <meyering@lucent.com>
23228
23229         * lib/makepath.c: Include quote.h.
23230         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
23231         corresponding argument in a `quote (...)' call.
23232         Give better diagnostics.
23233
23234         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
23235         (noinst_HEADERS): Add quote.h.
23236
23237         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
23238         from tar's src/misc.c.
23239         * lib/quote.h: New file.  Prototypes for same.
23240
23241 2000-07-14  Paul Eggert  <eggert@twinsun.com>
23242
23243         From a suggestion by Bruno Haible.
23244         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
23245         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
23246         to decide whether to define the BeOS workaround macro;
23247         this adjusts to the change to AC_MBSTATE_T.
23248
23249 2000-07-14  Jim Meyering  <meyering@lucent.com>
23250
23251         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
23252         jm_AC_TYPE_UINTMAX_T.
23253
23254 2000-07-13  Paul Eggert  <eggert@twinsun.com>
23255
23256         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
23257
23258         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
23259         quotearg_buffer_restyled): Add support for
23260         clocale_quoting_style.  Undo previous change to
23261         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
23262         and "{RIGHT QUOTATION MARK}" msgids.
23263
23264 2000-07-10  Paul Eggert  <eggert@twinsun.com>
23265
23266         From a suggestion by Bruno Haible.
23267         * m4/mbstate_t.m4 (AC_MBSTATE_T):
23268         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
23269         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
23270         and mbstate_t, to a single-part test that simply defines mbstate_t.
23271         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
23272         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
23273
23274 2000-07-10  Jim Meyering  <meyering@lucent.com>
23275
23276         * m4/strerror_r.m4: Mirror the correction made in autoconf.
23277
23278         * m4/gnu-source.m4: Output to confdefs.h directly.
23279         Suggestion from Akim Demaille.
23280
23281 2000-07-09  Paul Eggert  <eggert@twinsun.com>
23282
23283         The old behavior of quoting `like this' doesn't look good with
23284         newer, ISO-style fonts.  See:
23285         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
23286
23287         Instead, quote "like this" by default.  Let the translator
23288         tailor the locale-specific quoting behavior by providing
23289         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
23290
23291         * lib/quotearg.c (N_): New macro.
23292         (gettext_default): New function.
23293         (quotearg_buffer_restyled): Use
23294         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
23295         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
23296
23297 2000-07-09  Jim Meyering  <meyering@lucent.com>
23298
23299         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
23300         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
23301
23302         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
23303         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
23304
23305 2000-07-09  Jim Meyering  <meyering@lucent.com>
23306
23307         * lib/Most files: Update copyright dates to include 2000.
23308
23309 2000-07-08  Jim Meyering  <meyering@lucent.com>
23310
23311         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
23312         if not defined.
23313         (xgethostname): Remove now-unnecessary #ifdef.
23314         Move declaration of `err' into loop where it's used.
23315
23316 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23317         and Bruno Haible  <haible@clisp.cons.org>
23318
23319         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
23320         only if the test for an object-type mbstate_t fails.  This
23321         prevents us from mistakenly reporting that mbstate_t is a
23322         system object type after we "#define mbstate_t int" to work
23323         around its lack.
23324
23325 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23326         and Bruno Haible  <haible@clisp.cons.org>
23327
23328         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
23329
23330 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23331
23332         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
23333         to strerror_r.
23334         Include <ctype.h> for use of isalpha.
23335
23336 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23337
23338         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
23339         by allocating a larger buffer. Test the gethostname return value for
23340         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
23341         returns an error and ENAMETOOLONG isn't defined.
23342
23343 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23344
23345         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
23346         dimension.
23347
23348 2000-07-04  Jim Meyering  <meyering@lucent.com>
23349
23350         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
23351         of the deprecated AC_CHECKING.
23352
23353 2000-07-04  Jim Meyering  <meyering@lucent.com>
23354
23355         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
23356         Reported by Bruno Haible.
23357
23358 2000-07-04  Jim Meyering  <meyering@lucent.com>
23359
23360         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
23361         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
23362         lacks mbrtowc.
23363
23364 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23365
23366         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
23367         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
23368
23369 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23370         and Bruno Haible  <haible@clisp.cons.org>
23371
23372         * lib/quotearg.c (mbrtowc):
23373         Assign to *pwc, and return 1 only if result is nonzero.
23374         (iswprint): Use ISPRINT when substituting our own mbrtowc.
23375
23376 2000-07-03  Jim Meyering  <meyering@lucent.com>
23377
23378         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
23379
23380 2000-07-03  Jim Meyering  <meyering@lucent.com>
23381
23382         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
23383         This is necessary to get a definition of e.g., UTMP_FILE on
23384         HP-UX 10.20.
23385         From Bob Proulx.
23386
23387 2000-07-02  Jim Meyering  <meyering@lucent.com>
23388
23389         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
23390
23391         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
23392         AC_LIBOBJ(function_name).
23393         * m4/chown.m4: Likewise.
23394         * m4/fnmatch.m4: Likewise.
23395         * m4/ftruncate.m4: Likewise.
23396         * m4/getgroups.m4: Likewise.
23397         * m4/getline.m4: Likewise.
23398         * m4/group-member.m4: Likewise.
23399         * m4/jm-macros.m4: Likewise.
23400         * m4/lstat.m4: Likewise.
23401         * m4/malloc.m4: Likewise.
23402         * m4/memcmp.m4: Likewise.
23403         * m4/nanosleep.m4: Likewise.
23404         * m4/putenv.m4: Likewise.
23405         * m4/realloc.m4: Likewise.
23406         * m4/regex.m4: Likewise.
23407         * m4/stat.m4: Likewise.
23408         * m4/strftime.m4: Likewise.
23409
23410 2000-07-02  Jim Meyering  <meyering@lucent.com>
23411
23412         * lib/quotearg.c (mbstate_t): Don't define here.
23413
23414 2000-07-02  Jim Meyering  <meyering@lucent.com>
23415
23416         * lib/nanosleep.c (SIGCONT): Define if not already defined.
23417
23418 2000-07-01  Jim Meyering  <meyering@lucent.com>
23419
23420         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
23421
23422 2000-07-01  Jim Meyering  <meyering@lucent.com>
23423
23424         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
23425         problem.
23426
23427 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23428
23429         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
23430         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
23431
23432 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23433
23434         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
23435         per change in ../m4/ls-mntd-fs.m4.
23436         (read_filesystem_list): Ignore symbolic links.
23437
23438 2000-06-29  Jim Meyering  <meyering@lucent.com>
23439
23440         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
23441         for declaration of strcmp.
23442
23443         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
23444
23445         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
23446         Avoid warning by casting result to `char *' to remove `const'.
23447
23448 2000-06-28  Jim Meyering  <meyering@lucent.com>
23449
23450         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
23451         included by quotearg.c, for which we perform this test.  From
23452         Bruno Haible.
23453
23454 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23455
23456         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
23457         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
23458         <utmpx.h> exists, put readutmp.o into LIBOBJS.
23459
23460 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23461
23462         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
23463
23464 2000-06-26  Paul Eggert  <eggert@twinsun.com>
23465
23466         savedir now sets errno on failure and invokes xmalloc to get memory.
23467         Fix a couple of other minor bugs while we're at it.
23468
23469         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
23470         (NAMLEN): Remove macro.
23471         (malloc, realloc): Remove decls.
23472         (stpcpy): Likewise.
23473         ("xalloc.h"): Include.
23474         (NAME_SIZE_DEFAULT): New macro.
23475         (savedir): Use xmalloc / xrealloc to allocate memory.
23476         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
23477         Skip "" directory entries.
23478         Use strlen to calculate directory entry length, since the old method
23479         is rarely used these days and isn't worth supporting.
23480         Don't use a pointer after freeing it.
23481         Check for integer overflow when calculating allocation size.
23482         Use memcpy to copy entries, instead of stpcpy.
23483         Set errno properly when returning NULL.
23484         Check for readdir error.
23485
23486 2000-06-26  Jim Meyering  <meyering@lucent.com>
23487
23488         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
23489
23490 2000-06-25  Jim Meyering  <meyering@lucent.com>
23491
23492         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
23493         Linux header bug when _XOPEN_SOURCE is defined to 500.
23494
23495 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23496
23497         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
23498         deficiency.
23499
23500 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23501
23502         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
23503         Include xalloc.h.
23504         Don't include <stdlib.h>.  Don't declare malloc, realloc.
23505
23506 2000-06-24  Jim Meyering  <meyering@lucent.com>
23507
23508         * m4/strerror_r.m4: Revive this file -- to try out an experimental
23509         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
23510         for which strerror does return char*, but which lacks a conveniently
23511         accessible declaration of the function.  If the compile-test says
23512         strerror_r doesn't work, then resort to a `run'-test that works on
23513         BeOS and segfaults on DEC Unix.
23514
23515 2000-06-24  Jim Meyering  <meyering@lucent.com>
23516
23517         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
23518
23519 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23520
23521         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
23522         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
23523
23524 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23525
23526         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
23527         (mbrtowc, mbstate_t): Define substitutes if
23528         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
23529         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
23530         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
23531
23532 2000-06-23  Jim Meyering  <meyering@lucent.com>
23533
23534         * m4/afs.m4: Add missing AC_MSG_RESULT.
23535         Reported by Bruno Haible.
23536
23537         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
23538         Suggestion from Bruno Haible.
23539
23540 2000-06-23  Jim Meyering  <meyering@lucent.com>
23541
23542         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
23543
23544 2000-06-21  Jim Meyering  <meyering@lucent.com>
23545
23546         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
23547
23548 2000-06-21  Jim Meyering  <meyering@lucent.com>
23549
23550         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
23551         (noinst_HEADERS): Add getstr.h.
23552
23553         * lib/getline.c (getstr): Move into a separate file.
23554         * lib/getstr.c (getstr): New file, extracted from getline.c, with
23555         the following changes: new parameter, delim2; both delim[12]
23556         parameters have type `int', not `char'.  The latter would lose
23557         with 8-bit delimiters.
23558         * lib/getstr.h: New file.
23559
23560 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23561
23562         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
23563         than 1024, return a memory chunk of least possible size, instead
23564         of size PATH_MAX + 2. In the loop, increment the size proportionally.
23565         Use free/xmalloc instead of xrealloc to avoid copying for very long
23566         paths.
23567
23568 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23569
23570         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
23571         the empty string.
23572
23573 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23574
23575         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
23576         address, not strdup.  Include <stdlib.h> and don't declare free().
23577
23578 2000-06-19  Jim Meyering  <meyering@lucent.com>
23579
23580         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
23581
23582 2000-06-18  Jim Meyering  <meyering@lucent.com>
23583
23584         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
23585
23586         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
23587         `checking whether...' message to be consistent with that of the
23588         lstat test.
23589
23590 2000-06-18  Jim Meyering  <meyering@lucent.com>
23591
23592         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
23593         Besides, these days every porting target provides a mkdir function.
23594
23595         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
23596         needed. (this snippet comes from src/system.h).
23597
23598 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
23599
23600         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
23601
23602 2000-06-15  Paul Eggert  <eggert@twinsun.com>
23603
23604         * lib/human.c (adjust_value): New function.
23605         (human_readable_inexact): Apply rounding style even when
23606         printing approximate values.
23607
23608 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23609
23610         * lib/human.c (human_readable_inexact): Allow an input block
23611         size that is not a multiple of the output block size, and vice versa.
23612         Reported by Piergiorgio Sartor.
23613
23614 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23615
23616         * lib/getdate.y (get_date): Apply relative times after time
23617         zone indicator, not before.  Reported by Todd A. Jacobs.
23618
23619 2000-06-13  Jim Meyering  <meyering@lucent.com>
23620
23621         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
23622
23623         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
23624
23625 2000-06-12  Paul Eggert  <eggert@twinsun.com>
23626
23627         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
23628
23629 2000-06-12  Jim Meyering  <meyering@lucent.com>
23630
23631         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
23632         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
23633         optional argument.
23634         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
23635         the optional argument, `lib'.
23636
23637 2000-06-08  Jim Meyering  <meyering@lucent.com>
23638
23639         * m4/largefile.m4: Remove file (now that it's part of autoconf).
23640
23641 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23642
23643         Rewrite largefile configuration so that we don't need to run
23644         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
23645         AC_CANONICAL_HOST in configure.in -- jmm]
23646
23647         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
23648         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
23649         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
23650         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
23651         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
23652         All uses changed.
23653         Instead of inspecting the output of getconf, try to compile the
23654         test program without and with the macro definition.
23655         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
23656         for getconf.  Instead, check for the needed flags by compiling
23657         test programs.
23658
23659 2000-06-04  Paul Eggert  <eggert@twinsun.com>
23660
23661         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
23662
23663 2000-06-04  Jim Meyering  <meyering@lucent.com>
23664
23665         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
23666         SunOS 4.1.4 for which gid_t is an unsigned type.
23667
23668 2000-06-03  Jim Meyering  <meyering@lucent.com>
23669
23670         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
23671         now that autoconf requires that.
23672
23673         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
23674         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
23675         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
23676
23677 2000-06-03  Jim Meyering  <meyering@lucent.com>
23678
23679         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
23680
23681 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23682
23683         * m4/glibc21.m4: New file.
23684         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
23685
23686 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
23687
23688         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
23689         newer, don't install charset.alias.
23690         * lib/config.charset: Change the Linux/glibc rules so they become empty
23691         on glibc-2.1 or newer.
23692
23693 2000-06-02  Jim Meyering  <meyering@lucent.com>
23694
23695         * lib/mountlist.c: Back out last change.  Instead, do this...
23696         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
23697         me_dummy member using the same `ignore'-testing code.
23698         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
23699         fs_type strings.
23700         From Mark D. Roth.
23701
23702 2000-05-29  Jim Meyering  <meyering@lucent.com>
23703
23704         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
23705         mounts with the `ignore' attribute.  Based on a patch from
23706         Mark D. Roth.
23707
23708 2000-05-28  Jim Meyering  <meyering@lucent.com>
23709
23710         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
23711         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23712         * m4/stat.m4: Likewise.
23713         * m4/lstat.m4: Likewise.
23714         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
23715
23716         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
23717         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
23718
23719 2000-05-26  Jim Meyering  <meyering@lucent.com>
23720
23721         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
23722
23723 2000-05-24  Jim Meyering  <meyering@lucent.com>
23724
23725         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
23726         autoconf requires that.
23727         * m4/lib-check.m4: Likewise.
23728         * m4/jm-macros.m4: Likewise.
23729         * m4/strftime.m4: Likewise.
23730
23731         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
23732         AC_CHECK_DECLS, now that autoconf requires that.
23733
23734 2000-05-22  Jim Meyering  <meyering@lucent.com>
23735
23736         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
23737         * m4/lstat.m4: Likewise.
23738
23739 2000-05-22  Jim Meyering  <meyering@lucent.com>
23740
23741         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
23742
23743 2000-05-20  Jim Meyering  <meyering@lucent.com>
23744
23745         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
23746         (jm_PREREQ): Use it.
23747
23748 2000-05-18  Jim Meyering  <meyering@lucent.com>
23749
23750         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
23751         back, too, since it may have been modified by allocate_entry.
23752         (hash_delete): Rewrite to use neither the assignment operator
23753         nor the comma operator in an if-expression.
23754
23755 2000-05-15  Paul Eggert  <eggert@twinsun.com>
23756
23757         * lib/closeout.c:
23758         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
23759         Remove; no longer needed.
23760         "quotearg.h": Add include.
23761         (file_name): Do not bother to explicitly initialize to NULL; it's less
23762         efficient on some hosts.
23763         (close_stdout_status): Remove test as to whether stdout was already
23764         closed; it breaks for the case "echo x | sort >&-".
23765         Quote file name colons.
23766         Do not assume that _("write error") lacks format strings.
23767
23768 2000-05-15  Jim Meyering  <meyering@lucent.com>
23769
23770         * lib/version-etc.c (version_etc_copyright): Update the copyright
23771         string used in all --version output.
23772
23773 2000-05-14  Jim Meyering  <meyering@lucent.com>
23774
23775         * lib/closeout.c (close_stdout_set_file_name): New function.
23776         (close_stdout_status): Use new file-scoped global.
23777         Return right away if fstat says the stdout file descriptor is invalid.
23778         * lib/closeout.h (close_stdout_set_file_name): Declare.
23779
23780 2000-05-10  Jim Meyering  <meyering@lucent.com>
23781
23782         * lib/closeout.c [default_exit_status]: New file-scoped variable.
23783         (close_stdout_set_status): New function.
23784         * lib/closeout.h (close_stdout_set_status): Declare.
23785
23786 2000-05-09  Jim Meyering  <meyering@lucent.com>
23787
23788         * m4/gettext.m4: Rename this...
23789         * m4/libintl.m4: ...to this.
23790
23791 2000-05-08  Jim Meyering  <meyering@lucent.com>
23792
23793         * lib/long-options.c: Don't include closeout.h.
23794         (parse_long_options): Don't call close_stdout for --version.
23795
23796 2000-05-06  Paul Eggert  <eggert@twinsun.com>
23797
23798         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
23799         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
23800         2.1.3 bug.  This avoids a clash when files like regex.c define
23801         _GNU_SOURCE.
23802
23803 2000-05-06  Jim Meyering  <meyering@lucent.com>
23804
23805         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
23806         (AC_REPLACE_FUNCS): Add strnlen.
23807
23808         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
23809         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
23810
23811         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
23812         AC_SEARCH_LIBS call for nanosleep.
23813         (LIB_NANOSLEEP): Set and AC_SUBST.
23814
23815 2000-05-06  Jim Meyering  <meyering@lucent.com>
23816
23817         * lib/strnlen.c: Undefine __strnlen and strnlen.
23818         [!weak_alias]: Define __strnlen to strnlen.
23819
23820         * lib/atexit.c: New file, from libiberty.
23821
23822 2000-05-06  Jim Meyering  <meyering@lucent.com>
23823
23824         * lib/closeout.c (close_stdout_status): Also check for errors on the
23825         stderr stream.
23826
23827 2000-05-05  Jim Meyering  <meyering@lucent.com>
23828
23829         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
23830         AC_SEARCH_LIBS call for clock_gettime.
23831         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
23832
23833         * m4/search-libs.m4: Update from autoconf.
23834
23835         su doesn't work on Solaris 2.6.
23836         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
23837         <shadow.h>.  Reported by Dragos Harabor.
23838
23839 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
23840
23841         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
23842         memcpy instead of xmalloc, xrealloc, path_concat.
23843         (locale_charset): Treat empty environment variables as absent.
23844         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
23845
23846 2000-05-04  Jim Meyering  <meyering@lucent.com>
23847
23848         * lib/getopt.c: Update from glibc.
23849         * lib/obstack.c: Likewise.
23850         * lib/obstack.h: Likewise.
23851         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
23852         file
23853
23854         * lib/regex.h: Likewise.
23855         * lib/strndup.c: Likewise.
23856         * lib/strnlen.c: New file, from glibc.
23857
23858 2000-05-03  Jim Meyering  <meyering@lucent.com>
23859
23860         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
23861
23862 2000-05-02  Paul Eggert  <eggert@twinsun.com>
23863
23864         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
23865         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
23866         compile-time test, rather than inspecting host and OS, to
23867         decide whether to define _LARGEFILE_SOURCE.
23868
23869 2000-05-01  Jim Meyering  <meyering@lucent.com>
23870
23871         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
23872
23873         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
23874         Based on a patch from Bruno Haible.
23875
23876 2000-05-01  Jim Meyering  <meyering@lucent.com>
23877
23878         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
23879
23880 2000-04-29  Jim Meyering  <meyering@lucent.com>
23881
23882         * lib/path-concat.c: Declare strdup only if it's not defined.
23883         * lib/canon-host.c: Likewise.
23884
23885 2000-04-28  Jim Meyering  <meyering@lucent.com>
23886
23887         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
23888         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
23889         is included first, then limits.h is included by locale.h by libintl.h.
23890         From John David Anglin.
23891
23892 2000-04-25  Jim Meyering  <meyering@lucent.com>
23893
23894         * lib/makepath.c (S_IRWXUGO): Define.
23895         (make_path): Always perform explicit chmod if MODE specifies any
23896         of the `special' permission bits.  Prompted by a bug report against
23897         install from Mate Wierdl and Joost van Baal.
23898
23899 2000-04-18  Jim Meyering  <meyering@lucent.com>
23900
23901         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
23902         (jm_PREREQ): Use it.
23903
23904 2000-04-18  Jim Meyering  <meyering@lucent.com>
23905
23906         * lib/README: New file.
23907
23908         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
23909         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
23910
23911 2000-04-17  Jim Meyering  <meyering@lucent.com>
23912
23913         Get it right :-)
23914         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
23915         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
23916         Suggestion from Akim Demaille.
23917
23918 2000-04-17  Jim Meyering  <meyering@lucent.com>
23919
23920         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
23921         the definition of it to rpl_strftime also defined-away the system's
23922         declaration.
23923
23924 2000-04-15  Jim Meyering  <meyering@lucent.com>
23925
23926         Use `C' to denote so-called `contiguous' files, the same way
23927         that tar does.
23928         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
23929         (ftypelet): Use S_ISCTG.
23930         From Michael Deutschmann.
23931
23932 2000-04-14  Jim Meyering  <meyering@lucent.com>
23933
23934         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
23935         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
23936         clobbered.
23937
23938 2000-04-14  Jim Meyering  <meyering@lucent.com>
23939
23940         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
23941
23942 2000-04-13  Jim Meyering  <meyering@lucent.com>
23943
23944         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
23945         AH_VERBATIM to insert required #ifndef into config.h.in.
23946         Suggestion from Akim Demaille.
23947
23948 2000-04-12  Jim Meyering  <meyering@lucent.com>
23949
23950         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
23951         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
23952         Christian Krackowizer.
23953
23954         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
23955         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
23956         (AC_SYS_LARGEFILE): Require.
23957         (AM_C_PROTOTYPES): Require.
23958
23959 2000-04-08  Jim Meyering  <meyering@lucent.com>
23960
23961         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
23962         names don't conflict.  Reported by Eli Zaretskii.
23963
23964 2000-04-07  Jim Meyering  <meyering@lucent.com>
23965
23966         * lib/putenv.c: Move inclusion of errno.h so it follows that of
23967         sys/types.h, to work around system header problems on AIX 3.2.5.
23968         From Bruno Haible.
23969
23970 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
23971
23972         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
23973         bug.  Deal with the different error behavior of Irix iconv.
23974
23975 2000-04-05  Paul Eggert  <eggert@twinsun.com>
23976
23977         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
23978         IRIX if the installer said otherwise.
23979
23980 2000-04-05  Jim Meyering  <meyering@lucent.com>
23981
23982         Portability tweaks required for ultrix4.3.
23983         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
23984         (jm_CHECK_DECLS): Add getutent to the list of functions.
23985         (_jm_DECL_HEADERS): Add utmpx.h.
23986         From John David Anglin.
23987
23988         * m4/strftime.m4: Back out the 2000-04-02 change.
23989         Instead of that change, simply undefine putenv in the test program.
23990
23991 2000-04-05  Jim Meyering  <meyering@lucent.com>
23992
23993         Portability tweaks required for ultrix4.3.
23994         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
23995         getutent.
23996         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
23997         * lib/canon-host.c: Declare strdup.
23998         * lib/path-concat.c: Likewise.
23999         From John David Anglin.
24000
24001 2000-04-04  Jim Meyering  <meyering@lucent.com>
24002
24003         Be more DOS 8.3-friendly.
24004         * lib/ref-add.sin: Renamed from ref-add.sed.in.
24005         * lib/ref-del.sin: Renamed from ref-del.sed.in.
24006         * lib/Makefile.am: Reflect renaming.
24007         Reported by Eli Zaretskii.
24008
24009         Use a temporary file name that won't clash with `charset.alias'
24010         in the DOS 8.3 name space.
24011         * lib/Makefile.am (charset_tmp): Define.
24012         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
24013         (uninstall-local): Likewise.
24014         Reported by Eli Zaretskii.
24015
24016 2000-04-03  Jim Meyering  <meyering@lucent.com>
24017
24018         * m4/gettext.m4: Fix typo in comment.
24019
24020         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
24021         textutils/configure.in).  Suggestion from Paul Eggert.
24022         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
24023
24024 2000-04-02  Paul Eggert  <eggert@twinsun.com>
24025
24026         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
24027         variable in the shell rather than using putenv, which isn't
24028         portable.  This avoids the configure-time inter-test dependency
24029         on the potentially-renamed putenv function.
24030
24031 2000-03-30  Paul Eggert  <eggert@twinsun.com>
24032
24033         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
24034         before checking struct stat.st_blksize, so that
24035         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
24036
24037 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24038
24039         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
24040         since strftime.c uses HAVE_STRFTIME to decide whether to use
24041         the underlying strftime.
24042
24043 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24044
24045         * lib/time/strftime.c (my_strftime): Make sure we call the system
24046         strftime, not ourselves, when invoking the underlying strftime.
24047
24048 2000-03-24  Jim Meyering  <meyering@lucent.com>
24049
24050         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
24051         (charset_alias): Define.
24052         (install-exec-local): Factor out common code.
24053         (uninstall-local): Split lines longer than 80.
24054         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
24055         (SUFFIXES): Define.
24056         (.sed.in.sed): New rule.  Don't redirect directly to $@.
24057         (CLEANFILES): Add ref-add.sed and ref-del.sed.
24058
24059 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
24060
24061         * lib/config.charset: Output a line containing "Packages using this
24062         file".
24063         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
24064         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
24065         ref-del.sed): New rules.
24066
24067 2000-03-17  Jim Meyering  <meyering@lucent.com>
24068
24069         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
24070         Otherwise, include <strings.h>
24071
24072 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
24073
24074         * lib/unicodeio.c (utf8_wctomb): New function.
24075         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
24076         format instead of in UCS-4 with platform dependent endianness.
24077
24078 2000-03-10  Jim Meyering  <meyering@lucent.com>
24079
24080         * m4/lib-check.m4: Look for getspnam in -lgen, too.
24081         From Marco Franzen.
24082
24083 2000-03-07  Paul Eggert  <eggert@twinsun.com>
24084
24085         * lib/savedir.c (savedir): Work even if directory size is
24086         negative; this can happen with some screwy NFS configurations.
24087
24088 2000-03-06  Jim Meyering  <meyering@lucent.com>
24089
24090         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
24091         if it's NULL (because we ran out of memory).  From Bruno Haible.
24092
24093 2000-03-05  Jim Meyering  <meyering@lucent.com>
24094
24095         * lib/localcharset.c ("path-concat.h"): Include.
24096         (get_charset_aliases): Use path_concat instead of ANSI string
24097         concatenation.
24098
24099         * lib/unicodeio.h (PARAMS): Define.
24100         Use it to guard prototype.
24101
24102 2000-03-04  Jim Meyering  <meyering@lucent.com>
24103
24104         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
24105         for lib/localcharset.c.
24106
24107 2000-03-04  Jim Meyering  <meyering@lucent.com>
24108
24109         * lib/Makefile.am (install-exec-local): Create $(libdir) before
24110         installing into it.
24111         (uninstall-local): Uncomment this rule so `make distcheck' works
24112         once again.
24113
24114         * lib/unicodeio.c (<errno.h>): Include it.
24115         (errno): Declare if not defined.
24116
24117         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
24118
24119         * lib/config.charset: New version, incorporating remarks from a linux
24120         i18n mailing list.  From Bruno Haible.
24121
24122 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
24123
24124         * m4/codeset.m4: New file.
24125         * m4/iconv.m4: New file.
24126         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
24127
24128 2000-03-03  Jim Meyering  <meyering@lucent.com>
24129
24130         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
24131
24132 2000-03-02  Jim Meyering  <meyering@lucent.com>
24133
24134         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
24135         the messages come out on separate lines.
24136
24137         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
24138         rather than jm_CHECK_DECLARATIONS.
24139         * m4/decl.m4: Remove now-unused file.
24140
24141         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
24142         geteuid.
24143
24144 2000-03-02  Jim Meyering  <meyering@lucent.com>
24145
24146         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
24147
24148 2000-03-01  Jim Meyering  <meyering@lucent.com>
24149
24150         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
24151         * lib/unicodeio.c: Likewise.
24152
24153 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
24154
24155         * lib/config.charset: New file.
24156         * lib/localcharset.c: New file.
24157         * lib/unicodeio.h, lib/unicodeio.c: New files.
24158         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
24159         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
24160         (noinst_HEADERS): Add unicodeio.h.
24161         (all-local, install-exec-local, charset.alias): New targets.
24162
24163 2000-02-28  Paul Eggert  <eggert@twinsun.com>
24164
24165         * lib/quotearg.c (ALERT_CHAR): New macro.
24166         (quotearg_buffer_restyled): Use it.
24167
24168 2000-02-27  Jim Meyering  <meyering@lucent.com>
24169
24170         * m4/check-decl.m4: Add getenv to the list.
24171
24172 2000-02-27  Jim Meyering  <meyering@lucent.com>
24173
24174         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
24175         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
24176
24177         * lib/backupfile.c: Guard inclusion of stdlib.h with
24178         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
24179         Declare malloc if needed.
24180
24181         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
24182         `#ifndef HAVE_DECL..'
24183         now that autoconf always defines the HAVE_DECL_ symbols.
24184         * lib/human.c: Likewise.
24185         * lib/same.c: Likewise.
24186         * lib/strtoumax.c: Likewise.
24187
24188         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
24189         declaration check was not run.
24190         * lib/hash.c: Likewise.
24191         * lib/human.c: Likewise.
24192         * lib/same.c: Likewise.
24193         * lib/strtoumax.c: Likewise.
24194
24195         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
24196         `.', then first look up the entire `.'-containing string as a login
24197         name.
24198
24199 2000-02-23  Jim Meyering  <meyering@lucent.com>
24200
24201         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
24202         in place of my hack.
24203
24204 2000-02-18  Paul Eggert  <eggert@twinsun.com>
24205
24206         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
24207         (textint): New typedef.
24208         (parser_control): Member year changed from int to textint.
24209         All uses changed.
24210         (YYSTYPE): Removed; replaced by %union with int and textint members.
24211         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
24212         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
24213         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
24214         (tSNUMBER, tUNUMBER): Now of type <textintval>.
24215         (date, number, to_year): Use width of number in digits, not its value,
24216         to determine whether it's a 2-digit year, or a 2-digit time.
24217         (yylex): Store number of digits of numeric tokens.
24218         Reported by John Kendall.
24219
24220         (parser_control): Changed from struct parser_control to typedef (for
24221         consistency).  All uses changed.
24222
24223         (tID): Removed; not used.
24224         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
24225
24226 2000-02-14  Paul Eggert  <eggert@twinsun.com>
24227
24228         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
24229         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
24230
24231 2000-02-12  Jim Meyering  <meyering@lucent.com>
24232
24233         * lib/userspec.c (ISDIGIT): Define it.
24234         (isdigit): Remove definition.
24235         (is_number): Use ISDIGIT, not isdigit.
24236         <libintl.h>: Include.
24237         (_ and N_): Define.
24238         (parse_user_spec): Mark translatable strings.
24239
24240 2000-02-10  Jim Meyering  <meyering@lucent.com>
24241
24242         With these changes, nanosleep.[ch] are finally enough like the other
24243         lib/* replacement files to compile on a few more losing systems.
24244
24245         * lib/nanosleep.h: Don't include config.h.
24246         Remove prototype from declaration of nanosleep.
24247         (PARAMS): Remove now-unneeded definition.
24248         * lib/nanosleep.c: #undef nanosleep.
24249         (rpl_nanosleep): Rename from nanosleep.
24250
24251 2000-02-10  Jim Meyering  <meyering@lucent.com>
24252
24253         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
24254         gnu_nanosleep to rpl_nanosleep.
24255
24256 2000-02-09  Jim Meyering  <meyering@lucent.com>
24257
24258         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
24259         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
24260
24261 2000-02-08  Akim Demaille  <akim@epita.fr>
24262
24263         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
24264         `[' and `]' and remove uses of `changequote'.
24265         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
24266         (AC_SYS_LARGEFILE): Likewise.
24267         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
24268         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
24269         of changequote.
24270         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
24271         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
24272         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
24273         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
24274
24275 2000-02-05  Jim Meyering  <meyering@lucent.com>
24276
24277         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
24278         Remove explicit use of AC_HEADER_TIME.  It is required by
24279         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
24280         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
24281         in autoconf whereby the expansion of the latter ended up preceding
24282         the expansion of its prerequisite, AC_HEADER_TIME.
24283         Reported by Volker Borchert.
24284
24285 2000-02-03  Jim Meyering  <meyering@lucent.com>
24286
24287         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
24288
24289 2000-02-03  Jim Meyering  <meyering@lucent.com>
24290
24291         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
24292         rather than with `#if HAVE_UTMPNAME'.
24293
24294 2000-02-02  Jim Meyering  <meyering@lucent.com>
24295
24296         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
24297         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
24298         Reported by Eli Zaretskii.
24299
24300 2000-02-01  Jim Meyering  <meyering@lucent.com>
24301
24302         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
24303
24304 2000-01-31  Jim Meyering  <meyering@lucent.com>
24305
24306         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
24307         functions.  Add the time.h and sys/time.h headers along with the
24308         AC_REQUIRE'ment of AC_HEADER_TIME.
24309
24310 2000-01-31  Jim Meyering  <meyering@lucent.com>
24311
24312         * lib/nanosleep.h (nanosleep): Guard declaration with
24313         `#if ! HAVE_DECL_NANOSLEEP'.
24314         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
24315         the declaration in that vendor's sys/timers.h.
24316         Reported by Christian Krackowizer.
24317
24318         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
24319         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
24320         (ISPRINT): Likewise.
24321         Reported by Tom Tromey.
24322
24323 2000-01-30  Jim Meyering  <meyering@lucent.com>
24324
24325         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
24326
24327         * m4/prereq.m4 (utmp_includes): Define.
24328         Check for ut_user and ut_name members in both struct utmpx
24329         and struct utmp.
24330
24331 2000-01-30  Jim Meyering  <meyering@lucent.com>
24332
24333         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
24334         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
24335         header files where only utmpx.ut_user is declared.
24336
24337         * lib/readutmp.h (UT_USER): Define.
24338
24339 2000-01-29  Jim Meyering  <meyering@lucent.com>
24340
24341         * m4/lib-check.m4: New file containing library-related checks from
24342         fileutils and sh-utils (textutils had none).
24343
24344 2000-01-28  Jim Meyering  <meyering@lucent.com>
24345
24346         * m4/perl.m4: Change format of warning message to look more like that
24347         from the missing script.  Suggestion from François Pinard.
24348
24349 2000-01-25  Jim Meyering  <meyering@lucent.com>
24350
24351         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
24352         well as time.h in the compile check.
24353         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
24354         Fix typo in cross-compiling case: s/yes/no/.
24355
24356 2000-01-23  Jim Meyering  <meyering@lucent.com>
24357
24358         * m4/jm-macros.m4: Move df-related tests here from
24359         fileutils/configure.in
24360
24361         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
24362         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
24363
24364         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
24365         s/space/ac_fsusage_space/.
24366         (jm_FILE_SYSTEM_USAGE): Take two parameters.
24367
24368         * m4/ftruncate.m4: New file (derived from part of
24369         fileutils/configure.in).
24370         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
24371         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
24372
24373         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
24374         AC_SUBST these here, rather than just in sh-util/configure.in, so
24375         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
24376         all the same.
24377         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
24378         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
24379         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
24380         (AC_SUBST(POW_LIBM)): Likewise.
24381         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
24382
24383 2000-01-23  Jim Meyering  <meyering@lucent.com>
24384
24385         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
24386         obstack.c.
24387
24388 2000-01-22  Jim Meyering  <meyering@lucent.com>
24389
24390         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
24391
24392         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
24393
24394         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
24395         configure.in
24396         (AC_CHECK_HEADERS): Likewise for sh-utils.
24397         (AC_CHECK_HEADERS): Likewise for textutils.
24398         Merge the three lists of headers.
24399
24400         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
24401         from fileutils' configure.in.
24402
24403         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
24404         code. Moved tests into their own function (_jm_DECL_HEADERS) in
24405         check-decl.m4.
24406
24407         * m4/check-decl.m4: Use #if rather than #ifdef.
24408         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
24409         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
24410         (_jm_DECL_HEADERS): Define new function.
24411         (jm_CHECK_DECLARATIONS): Require it.
24412
24413 2000-01-22  Jim Meyering  <meyering@lucent.com>
24414
24415         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
24416         [! HAVE_DECL_STRTOULL]: Declare strtoull.
24417         Required for some AIX systems.  Reported by Christian Krackowizer.
24418         [TESTING] (main): New function.
24419
24420         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
24421         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
24422         letters.
24423
24424         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
24425         iswprint.
24426
24427         * lib/strverscmp.c (ISDIGIT): Define.
24428         (strverscmp): Use ISDIGIT, not isdigit.
24429
24430 2000-01-19  Jim Meyering  <meyering@lucent.com>
24431
24432         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
24433         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
24434         defines `struct timespec' in <sys/time.h>
24435
24436         * m4/c-bs-a.m4: Remove uses of changequote altogether.
24437         Thanks to Akim for explaining.
24438
24439 2000-01-17  Paul Eggert  <eggert@twinsun.com>
24440
24441         * lib/nanosleep.c (nanosleep):
24442         Don't use SA_INTERRUPT to decide whether to call sigaction, as
24443         POSIX.1 doesn't require SA_INTERRUPT and some systems
24444         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
24445         it's been part of POSIX.1 since day 1 (in 1988).
24446
24447 2000-01-17  Jim Meyering  <meyering@lucent.com>
24448
24449         * lib/interlock: Remove unused file.  Reported by François Pinard.
24450
24451 2000-01-16  Paul Eggert  <eggert@twinsun.com>
24452
24453         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
24454         alert, backslash, formfeed, and vertical tab unnecessarily in
24455         shell quoting style.
24456
24457 2000-01-16  Jim Meyering  <meyering@lucent.com>
24458
24459         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
24460         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
24461         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
24462         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
24463
24464 2000-01-16  Jim Meyering  <meyering@lucent.com>
24465
24466         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
24467         because the latter didn't work.
24468
24469 2000-01-15  Jim Meyering  <meyering@lucent.com>
24470
24471         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
24472         (AC_REPLACE_FUNCS): Add memcpy and memset.
24473         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
24474         Add strpbrk.
24475         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
24476
24477 2000-01-12  Jim Meyering  <meyering@lucent.com>
24478
24479         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
24480         (jm_PREREQ): Use it.
24481         (jm_PREREQ_READUTMP): New macro.
24482         (jm_PREREQ): Use it.
24483
24484 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24485
24486         Quote multibyte characters correctly.
24487         * m4/c-bs-a.m4: New file.
24488         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
24489         (jm_PREREQ): Use it.
24490
24491 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24492
24493         * m4/uintmax_t.m4: Port to autoconf 2.13.
24494
24495 2000-01-08  Jim Meyering  <meyering@ascend.com>
24496
24497         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
24498         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
24499
24500 2000-01-04  Jim Meyering  <meyering@ascend.com>
24501
24502         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
24503         jm_STRUCT_DIRENT_D_TYPE.
24504         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
24505         jm_STRUCT_DIRENT_D_INO.
24506         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
24507         jm_STRUCT_UTIMBUF.
24508         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
24509         renamings.
24510         * m4/utime.m4: Likewise.
24511
24512         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
24513         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
24514
24515 2000-01-03  Paul Eggert  <eggert@twinsun.com>
24516
24517         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
24518         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
24519
24520 2000-01-02  Jim Meyering  <meyering@ascend.com>
24521
24522         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
24523         remember if this is necessary.
24524
24525 1999-12-26  Jim Meyering  <meyering@ascend.com>
24526
24527         * m4/jm-macros.m4: Use it here.
24528         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
24529
24530 1999-12-23  Jim Meyering  <meyering@ascend.com>
24531
24532         * m4/jm-macros.m4: Check for clock_gettime (moved from
24533         fileutils/configure.in)
24534         Check for gettimeofday.
24535
24536 1999-12-20  Jim Meyering  <meyering@ascend.com>
24537
24538         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
24539         autoconf-2.14a-1999-12-20.
24540
24541 1999-12-19  Jim Meyering  <meyering@ascend.com>
24542
24543         * m4/lstat-slash.m4: New file.
24544         * m4/jm-macros.m4: Use the new macro:
24545         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24546
24547 1999-12-07  Jim Meyering  <meyering@ascend.com>
24548
24549         * m4/perl.m4: Require that File::Compare be available, too.
24550         Too many systems seem to lack it.
24551
24552         * m4/strftime.m4: Add checks for most of the cpp macros tested in
24553         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
24554
24555 1999-11-18  Paul Eggert  <eggert@twinsun.com>
24556
24557         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
24558         problem with the QNX 4.25 shell, which doesn't propagate exit
24559         status of failed commands inside shell assignments.
24560
24561 1999-11-17  Jim Meyering  <meyering@ascend.com>
24562
24563         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
24564
24565 1999-11-07  Jim Meyering  <meyering@ascend.com>
24566
24567         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
24568
24569 1999-11-06  Jim Meyering  <meyering@ascend.com>
24570
24571         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
24572         * m4/jm-macros.m4 (jm_MACROS): Use it here.
24573
24574 1999-11-05  Jim Meyering  <meyering@ascend.com>
24575
24576         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
24577         configure.in of textutils, fileutils, and sh-utils into this one
24578         (shared between those packages) file.
24579         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
24580         AC_STRUCT_ST_BLKSIZE.
24581
24582 1999-11-03  Jim Meyering  <meyering@ascend.com>
24583
24584         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
24585         of AC_CHECK_TYPE checks includes unistd.h.
24586         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
24587         Suggestion from Akim Demaille.
24588
24589 1999-10-30  Jim Meyering  <meyering@ascend.com>
24590
24591         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
24592         m4-quoted string.
24593         * m4/ls-mntd-fs.m4: Likewise.
24594         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
24595         * m4/jm-winsz1.m4: Likewise.
24596
24597         * m4/const.m4: Remove file, since the fix made it into the experimental
24598         version of autoconf.
24599         * m4/mktime.m4: Likewise.
24600
24601         * m4/check-type.m4: Remove file, now that the latest version of
24602         AC_CHECK_TYPE takes a third arg to specify additional #includes.
24603
24604         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
24605         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
24606         AC_CHECK_TYPE.
24607
24608 1999-10-04  Jim Meyering  <meyering@ascend.com>
24609
24610         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
24611
24612 1999-09-22  Paul Eggert  <eggert@twinsun.com>
24613
24614         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
24615         2.95.1 bug with HP-UX 10.20.
24616
24617 1999-09-17  Jim Meyering  <meyering@ascend.com>
24618
24619         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
24620         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
24621         due to missing strdup (against sh-utils-2.0).
24622
24623 1999-08-29  Jim Meyering  <meyering@ascend.com>
24624
24625         * m4/jm-macros.m4: Require jm_BISON.
24626         * m4/bison.m4: New file.
24627
24628 1999-08-17  Paul Eggert  <eggert@twinsun.com>
24629
24630         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
24631         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
24632
24633 1999-08-05  Jim Meyering  <meyering@ascend.com>
24634
24635         * m4/getline.m4: Rename test file from conftestdata to conftest.data
24636         to avoid conflicts with `conftest' on 8+3 filesystems.
24637         Suggestion from Eli Zaretskii.
24638
24639 1999-08-04  Jim Meyering  <meyering@ascend.com>
24640
24641         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
24642         fileutils and sh-utils (textutils's getline test was inadequate).
24643         (AM_FUNC_GETLINE): Run this test.
24644         (AC_CHECK_FUNCS): Check for getdelim.
24645         Reported by Bob Proulx.
24646
24647 1999-08-02  Jim Meyering  <meyering@ascend.com>
24648
24649         * m4/jm-macros.m4: Add a comment.
24650
24651 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24652
24653         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
24654         <inttypes.h> defines strtoumax as a macro (and not as a
24655         function).
24656
24657 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24658
24659         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
24660         that we can shift, multiply and divide unsigned long long
24661         values; Ultrix cc can't do it.
24662
24663 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24664
24665         * m4/mktime.m4: New file, which is a preview of what should appear
24666         in the next public autoconf release.
24667
24668 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24669
24670         * m4/lfs.m4: Remove this file.
24671         * m4/largefile.m4: New file.  It contains the old contents of
24672         lfs.m4, except that all names with prefix AC_LFS have been
24673         changed to use the prefix AC_SYS_LARGEFILE instead, to be
24674         compatible with future autoconf versions.  Also, some minor m4
24675         quoting problems have been fixed.
24676
24677 1999-08-01  Paul Eggert  <eggert@twinsun.com>
24678
24679         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
24680         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
24681         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
24682         and simplify the shell code.
24683
24684 1999-08-01  Jim Meyering  <meyering@ascend.com>
24685
24686         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
24687         m4.
24688
24689 1999-07-20  Jim Meyering  <meyering@ascend.com>
24690
24691         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
24692
24693 1999-07-15  Jim Meyering  <meyering@ascend.com>
24694
24695         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
24696
24697 1999-05-22  Jim Meyering  <meyering@ascend.com>
24698
24699         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
24700
24701 1999-05-20  Jim Meyering  <meyering@ascend.com>
24702
24703         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
24704         Add a colon after each `then' in case $4 is empty.
24705
24706 1999-05-16  Jim Meyering  <meyering@ascend.com>
24707
24708         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
24709
24710 1999-05-10  Jim Meyering  <meyering@ascend.com>
24711
24712         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
24713
24714         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
24715         AC_FUNC_MKTIME.
24716
24717 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
24718
24719         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
24720
24721 1999-05-04  Paul Eggert  <eggert@twinsun.com>
24722
24723         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
24724         not CPPFLAGS, so that linking works correctly in IRIX.
24725
24726 1999-04-30  Paul Eggert  <eggert@twinsun.com>
24727
24728         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
24729
24730 1999-04-20  Paul Eggert  <eggert@twinsun.com>
24731
24732         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
24733         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
24734         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
24735         jm_AC_TYPE_UNSIGNED_LONG_LONG.
24736         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
24737
24738         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
24739
24740 1999-04-20  Jim Meyering  <meyering@ascend.com>
24741
24742         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
24743         AC_REPLACE xstroull if necessary.  From Paul Eggert.
24744         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
24745
24746 1999-04-18  Jim Meyering  <meyering@ascend.com>
24747
24748         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
24749         * m4/jm-macros.m4: Use it.
24750
24751 1999-04-06  Jim Meyering  <meyering@ascend.com>
24752
24753         * m4/strftime.m4: Remove test for %f.
24754
24755 1999-03-29  Jim Meyering  <meyering@ascend.com>
24756
24757         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
24758         superset of the AC_TYPE_* checks in the textutils, fileutils,
24759         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
24760         AC_TYPE_PID_T.
24761
24762 1999-03-28  Jim Meyering  <meyering@ascend.com>
24763
24764         * m4/jm-macros.m4: Define GNU_PACKAGE here.
24765         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
24766         replaced e.g., in the *.sh files of the sh-utils.
24767
24768 1999-03-20  Jim Meyering  <meyering@ascend.com>
24769
24770         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
24771         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
24772         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
24773
24774 1999-03-19  Jim Meyering  <meyering@ascend.com>
24775
24776         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
24777
24778 1999-03-12  Jim Meyering  <meyering@ascend.com>
24779
24780         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
24781
24782 1999-03-07  Jim Meyering  <meyering@ascend.com>
24783
24784         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
24785         declared.
24786
24787 1999-02-17  Jim Meyering  <meyering@ascend.com>
24788
24789         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
24790         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
24791
24792 1999-02-07  Jim Meyering  <meyering@ascend.com>
24793
24794         * m4/group-member.m4: New file -- extracted from sh-utils'
24795         configure.in.
24796
24797         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
24798         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
24799
24800 1999-02-06  Jim Meyering  <meyering@ascend.com>
24801
24802         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
24803         * m4/fnmatch.m4: Likewise.
24804         * m4/getgroups.m4: Likewise.
24805         * m4/lstat.m4: Likewise.
24806         * m4/malloc.m4: Likewise.
24807         * m4/putenv.m4: Likewise.
24808         * m4/realloc.m4: Likewise.
24809         * m4/regex.m4: Likewise.
24810         * m4/stat.m4: Likewise.
24811         * m4/strftime.m4: Likewise.
24812         Suggestion from Alain Magloire.
24813
24814         * m4/chown.m4: Use `.$ac_objext', not `.o'.
24815         * m4/fnmatch.m4: Likewise.
24816         * m4/getgroups.m4: Likewise.
24817         * m4/getline.m4: Likewise.
24818         * m4/lstat.m4: Likewise.
24819         * m4/malloc.m4: Likewise.
24820         * m4/memcmp.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/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
24829         an argument.
24830
24831         * m4/regex.m4: Add a run-time Test for proper operation of
24832         re_compile_pattern.
24833
24834 1999-01-31  Jim Meyering  <meyering@ascend.com>
24835
24836         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
24837
24838 1999-01-30  Jim Meyering  <meyering@ascend.com>
24839
24840         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
24841
24842         * m4/jm-mktime.m4: Make this a wrapper around the official
24843         AM_FUNC_MKTIME rather than my private copy, now that the official one
24844         is up to date.
24845         * m4/mktime.m4: Remove file.
24846
24847         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
24848         * m4/uptime.m4: Likewise.
24849         * m4/uintmax_t.m4: Likewise.
24850
24851 1999-01-28  Jim Meyering  <meyering@ascend.com>
24852
24853         * m4/jm-macros.m4: Use jm_AFS.
24854         * m4/afs.m4: New file (from fileutils' configure.in).
24855
24856         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
24857         * m4/chown.m4: Likewise.
24858         * m4/d-ino.m4: Likewise.
24859         * m4/d-type.m4: Likewise.
24860         * m4/fnmatch.m4: Likewise.
24861         * m4/getgroups.m4: Likewise.
24862         * m4/gettext.m4: Likewise.
24863         * m4/jm-mktime.m4: Likewise.
24864         * m4/jm-winsz2.m4: Likewise.
24865         * m4/lcmessage.m4: Likewise.
24866         * m4/ls-mntd-fs.m4: Likewise.
24867         * m4/malloc.m4: Likewise.
24868         * m4/memcmp.m4: Likewise.
24869         * m4/putenv.m4: Likewise.
24870         * m4/realloc.m4: Likewise.
24871         * m4/st_mtim.m4: Likewise.
24872         * m4/strftime.m4: Likewise.
24873
24874 1999-01-16  Jim Meyering  <meyering@ascend.com>
24875
24876         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
24877         (ARGMATCH_DIE_DECL): Define.
24878
24879 1999-01-12  Jim Meyering  <meyering@ascend.com>
24880
24881         * m4/Makefile.am.in: Rewrite to avoid using fmt.
24882         Reported by Lars Hecking.
24883
24884 1999-01-10  Jim Meyering  <meyering@ascend.com>
24885
24886         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
24887         gross kludge.
24888         * m4/inttypes_h.m4: Likewise.
24889         * m4/lstat.m4: Likewise.
24890         * m4/malloc.m4: Likewise.
24891         * m4/readdir.m4: Likewise.
24892         * m4/realloc.m4: Likewise.
24893         * m4/st_dm_mode.m4: Likewise.
24894         * m4/stat.m4: Likewise.
24895         * m4/utimbuf.m4: Likewise.
24896         * m4/utimes.m4: Likewise.
24897
24898         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
24899         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
24900         comments in config.h.in are meaningful.
24901
24902         * m4/jm-macros.m4: Require autoconf-2.13 here.
24903
24904         * m4/regex.m4: By default, don't use the included regex.c on systems
24905         with glibc 2.  Suggestion from Uli Drepper.
24906
24907 1999-01-02  Jim Meyering  <meyering@ascend.com>
24908
24909         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
24910
24911 1998-12-18  Jim Meyering  <meyering@ascend.com>
24912
24913         * m4/Makefile.am.in (Makefile.am): Simplify rule.
24914         Based on a suggestion from Lars Hecking.
24915
24916 1998-11-16  Paul Eggert  <eggert@twinsun.com>
24917
24918         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
24919
24920 1998-11-16  Jim Meyering  <meyering@ascend.com>
24921
24922         * m4/lfs.m4: Double-quote the `uname...` expression.
24923
24924 1998-11-14  Jim Meyering  <meyering@ascend.com>
24925
24926         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
24927         * m4/stat.m4: Likewise.
24928
24929 1998-11-03  Jim Meyering  <meyering@ascend.com>
24930
24931         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
24932         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
24933
24934 1998-10-18  Jim Meyering  <meyering@ascend.com>
24935
24936         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
24937
24938 1998-10-17  Jim Meyering  <meyering@ascend.com>
24939
24940         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
24941         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
24942         calls for those previously hard-coded headers.  Instead, take a new
24943         parameter.
24944         (jm_CHECK_DECLARATIONS): Reflect interface change.
24945         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
24946         (jm_CHECK_DECL_LOCALTIME_R): New macro.
24947
24948         * m4/mktime.m4: Test for spring-forward gap before long-running test.
24949
24950 1998-10-14  Jim Meyering  <meyering@ascend.com>
24951
24952         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
24953         instead of "TZ=America/Vancouver".  From Paul Eggert.
24954
24955 1998-10-11  Jim Meyering  <meyering@ascend.com>
24956
24957         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
24958         This adds a test for a recently added compatibility fix for mktime.c.
24959         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
24960
24961 1998-09-27  Jim Meyering  <meyering@ascend.com>
24962
24963         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
24964
24965         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
24966         ../configure.in, including a change from Gordon Matzigkeit to allow
24967         cross-compiling for the Hurd.
24968
24969         * m4/glibc.m4: New file/macro to test for the GNU C Library
24970         versions 1 and 2.  From Gordon Matzigkeit.
24971         Indent.
24972
24973 1998-09-21  Jim Meyering  <meyering@ascend.com>
24974
24975         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
24976
24977 1998-08-18  Paul Eggert  <eggert@twinsun.com>
24978
24979         Port nanosecond-resolution times to UnixWare 2.1.2 and
24980         pedantic Solaris 2.6.
24981
24982         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
24983         AC_STRUCT_ST_MTIM.
24984         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
24985         Generate name of ns member, instead of just 1 or undef.
24986         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
24987
24988 1998-08-15  Jim Meyering  <meyering@ascend.com>
24989
24990         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
24991         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
24992         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
24993         instead of jm_TYPE_SSIZE_T.
24994
24995 1998-08-12  Jim Meyering  <meyering@ascend.com>
24996
24997         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
24998
24999 1998-08-02  Jim Meyering  <meyering@ascend.com>
25000
25001         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
25002         in acconfig.h manually.
25003
25004 1998-07-31  Paul Eggert  <eggert@twinsun.com>
25005
25006         * m4/st_mtim.m4: New file.
25007
25008 1998-07-28  Jim Meyering  <meyering@ascend.com>
25009
25010         * m4/utimes.m4: Undef stat.
25011
25012 1998-07-25  Jim Meyering  <meyering@ascend.com>
25013
25014         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
25015         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
25016
25017 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
25018
25019         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
25020         uid and gid actually remain unchanged.
25021
25022 1998-07-07  Jim Meyering  <meyering@ascend.com>
25023
25024         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
25025
25026 1998-07-04  Jim Meyering  <meyering@ascend.com>
25027
25028         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
25029         to prove that this macro can be used in packages without regex.c.
25030
25031 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
25032
25033         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
25034         is to be used.
25035
25036 1998-07-03  Jim Meyering  <meyering@ascend.com>
25037
25038         * m4/gettext.m4: Add -lintl if it's found to be necessary.
25039
25040         * m4/gettext.m4: New file -- from gettext-0.10.35.
25041         * m4/lcmessage.m4: Likewise.
25042         * m4/progtest.m4: Likewise.
25043
25044         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
25045         * m4/jm-macros.m4: Require the new macro.
25046
25047 1998-06-29  Jim Meyering  <meyering@ascend.com>
25048
25049         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
25050         for the definition of NGROUPS (used in a system header included
25051         by sys/mount.h).
25052
25053 1998-06-28  Jim Meyering  <meyering@ascend.com>
25054
25055         * m4/ls-mntd-fs.m4: New file.
25056         * m4/fstypename.m4: New file.
25057
25058         * m4/jm-macros.m4: Require the new macro.
25059         * m4/jm-glibc-io.m4: New file.
25060
25061 1998-05-19  Jim Meyering  <meyering@ascend.com>
25062
25063         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
25064         * m4/lchown.m4: New file.
25065
25066         * m4/Makefile.am.in: New file.
25067         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
25068
25069 1998-05-14  Jim Meyering  <meyering@ascend.com>
25070
25071         * m4/Makefile.am (EXTRA_DIST): Add them.
25072         * m4/jm-macros.m4: New file.
25073         * m4/utimbuf.m4: New file.
25074
25075 1998-05-12  Jim Meyering  <meyering@ascend.com>
25076
25077         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
25078
25079 1998-05-11  Jim Meyering  <meyering@ascend.com>
25080
25081         * m4/isc-posix.m4: New file.
25082
25083 1998-05-10  Jim Meyering  <meyering@ascend.com>
25084
25085         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
25086
25087 1998-05-09  Jim Meyering  <meyering@ascend.com>
25088
25089         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
25090         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
25091         with automake.
25092
25093         * m4/ssize_t.m4: New file.
25094         * m4/mktime.m4: Remove file -- the new automake has this now.
25095
25096 1998-04-26  Jim Meyering  <meyering@ascend.com>
25097
25098         * m4/assert.m4: New file.
25099         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
25100
25101 1998-04-05  Jim Meyering  <meyering@ascend.com>
25102
25103         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
25104         (jm_PREREQ): Use it here.
25105
25106 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
25107
25108         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
25109         in acconfig.h.
25110
25111 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
25112
25113         * m4/prereq.m4: New file.
25114         * m4/error.m4: New file.
25115         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
25116
25117 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
25118
25119         * m4/getline.m4: Don't set am_cv_func_working_getline before the
25120         cache-check for the same variable -- that defeated the purpose of
25121         the test; the test program was never run.  This was a problem only
25122         on systems with losing getline functions -- HP-UX 10.20 is one.
25123         Reported by Bjorn Helgaas.
25124
25125 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
25126
25127         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
25128
25129 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
25130
25131         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
25132
25133         * m4/const.m4: New file.  Use an initializer in this declaration
25134         typedef int charset[2]; const charset x;
25135         Reported by Bob Glickstein.
25136
25137 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
25138
25139         * m4/chown.m4: Fix reversed types on -1 args to chown.
25140         From Kaveh Ghazi.
25141
25142 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
25143
25144         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
25145         Add lseek and memchr.
25146
25147         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
25148         T.E.Dickey <dickey@clark.net> said that some older preprocessors
25149         have a 20-character limit on names.
25150
25151 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
25152
25153         * m4/inttypes_h.m4: New file.
25154         * m4/uintmax_t.m4: New file.
25155         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
25156
25157 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
25158   Free Software Foundation, Inc.
25159 Copying and distribution of this file, with or without modification,
25160 are permitted provided the copyright notice and this notice are preserved.